From 13ac8c9c67d342d6b79b205cd07bfa98cbcee2a3 Mon Sep 17 00:00:00 2001 From: zyx0814 Date: Tue, 4 Sep 2018 12:03:12 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=88=B02.02=E7=89=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .htaccess | 4 +- UPDATE.md | 22 +- admin/appmarket/cloudappmarket.php | 23 - admin/appmarket/cp.php | 11 +- admin/appmarket/dzz_app_appmarket.xml | 3 +- admin/appmarket/edit.php | 1 + admin/appmarket/extopen.php | 44 +- admin/appmarket/install_app_ajax.php | 36 +- admin/appmarket/template/cloudappmarket.htm | 2 +- admin/appmarket/template/extopen.htm | 2 +- admin/appmarket/template/import.htm | 2 +- admin/appmarket/template/index.htm | 5 +- admin/appmarket/upgrade.php | 35 + admin/appmarket/upgrade_app_ajax.php | 40 +- admin/dzzofficefiles.md5 | 397 +- admin/filemanage/index.php | 272 +- admin/filemanage/language/zh-cn/lang.php | 4 +- admin/filemanage/template/list.htm | 22 +- admin/function/function_admin.php | 13 +- admin/member/template/profile.htm | 12 +- admin/member/template/profileset.htm | 12 +- admin/member/template/profileset_edit.htm | 22 +- admin/orguser/import.php | 4 +- admin/orguser/scripts/orguser.js | 4 + admin/orguser/template/adduser.htm | 3 +- admin/orguser/template/edituser.htm | 3 +- admin/orguser/template/import_guide.htm | 2 +- admin/setting/index.php | 15 +- admin/setting/template/main.htm | 2 +- admin/system/database.php | 23 +- config/config_default.php | 27 +- core/api/wopi/wopi.php | 28 +- core/class/class_core.php | 7 +- core/class/class_image.php | 7 +- core/class/class_xml.php | 48 +- core/class/dzz/dzz_app.php | 1041 +-- core/class/dzz/dzz_io.php | 1 + core/class/helper/helper_browser.php | 11 +- core/class/helper/helper_security.php | 2 +- core/class/io/io_baiduPCS.php | 8 +- core/class/io/io_dzz.php | 40 +- core/class/memory/memory_driver_redis.php | 4 + core/class/perm/perm_check.php | 54 +- core/class/table/table_comment_attach.php | 17 +- core/class/table/table_folder.php | 178 +- core/class/table/table_hooks.php | 15 +- core/class/table/table_local_router.php | 8 +- core/class/table/table_organization.php | 18 +- core/class/table/table_organization_admin.php | 11 +- core/class/table/table_organization_user.php | 2 +- core/class/table/table_resources.php | 323 +- core/class/table/table_resources_attr.php | 21 +- core/class/table/table_resources_path.php | 75 +- core/class/table/table_resources_recyle.php | 16 - core/class/table/table_resources_version.php | 50 +- core/class/table/table_user.php | 30 +- core/class/table/table_user_setting.php | 4 +- core/coreBase.php | 2 +- core/core_version.php | 4 +- .../cron_clean_copys0_attachment_by_month.php | 6 +- core/cron/cron_database_backup.php | 4 +- core/function/function_core.php | 98 +- core/language/zh-cn/lang.php | 124 +- .../template/default/common/commer_header.htm | 4 +- .../default/common/header_simple_start.htm | 2 +- core/template/default/common/mobile_about.htm | 2 +- .../default/common/mobile_simple_process.htm | 5 + .../default/common/mobile_simple_start.htm | 6 +- dzz/attach/saveto.php | 4 +- dzz/comment/ajax.php | 2 +- dzz/comment/images/comment.css | 13 +- dzz/comment/saveto.php | 23 +- dzz/comment/scripts/comment.js | 52 +- dzz/comment/template/publish_form.htm | 2 +- dzz/comment/template/reply_form.htm | 2 +- dzz/comment/template/reply_item.htm | 6 +- dzz/comment/template/thread_item.htm | 4 +- dzz/config/config-sample.php | 4 +- dzz/images/default/icodefault.png | Bin 8327 -> 2758 bytes dzz/images/extimg/gif.png | Bin 0 -> 11302 bytes dzz/images/extimg/jpeg.png | Bin 0 -> 11302 bytes dzz/images/extimg/jpg.png | Bin 0 -> 11302 bytes dzz/images/extimg/png.png | Bin 0 -> 11302 bytes dzz/images/newfile/excel.xlsx | Bin 9888 -> 11077 bytes dzz/images/newfile/ppt.pptx | Bin 30199 -> 29734 bytes dzz/index/index.php | 1 + dzz/language/zh-cn/lang.php | 17 +- dzz/shares/images/mobile/password.css | 3 + dzz/shares/index.php | 1 + dzz/shares/save.php | 7 +- dzz/shares/scripts/mobile/share.js | 1 + dzz/shares/template/header_left.htm | 2 +- dzz/shares/template/list.htm | 18 +- dzz/shares/template/mobile/list.htm | 9 +- dzz/shares/template/mobile/list_item.htm | 2 +- dzz/shares/template/mobile/share_password.htm | 16 +- dzz/shares/template/password.htm | 31 +- dzz/system/css/mobile/mobile_member.css | 1 + dzz/system/css/select-file.css | 12 +- dzz/system/css/selfilewindow.css | 4 +- dzz/system/fileselection.php | 8 +- dzz/system/fileselection/explorerfile.php | 192 +- dzz/system/fileselection/file.php | 9 - dzz/system/fileselection/json.php | 3 + dzz/system/fileselection/listtree.php | 2 +- dzz/system/filewindow.php | 9 +- .../function/function_filerouterule.php | 7 + dzz/system/mobilefileselection/file.php | 18 +- dzz/system/orgtree.php | 14 +- dzz/system/positionlist.php | 5 +- dzz/system/scripts/_perm.js | 3 +- dzz/system/scripts/contextmenu.js | 4 + dzz/system/scripts/explorer.js | 85 +- dzz/system/scripts/mobile/file_keep.js | 20 +- dzz/system/scripts/select-file.js | 2 +- dzz/system/scripts/selorguser.js | 9 + dzz/system/selposition.php | 6 +- dzz/system/template/filelist.htm | 20 +- dzz/system/template/fileselection/content.htm | 2 +- dzz/system/template/fileselection/index.htm | 111 +- .../template/fileselection/listcontent.htm | 26 +- .../template/mobilefileselection/filelist.htm | 8 +- .../mobilefileselection/footer_menu.htm | 2 +- .../template/mobilefileselection/group.htm | 11 +- .../template/mobilefileselection/index.htm | 116 +- .../template/mobilefileselection/search.htm | 17 +- .../mobilefileselection/searchfile.htm | 2 +- dzz/system/template/orgtree.htm | 3 +- dzz/system/template/positionlist.htm | 174 +- dzz/system/template/selectfile.htm | 1 - dzz/system/template/selorguser.htm | 10 +- dzz/system/ueditor/lang/zh-cn/zh-cn.js | 6 +- dzz/system/ueditor/ueditor.all.js | 23 +- dzz/test/admin.php | 38 + dzz/test/cache/cache_test.php | 10 + dzz/test/class/class_Chareset.php | 41 + dzz/test/class/table/table_test.php | 31 + dzz/test/classes/testone.php | 18 + dzz/test/config/config.php | 5 + dzz/test/cron/cron_test.php | 13 + dzz/test/css/test.css | 7 + dzz/test/disable.php | 10 + dzz/test/dzz_app_test.xml | 133 + dzz/test/enable.php | 10 + dzz/test/function/function_test.php | 15 + dzz/test/images/logo.png | Bin 0 -> 4965 bytes dzz/test/index.php | 43 + dzz/test/install.php | 27 + dzz/test/language/en-us/lang.php | 22 + dzz/test/language/zh-cn/lang.php | 22 + dzz/test/template/admin.htm | 121 + dzz/test/template/header_left.htm | 8 + dzz/test/template/index.htm | 19 + dzz/test/template/left.htm | 5 + dzz/test/uninstall.php | 24 + dzz/test/upgrade.php | 10 + htaccess_default.txt | 3 +- install/data/install.sql | 28 +- install/data/install_data.sql | 5 +- oauth.php | 2 +- static/css/app_manage.css | 5 - static/css/common.css | 33 +- static/dzzicon/fonts/dzz.eot | Bin 29164 -> 29876 bytes static/dzzicon/fonts/dzz.svg | 5 + static/dzzicon/fonts/dzz.ttf | Bin 29000 -> 29712 bytes static/dzzicon/fonts/dzz.woff | Bin 29076 -> 29788 bytes static/dzzicon/icon.css | 25 +- .../jquery_file_upload/jquery.fileupload.js | 13 +- static/jquery_weui/js/appevent.js | 214 + static/jquery_weui/js/jquery-weui.js | 6441 ++++++++++++++ static/js/common.js | 16 +- static/js/input_field.js | 57 +- static/js/jquery.leftDrager.js | 156 +- static/swiper/css/swiper.min.css | 12 + static/swiper/js/swiper.esm.bundle.js | 6622 ++++++++++++++ static/swiper/js/swiper.esm.js | 6605 ++++++++++++++ static/swiper/js/swiper.js | 7637 +++++++++++++++++ static/swiper/js/swiper.min.js | 13 + static/swiper/js/swiper.min.js.map | 1 + user/config/config.php | 2 +- user/register/classes/regcommon.php | 2 +- 181 files changed, 30981 insertions(+), 2056 deletions(-) create mode 100644 admin/appmarket/upgrade.php create mode 100644 core/template/default/common/mobile_simple_process.htm create mode 100644 dzz/images/extimg/gif.png create mode 100644 dzz/images/extimg/jpeg.png create mode 100644 dzz/images/extimg/jpg.png create mode 100644 dzz/images/extimg/png.png create mode 100644 dzz/test/admin.php create mode 100644 dzz/test/cache/cache_test.php create mode 100644 dzz/test/class/class_Chareset.php create mode 100644 dzz/test/class/table/table_test.php create mode 100644 dzz/test/classes/testone.php create mode 100644 dzz/test/config/config.php create mode 100644 dzz/test/cron/cron_test.php create mode 100644 dzz/test/css/test.css create mode 100644 dzz/test/disable.php create mode 100644 dzz/test/dzz_app_test.xml create mode 100644 dzz/test/enable.php create mode 100644 dzz/test/function/function_test.php create mode 100644 dzz/test/images/logo.png create mode 100644 dzz/test/index.php create mode 100644 dzz/test/install.php create mode 100644 dzz/test/language/en-us/lang.php create mode 100644 dzz/test/language/zh-cn/lang.php create mode 100644 dzz/test/template/admin.htm create mode 100644 dzz/test/template/header_left.htm create mode 100644 dzz/test/template/index.htm create mode 100644 dzz/test/template/left.htm create mode 100644 dzz/test/uninstall.php create mode 100644 dzz/test/upgrade.php create mode 100644 static/jquery_weui/js/appevent.js create mode 100644 static/jquery_weui/js/jquery-weui.js create mode 100644 static/swiper/css/swiper.min.css create mode 100644 static/swiper/js/swiper.esm.bundle.js create mode 100644 static/swiper/js/swiper.esm.js create mode 100644 static/swiper/js/swiper.js create mode 100644 static/swiper/js/swiper.min.js create mode 100644 static/swiper/js/swiper.min.js.map diff --git a/.htaccess b/.htaccess index cac7a10..aa4e454 100644 --- a/.htaccess +++ b/.htaccess @@ -3,11 +3,9 @@ RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f - RewriteRule ^wopi\/files\/(\w+)\/contents(.*)$ core/api/wopi/index.php?action=contents&path=$1&$2 [QSA,PT,L] RewriteRule ^wopi\/files\/(\w+)\/(lock|unlock)(.*)$ core/api/wopi/index.php?action=$2&path=$1&$3 [QSA,PT,L] RewriteRule ^wopi\/files\/(\w+)(.*)$ core/api/wopi/index.php?path=$1&$2 [QSA,PT,L] RewriteRule ^wopi\/files\/(.*)$ core/api/wopi/index.php?$1 [QSA,PT,L] - - + RewriteRule ^dingredirect\/(\w+)$ index.php?mod=dingtalk&op=dingredirect&url=$1 [QSA,PT,L] \ No newline at end of file diff --git a/UPDATE.md b/UPDATE.md index 38412a8..9cb9c3d 100644 --- a/UPDATE.md +++ b/UPDATE.md @@ -8,27 +8,11 @@ ### DzzOffice2.01主要更新内容 -1. 增加 云设置和管理 ,支持阿里云存储、七牛云存储、FTP/SFTP、本地磁盘等存储方式; +1. 缓存优化,开启内存huanc(如:memcached等)会显著提高效率; -2. 增加 用户资料管理 ,支持自定义用户资料项,资料审核、认证和审核; +2. 应用市场应用名称旁显示版本; -3. 修改应用市场应用在线安装方式,提高应用下载速度; - -4. 增加伪静态支持,可以通过应用“伪静态管理”灵活配置各个页面的伪静态规则; - -5. 机构和用户管理 优化添加部门管理员的体验; - -6. 导入导出用户功能优化调整; - -7. 部分页面移动端适配; - -8. 增加首次安装引导页,引导管理员首次能正确配置系统; - -9. 开放讨论板应用(可在应用市场内在线安装); - -10. 开放任务板应用(可在应用市场内在线安装); - -11. 其他功能完善、及beta版反馈问题的修复; +3. 其他功能完善、及已知问题的修复; ### DzzOffice在线更新方法 diff --git a/admin/appmarket/cloudappmarket.php b/admin/appmarket/cloudappmarket.php index b0e500c..abf2b0a 100644 --- a/admin/appmarket/cloudappmarket.php +++ b/admin/appmarket/cloudappmarket.php @@ -67,28 +67,5 @@ function curlcloudappmarket( $url="",$post_data="", $token="" ){ return($response); } -function striplinks($document) -{ - preg_match_all("'<\s*a\s.*?href\s*=\s* # find ]+)) # if quote found, match up to next matching - # quote, otherwise match up to next space - 'isx", $document, $links); - - // catenate the non-empty matches from the conditional subpattern - - while (list($key, $val) = each($links[2])) { - if (!empty($val)) - $match[] = $val; - } - - while (list($key, $val) = each($links[3])) { - if (!empty($val)) - $match[] = $val; - } - - // return the links - return $match; -} ?> diff --git a/admin/appmarket/cp.php b/admin/appmarket/cp.php index 583d328..8fb95a1 100644 --- a/admin/appmarket/cp.php +++ b/admin/appmarket/cp.php @@ -24,7 +24,7 @@ if ($do == 'export') {//应用导出 $app['appico'] = imagetobase64($app['appico']); $app['extra'] = array(); $appid=$app['appid']; - unset($app['mid']); + //unset($app['mid']); unset($app['appid']); unset($app['orgid']); unset($app['available']); @@ -58,8 +58,10 @@ if ($do == 'export') {//应用导出 $apparray['app'] = $app; $apparray['version'] = strip_tags($_G['setting']['version']); $hooks=array(); - foreach(DB::fetch_all("SELECT name,addons FROM %t where `status`='1' and app_market_id='".$appid."' ORDER BY priority",array('hooks')) as $value) { - $hooks[$value['name']]=$value['addons']; + + foreach(DB::fetch_all("SELECT * FROM %t where `status`='1' and app_market_id='".$appid."' ORDER BY priority",array('hooks')) as $value) { + $hooks[$value['name']]=$value['addons']; + $hooks['_attributes'][$value['name']]=array("priority"=>$value['priority'],'description'=>$value['description']); } if($hooks) $apparray['hooks']=$hooks; @@ -71,8 +73,7 @@ elseif ($do == 'import') {//导入应用 if (!submitcheck('importsubmit')) { include template('import'); } else { - $apparray = getimportdata('Dzz! app'); - + $apparray = getimportdata('Dzz! app'); if ($apparray['app']['identifier']) { if(empty($apparray['app']['app_path'])) $apparray['app']['app_path']='dzz'; if (!is_dir(DZZ_ROOT . './'.$apparray['app']['app_path'].'/' . $apparray['app']['identifier'])) { diff --git a/admin/appmarket/dzz_app_appmarket.xml b/admin/appmarket/dzz_app_appmarket.xml index c51a52b..89717c3 100644 --- a/admin/appmarket/dzz_app_appmarket.xml +++ b/admin/appmarket/dzz_app_appmarket.xml @@ -1275,8 +1275,9 @@ QmCC - + + diff --git a/admin/appmarket/edit.php b/admin/appmarket/edit.php index b884a27..e6b385d 100644 --- a/admin/appmarket/edit.php +++ b/admin/appmarket/edit.php @@ -100,6 +100,7 @@ if (submitcheck('appsubmit')) { $setarr['dateline'] = $_G['timestamp']; if (!$setarr['appico']) $setarr['appico'] = 'dzz/images/default/icodefault.png'; + $setarr["version"]="1.0";//默认版本1.0开始 $appid = C::t('app_market') -> insert($setarr, 1); } //处理标签 diff --git a/admin/appmarket/extopen.php b/admin/appmarket/extopen.php index 7ff212e..ab763eb 100644 --- a/admin/appmarket/extopen.php +++ b/admin/appmarket/extopen.php @@ -32,38 +32,43 @@ if ( $do =="setdefault" ) { } error(lang('set_default').lang('failure')); } - +$sql_app="`available`>0"; +$param_app=array('app_market'); +$sql = '1'; +$param=array('app_open'); +if(preg_match("/[a-zA-Z0-9]{1,10}/i",$_GET['ext'])){ + $ext = trim($_GET['ext']); + $sql .= " and `ext` = %s"; + $param[]=$ext; +}elseif($_GET['ext']){ + $appname=trim($_GET['ext']); + $sql_app.=' and appname LIke %s'; + $param_app[]='%'.$appname.'%'; +} $ext = trim($_GET['ext']); $appid = intval($_GET['appid']); -$orderby = trim($_GET['s']); + $page = empty($_GET['page']) ? 1 : intval($_GET['page']); $perpage = 20; $gets = array('mod' => 'appmarket', 'op' => 'extopen', 'ext' => $ext, 'appid' => $appid); $theurl = BASESCRIPT . "?" . url_implode($gets); $refer = urlencode($theurl . '&page=' . $page); -if ($orderby) - $order = 'ORDER BY ' . $orderby; -else - $order = 'order by disp DESC'; + $start = ($page - 1) * $perpage; $apps = array(); -$sql = '1'; -$param=array('app_open'); + if ($appid) { - $sql .= " and `appid` = '{$appid}'"; - $map["appid"]=$appid; + $sql .= " and `appid` = %d"; $param[]=$appid; -} elseif ($ext) { - $sql .= " and `ext` = '{$ext}'"; - $map["ext"]=$ext; - $param[]=$ext; -} +} -$count = DB::result_first("select COUNT(*) from %t where 1",array('app_market'));//C::tp_t("app_open")->where($map)->count(); +$count = DB::result_first("select COUNT(*) from %t where $sql_app ",$param_app); if($count){ - $appdatas =DB::fetch_all("select appid,appico,appname,appurl from %t where 1",array('app_market'),'appid');// C::tp_t('app_market')->getField("appid,appico,appname,appurl"); - $list = DB::fetch_all("select * from %t where $sql ORDER BY appid DESC",$param);//C::tp_t("app_open")->where($map)->order("appid desc")->select(); + $appdatas =DB::fetch_all("select appid,appico,appname,appurl from %t where $sql_app ",$param_app,'appid'); + $sql .= ' and `appid` IN(%n)'; + $param[] = array_keys($appdatas); + $list = DB::fetch_all("select * from %t where $sql ORDER BY ext DESC",$param); $newlist=array(); foreach($list as $k=>$v ){ $appdata = $appdatas[$v["appid"]]; @@ -78,6 +83,7 @@ if($count){ } $multi = multi($count, $perpage, $page, $theurl ); //根据分页截取数组 +ksort($newlist,SORT_STRING ); $list = array_slice($newlist,$start,$perpage); foreach($list as $k=>$nlist){ $sort = array( @@ -95,6 +101,6 @@ foreach($list as $k=>$nlist){ } $list[$k]=$nlist; } -// print_r($list);exit; +//print_r($list);exit; include template('extopen'); ?> diff --git a/admin/appmarket/install_app_ajax.php b/admin/appmarket/install_app_ajax.php index 578fd8e..48495fe 100644 --- a/admin/appmarket/install_app_ajax.php +++ b/admin/appmarket/install_app_ajax.php @@ -51,9 +51,9 @@ if ($operation == 'check_install' ) {//根据appid检查app应用是否需要更 $return["msg"]=lang('app_upgrade_mysqlversion_error', array('version' => $baseinfo['mysqlversion'])); exit(json_encode($return));//不需要安装 } - - $appinfo = DB::result_first("select COUNT(*) from %t where mid=%d",array('app_market',$baseinfo['mid']));//C::tp_t('app_market')->where($map)->find(); $time =dgmdate(TIMESTAMP,'Ymd'); + + $appinfo = DB::result_first("select COUNT(*) from %t where mid=%d",array('app_market',$baseinfo['mid']));//C::tp_t('app_market')->where($map)->find(); $return=array( "url"=>ADMINSCRIPT .'?mod='.MOD_NAME.'&op=install_app_ajax', "status"=>1, @@ -61,14 +61,40 @@ if ($operation == 'check_install' ) {//根据appid检查app应用是否需要更 "second"=>1, "msg"=>lang("app_upgrade_check_is_install") ); - if( $appinfo ){ + //start 处理检查是否已有该目录 + $isinstall=0; + $app_folder=DZZ_ROOT.'./'.$baseinfo['app_path'].'/'.$baseinfo['identifier']; + if( is_dir($app_folder) ){ + $isinstall=1; + $xmlfile = 'dzz_app_' . $baseinfo['identifier'] . '.xml'; + $importfile = $app_folder . '/' . $xmlfile; + if ( file_exists($importfile) ) { + $importtxt = @implode('', file($importfile)); + $apparray = getimportdata('Dzz! app', 0, 0, $importtxt); + $mid = isset($apparray['app']['mid'])?intval($apparray['app']['mid']):0; + if( $mid==$baseinfo['mid'] ){ + $isinstall=0; + } + } + } + //end处理检查是否已有该目录 + + if( $appinfo || $isinstall){ $return["status"]=0; - $return["msg"]= lang("app_upgrade_installed"); + if($appinfo){ + $return["msg"]= lang("app_upgrade_installed"); + }else{ + $return["msg"]= lang( $baseinfo["app_path"]."/".$baseinfo["identifier"]." 目录已存在,请重命名该目录或移除,防止重复或覆盖" ); + } /*if( $appinfo["mid"]==0 ){ $return["msg"]= lang("app_upgrade_installed_local"); }*/ exit(json_encode($return));//不需要安装 } + + //删除安装临时文件 + $temp_download=DZZ_ROOT.'./data/update/app/'.$baseinfo['app_path'].'/'.$baseinfo['identifier']; + removedirectory($temp_download); exit(json_encode($return));//未安装 } elseif($operation == 'upgrade' ){ @@ -250,7 +276,7 @@ elseif($operation == 'cross' || $operation == 'patch'){ exit(json_encode($return)); exit; } - elseif($step==4){ + elseif($step==4){ $return["percent"]=80; $return["second"]=1; $return["msg"]= lang("app_upgrade_installing"); diff --git a/admin/appmarket/template/cloudappmarket.htm b/admin/appmarket/template/cloudappmarket.htm index f0c79fd..ba41048 100644 --- a/admin/appmarket/template/cloudappmarket.htm +++ b/admin/appmarket/template/cloudappmarket.htm @@ -121,7 +121,7 @@
-

$value[name]

+

$value[name] $value[version]

{eval echo $value[desc_short]?$value[desc_short]:lang('none');}
diff --git a/admin/appmarket/template/extopen.htm b/admin/appmarket/template/extopen.htm index 2d795a1..513af2e 100644 --- a/admin/appmarket/template/extopen.htm +++ b/admin/appmarket/template/extopen.htm @@ -50,7 +50,7 @@ {lang default} - {lang application_name} + {lang application_name} diff --git a/admin/appmarket/template/import.htm b/admin/appmarket/template/import.htm index 2278787..03418a6 100644 --- a/admin/appmarket/template/import.htm +++ b/admin/appmarket/template/import.htm @@ -21,7 +21,7 @@
- +
+ diff --git a/admin/appmarket/template/index.htm b/admin/appmarket/template/index.htm index eecf77c..bfe05a1 100644 --- a/admin/appmarket/template/index.htm +++ b/admin/appmarket/template/index.htm @@ -162,9 +162,10 @@ $value[appname] $value[appname] - + + $value[version]

-
{eval echo $value['appdesc']?$value['appdesc']:lang('none');}
+
{eval echo $value['appdesc']?$value['appdesc']:lang('none');}
$value[vendor] diff --git a/admin/appmarket/upgrade.php b/admin/appmarket/upgrade.php new file mode 100644 index 0000000..f3db523 --- /dev/null +++ b/admin/appmarket/upgrade.php @@ -0,0 +1,35 @@ +$value['version'], + "identifier"=>$value['identifier'], + "app_path"=>$value["app_path"] + ); + $json = $dzz_upgrade->curlcloudappmarket($url,$post_data); + $json = json_decode($json,true); + if( $json["status"]==1){ + $mid = $json["mid"]; + DB::update('app_market',array('mid'=>$mid),"appid=".$value["appid"]); + } + } +} + +$finish = true; diff --git a/admin/appmarket/upgrade_app_ajax.php b/admin/appmarket/upgrade_app_ajax.php index 376104a..4b797f2 100644 --- a/admin/appmarket/upgrade_app_ajax.php +++ b/admin/appmarket/upgrade_app_ajax.php @@ -33,7 +33,10 @@ if ($operation == 'check_upgrade' ) {//根据appid检查app应用是否需要更 "mid"=>$appinfo["mid"], "msg"=> lang("app_upgrade_check_need_update") ); - + //删除安装临时文件 + $temp_download=DZZ_ROOT.'./data/update/app/'.$appinfo['app_path'].'/'.$appinfo['identifier']; + removedirectory($temp_download); + if($appinfo["check_upgrade_time"]==$time){//今天已经检查过是否需要更新 if( $appinfo["upgrade_version"]!="" ){ $return["url"] = ADMINSCRIPT .'?mod=appmarket&op=upgrade_app_ajax&appid='.$appid; @@ -215,19 +218,29 @@ elseif($operation == 'cross' || $operation == 'patch'){ $upgradeinfo["latestversion"]= $upgradeinfo["version"]; //判断目录或标识发生变化 $upgradeinfo最新版本信息 - if( md5($upgradeinfo["app_path"].$upgradeinfo["identifier"])!= md5($appinfo["app_path"].$appinfo["identifier"])) { + if( md5($upgradeinfo["app_path"].$upgradeinfo["identifier"])!= md5($appinfo["app_path"].$appinfo["identifier"])) { + $upgradeinfo=getappidentifier($upgradeinfo); //获取并判断新标识名称 + //如果有新标识名称 抛出错误停止更新 + if( isset( $upgradeinfo["new_identifier"]) && $upgradeinfo["new_identifier"] ){ + $linkurl=ADMINSCRIPT.'?mod=appmarket&op=upgrade'; + $return["url"]=$linkurl; + $return["status"]=0; + $return["msg"]= lang( $upgradeinfo["app_path"]."/".$upgradeinfo["identifier"]." 目录已存在,请重命名该目录或移除,防止重复或覆盖" ); + exit(json_encode($return)); + } + //判断是否是路径不相等 if( $appinfo["app_path"]!=$upgradeinfo["app_path"]) { $appinfo["app_path"]=$upgradeinfo["app_path"]; } //版本判断 if( $appinfo["identifier"]!=$upgradeinfo["identifier"]) { - //如果新版本目录存在则 获取另外一个新版本标识名称 - $upgradeinfo=getappidentifier($upgradeinfo); + //如果新版本目录存在则 获取另外一个新版本标识名称 $appinfo["identifier"]=$upgradeinfo["identifier"]; + //禁止标识相同的直接修改 if( isset( $upgradeinfo["new_identifier"]) && $upgradeinfo["new_identifier"] ){ $appinfo["identifier"]=$upgradeinfo["new_identifier"]; $appinfo["new_identifier"]=$upgradeinfo["new_identifier"]; - } + } } } $appinfo["upgradeinfo"]=$upgradeinfo; @@ -341,10 +354,10 @@ elseif($operation == 'cross' || $operation == 'patch'){ //与本地文件对比过滤出更新文件 list($updatefilelist, $updatemd5filelist) = $dzz_upgrade->compare_basefile_bymd5($appinfo, $updatefilelist,$updatemd5filelist); $theurl = ADMINSCRIPT . '?mod=appmarket&op=upgrade_app_ajax&operation=' . $operation . '&appid=' .$appid. '&locale=' . $locale . '&charset=' . $charset; - if(empty($updatefilelist)) { - $return["status"]=0; - $return["msg"]= lang('app_upgrade_exchange_none', array('upgradeurl' => upgradeinformation_app(-9))); - exit(json_encode($return)); + if(empty($updatefilelist)) {//不存在修改的继续执行 + //$return["status"]=0; + //$return["msg"]= lang('app_upgrade_exchange_none', array('upgradeurl' => upgradeinformation_app(-9))); + //exit(json_encode($return)); } //end @@ -501,7 +514,7 @@ elseif($operation == 'cross' || $operation == 'patch'){ //保存对应的应用名及应用地址 if ( $appinfo['identifier']!=$upgradeinfo['identifier'] ) { - $apparray['app']['identifier']=$appinfo['new_identifier']; + $apparray['app']['identifier']=$appinfo['identifier'];//$appinfo['new_identifier']; $apparray['app']['appurl']= str_replace("mod=".$upgradeinfo['identifier'],"mod=".$appinfo['identifier'],$appinfo['app']['appurl']); $apparray['app']['appadminurl']= str_replace("mod=".$upgradeinfo['identifier'],"mod=".$appinfo['identifier'],$appinfo['app']['appadminurl']); $apparray['app']['noticeurl']= str_replace("mod=".$upgradeinfo['identifier'],"mod=".$appinfo['identifier'],$appinfo['app']['noticeurl']); @@ -515,7 +528,7 @@ elseif($operation == 'cross' || $operation == 'patch'){ writelog('otherlog', "更新应用 ".$apparray['app']['appname']); } - $linkurl = ADMINSCRIPT . '?mod=appmarket&op=upgrade_app_ajax&operation=' . $operation . '&appid=' .$appid. '&step=5&confirm=' . $confirm; + $linkurl = ADMINSCRIPT . '?mod=appmarket&op=upgrade_app_ajax&operation=' . $operation . '&appid=' .$_GET["appid"]. '&step=5&confirm=' . $confirm; $return["url"]=$linkurl; $return["percent"]=80; $return["second"]=300; @@ -548,7 +561,7 @@ elseif($operation == 'cross' || $operation == 'patch'){ "upgrade_version"=>"" ); - $re=C::tp_t('app_market')->where("appid=".$appid)->save( $map ); + $re=C::t('app_market')->update( $appid,$map); updatecache('setting'); $return["url"] = ADMINSCRIPT . '?mod=appmarket&op=upgrade_app_ajax&operation=check_upgrade&appid='.$appinfo["appid"]; @@ -582,6 +595,7 @@ elseif($operation == 'localupgrade' ){ $filename = $apparray['app']['extra']['upgradefile']; $toversion = $apparray['app']['version']; + $mid = isset($apparray['app']['mid'])?intval($apparray['app']['mid']):0; if (!empty($apparray['app']['extra']['upgradefile']) && preg_match('/^[\w\.]+$/', $apparray['app']['extra']['upgradefile'])) { $filename = $entrydir . '/' . $apparray['app']['extra']['upgradefile']; if (file_exists($filename)) { @@ -594,10 +608,12 @@ elseif($operation == 'localupgrade' ){ } if ($finish) { $map=array( + "mid"=>$mid, "version"=>$toversion, "upgrade_version"=>"", "check_upgrade_time"=>0 ); + $re=C::t('app_market')->update($appid,$map);//C::tp_t('app_market')->where("appid=".$appid)->save( $map ); } diff --git a/admin/dzzofficefiles.md5 b/admin/dzzofficefiles.md5 index 1c0f2e2..803122d 100644 --- a/admin/dzzofficefiles.md5 +++ b/admin/dzzofficefiles.md5 @@ -1,12 +1,12 @@ -f2ec4f7b30463be48394efaed8f4472a *./.htaccess +e7f995486e61c6a0331fdc7d6da0a9f3 *./.htaccess 6dc0d2a0a7e27ee9a16e0b58b15809f7 *admin/appmarket/appupgrade.php 919cce3cb400d46ce85b542ffb764296 *admin/appmarket/check_upgrade.php -35bd9c07707035a1e88ce978e04346e0 *admin/appmarket/cloudappmarket.php -5d86e09be09503ad5331cf27cdfc624f *admin/appmarket/cp.php +333764e38783fc4dc20f84f445c75628 *admin/appmarket/cloudappmarket.php +cfd91022f1d8473f0ae55adfc7c61d9a *admin/appmarket/cp.php 9e542e07bada661e3097f8509160cb1c *admin/appmarket/default.php -1d6268c36b00d94c8be2f8f5310a1d16 *admin/appmarket/dzz_app_appmarket.xml -446c61ea0c13a747621b0dd960d1ba3e *admin/appmarket/edit.php -5a13af4bbe0f55b2a1bebc34a57aef98 *admin/appmarket/extopen.php +8061b74142c60835d0f8631e4631bba9 *admin/appmarket/dzz_app_appmarket.xml +c09a74606e4fd866ecb43cea83f13249 *admin/appmarket/edit.php +c02a864576b81325c93e60a633e4952a *admin/appmarket/extopen.php 6c40db49559a5cdc2b42619de3c8d1cf *admin/appmarket/function/function_appmarket.php 36d68c254c1d919154bd013ec7c8abd8 *admin/appmarket/images/bg.gif a60a1301b066da3e2fdeaf35bb6f86a0 *admin/appmarket/images/bg.jpg @@ -17,18 +17,18 @@ a5ae57a33635c65da7a22c258ec8bf39 *admin/appmarket/images/market.css 338655a5d330e7af1ef36a314c689637 *admin/appmarket/images/new.gif ee7381a43181ed4e09c5e420181fde57 *admin/appmarket/import.php 013b8979b2806657ecf5de4d8abe8d5a *admin/appmarket/index.php -c204a5a0313b980f26bdaf871330fb8a *admin/appmarket/install_app_ajax.php +27b682f26f84a34fdb4eae6e1a0f182a *admin/appmarket/install_app_ajax.php 562280ddfeb6d3b9fa671beb3a387bd8 *admin/appmarket/language/zh-cn/lang.php 41dc4a9ba19963d98dc75b22f8017c27 *admin/appmarket/list.php 7e6274a1780df6ddeeb2a88b8bbadb2a *admin/appmarket/scripts/jquery-ui.js 2b8aa0083494a2dc6b9a226dc8987c2a *admin/appmarket/template/appdefault.htm -c70d7ece197b417792434e1c3535684f *admin/appmarket/template/cloudappmarket.htm +a3ce2c8467f92aef6d2c63aaf13e789f *admin/appmarket/template/cloudappmarket.htm 5e934bd1298d64175e148e2d3f130f0b *admin/appmarket/template/cross.htm 46621df70e5d1d89267810eba3976159 *admin/appmarket/template/edit.htm -1ab792046123a4c933182c1fdf591fd5 *admin/appmarket/template/extopen.htm +c5e919821ce09ea1085a65f6d9ebbd6f *admin/appmarket/template/extopen.htm 153f49ce00f40760da21bc477b0a412d *admin/appmarket/template/header_search.htm -65c121ca580d4d3b9642ab286d17391d *admin/appmarket/template/import.htm -5649601b2b034b080250a7407531f234 *admin/appmarket/template/index.htm +98410351626e851e2a74284df0b0aab9 *admin/appmarket/template/import.htm +3dc749c413e1074a747c43bbaede6aa7 *admin/appmarket/template/index.htm 0911a569d6130c5101dc68430b64eee3 *admin/appmarket/template/left.htm 4258ce637050f6b8ca9ff14db7e5dd0f *admin/appmarket/template/list.htm 071dd61005cc9be0bbb176656df632b6 *admin/appmarket/template/list_list_available.htm @@ -36,7 +36,8 @@ c70d7ece197b417792434e1c3535684f *admin/appmarket/template/cloudappmarket.htm b00ac089599fc47f9a454ad7ec99ca75 *admin/appmarket/template/list_list_upgrade.htm 69d3f752c254c5e02af95867abf0a465 *admin/appmarket/template/uninstall_confirm.htm bd591d7bd24f89f6002c07d50c001473 *admin/appmarket/template/upgrade.htm -a7086be3f472bce7370c65b79131638d *admin/appmarket/upgrade_app_ajax.php +84c78c434783d82ef274084947bdf5e4 *admin/appmarket/upgrade.php +5fdf01589b66e1f42a88777f0e6f86b1 *admin/appmarket/upgrade_app_ajax.php 6150c674042c7de136a3a128c441dbc6 *admin/cloud/add.php 7eb4ad475512aafe5626ba24a660c3cb *admin/cloud/dzz_app_cloud.xml 9a8615fbb7362c3e9a391a4564f4791a *admin/cloud/edit.php @@ -70,24 +71,13 @@ d3f5f07037eb2c9370339bd765dc6a79 *admin/filemanage/dzz_app_filemanage.xml 561aeaaeefe3c791ef5f1eaf45856456 *admin/filemanage/images/folder.css 2352874b5f636ca331fe9509a2f9bdd7 *admin/filemanage/images/sort_asc.gif d104fcf119d40c51554ddb8b377142e5 *admin/filemanage/images/sort_desc.gif -86917b2d18bd9f9a67ec38cdfeab2189 *admin/filemanage/index.php -a7a903bca116dbf5cf35b54f5da90de6 *admin/filemanage/language/zh-cn/lang.php -3c2451262e5677b4e5d63440f1df0d40 *admin/filemanage/template/list.htm -8a1c8aed30f4e5bea4cdaefa47d69555 *admin/function/function_admin.php -6bc52b9254c490bc2b387754b1577ae8 *admin/images/app.css -4c4d82a0d580966af306100829a50899 *admin/images/aside-hover-on.png -a5e74c4930ec435b32e58038bb70c021 *admin/images/aside-right-shadow.jpg +3638eeb93161b336e6e1987f2add052a *admin/filemanage/index.php +8c1eab3b4ac3bc90d228d333ca5dc136 *admin/filemanage/language/zh-cn/lang.php +286cae699a1f719881518ce103c85ed4 *admin/filemanage/template/list.htm +3e13993be77abb25aa6068d8a1fa200a *admin/function/function_admin.php 3ee26adfd5fdd169d2c303ed8fcdc04f *admin/images/color.jpg 63ce7b2aeb0a778a8913db95faf80640 *admin/images/getcolor.htm -99e8d181fb65094382dfa258aa758dde *admin/images/icon.png 04f6bdcff2ca03feba74fe22924c4cc7 *admin/images/loadding.gif -ff266b72e4c62b6d4757817d114cf1ad *admin/images/login_title.gif -c8936391e4e90cc6e03c00b4d45edd2b *admin/images/main.css -1a9bb897ce9fdacd48ac65dc4f38df12 *admin/images/member.css -f4752b454b5a54411da6962dcb6382d5 *admin/images/organization.css -9775fea362e21f211072c1b494d73a30 *admin/images/transcolor.gif -c3e63602d4d30c7f91b1cef3f3ff8ffe *admin/images/transparent.gif -a637fd4719e99a8603cb93668b4af3a4 *admin/images/_Window.js 313f655a315f1454823c8468664a775b *admin/language/zh-cn/lang.php 9eb753c6f0902b4f0104f81c07664167 *admin/login/classes/adminlogin.php 51bcacee1c7fed967c6f91b256e9c139 *admin/login/images/adminlogin.css @@ -109,13 +99,13 @@ e4ed91ad5de8eebcfbcb0e94d4dac420 *admin/member/images/themes/default/user.png 66c169809677b2147eb8d52312885e7c *admin/member/profileset.php 09747a8e233cf26f9eeb9bc12e2eccf9 *admin/member/scripts/orguser.js b1d8985e0aa3e73ee4b875402d20afa6 *admin/member/template/left.htm -57ddf40abc267c9c5d4e872bd931acff *admin/member/template/profile.htm -c190984ec656d1553b921e3b8cdf6bcf *admin/member/template/profileset.htm -a3db72d6e566435a2765bc6ceba64628 *admin/member/template/profileset_edit.htm -706b6393609cb6d13c51a577da779ac0 *admin/member/template/verify.htm +726e6554c845ea42c4ef7ea4b712229f *admin/member/template/profile.htm +743703802821e870686d010927eb7e01 *admin/member/template/profileset.htm +1ca4f10aae3c07733471c1ed16482db2 *admin/member/template/profileset_edit.htm +bcdbf2aec91d38d4b369372ee656bcc2 *admin/member/template/verify.htm ce82e99af40f4f6208f7bba45d993f56 *admin/member/template/verifyset.htm 21c33098168015eddb336ee1cd37a3fd *admin/member/template/verifyset_edit.htm -195c8df5cf7774cf82ff7cbd6d87bc07 *admin/member/verify.php +685c87afd431f0e617cdf8760f7b6804 *admin/member/verify.php 449d0edcd96dabe280d445408fa26c38 *admin/member/verifyset.php 0581feb012b1edb2c7f4b57dcba2c5c9 *admin/orguser/ajax.php b0a59cf91fc5438aea9d5887677f0d2b *admin/orguser/dzz_app_orguser.xml @@ -137,19 +127,19 @@ b66c481771c3da042b6119ef956be56a *admin/orguser/images/themes/default/style.css 9ed4669f524bec38319be63a2ee4ba26 *admin/orguser/images/themes/default/throbber.gif e4ed91ad5de8eebcfbcb0e94d4dac420 *admin/orguser/images/themes/default/user.png 93896df44bc705c81022aeb152d33917 *admin/orguser/images/user_bg.png -7c8afcb59eb336d8decb1f7b66075581 *admin/orguser/import.php +02ad0340678670df6ff375dccda9440b *admin/orguser/import.php 328456cb05d0366d7bd28a2a55588e01 *admin/orguser/index.php 7f51291cb835a2a59a5d1a1d9fb1f260 *admin/orguser/language/zh-cn/lang.php -ed6bf5b6831d19f1148ab828c61bef63 *admin/orguser/scripts/orguser.js -6c7c2b4c5b37004cb4ad8ef89fbabc83 *admin/orguser/template/adduser.htm +963b4fb863272a1f2967f02c8415f6db *admin/orguser/scripts/orguser.js +1349e1c9f427e434c43cad45655c62a0 *admin/orguser/template/adduser.htm 8b68f310214b65d9960658edd9aa07ff *admin/orguser/template/detail_org.htm a1ba58645da58921c4deddff284dacd4 *admin/orguser/template/detail_user.htm -c8ae0c28e030bca63a18469010b1612e *admin/orguser/template/edituser.htm +b9187cf38be244e7e87aa2bcdce144a0 *admin/orguser/template/edituser.htm ee188d05e058f2c3030941b3c3bef1b0 *admin/orguser/template/export.htm cd4075afe95addd6a1dde7c90647dae9 *admin/orguser/template/guide.htm 5bb95d9914284024bfbde8e8cb60286f *admin/orguser/template/header_left.htm 497f0e395a23b521fbc1cfa776d10f41 *admin/orguser/template/header_search.htm -4513c4d0e712f3d6d976242f8cb8a7e7 *admin/orguser/template/import_guide.htm +9c53a4118061b28dcd75230935e4b4db *admin/orguser/template/import_guide.htm 780adb4e888b07bbb23465c35f27b124 *admin/orguser/template/import_list.htm 22406b2e5991a5359b8230f90953b4a0 *admin/orguser/template/main.htm 5afe9ef3efc2f8479e53236de858e701 *admin/orguser/template/profile.htm @@ -167,7 +157,7 @@ b765d84edd07b710d40795eacbac9b34 *admin/setting/images/0.png 83901ce79bb088d33639e8b0793dd022 *admin/setting/images/template1.jpg d7c3760175ba38a52cc1a91023a3bf5b *admin/setting/images/template2.jpg 2f819e15ed963ee87da7cdc5bfd2744c *admin/setting/images/template3.jpg -58655ca2cfaa0c13228ff03851b20647 *admin/setting/index.php +779ad97fb15fc0a64079f331e74f3885 *admin/setting/index.php 8e6ea53e403536b5111de5bd1dba50ac *admin/setting/language/zh-cn/lang.php 4efb844e384283cb9f326fab554fe6ff *admin/setting/mailcheck.php cca460363ba240cd8b70de3e1ce93527 *admin/setting/permgroup.php @@ -177,34 +167,17 @@ dd9782184510489aefd44425ece0b198 *admin/setting/template/assistant.htm 5bb95d9914284024bfbde8e8cb60286f *admin/setting/template/header_left.htm 2be011b50cad3167550571b12f2e1ed9 *admin/setting/template/left.htm 0c94f48220af46f4c0e1e19883af190e *admin/setting/template/mailcheck.htm -6ce565208ebc28d090530dca2c3e4fb1 *admin/setting/template/main.htm +209d5226b35fded216412d0f49a0973a *admin/setting/template/main.htm 38a288d3c5888d318a541b7efa8bf061 *admin/setting/template/perm_group.htm 974cc5101006b66f96b1932dd6b2f9d1 *admin/setting/template/smiley.htm 08faf8f44f67eacb7c3a23109edbd913 *admin/setting/template/smileyedit.htm -350ebaeba5841f728b35fafe7ecc77b6 *admin/setting/template/wxsyn.htm 67f9feb273a4027516371111ef82573c *admin/setting/upload.php -d2bfa03bc13c4572845f9dba026fe201 *admin/setting/wxsyn.php -bda9365eecd8ba85a32ed1e8c171b91a *admin/setting/wxsyn_down.php -0596ccb56c8a8dc08fa2c217346cc921 *admin/share/ajax.php -ce0118c248a0471ad331fc5e9620535d *admin/share/dzz_app_share.xml -3ce7b7f807d0f663831f98c224a27079 *admin/share/images/checkbox.png -5b3ac58fc29ecc1622cfc845c5c4d310 *admin/share/images/locked.gif -b8671da22d7216797b78c4fb667c97fa *admin/share/images/locked.png -5843b9fc18df7200389c69d872348f6c *admin/share/images/selected.png -c5b13e6cdfe91855a872d962f93aa492 *admin/share/images/share.css -2352874b5f636ca331fe9509a2f9bdd7 *admin/share/images/sort_asc.gif -d104fcf119d40c51554ddb8b377142e5 *admin/share/images/sort_desc.gif -fdd2639e71b3ecf2d46ab060fba5f515 *admin/share/index.php -3391357004df104ceb6081fda70a1041 *admin/share/language/zh-cn/lang.php -ab196ffc35f8b98049dcf39675d7444c *admin/share/template/header_search.htm -e8a95727d570120ecfca07f5b16075f7 *admin/share/template/left.htm -8767adc8c21952cd05743dd57cf8b543 *admin/share/template/share.htm ee848010db9a3f161df9f438ed7a9889 *admin/system/cron.php -a17cd6ce62918c025e093399f1e56490 *admin/system/database.php +5b2e345f0e6c51c8b3aaef74074f045a *admin/system/database.php 8d7c07092d47f55663ca434b39de7032 *admin/system/dzz_app_system.xml e47256d23636eb3804995d964212df79 *admin/system/index.php e9b2426f3829bb74dfd3d605dc414e62 *admin/system/language/zh-cn/lang.php -44df4859dde5cd8ced798b9f12970101 *admin/system/systemupgrade.php +6e4eadec51a48a5007a23e502d5a4355 *admin/system/systemupgrade.php e20e686567f3687922fb302ba805b956 *admin/system/template/cron.htm ca1b28e030ced95bc1b2d3a8395a0c12 *admin/system/template/database.htm 720f28a01c9278ec17b75082e696928a *admin/system/template/left.htm @@ -226,9 +199,8 @@ dca7feaeaecbf7a3a4ca643b314bceeb *admin/systemlog/uninstall.php 5bb95d9914284024bfbde8e8cb60286f *admin/template/header_left.htm 1fec385d821c7a3884a5705aa6fc1545 *./admin.php 09920c28e407e3831bb20c614652f7f4 *./avatar.php -23f78c219293a7e7f5167013171a9203 *config/config_default.php +266cc89e747934800cfd66c3be589cb6 *config/config_default.php 99136f1f8b2b24c12000120ed2ab2c33 *config/config_frame.php -d41d8cd98f00b204e9800998ecf8427e *config/index.html 17b5c3b0f95e15f0734599c5dd16e05c *core/adminstart.php 46135ffbb393b51b168f31507e640b01 *core/api/BaiduPCS/Baidu.php 728d247907dfa6d5a70aef31c98599e2 *core/api/BaiduPCS/BaiduApiClient.php @@ -259,7 +231,7 @@ da9fde315737bbebb8bd6bd0ef9fd158 *core/api/qiniu/rs.php 6f599832ca3fded2c694bc42d01ac3e5 *core/api/qiniu/rs_utils.php c558e210da4c7d6b86d5325467988dae *core/api/qiniu/utils.php ceb292e4764a62ddf1a7e890fa7d6f34 *core/api/wopi/index.php -ea04a1df42129dd9a9879abe74ffa974 *core/api/wopi/wopi.php +cb85fadf5dd5ba7a72a3713e833eeafb *core/api/wopi/wopi.php ecfb7f3b16abc36f8e5d57e1251d1b10 *core/class/cache/cache_file.php 429a01afbdeca7c93df2ad4bae3980d8 *core/class/cache/cache_sql.php 731e494c7d4cf8833967b87c63915ef2 *core/class/chinesetable/big5-unicode.table @@ -269,12 +241,12 @@ e914c1c998605c629042698c546d9b84 *core/class/chinesetable/gb-unicode.table 14bf991b0431396b48990a3b297dff07 *core/class/class_CException.php f379c1822673f1081197ae14976034f2 *core/class/class_Chinese.php 45c1dd33e8e79e9983896a1726964c0e *core/class/class_command.php -abd334797460c53fc8a81620bb524c73 *core/class/class_core.php +4416b7f8cd45d1e53813c3b7f05d8601 *core/class/class_core.php 581b0b21604ee23cd14f548caf88f17a *core/class/class_DbException.php 3ce9db683150a76cd033167c7e281391 *core/class/class_Des.php 4719703ed3b405846258108237228a1f *core/class/class_FileDownload.php 632b1d48325f718b94626061b47c7bd5 *core/class/class_GifMerge.php -60a90d6874eab3de0fae96e8a47fff0b *core/class/class_image.php +9d4af0da8ff8b0418a7380a4c40783a9 *core/class/class_image.php 1b836428237ca8d2bb58695cbe37df67 *core/class/class_JSSDK.php 986ad79bf8a9bff90c64c82918c0fa74 *core/class/class_Minifier.php 8987c817fd10d12a23dc995a40e00869 *core/class/class_PHPExcel.php @@ -285,7 +257,7 @@ c72c0c4c7ab60a46afc34a6ac1ac801c *core/class/class_qyWechat.php 410c9e016d2bbc91c51af4897cae9019 *core/class/class_template.php e919f32dbde540fc7bc7613e3b7db7f9 *core/class/class_uploadhandler.php 707d3ad1748a53deb8d139c0d6f6cdfe *core/class/class_Wechat.php -e569bf1de139a7dce62d8442a5acc568 *core/class/class_xml.php +aad678f562cc69d34e1a52f249e45ec1 *core/class/class_xml.php 5ecbae2549bd8d3b1ad6a7123a41d862 *core/class/class_zip.php fa9de8fcb879e1c72f765268f798393d *core/class/class_zip1.php f06571c2d1d260c9f4a4bab49ad1d0fa *core/class/class_ZipStream.php @@ -295,9 +267,9 @@ a5ee1ee82acf648f07127353f8b2116b *core/class/db/db_driver_mysqli_slave.php 8d33849f3d582eb8faa608386105a28e *core/class/db/db_driver_mysql_slave.php aa439e22adcd2c891dc614294517c6f4 *core/class/dzz/apprun.php 5c421f32cbe73f55fd2ee6b738d4236d *core/class/dzz/config.php -a3bfcbfd01390f69a9b5ae222d1d8959 *core/class/dzz/datareturn.php +a3bfcbfd01390f69a9b5ae222d1d8959 *core/class/dzz/Datareturn.php de5663485ca8d68bb3ab6f460685ac49 *core/class/dzz/dzz_admincp.php -84f3eb4c356dd18f875641de8c6eaa08 *core/class/dzz/dzz_app.php +9c781121b82726ff81c1652069a1c7a6 *core/class/dzz/dzz_app.php 91adfa54c54bf8db812f4b65e5f2f2c5 *core/class/dzz/dzz_base.php 3918258ed5ebdbed13efe8a563f1f7e1 *core/class/dzz/dzz_censor.php 5f0774d004cd5e8dde0ece8f83626c32 *core/class/dzz/dzz_container.php @@ -305,18 +277,18 @@ de5663485ca8d68bb3ab6f460685ac49 *core/class/dzz/dzz_admincp.php d4504e1ba91d3577827fff6f326c1603 *core/class/dzz/dzz_database.php 0cb79bf8363dceb6fe1509799fd4cb40 *core/class/dzz/dzz_error.php 52a5b6b92b54e82e1564f1b613d852e9 *core/class/dzz/dzz_ftp.php -01d34b319da8e96c20b1110a1c47450c *core/class/dzz/dzz_io.php +d9e971b92a8fb153966dda3b575f048b *core/class/dzz/dzz_io.php ef217cab20e4391a31198ea4cb47ecbe *core/class/dzz/dzz_memory.php eb5c167211bc5df07bcb8dad61c3649a *core/class/dzz/dzz_mime.php 0c20769180e19a1160b859f8b7b4ec8b *core/class/dzz/dzz_mode.php -5df7d61f22109eed380ad8ee07bff378 *core/class/dzz/dzz_notification.php +dcfe326238b95cc4507a0e2428882777 *core/class/dzz/dzz_notification.php 6e5edf97d402f3da32d57507d60c3f81 *core/class/dzz/dzz_process.php f6da4473134a84fd321b7c38b7049c69 *core/class/dzz/dzz_session.php 52179613a0b32abcc5e90307ef84cf7c *core/class/dzz/dzz_session_close.php 00961aa427aeb7f054ac7251d9110c97 *core/class/dzz/dzz_sftp.php af8a8b3cdd6cbd7a5c5e510a5fd7b58a *core/class/dzz/dzz_table.php f076e75181a19fc4623cbfc9c5a3aa3c *core/class/dzz/dzz_table_archive.php -5663c7fbffcea14593ec016e4559ca01 *core/class/dzz/dzz_upgrade.php +434da5c3c35f95f33f84119246028de0 *core/class/dzz/dzz_upgrade.php 93bd7052342fff7ec1eb0c107986c192 *core/class/dzz/dzz_upgrade_app.php 81436a74a8db58c639dc617c3f5bcc13 *core/class/dzz/dzz_view_mode.php 9a560e743bd7c0642537e635fcfad2cd *core/class/dzz/Hook.php @@ -328,7 +300,7 @@ d92d3c5fa95f9400ead652f4af451159 *core/class/dzz/route.php e49c3bae8780823c440320a0811002f4 *core/class/dzz/Tpdb.php 586276596952c421a8fe66588c545a1a *core/class/dzz/Tpsql.php 892c4d10eeb365e00bb8ab69e7407945 *core/class/dzz/Tpsqli.php -f506b5ecfd4adcc9927f2b802598d72d *core/class/helper/helper_browser.php +5afac2fd7c46fc369547b89096f6b1ff *core/class/helper/helper_browser.php 0ab7e122d9219c694379f6d66fd8110f *core/class/helper/helper_config.php 69bdb93a25987843f92cf86888fcedee *core/class/helper/helper_dbtool.php 03d001a775d61b78a731609a1a8cae05 *core/class/helper/helper_form.php @@ -336,14 +308,14 @@ f506b5ecfd4adcc9927f2b802598d72d *core/class/helper/helper_browser.php 8531c5986295c9a1922e98aee625e3df *core/class/helper/helper_log.php 95880c795414dd0afa1b0c5bea1b28cb *core/class/helper/helper_output.php fc1a3aee7b9c57c86e678e1fb5ca4c19 *core/class/helper/helper_page.php -9ac5562335395e3a35968e0351478595 *core/class/helper/helper_security.php +db84946a56450d9e7a59a560d89cc51e *core/class/helper/helper_security.php 32f0ac45d5e6cc280f4ef9f5aeefab14 *core/class/helper/helper_sysmessage.php 3439600362cb0d913ff506684e108985 *core/class/helper/helper_util.php 7bf96e081815be033a1172e0b1c7a4c9 *core/class/io/io_ALIOSS.php 19791b917ad5b7eab111b7b36957b48c *core/class/io/io_api.php -a43090149d42bdd7ec9e08abcc5d4e71 *core/class/io/io_baiduPCS.php +00733138accf395cac74e1029e71f766 *core/class/io/io_baiduPCS.php 7a30c4e322b5ed41c06c648411500576 *core/class/io/io_disk.php -e55cfdd6a21a2368c5802bf2b0235448 *core/class/io/io_dzz.php +ee78e7628ecb0c956ca9b39046542fef *core/class/io/io_dzz.php e9a046f8a52aec03b58e7fe93752a4b8 *core/class/io/io_ftp.php 65f6a912c91184852ac8fd6b1ca46f71 *core/class/io/io_OneDrive.php 48b9924d0fc7abd3c61aee349a350db0 *core/class/io/io_qiniu.php @@ -351,11 +323,11 @@ e9a046f8a52aec03b58e7fe93752a4b8 *core/class/io/io_ftp.php 2043a83f4174b5324560eb9b384dfaf5 *core/class/memory/memory_driver_apc.php 54dda3ac75d87081e56d4c7dd696633b *core/class/memory/memory_driver_eaccelerator.php 28e50565d89e5912dfc110e0d3a03417 *core/class/memory/memory_driver_memcache.php -b6f9d067bb2daa2c45c69548d163a013 *core/class/memory/memory_driver_redis.php +e6affa982f81ae228caa0c989738a397 *core/class/memory/memory_driver_redis.php 9171a62d7d35e654c2127fecca81a448 *core/class/memory/memory_driver_wincache.php e4afa33b2dfc7d77d004b8fc0bca2a72 *core/class/memory/memory_driver_xcache.php e3889b97f905a8cf85b04229a5cfed3e *core/class/perm/perm_binPerm.php -396fd6ca6cff8c3e6cec0cfa046510d2 *core/class/perm/perm_check.php +3612b3fc10285f3c8df40645e1c70503 *core/class/perm/perm_check.php b20ab4c389e6ba952dd75e39c92d83f3 *core/class/perm/perm_FileSPerm.php d5ab9253e0657f0b179631838da82373 *core/class/perm/perm_FolderSPerm.php 7f514b8f61b36c8de14d9f53c5ee8882 *core/class/PHPExcel/Autoloader.php @@ -599,7 +571,7 @@ f01baefae751e4356b2371a16a5cf5c2 *core/class/table/table_app_relative.php 269f7123de14877ebb542e15ec5bc153 *core/class/table/table_collect.php 2b7614fbe606c470ea0b5f0b1d8710c4 *core/class/table/table_comment.php a5eecd0dd840a4032d28a07fecb16cb2 *core/class/table/table_comment_at.php -191c7e370c88946e2c234eb8616bda25 *core/class/table/table_comment_attach.php +026f27eed5d40316b7641ce614538421 *core/class/table/table_comment_attach.php 9b0d3df264662c2f126bb6726bb54348 *core/class/table/table_connect.php f7b6e998e6e32083de6fd5464d7317d4 *core/class/table/table_connect_disk.php 3f3f225daf9fa2d44fc03cafd54455eb *core/class/table/table_connect_ftp.php @@ -612,37 +584,47 @@ e7500c15cb7641082de4d2cbb1f29e2e *core/class/table/table_cron.php 3f5d91e94299cfb6373fbd2c7fee1e47 *core/class/table/table_document_event.php 26f85ab5e5076377d4e448ae9719b353 *core/class/table/table_document_reversion.php b3e80746173074e9075c5bbf3136c0ae *core/class/table/table_failedlogin.php -1698fa73d82b5728ac3dbfd25edcdb60 *core/class/table/table_folder.php +fa9c92993126482ca261226b11f2f80f *core/class/table/table_feed_at.php +90ac03b7504f7bdc793ab414e019a503 *core/class/table/table_feed_attach.php +79c62b854612b740692980432fac51f4 *core/class/table/table_feed_collection.php +9263fa4228fe969e3704e6f96e1c06a4 *core/class/table/table_feed_post.php +9c4d1fa678e3458ef399a55f6d12e663 *core/class/table/table_feed_reply.php +cc20e52e401eab6a5df9b8664074f52c *core/class/table/table_feed_thread.php +13de4a7ffd7b471e38bafadbdf17591a *core/class/table/table_folder.php d21f6a965bb99e54d00f47fdedfec495 *core/class/table/table_folder_attr.php 711bed5d3de20aff6e476259c42eb2ac *core/class/table/table_folder_default.php -5849df89b59dbc51f9cffed0e2389d54 *core/class/table/table_hooks.php +807b32194e1128467552a1b72ecbdf80 *core/class/table/table_hooks.php 9f535b0fb3c7d29355f2ca12a5d820ec *core/class/table/table_icon.php b04b6b407ca658549cdf211a21a53050 *core/class/table/table_iconview.php 24bb041d2d61827a2537958d39cd3c2e *core/class/table/table_imagetype.php -f668d913d16288c27880d17bd20639ea *core/class/table/table_local_router.php +165cb100356fe52c78e5bceb4abf8cee *core/class/table/table_local_router.php c04f3913aac69d2c21d84142a15db2a2 *core/class/table/table_local_storage.php c71baa033e08eabf9ed83418ec05f073 *core/class/table/table_mailcron.php 074bc5e1b90961f768a1bfa294786f39 *core/class/table/table_mailqueue.php +36b8f0ccf06f74762a49f9be46363aa9 *core/class/table/table_market.php +331e68a091e59866fdab1a1ffe315860 *core/class/table/table_market_class.php +37d6220d3559f89e624dd629c34cba23 *core/class/table/table_market_developer.php +cab81ce9cdd9b5738566f5722fbe3665 *core/class/table/table_market_field.php b07a37b2b1029450e951600439afdcce *core/class/table/table_notification.php 018c57fdf8e98caa2f3ec0ad514d0b0e *core/class/table/table_onlinetime.php -d17616ac47e861ba227322c98ccc454c *core/class/table/table_organization.php -3b113c502933cc243e8f72b163fd5741 *core/class/table/table_organization_admin.php +096ef3f7b9ae1117de08c0ff67f1a858 *core/class/table/table_organization.php +57b04631c2ccabc98c514d6eac02929b *core/class/table/table_organization_admin.php f5e3e7ceb99da1ac14e826b997cb8757 *core/class/table/table_organization_job.php 5be3037a987d3c456eea51c7d26d49c2 *core/class/table/table_organization_upjob.php -3f58af08e1f713505e56d4064bc17c8a *core/class/table/table_organization_user.php +541167a535740b1451676ce9364a2902 *core/class/table/table_organization_user.php 6f3e7d98422122a98d5b61ff47f734ac *core/class/table/table_process.php -07780bac6c79b0679e68033a85e84123 *core/class/table/table_resources.php -f5724cf7656b669330ccf88d61f38f92 *core/class/table/table_resources_attr.php +e7b6a1f01f0962866034cd27537a978d *core/class/table/table_resources.php +83880bdde28232dcf7379e72bbc01601 *core/class/table/table_resources_attr.php 0c5653e1fc3cf578e0f67704b595d187 *core/class/table/table_resources_cat.php 2c66368d17f62a69a7fdaace083d6a01 *core/class/table/table_resources_clipboard.php 4e2e767ece895087567aa687fdbb21e5 *core/class/table/table_resources_collect.php 55ea5ffa4414995bcbd0ca63c0f24dd7 *core/class/table/table_resources_event.php -7e4e6ca65ddd7c42918ddba963625150 *core/class/table/table_resources_path.php +2da6c38588059d6d2527e50b3c1a6171 *core/class/table/table_resources_path.php 05db9f79c46c41fd8ec7a364d8a43932 *core/class/table/table_resources_permgroup.php -0775d26bdb64d7397776f8743a298231 *core/class/table/table_resources_recyle.php +6bfe3e068d5826e23f404c7b8d048fd2 *core/class/table/table_resources_recyle.php c87db2542ecf9d63f67a7f021d1b2ac7 *core/class/table/table_resources_statis.php 83e575093d6f2e813baae62db3c08303 *core/class/table/table_resources_tag.php -3340ab472f43c3ea64f7be93fe9b4fea *core/class/table/table_resources_version.php +a3c2355198bb40c0294696fd7b584712 *core/class/table/table_resources_version.php 6c5ad047f0787a52397bf525ac819dab *core/class/table/table_session.php 35111db3ec2ac5d6ef06f9444c731665 *core/class/table/table_setting.php bf9165ba9903ee75160f7d72a438708d *core/class/table/table_shares.php @@ -651,15 +633,13 @@ c60e2abf3fc9213ef8c68c055ad7640e *core/class/table/table_shorturl.php 4bfd1f3f64f71027489b13a35a6f796c *core/class/table/table_syscache.php 7d1f96ba8053bbac76cbf38b0ccdec1c *core/class/table/table_tag.php b79e9b3b2dda9cabb829930e6834add7 *core/class/table/table_thame.php -8d3b711788151c0ad6fb9c629203b07b *core/class/table/table_user.php +2e3332296ce5fa69554dfd8c8e3293ef *core/class/table/table_user.php 7d7fa83769645842594a296d20ac6a61 *core/class/table/table_usergroup.php 695311cdc7baf197d0568ebb9f36bb43 *core/class/table/table_usergroup_field.php 81c66178196d5373fa84f9e8224ec5cb *core/class/table/table_user_field.php -fd8f3c37978c4fb12efeac33b671e236 *core/class/table/table_user_profile.php +324475984445ae35d2947f0778bc57f5 *core/class/table/table_user_profile.php 66dcfe5a1a7c72d5600e6cb89ffee519 *core/class/table/table_user_profile_setting.php -aa4e02be436ffe5f49cb9f5a0b1c3a9a *core/class/table/table_user_salf.php -d962fc8fa4385d7a0f891aa73e5faf7c *core/class/table/table_user_sdk.php -15cb62196d02ecc328804f7542621e05 *core/class/table/table_user_setting.php +b5c87242389ec8fb33a71922db91b4b4 *core/class/table/table_user_setting.php 855ff57bf61027f8334e56b728f745f4 *core/class/table/table_user_status.php 8ca018fc835a50d50d11dec02c531961 *core/class/table/table_user_verify.php fb5df76186947374235edfb3860fa66d *core/class/table/table_user_verify_info.php @@ -668,12 +648,12 @@ ebf391291e92075c3ce7b7c285cf13c8 *core/class/table/table_vote.php 95510145cfc3f0f7f8aa310f3fe874d8 *core/class/table/table_vote_item.php 6ee1d1ad1b9cccabf10eff0b2d1eec7b *core/class/table/table_vote_item_count.php 14ea64ba36379648a043c384dc9b0c50 *core/class/table/table_wx_app.php -91e87b3ea4a55ed25a25750f172abe64 *core/coreBase.php -f420371dfaaa53f631c72b9b7cc95856 *core/core_version.php +cf8d43fc516021e7cd5644de3155319f *core/coreBase.php +fbca4cd8327b06aed44dd8c01dc4ed56 *core/core_version.php e5973e34787ad5bd32286eab3a9a758b *core/cron/cron_cache_cleanup_week.php -52e52d8c88376dea6200039170562001 *core/cron/cron_clean_copys0_attachment_by_month.php +b7a021218c1a6253ba85fa35559f8217 *core/cron/cron_clean_copys0_attachment_by_month.php 24a84f90b0839e8e6a3e697da7896f5d *core/cron/cron_clean_notification_month.php -0c427b615617ae65b31eb667f27ad132 *core/cron/cron_database_backup.php +6708d3f41fb5435a08994f5cc38cab46 *core/cron/cron_database_backup.php aef39338edf00b040abc6db5fe1ec843 *core/cron/cron_fragment_cleanup_day.php ea44194d8583db2c3333a91d1ddad5d0 *core/cron/cron_getAtoken_by_Rtoken_week.php 928f636606eab8c241f79c32dcbf30e8 *core/cron/cron_imgcache_cleanup_week.php @@ -692,7 +672,7 @@ f2adbe22f5fae255c730024998283b74 *core/function/cache/cache_usergroups.php 76d1658764d98655606c1a67c68712bc *core/function/cache/cache_userstats.php 3b17eeb2d84ce01d3e7df337202e6352 *core/function/function_cache.php 2b96127ffb53498611ed69a22f7bfd55 *core/function/function_code.php -271af7e1c0dd482a36cd3e23a278db8c *core/function/function_core.php +c71e226d059f724417016984325737b2 *core/function/function_core.php 1c007b07588eb2dc1054eb46f7143072 *core/function/function_filesock.php 0c97b2967d924bbe3e88d1821e730fee *core/function/function_mail.php eb2fc5813f9b4da92c7e4927ee2edd61 *core/function/function_message.php @@ -700,9 +680,9 @@ eb2fc5813f9b4da92c7e4927ee2edd61 *core/function/function_message.php bf630cbd6caa4024e16fc62301eaff12 *core/function/function_organization.php eae202687756c11c51cb9d972b04ccef *core/function/function_seccode.php fb2092242775371cc2fd1ea2251c4e33 *core/function/function_security.php -cec7758f62ec177ad0883fec816dd391 *core/language/zh-cn/lang.php +ab937389810430e132b6c86faa387e01 *core/language/zh-cn/lang.php 09a93b7ed07a65d0897ab635ce69062c *core/template/default/common/about.htm -af38fa2bafdb5c711f56e3d163f4d3f2 *core/template/default/common/commer_header.htm +3934332340f3f0890096120d2a42a042 *core/template/default/common/commer_header.htm 24365d785caa54cd1fd94dc08a3ae9d1 *core/template/default/common/footer.htm dcecf9502c1ceadebea0ae4c229d3364 *core/template/default/common/footer_ajax.htm 9aca73d28649b755b4a8b75e87fcd8aa *core/template/default/common/footer_reload.htm @@ -716,12 +696,13 @@ f67de157cbfceb3ecbaa040471176538 *core/template/default/common/header_common.htm ec6eb1a7a88e529a43df62b8f3af204b *core/template/default/common/header_right.htm 9de4659d520e3bbae0efdd85af2c1652 *core/template/default/common/header_simple.htm 2d3290bd2d37e19040655c5fcaf7ec4e *core/template/default/common/header_simple_end.htm -632e88d37340014c63ae7e9f473083f2 *core/template/default/common/header_simple_start.htm +62944c1f167d8a87048d80d89aeb39fe *core/template/default/common/header_simple_start.htm d6487a677351f23ca8d84b6153963bd1 *core/template/default/common/header_simple_start_none.htm +074801b30c5e8b069f72818e630edccc *core/template/default/common/header_simple_start_shou.htm 0036c55188791f5520f336fa596c0c4e *core/template/default/common/header_start.htm -f20c98c7804c6d50a2a5108feb2facee *core/template/default/common/mobile_about.htm -028400f85b4cea122460713a0e8a8c3a *core/template/default/common/mobile_simple_end.htm -f23fec3884a9633ec1a218295fb3c64a *core/template/default/common/mobile_simple_start.htm +68ad818529d45d119a84cd743cd2da14 *core/template/default/common/mobile_about.htm +028400f85b4cea122460713a0e8a8c3a *core/template/default/common/mobile_simple_process.htm +c7fc67eea17c110556f811fdfc07b566 *core/template/default/common/mobile_simple_start.htm 4998c1105a464ced43aa0eb9bbaf3756 *core/template/default/common/safechk.htm 79fa787397d5da73910266ef70cb3c34 *core/template/default/common/seccheck.htm 1cb4d8cee04c97c0a580f882bc9da940 *core/template/default/common/showmessage.htm @@ -731,7 +712,6 @@ f73b4e96153e7d5e10de63aa55c31007 *core/template/default/common/wx_appinfo.htm 9990d7555fdf8210fa4a2a8672f20fd5 *core/template/default/common/wx_menu.htm 768cfd48e43c4a205b1d40ab82acde57 *core/template/default/common/wx_mpinfo.htm 2c434d049b105f3f51bb1d6d7da484f1 *./crossdomain.xml -76816fac64e42999777a36595254a639 *data/attachment/.htaccess 488bcacd7cad8d74d8e5641224b14ab4 *data/attachment/appico/201712/21/103805dczcm89b0gi8i9gc.png dac24e24bace4acd73c2a5d1612d5d09 *data/attachment/appico/201712/21/113527zz2665xg7d3h2777.png 7009fe55c04186e21da269e88eeb76f9 *data/attachment/appico/201712/21/123754pb0s666i6sjws1jc.png @@ -788,7 +768,7 @@ f8aec68ab3d16b5b9b2912b2291f0e3e *dzz/attach/ajax.php bfa6363585dba0346a8ce9f895c26d26 *dzz/attach/controller.php 2784dcca3d8a314c438fc5cc02175317 *dzz/attach/down.php db79e7752ea9464ede864e1a0a1bb319 *dzz/attach/preview.php -2f782fcdefb8b1ac41d48d4af3202b60 *dzz/attach/saveto.php +cbff3d02cf14de4b505ad7de059e9762 *dzz/attach/saveto.php d14686608818ee591868ea028cf6affd *dzz/attach/Uploader.class.php 272a7b7e1883d1b12c77f65fbf676a05 *dzz/attach/view.php f79e3c61653f067e72141e72cb510e52 *dzz/class/class_caiji.php @@ -796,10 +776,10 @@ f79e3c61653f067e72141e72cb510e52 *dzz/class/class_caiji.php 6911980da1032262c22f51db577ac3f5 *dzz/class/class_ico.php 13c254265bb582c52f96d64971ab24df *dzz/class/class_json.php 5c181de058570f574b29ff49c38261df *dzz/class/class_UploadHandler.php -45966ced08482af2d9800ac62a573e16 *dzz/comment/ajax.php +37bbaae3190656b7321f3b9ef1ededcf *dzz/comment/ajax.php 2129c5b4c274321aedf505fa2e89241f *dzz/comment/down.php 157fa913142a749610d08a99bebbb553 *dzz/comment/dzz_app_comment.xml -1cdcb020a32eecafbdee9cd33db2152b *dzz/comment/images/comment.css +95cf0878b95e6798869a56ea49bf997b *dzz/comment/images/comment.css 523a6426ca3bf24d068f24f0afb7bb68 *dzz/comment/images/comment_triangle.gif b5e8fc70c992e4311bb6b762161d924f *dzz/comment/images/icons.png 8c108cb541f9fadbd45e0d1dd91b60d7 *dzz/comment/images/ico_feed.gif @@ -821,15 +801,15 @@ dbc4562b881658c2328a46c73ba5b77a *dzz/comment/images/video50.png 805e9d70e907f9b8151c43357de8af77 *dzz/comment/images/zoomin.cur e5f236bf2b60f8c8fc1867d70636a046 *dzz/comment/images/zoomout.cur c23e65a7cfa12bd4ba82c8495df4b4a8 *dzz/comment/preview.php -3b6e6513c8d274920272df89ecc84d0e *dzz/comment/saveto.php -6c73a1c731dc4c91f4cf51c355fd48a0 *dzz/comment/scripts/comment.js +8f9d52929e11241382cdaae64834db1e *dzz/comment/saveto.php +256106dc16f0196e589c657117d36de9 *dzz/comment/scripts/comment.js e4f08555a17775cdb96f0b83cccef3bf *dzz/comment/template/ajax.htm 4c55a7e1ce9007bf50153f950f94e76a *dzz/comment/template/edit_form.htm -5fce1becbf1bf6d33e358bc1926cd1ff *dzz/comment/template/publish_form.htm -46b0e72304839062ad3e12fd60fbbc0b *dzz/comment/template/reply_form.htm -cd3414faa581412247c007e9254bcb1f *dzz/comment/template/reply_item.htm -2fb608a4289e09b1915a620aecfe7b9c *dzz/comment/template/thread_item.htm -0692cb2ce17440c128e97ff5df411c22 *dzz/config/config-sample.php +a522cfcda55d2d773258cb6eb07ba72a *dzz/comment/template/publish_form.htm +8abf1ad4c650c7a6c7061017d517c79e *dzz/comment/template/reply_form.htm +2da1b37ef46b0ce6a0cc8cda00a7cb0b *dzz/comment/template/reply_item.htm +558b34d8891a591d3ae40c2f8245f583 *dzz/comment/template/thread_item.htm +07c451588feef0d0745ba7aa568bd7ed *dzz/config/config-sample.php 6d2550a5c92115cf0a7cd988517679b3 *dzz/config/config.php 1c23481d370408e07ef71c36da36d6a4 *dzz/connect/addcloud.php 4359bafb633e6ec623c583d39e915a81 *dzz/connect/ajax.php @@ -879,7 +859,7 @@ eab7b77fc556c19e0d47ad48cecb6587 *dzz/images/cur/aero_ru.cur 173fe4c17631ba7789f03f42df06f3be *dzz/images/default/delete.png 8ba563a37aeddf42c0433f63aa6c43ce *dzz/images/default/e.png 88c2a4a8ef5a02e82c6715155b645ce0 *dzz/images/default/icobg.png -8ba563a37aeddf42c0433f63aa6c43ce *dzz/images/default/icodefault.png +08036e4f06503080e1f4dea72cf140ab *dzz/images/default/icodefault.png 4836e477448b514ed4316723253dd9cb *dzz/images/default/imageloading.gif a69a0a404fedd3a334f295db86001589 *dzz/images/default/loading.gif 25b023c9a97dc186e7ef8283c67af083 *dzz/images/default/loading.png @@ -958,6 +938,7 @@ ccd2210801aa8cf388d200899a62e9bb *dzz/images/extimg/et.png 27d3a7498d3b2430485b6168a7ab8216 *dzz/images/extimg/flv.png 21cbd600a6f15595bd2da3e064fd8010 *dzz/images/extimg/folder.png 5aa402aa67a5012673fc6fd25a5f60ed *dzz/images/extimg/fon.png +8fb5a1819e7f38a87006c9e22e8bbc2c *dzz/images/extimg/gif.png e94d4351df4dd3a543218bdb65ee9c99 *dzz/images/extimg/h.png d43fa8605d50920db6c4760b4603ed34 *dzz/images/extimg/hta.png 84727447c443eb20529f58be8261f322 *dzz/images/extimg/htc.png @@ -969,6 +950,8 @@ ab3f0ed10c01bd7e4390c5490aae2405 *dzz/images/extimg/ini.png 0927e53ea32041d948bb0c4314566e73 *dzz/images/extimg/iso.png 2c7e711aed0a955966289c67ba65cf24 *dzz/images/extimg/jar.png 8416d4f50341a3ef286ed33d0cb39233 *dzz/images/extimg/java.png +8fb5a1819e7f38a87006c9e22e8bbc2c *dzz/images/extimg/jpeg.png +8fb5a1819e7f38a87006c9e22e8bbc2c *dzz/images/extimg/jpg.png e2dbad90a0f202c3df360229d0f0b17d *dzz/images/extimg/js.png 0d287047eff051cd870a77944aa198bb *dzz/images/extimg/json.png 7f3f894c0078c2dd5f517ba383701332 *dzz/images/extimg/jsp.png @@ -1001,6 +984,7 @@ df27cb50bffb010ac11a2b2b7546d878 *dzz/images/extimg/php.png 19cb95e098c2a5204acffa972ff24b36 *dzz/images/extimg/php3.png 08722aeed56e50d37692e2224512f3c7 *dzz/images/extimg/php4.png e24fc1721c7a4609b4513543f8cb2d43 *dzz/images/extimg/php5.png +8fb5a1819e7f38a87006c9e22e8bbc2c *dzz/images/extimg/png.png 3cd97c1e359a13e45387ededb995284a *dzz/images/extimg/ppt.png 796944e10a4882a04db931454e44fb92 *dzz/images/extimg/pptx.png e008a5717d253acff971e9ea142309f5 *dzz/images/extimg/proj.png @@ -1157,8 +1141,8 @@ b6a60060a023abcdb3316fdfc1a76cac *dzz/images/icons/xlsx.png 50c5e3e79b276c92df6cc52caeb464f0 *dzz/images/loading.gif a3f446147e4e8c40f3bbb923a4a0b0ee *dzz/images/logo-blue.png ea3e5ec285504e56213f8d3a75367195 *dzz/images/logo.png -aad44c277412d7d72795ad456e424840 *dzz/images/newfile/excel.xlsx -2a65b19ecc4a3a6d90f31c33e4567960 *dzz/images/newfile/ppt.pptx +fde5727e64f35e01f53b56f5b50fef76 *dzz/images/newfile/excel.xlsx +6541a5557bb885ede7d5587a44bc1641 *dzz/images/newfile/ppt.pptx 78c8ffe41469fd232c99c281ea1f8c14 *dzz/images/newfile/word.docx ae9ca305f7567a9dff7d29d3920897ff *dzz/images/taskicon/appmarket.png c0dbe83de0d8064f5c8e8dda42cf0a27 *dzz/images/taskicon/baiduplayer.png @@ -1206,14 +1190,14 @@ bef427cd859768705aaf16a15d5ae0b6 *dzz/images/taskicon/绯荤粺璁剧疆.png bcf1b924f442bcf1c6be85f65f270334 *dzz/index/images/gitee.png b8489fc8ccf934910c74b9672fabd893 *dzz/index/images/github.png 8e9ae687ea62ce7b672238c8c4914dfa *dzz/index/images/qqwpa.png -f70f496f5a7f9667b83e617a743c4e90 *dzz/index/index.php +cc91fe766b56fb7158fb18a1d299185c *dzz/index/index.php 4ce5d6c44e68a76f7a049f07c3fd39b4 *dzz/index/language/zh-cn/lang.php c35a8d6e16d72b7abc7f0f8621ae38d3 *dzz/index/template/main.htm 5a0e0fc22591445b7f00801a79621cf6 *dzz/io/download.php ad75c35fea05c9dc036d6464877c69ef *dzz/io/getStream.php 2e6fe45698d56a394705fd0150446d22 *dzz/io/setStream.php 429e9d9d6d2635386607cf3904f599f6 *dzz/io/thumbnail.php -25e67c63c456eeb63fb210e3cb87e994 *dzz/language/zh-cn/lang.php +0ed27c6f9475dee6ec4e033734bc219f *dzz/language/zh-cn/lang.php 11a39ccf47178d07f11e3fc2ffba0d3a *dzz/market/dzz_app_market.xml 325864d85a6d82fab3bb781291582669 *dzz/market/index.php c62e6af65e69b6911e51422eb4ac7385 *dzz/market/language/zh-cn/lang.php @@ -1230,7 +1214,7 @@ d41f7962ad08e37707c943635dc3cae8 *dzz/shares/images/folder.css 01f5f471ba8adf97f7dd05e461f01f09 *dzz/shares/images/ic-files54.png 5b3ac58fc29ecc1622cfc845c5c4d310 *dzz/shares/images/locked.gif b8671da22d7216797b78c4fb667c97fa *dzz/shares/images/locked.png -43a52f16c2cd1fff5c847a4bf2915f02 *dzz/shares/images/mobile/password.css +573690f8c52697f7d79a2c69fdaf80f3 *dzz/shares/images/mobile/password.css 325472601571f31e1bf00674c368d335 *dzz/shares/images/preview/b.gif 6276eb066bce3e9e2c383f998e3ac5cf *dzz/shares/images/preview/btn_switch.gif c4b7eb55bc26adb07a8f56832265a041 *dzz/shares/images/preview/btn_switch.png @@ -1244,21 +1228,21 @@ f24228c3ce9b416442e4dfe16e3607c6 *dzz/shares/images/preview/popup_title.png 5843b9fc18df7200389c69d872348f6c *dzz/shares/images/selected.png 2352874b5f636ca331fe9509a2f9bdd7 *dzz/shares/images/sort_asc.gif d104fcf119d40c51554ddb8b377142e5 *dzz/shares/images/sort_desc.gif -cdc6306e88e1a01d2aabb33183b57872 *dzz/shares/index.php +0ebf8e0dcc2fd976490c7e7ea32acf8e *dzz/shares/index.php 87b23c608c4792b3387087b753930eac *dzz/shares/language/zh-cn/lang.php -11120bacbe65d5f6da12937dc6f4e532 *dzz/shares/save.php +72c2bb771f482843842b91d1db8c22fd *dzz/shares/save.php 01845fd4def2e00884936b425489fe66 *dzz/shares/scripts/jquery.dzzthumb.js 911a507597916339c573e9ee23c70d15 *dzz/shares/scripts/mobile/appevent.js -33d111df3c8daabd4eaa069f191e05e9 *dzz/shares/scripts/mobile/share.js -09cac06217386208439a5eb77015fa3d *dzz/shares/template/header_left.htm +c2f1c155602dab063342eb6e6417fbd8 *dzz/shares/scripts/mobile/share.js +8ec65c3f33341493a5afd6a3814dd246 *dzz/shares/template/header_left.htm 55aa02ae164ebba0e2045d30a252e405 *dzz/shares/template/header_right.htm c5e943686c5b9cb03bc0fbd3a9d6c6a7 *dzz/shares/template/header_search.htm -204cddb0a1724c8162fb5ab8df17d424 *dzz/shares/template/list.htm +51aaac8e9b282dedcfb84b3c1184084e *dzz/shares/template/list.htm ac530a31f5733f204a0d725bc744b96e *dzz/shares/template/list_item.htm -3cd74c531537297004227957efc84f9e *dzz/shares/template/mobile/list.htm -4a9350f2c1dde16fba31d24d9259a367 *dzz/shares/template/mobile/list_item.htm -2ad5debd1cbab9b6cffcc20d2ee93f4c *dzz/shares/template/mobile/share_password.htm -61c0f69d827f1ace3455d0b2b4208574 *dzz/shares/template/password.htm +07982c7cbd7af8b1aefece190822f173 *dzz/shares/template/mobile/list.htm +9559db4aee8a4d55caa79c2f1a458e2a *dzz/shares/template/mobile/list_item.htm +64395b3a3d2410c87560620cf281363f *dzz/shares/template/mobile/share_password.htm +13a4556fe20b8d705c594d5bb7a8bea5 *dzz/shares/template/password.htm 7193f18e1398082a787280a118bf9dd0 *dzz/shares/template/share_password.htm 2352874b5f636ca331fe9509a2f9bdd7 *dzz/styles/filemanage/window_jd/images/sort_asc.gif d104fcf119d40c51554ddb8b377142e5 *dzz/styles/filemanage/window_jd/images/sort_desc.gif @@ -1504,7 +1488,7 @@ dbc4562b881658c2328a46c73ba5b77a *dzz/system/css/filelist_middleicon/images/vide d41d8cd98f00b204e9800998ecf8427e *dzz/system/css/filelist_middleicon/index.htm d1105f6bae355149db115609331f4a39 *dzz/system/css/filelist_middleicon/style.css 9f7a958a07ba7262ccc1932745762070 *dzz/system/css/file_detailed.css -d69c9f897ff73db1de66b99aa88f5157 *dzz/system/css/mobile/mobile_member.css +4c45d673d159e1c14f7fce63aa686b37 *dzz/system/css/mobile/mobile_member.css 8a8d46c852e137917cb6f0d6c3988276 *dzz/system/css/rightmenu/images/icons.gif a3eb71ed1cdb4911099b8ac05b715b30 *dzz/system/css/rightmenu/images/icons.png d41d8cd98f00b204e9800998ecf8427e *dzz/system/css/rightmenu/images/index.htm @@ -1516,20 +1500,20 @@ ced974d5c685e5dfa0a37b824a6b5d48 *dzz/system/css/rightmenu/images/menu_split_dow d41d8cd98f00b204e9800998ecf8427e *dzz/system/css/rightmenu/index.htm cfa7986441440419e19c3d26d8d33f5e *dzz/system/css/rightmenu/style.css e94ac8176b281956955e3b5425e1afc9 *dzz/system/css/rightmenu.css -9ef6a0705e8dd275e9c5d9fb8bad80c8 *dzz/system/css/select-file.css -02c6de9b35ac1e6c14ef0896ea1e986f *dzz/system/css/selfilewindow.css +8ca3f1a9c01e9034af0623aad3c80954 *dzz/system/css/select-file.css +d3177bffb8de1edd68bfc355b4bad158 *dzz/system/css/selfilewindow.css 4346053e0a14ad0c0e12fc4cbb9e16cc *dzz/system/filelist.php 566c12096002c83fd6c86138c0105f4d *dzz/system/fileselection/ajax.php f548cd2abf7a7628de34b6e69b7bed30 *dzz/system/fileselection/dzzcp.php -deb93ffb11aa3f9bc66eb8516d9d51da *dzz/system/fileselection/explorerfile.php -f7eb5195424a01c126f3beef0c88378c *dzz/system/fileselection/file.php -f27bdeee2468aba8312415c366c7fa8b *dzz/system/fileselection/json.php +9eeed160ed69666ea9edfc9f0fc6ecf3 *dzz/system/fileselection/explorerfile.php +021cf9cdb7a12cd2831baf6b46504d24 *dzz/system/fileselection/file.php +1c8bf331f565f3fb7d8849a0dbaf26c3 *dzz/system/fileselection/json.php 770af22c62d69c69a9e4ac51cab56891 *dzz/system/fileselection/listcontent.php -429ad5760831ebf1adeba30cb97df24c *dzz/system/fileselection/listtree.php +5121fe8ef7dc91ab2d9998da25e01a34 *dzz/system/fileselection/listtree.php add07479faf0fc31453f1aa961a2fad8 *dzz/system/fileselection/save.php -bfbee32ffe49867d146bf3ebcbd7ba41 *dzz/system/fileselection.php -566f25c2fe4e79b8cccbf7b7154c78e3 *dzz/system/filewindow.php -f92629a195d952a56ed79e7fc57b291b *dzz/system/function/function_filerouterule.php +6d2cd0fc5899ecb48e272fe2b18cde07 *dzz/system/fileselection.php +4d4aff3da2e4abfabe68c8d0aeae9b99 *dzz/system/filewindow.php +85abded6009c60b22f85097225b5dfaa *dzz/system/function/function_filerouterule.php 723b6c92c1bd9d60484fa92abb0c72fd *dzz/system/images/32px.png ce51355f92c8fd6132e4b2c6609f7c9b *dzz/system/images/ALIOSS.png ce51355f92c8fd6132e4b2c6609f7c9b *dzz/system/images/baiduPCS.png @@ -1567,7 +1551,7 @@ e4ed91ad5de8eebcfbcb0e94d4dac420 *dzz/system/images/user.png 4f94f0bf2df0a3b5fa89302a825f2cfe *dzz/system/images/video.png 69457ec0f7a1ab2bbea81c40588c4a10 *dzz/system/language/zh-cn/lang.php e149fb1e6f94c1fd65604b7f8f2df0c0 *dzz/system/mobilefileselection/ajax.php -0f373db8b3eb92566b402cb25da4b116 *dzz/system/mobilefileselection/file.php +36cfa42ea2a66a591fb65fb5675e4bed *dzz/system/mobilefileselection/file.php dd805ad49d4c46a8c74d1f02bbda8f8f *dzz/system/mobilefileselection/group.php 5d263468f47d57935011faad4760a4de *dzz/system/mobilefileselection/home.php 684fd045120bf39b57c64cc5502ecb54 *dzz/system/mobilefileselection/json.php @@ -1578,11 +1562,11 @@ dd805ad49d4c46a8c74d1f02bbda8f8f *dzz/system/mobilefileselection/group.php b7bf7b9750777cb9d23c28d7a75c4b18 *dzz/system/mobilefileselection.php 82a67a5f019c661d52d6a7498b0d855c *dzz/system/mobile_selectuser.php ef634dbd74bd1aa9b1eb51b5f700e11b *dzz/system/notification.php -4bab796b82b6560f0d29943405ea2998 *dzz/system/orgtree.php -881c39bbd2476e048d98ebe0c38e2cb1 *dzz/system/positionlist.php +ace7d3b5841589b6996af60e17262f1b *dzz/system/orgtree.php +466e69964c17c5e0c4597397769bd121 *dzz/system/positionlist.php f67684dc7ed0453c8a592b61a8b1504b *dzz/system/save.php -117830959dd5ad2e68969ba95e2e8789 *dzz/system/scripts/contextmenu.js -bd41ec35a66e746c81e149df8f88e485 *dzz/system/scripts/explorer.js +8df67ffbc7d0662af75ce75587fe27ad *dzz/system/scripts/contextmenu.js +c4c9098f3a3252c6c7dccdf936031e73 *dzz/system/scripts/explorer.js a788e955ad32ae1bfe871c56c5f33fbe *dzz/system/scripts/filemanage.js e2ef57a7834817cb31f270a555f22a21 *dzz/system/scripts/jquery.cookie.js 0c9023c15701761e4d67554c6097553b *dzz/system/scripts/jquery.hotkeys.js @@ -1591,10 +1575,10 @@ edaf1176cc0dcd6b07ea287b6e46c3ac *dzz/system/scripts/jquery.jstree.js 529be43900119fca34f21961b4bb0e14 *dzz/system/scripts/jquery.jstree.min.js 911a507597916339c573e9ee23c70d15 *dzz/system/scripts/mobile/appevent.js 34251ffa94136ca327f73b910d5d95c9 *dzz/system/scripts/mobile/explorer.js -b9e07bd443863975e1e67ecef6042288 *dzz/system/scripts/mobile/file_keep.js -eea9a1aad3de6ef678b02a5409f042ff *dzz/system/scripts/select-file.js +eec205779f06850b23788bcbdb791963 *dzz/system/scripts/mobile/file_keep.js +fb080370c74a70f54dabd1780456e20b *dzz/system/scripts/select-file.js 8bdcd695f15e41197d7c0e23c207b505 *dzz/system/scripts/selorg.js -7ea0d16715b5854b1b18e1920fbee161 *dzz/system/scripts/selorguser.js +87b26c22b3634317270d4f44da2b07de *dzz/system/scripts/selorguser.js eb12f0d34682685e9c0765c86f849230 *dzz/system/scripts/themes/apple/bg.jpg 84c5c7217fd02dc781c5bffd619e6f2a *dzz/system/scripts/themes/apple/d.png 8c304279c4e1d2ff621937a27c636f68 *dzz/system/scripts/themes/apple/dot_for_ie.gif @@ -1616,17 +1600,17 @@ d26c0f2c59237a6bdc1e9ca9a604075b *dzz/system/scripts/themes/default-rtl/style.cs 7b9776076d5fceef4993b55c9383dedd *dzz/system/scripts/themes/default-rtl/throbber.gif 0395803468e464876f63b25aea5889ad *dzz/system/scripts/uplodfile.js 14f91b4b5f7c7741f2dab03a97340206 *dzz/system/scripts/_hotkey.js -a5669344f30c92c568751f441fdf1739 *dzz/system/scripts/_perm.js +8b94bfe6ca28a2f1a030a1170373efc8 *dzz/system/scripts/_perm.js 8cc38e377cc8a6294ed6647cd224bf23 *dzz/system/scripts/_select.js e28c28fc8b94e3aecab50d8a7b7c875c *dzz/system/selectfile.php 7722f936f4c2c3c283b6e72c30ef6ee3 *dzz/system/selorguser.php -b45249006fcb42321f23bd834f25a005 *dzz/system/selposition.php +ea612db9647dfa2f8f11d5bad239ae81 *dzz/system/selposition.php dc1664a6d20210197360bba428c9de4e *dzz/system/template/app_ajax.htm -7771730702c65fcd8f51e3a9fb40c3b7 *dzz/system/template/filelist.htm +9184872d11d3b826cd6965a8379a7235 *dzz/system/template/filelist.htm 73cd8519b4ee8b4c2324fc0935455ef1 *dzz/system/template/fileselection/ajax.htm -02a807bc4a511347ab0f3f5efcdc76fa *dzz/system/template/fileselection/content.htm -d45f3e3b3efe2eabc577b2063080f857 *dzz/system/template/fileselection/index.htm -8f0d7ca6d3a70948721cda3b7a8013b9 *dzz/system/template/fileselection/listcontent.htm +b95ba99f2696cbde12732b83d2e5acce *dzz/system/template/fileselection/content.htm +776a90962af40fa1a2199f01c2614a00 *dzz/system/template/fileselection/index.htm +4a90743d744bd6ac36057b997aacf72d *dzz/system/template/fileselection/listcontent.htm a73d4b733d3c1a54a25c1bba8449dc45 *dzz/system/template/fileselection/right_contextmenu.htm 6a38a1b2d567c40843bdc0080f8c9201 *dzz/system/template/fileselection/template_file_detaillist.htm df4f41db142786f8832eb99c29f3c416 *dzz/system/template/fileselection/template_file_detaillist_cat.htm @@ -1634,23 +1618,23 @@ df4f41db142786f8832eb99c29f3c416 *dzz/system/template/fileselection/template_fil a5a81c7303ae24414c9a9087e46a81b4 *dzz/system/template/header_left.htm 8de513f82582c2989d238c598f3f3cd5 *dzz/system/template/header_search.htm bc910331b0e60aa33e26ade348d52ae9 *dzz/system/template/mobilefileselection/commer_header.htm -bcc7353925a55cffb28494658f9b39ed *dzz/system/template/mobilefileselection/filelist.htm +fc8a51dabb8dbc2607fb3c7dd79cb215 *dzz/system/template/mobilefileselection/filelist.htm 961bd665874805708c56fe31b33f2175 *dzz/system/template/mobilefileselection/flie_select.htm -9b58f729512964432ca3d831135ca9e3 *dzz/system/template/mobilefileselection/footer_menu.htm -53019107bd5e325ccc21079603e003c3 *dzz/system/template/mobilefileselection/group.htm -9411e701f2bbfca4ddcf1d1ffb508f24 *dzz/system/template/mobilefileselection/index.htm +031a6422b858ec0277eb048e69e2e5e3 *dzz/system/template/mobilefileselection/footer_menu.htm +ad87ddcb6434f626ca945ab06cb8709c *dzz/system/template/mobilefileselection/group.htm +e3889d3405e7529e75ea886a5df3e68a *dzz/system/template/mobilefileselection/index.htm 42eb29cad003483f7040696f9eefde76 *dzz/system/template/mobilefileselection/index_content.htm -058db13f6bb5a7d0f7eff1b2aaf163fb *dzz/system/template/mobilefileselection/search.htm -634289bb97bf0d5535d1b84804971969 *dzz/system/template/mobilefileselection/searchfile.htm +b948a426e7a9e679e06e23b399fcc636 *dzz/system/template/mobilefileselection/search.htm +3da5d148f3f2272bf4af9e354af4403c *dzz/system/template/mobilefileselection/searchfile.htm fe4fe9cbb1a72383f720cb20a30fdfee *dzz/system/template/mobile_commer_header.htm e535bcca4a9c027ad87ad54feaa540a8 *dzz/system/template/mobile_selectuser.htm e640f18f579a2e11d77562aad5d908bf *dzz/system/template/notification.htm e8812fae9454a2b0115412e2b3b88e7c *dzz/system/template/notification_list.htm 43723415cf8dcbdeb504ffb82db073a0 *dzz/system/template/notification_list_item.htm -2a00fe3e452faa5673c8565e73ddf0b0 *dzz/system/template/orgtree.htm -f3b05a45a98edc1a5ca37d5ab074895e *dzz/system/template/positionlist.htm -e6ee2e651a173533cb03a2310bdebced *dzz/system/template/selectfile.htm -fe7157dc63ca91fb69a2cbb065473f54 *dzz/system/template/selorguser.htm +5c79664f2b688683aeb20ffb2855605b *dzz/system/template/orgtree.htm +041a0fa004c38103ffd676f586d4244a *dzz/system/template/positionlist.htm +11206a88b559ee346c98caa3f14cb5ba *dzz/system/template/selectfile.htm +84a7e4ae610cb515fc791a16d2dcfb2c *dzz/system/template/selorguser.htm 6156d251d05196a574a8db0e6b41f964 *dzz/system/template/selposition.htm f76251acf9a314912f04f1623b902ffd *dzz/system/ueditor/dialogs/anchor/anchor.html 18637ff2025925f1c8efcafcffc341a6 *dzz/system/ueditor/dialogs/attachment/attachment.css @@ -2287,7 +2271,7 @@ bfc1b0155bfe9e60373c6e7f131f2771 *dzz/system/ueditor/lang/en-us/images/rotaterig c754e6ca1921cd639739499d3cf45875 *dzz/system/ueditor/lang/zh-cn/images/localimage.png 6d299069db6f24cf2ba1a90a64b49db7 *dzz/system/ueditor/lang/zh-cn/images/music.png e0a1a76441b4da770097e1af0a650b93 *dzz/system/ueditor/lang/zh-cn/images/upload.png -bbd2bce27833f90f8d2787521ea2186a *dzz/system/ueditor/lang/zh-cn/zh-cn.js +c046922f62bdacb37bcbe4b590d56f5c *dzz/system/ueditor/lang/zh-cn/zh-cn.js e2a0fce1f89aed4b628c944c3ab9cde0 *dzz/system/ueditor/php/action_crawler.php 1e0dd382e3d7a94342038a311f1231d9 *dzz/system/ueditor/php/action_list.php 2dfe45bcfd12a3936418e79e0ba82877 *dzz/system/ueditor/php/action_upload.php @@ -2416,35 +2400,56 @@ ac30cd2e245e5988d8cfb2dc6f185ec2 *dzz/system/ueditor/third-party/webuploader/web 56acbc88efd2b5c82448f8db32f1efa9 *dzz/system/ueditor/third-party/zeroclipboard/ZeroClipboard.js cd022aa32cf4146a2d405bdade9a7316 *dzz/system/ueditor/third-party/zeroclipboard/ZeroClipboard.min.js cc114c6d12a97635096956aab117b4d4 *dzz/system/ueditor/third-party/zeroclipboard/ZeroClipboard.swf -7f687126612e0ec2fe1ce34e24072a6d *dzz/system/ueditor/ueditor.all.js +037a4ecaf4744a4e122f39af23615c95 *dzz/system/ueditor/ueditor.all.js 7a7034f1b4e1add20f1c4b8739a41148 *dzz/system/ueditor/ueditor.all.min.js 782a36f7764d2c0a2fd91226c2f91cda *dzz/system/ueditor/ueditor.config.js 3697da73a28950bf921cb5f0b5b04152 *dzz/system/ueditor/ueditor.parse.js b58abee074812a05133b8cecdc06b49c *dzz/system/ueditor/ueditor.parse.min.js 1997baed351597d2dacb8bc921dcf61f *dzz/system/wxredirect.php ab0852188312b7059fb7a78d213120ee *dzz/system/wxreply.php +2a2cbdad679635d3e76e7b97249fdfae *dzz/test/admin.php +8eead96d5baf21c2204bd5956b85bd6c *dzz/test/cache/cache_test.php +db67ed148fb578eb3e3ee14fdea9acfd *dzz/test/class/class_Chareset.php +e7714107857584c473c088f975231ed1 *dzz/test/class/table/table_test.php +8f278022a583913adebae2d6c6448513 *dzz/test/classes/testone.php +eb9da3876ed34d0f7239e581b24bbed1 *dzz/test/config/config.php +1f95d935487378a755a1a96af150eef3 *dzz/test/cron/cron_test.php +0e95aa2aef8245417b076f4fc2d7129d *dzz/test/css/test.css +f4bfd375d461b8077c29a44f4c122a9f *dzz/test/disable.php +372ddf8e466ec304f791d3da5bf28c45 *dzz/test/dzz_app_test.xml +c8a141e2527dab16eb9502a528d861d1 *dzz/test/enable.php +018d15b47263832e24bce90e05b3054e *dzz/test/function/function_test.php +509626f87d1ca30ae03f2afd5262e0ef *dzz/test/images/logo.png +e41c4f28b9de883d0e5b155f03a860dd *dzz/test/index.php +85da2c89973a3fc5c7734858d0c35a4d *dzz/test/install.php +7f40b5d55586d87453e9fef94503a0bd *dzz/test/language/en-us/lang.php +e4ce999c74bf07c54a5c46fdfcaeb384 *dzz/test/language/zh-cn/lang.php +4740a4dd4a8095bc45da34fc38271867 *dzz/test/template/admin.htm +f500a7020429344dae9e95f14a6bbfc0 *dzz/test/template/header_left.htm +0eb15621c0d3f2b2802087c925ce4edc *dzz/test/template/index.htm +37549f4314517229b03320b5a43c5f52 *dzz/test/template/left.htm +21b020a05351834f3301b42924288d4c *dzz/test/uninstall.php +b4ca1cf5972929a7362cfb7a036c6868 *dzz/test/upgrade.php 5f8ca227b92f482430e36f46cc5c066d *./favicon.ico -a4a998d1fe372c0aa6e678465afa9839 *./htaccess_default.txt +8e55bdb192a3aefe82e03292527819ca *./htaccess_default.txt 7848b9ceb88ab90365a845b5d39f7093 *./index.php 0dc82c721c05ff3448accc3630f6ffd8 *install/data/common_district_1.sql 0a8a4a1c9add7650d4bb613984275876 *install/data/common_district_2.sql c5de82c7d4b3c9c1531e9974bc038c54 *install/data/common_district_3.sql -aa031dd2afb8665046655d7613032397 *install/data/install.sql -a07bbbc286113b70b75be3be49b4da20 *install/data/install_data.sql +8fb659fc5897db4ee83fdd82500368e8 *install/data/install.sql +90b8242889ae53f00ba37bb38e975fb2 *install/data/install_data.sql feabf4e4c8e20dc73548dfd6ba8400f9 *install/images/error.png 2052fa74d6a2fe7db86fbfb5c995651d *install/images/logo.png 69a3166af18f4a6be031e2e97dc5dbe1 *install/images/right.png 94b02097d5c11c5ca1c1f7ee563a3d82 *install/images/sel.png 7d7bb734d5e82ccbb7900e974b0b623a *install/images/seled.png 67adb7cd7830800342b907c551019a9c *install/images/style.css -8642606a5e849c83fb5c490fbfc41348 *install/include/install_function.php +ea85201cad0a9db4783ee273ba2d120f *install/include/install_function.php 78664d577bbaee9782bf9557faadf023 *install/include/install_mysql.php 016a91e090554f947dc50aae4d9e775e *install/include/install_mysqli.php 4b3d7be5174156972d113e5380c57f3f *install/include/install_var.php b1a6347892ab759628c7cfe188828017 *install/index.php 46973cdaf6abcfacfd5aa1622d973202 *install/language/zh-cn/lang.php -cc4425a8d590bc44a7f2b2520ea2f89e *install/update.php -070a5857e02a2f44894f1498bab6431d *./INSTALL.md c29dba799dc987e98b67d3d522ce0104 *misc/ajax.php 66ee773a4c2e373da92f48f81930cf3f *misc/classes/init.php 0b53e65b9906cd59af11acee54c5a404 *misc/movetospace.php @@ -2453,13 +2458,13 @@ ca40e2b20bdc5878ca9acaaa5686bbce *misc/seluser.php 9fb354ca17a886428060b0d9cf11d7a6 *misc/sendmail.php d520f709aafa21279e7f287dc6a8e757 *misc/sendwx.php 7fb004e91c789ea64c1bd94f6fb64408 *misc/setunrun.php +4ae6ed90ea171d5a5b918c29431938c7 *misc/shoutospace.php 90048a0cb5d78acd3b032d4a93d75809 *misc/stat.php 338e34df44c0b0b70c6d4bb0230e7d7a *misc/syscache.php d365238875a6457eaea991f1e7913309 *misc/template/misc_seluser.htm 7659b35db4c11586402ab9270f6b02e9 *misc/upgrade.php ead2f4a4b24397ab4eb610d0c1d56e39 *./misc.php -7f872b8689feda4297fc28f746ff560c *./oauth.php -313eb03434d1d0d32877e4b268f342ea *./README.md +e766f2e68c1b7cc106dca37073b657a2 *./oauth.php fb7e5f3bf418508c5f8f9af190518c45 *./share.php 94062059a2d95028d8277eeb6744e035 *./short.php b5e8fc70c992e4311bb6b762161d924f *static/artZoom/icons.png @@ -2515,20 +2520,20 @@ ccb7f3909e30b1eb8f65a24393c6e12b *static/bootstrap/js/npm.js 3e5e0fa949e0e7c5ed5fed7b4cc0ee00 *static/clipboard/clipboard.min.js 049d0dd421fcccd81a1348b30ddefec3 *static/colorPicker/jquery.colorPicker.css 0a09681bc6b8bf3628085ef083ee476a *static/colorPicker/jquery.colorPicker.js -e8742bc21d5c92f665707651928ef891 *static/css/app_manage.css +c613dea8a9d674854c7a9801042ac2e8 *static/css/app_manage.css 0558805a20efbceaea35039a548fab7f *static/css/calendar.css 3c7b7885051c739119294ba3aaee1246 *static/css/checkbox.css -f1c6e1642067c3566aba9c2b98dfa9c3 *static/css/common.css +16ff8032931d554133fb90e0e090d23b *static/css/common.css 12813c6cae76dcdcf0ca0673a085362b *static/css/jquery-ui-1.10.4.custom.min.css 2ad158db1f748f93e608bbb264f4ea93 *static/css/mabile_common.css de5cc99580baf95f1bc098b92245a547 *static/css/pc-commer-header.css 1f85070b3a3652886cba741f23b9eef2 *static/css/smilies.css b3d07bda63452a4c717858f586653c28 *static/css/tip.css -3136991c56120ca276d6e0184f664b39 *static/dzzicon/fonts/dzz.eot -550c5d5904be0de71fc276a2482357f6 *static/dzzicon/fonts/dzz.svg -d87f8e6fb9f1ed54488b93d0e3d6dd74 *static/dzzicon/fonts/dzz.ttf -17bac9f0673bb8acb45d84e525bd6d63 *static/dzzicon/fonts/dzz.woff -9a7713536989edf056c7151189a5fae0 *static/dzzicon/icon.css +20f7dec08bcdab872f92e5fd00658bf7 *static/dzzicon/fonts/dzz.eot +bab5426c2e41cac25a364bca0d0687bf *static/dzzicon/fonts/dzz.svg +2545315cf884316f38d4ca50e07f5bc3 *static/dzzicon/fonts/dzz.ttf +68e44d78b03d25cb3d817eb619920fc2 *static/dzzicon/fonts/dzz.woff +09b33a5885a3ff265ca5ce6684031bb0 *static/dzzicon/icon.css 012634aaff45d55d359f7d7f43a8ebbd *static/dzzthumb/jquery.dzzthumb.css 2dce0d1499511aa23bda5b11b611c1b9 *static/dzzthumb/jquery.dzzthumb.js 325472601571f31e1bf00674c368d335 *static/dzzthumb/preview/b.gif @@ -2997,14 +3002,16 @@ b6ec8daaae10608b00f8c8661d97aab8 *static/jquery/jquery.json-2.4.min.js e071abda8fe61194711cfc2ab99fe104 *static/jquery/jquery.min.js 0da6f8ef76956f6ce7842dcf8941d1fa *static/jquery_file_upload/jquery.fileupload-process.js 16e6097813691c721f0e442f66360671 *static/jquery_file_upload/jquery.fileupload-validate.js -82187ca3f8a464cda4c5a9e3305cd56c *static/jquery_file_upload/jquery.fileupload.js +9d50227c013d7811de3d78deb8f7130a *static/jquery_file_upload/jquery.fileupload.js 487d5e5434beb03193861df573f01a93 *static/jquery_file_upload/jquery.iframe-transport.js 2f930cbfc9194f627fcc81f38cc73f04 *static/jquery_file_upload/jquery.ui.widget.js f8fdde04bdba1cc2763489e9475db740 *static/jquery_weui/.project 1d7f35266a0212c704e1fe066bf6f925 *static/jquery_weui/css/jquery-weui.min.css 830c01b15f1878fb94955ce159b1b603 *static/jquery_weui/css/weui.min.css +d09dc6fa2f453e5f51d331b05f80da22 *static/jquery_weui/js/appevent.js 3f3688138a1b9fc4ef669ce9056b6674 *static/jquery_weui/js/clipboard.min.js 215a68f06c7a0ffc44a579e8d18c19ab *static/jquery_weui/js/iscroll.js +5b355252b434617b7698333dee32cd0c *static/jquery_weui/js/jquery-weui.js 5336279efb617948c7975329a36eda43 *static/jquery_weui/js/jquery-weui.min.js e8a6b09a1b7f9b446eb201bb8011f86b *static/jquery_weui/js/navbarscroll.js 508d39206ef0008f8f468d3319b5da39 *static/jquery_weui/js/swiper.min.js @@ -3141,7 +3148,7 @@ b44074283db826a5f313757d6491f83a *static/js/bootstrap_datetimepicker/locales/boo 1c1e7187f0f4e00351fa7bdde9ee659e *static/js/bootstrap_datetimepicker/locales/bootstrap-datetimepicker.zh-CN.js 3c85783a31ea941cd4e1b032564c06d2 *static/js/bootstrap_datetimepicker/locales/bootstrap-datetimepicker.zh-TW.js 17b22da8aa4a35cac01d4816ad4c6eb9 *static/js/calendar.js -7bfea4f846f4e1552cbc9513df0b25e9 *static/js/common.js +b8c88d6de7981570261bb61511e30fa9 *static/js/common.js a3adf3f1ec2b774b272cbad60225a07b *static/js/datepicker/datepicker.css 36300a5ad0df4ef4ffe96934e940a219 *static/js/datepicker/jquery-ui-sliderAccess.js 159a27f2a686fb26e4a2045791f2380d *static/js/datepicker/jquery-ui-timepicker-addon.css @@ -3156,11 +3163,11 @@ df3fc0134f614f3879fb9005ba84abe4 *static/js/datepicker/jquery.ui.datepicker.js 7c44be106a61d3d1f5a22891d09fd734 *static/js/echarts.min.js dab27680f9accd4904c2106d5a439aea *static/js/header.js 4f94014ad9416a32e4a666e2c1a1bdd0 *static/js/imgReady.js -e36054c4f30541569565da8fe26ef1e9 *static/js/input_field.js +73b4b4085631867187276763e27ec392 *static/js/input_field.js 5849f3ff1537c3f9541bc7ad6e488ba0 *static/js/jquery.dragsort.js b4a8e5f8ec11754486eb8bf13a564d31 *static/js/jquery.highlight.js 6661199d97a935a23d46e9aa417a34c8 *static/js/jquery.kpdragsort.js -d630c3f5a0ecf53cb465eb04bc4c70d5 *static/js/jquery.leftDrager.js +21bbe39a4b911093afb22330c93a5eda *static/js/jquery.leftDrager.js 214ee334bd63ceb72b99b11a64799843 *static/js/jquery.mousewheel.js fca2e25aa726c6b099b4927782c96c2b *static/js/jquery.mousewheel.min.js c3dc7adae0c99f9a2010db8b29597a57 *static/js/jquery.placeholder.js @@ -3262,17 +3269,22 @@ fc4180203086f4db5723547477eb472f *static/select2/select2_locale_uk.js ce82206856d06c84b34b4750cf97fdf9 *static/select2/select2_locale_vi.js 81534c478c919097a58b0154664c1ee2 *static/select2/select2_locale_zh-CN.js 4c8498c7c7c582df2fe30520e64d8656 *static/select2/select2_locale_zh-TW.js +5c0f2c77026394b48961a2072e95068b *static/swiper/css/swiper.min.css +b109a73709caae2f915322813d5c220c *static/swiper/js/swiper.esm.bundle.js +21b877f9a29f091476b354f8379bcf62 *static/swiper/js/swiper.esm.js +7e8c599bc997edce03bdb105d93d5778 *static/swiper/js/swiper.js +b117060487d6ec17a9af7c5604a2c149 *static/swiper/js/swiper.min.js +82e4bfd0d39227dd6c33fefd69273788 *static/swiper/js/swiper.min.js.map 3d5c5f2d195cad6c3658bec52095df6b *static/switchery/switchery.min.css 82cf31e4c3a14ee9394c27cb900594c4 *static/switchery/switchery.min.js 5595c0a1d4b5200c42d3f10ee1a6f84e *static/tagsinput/jquery.tagsinput.css 16514f2dfada9501ab4e67c06b1706c6 *static/tagsinput/jquery.tagsinput.js -0e35a4f4d3b2da5b4d63cdd03b12e931 *./UPDATE.md cf0217a7943a59544537c29bfbee4e04 *user/ajax.php fea650655045ad578b46a224a3160e6b *user/classes/checklogin.php eb22faca2d0fe52c1e07a2719d2993a7 *user/classes/init.php 7369a569df07dad3b5d04b0938f13d7c *user/classes/route.php 29040baeef0147f66b8f939a815238d0 *user/classes/safechk.php -dd9483d4486854c4a342a197ca0efb19 *user/config/config.php +dea154c78c41460a64208fc72c33da8b *user/config/config.php 135aa86eb76ce37e5486d4fdc09c6f09 *user/function/function_profile.php ad0e8c5d9dca7a71e1064afafcab2d1d *user/function/function_user.php ddc9fcc5febab3bffe367bd2ba13dd6b *user/images/qq.png @@ -3307,7 +3319,7 @@ e962c9542c32b16cb7fb4e1407f24eff *user/profile/avatar.php 191b74f0d557e01e510e676d0eda1dc8 *user/profile/config/config.php 91eb6c4b4f48e2c20ce2b839e4629178 *user/profile/css/passsafe.css 575242cca40051543b7e43d398475bd0 *user/profile/images/step.png -a9f5f196289c95451df854c717322ddf *user/profile/index.php +dd01a34308cae40a3ae1cd2e297a4316 *user/profile/index.php 8e92af61ec0c2cc39d9b17a13186983b *user/profile/password.php ba0919fac2f4cd8666b00e150f9cf702 *user/profile/safeverify.php 767d077f52985cd74f3af4dfc8256e8b *user/profile/scripts/email.js @@ -3316,10 +3328,10 @@ ba0919fac2f4cd8666b00e150f9cf702 *user/profile/safeverify.php 4e01e0744f8e227ca5a9808d86d24209 *user/profile/template/editpass.htm 846c2810477f30a3d9d4faa86f8cb536 *user/profile/template/left.htm 9822c6a89a9318164933b70c02e27d36 *user/profile/template/pass_safe.htm -2ec8a66dcc8968f15f3dd91fe5f8a066 *user/profile/template/profile.htm +10d2fdc4f8b6ccca3031b8bc70fba6f0 *user/profile/template/profile.htm 69d7060500bcff9ec2286d95b16680da *user/register/ajax.php b4abf039c134d84eb99e5646adb5c139 *user/register/classes/checkvalue.php -412b68f4f812be1ded4dafcb9d47f13c *user/register/classes/regcommon.php +465b3ce03364c88154cd36c6d36978ac *user/register/classes/regcommon.php 8f50bca9aa9098dc8e1495b33cde9036 *user/register/classes/register.php 80c6a1daadb5fb4296a415118f529372 *user/register/images/register.css c9b53eec589aebfa4250ebeaa04ad283 *user/register/register.php @@ -3340,12 +3352,5 @@ ad472bd6461c3b3193ef20f147da5d61 *user/scripts/setbacksize.js 9f1473e15c10a73853e160f6c51e5c76 *user/space/navmenu.php 1d40e59cddf7a8d01e710b637806d59d *user/space/template/navmenu.htm b1a1c62e9c79bd181152c0d97755c5d8 *user/space/template/space.htm -2cb7057cee9c0907fcb813c85c410929 *user/sso/classes/oauth.php -c544db827330cf2327a4a4c32456d287 *user/sso/index.php -c71db25f9dacca81e124c6e3b7f0f8e1 *user/sso/template/index.htm -8085cb01df6b09a8fcad2273ffd679cc *user/sso/template/login.htm -da1a6eb90532a13e2399939be5e47d30 *user/sso/template/login_single.htm -ae27d428ddc42df55a01fa29fb342c43 *user/sso/template/login_single_mobile.htm -d28233af369fb8dbff23ae32ed050102 *user/sso/template/login_skip.htm 19ed3f8ff75b0bff6d0c8ee2ee5d744c *user/template/ajax.htm 0afe99a0801e30516384c5de21a35f7f *./user.php diff --git a/admin/filemanage/index.php b/admin/filemanage/index.php index f9d79a2..83b6e7f 100644 --- a/admin/filemanage/index.php +++ b/admin/filemanage/index.php @@ -6,143 +6,145 @@ * @link http://www.dzzoffice.com * @author zyx(zyx@dzz.cc) */ -if(!defined('IN_DZZ') || !defined('IN_ADMIN')) { - exit('Access Denied'); +if (!defined('IN_DZZ') || !defined('IN_ADMIN')) { + exit('Access Denied'); } -$navtitle= lang('appname'); -define('DZZSCRIPT','index.php'); -$typearr=array('image'=>lang('photo'), - 'document'=>lang('type_attach'), - 'link'=>lang('type_link'), - 'video'=>lang('online_video'), - 'dzzdoc'=>'DZZ'.lang('type_attach'), - 'attach'=>lang('rest_attachment') - ); +$navtitle = lang('appname'); +define('DZZSCRIPT', 'index.php'); +$typearr = array('image' => lang('photo'), + 'document' => lang('type_attach'), + 'link' => lang('type_link'), + 'video' => lang('online_video'), + 'dzzdoc' => 'DZZ' . lang('type_attach'), + 'attach' => lang('rest_attachment') +); require libfile('function/organization'); -if($_GET['do']=='delete'){ - $icoid=isset($_GET['icoid'])?trim($_GET['icoid']):''; - $icoids=explode(',',$icoid); - $ridarr = array(); - $bz= isset($_GET['bz']) ? trim($_GET['bz']):''; - foreach($icoids as $icoid){ - if(empty($icoid)){ - continue; - } - $return=IO::Delete($icoid,true); - if(!$return['error']){ - //处理数据 - $arr['sucessicoids'][$return['rid']]=$return['rid']; - $arr['msg'][$return['rid']]='success'; - $arr['name'][$return['rid']] = $return['name']; - $ridarr[]= $return['rid']; - $i++; - }else{ - $arr['msg'][$return['rid']]=$return['error']; - } - } - if(!$return['error']){ - showmessage('do_success',$_GET['refer']); - }else{ - showmessage($return['error'],$_GET['refer']); - } +if ($_GET['do'] == 'delete') { + $icoid = isset($_GET['icoid']) ? trim($_GET['icoid']) : ''; + $icoids = explode(',', $icoid); + $ridarr = array(); + $bz = isset($_GET['bz']) ? trim($_GET['bz']) : ''; + foreach ($icoids as $icoid) { + if (empty($icoid)) { + continue; + } + $return = IO::Delete($icoid, true); + if (!$return['error']) { + //处理数据 + $arr['sucessicoids'][$return['rid']] = $return['rid']; + $arr['msg'][$return['rid']] = 'success'; + $arr['name'][$return['rid']] = $return['name']; + $ridarr[] = $return['rid']; + $i++; + } else { + $arr['msg'][$return['rid']] = $return['error']; + $dels[] = $icoid.'_0'; + } + } + if (!$return['error']) { + Hook::listen('solrdel',$dels); + showmessage('do_success', $_GET['refer']); + } else { + showmessage($return['error'], $_GET['refer']); + } -}else{ - $perpage=20; - $pfid = isset($_GET['pfid']) ? intval($_GET['pfid']):''; - $type=isset($_GET['type']) ? trim($_GET['type']):''; - $keyword=isset($_GET['keyword']) ? trim($_GET['keyword']):''; - $orgid= isset($_GET['orgid']) ? intval($_GET['orgid']):''; - $page = (isset($_GET['page'])) ? intval($_GET['page']):1; - $start = ($page - 1) * $perpage; - $gets = array( - 'mod'=>'filemanage', - 'keyword'=>$keyword, - 'type' => $_GET['type'], - 'size'=>$_GET['size'], - 'dateline'=>$_GET['dateline'], - 'orgid'=>$orgid, - 'pfid'=>$pfid - ); - $theurl = BASESCRIPT."?".url_implode($gets); - $refer=$theurl.'&page='.$page; - if($_GET['size']=='desc'){ - $order='ORDER BY size DESC'; - }elseif($_GET['size']=='asc'){ - $order='ORDER BY size ASC'; - }elseif($_GET['dateline']=='asc'){ - $order='ORDER BY dateline ASC'; - }else{ - $_GET['dateline']='desc'; - $order='ORDER BY size DESC'; - } - $sql="type!='app' and type!='shortcut'"; - $foldername = array(); - $param=array(); - if($keyword) { - $sql.=' and (name like %s OR username=%s)'; - $param[]='%'.$keyword.'%'; - $param[]=$keyword; - } - if($type){ - $sql.=' and type=%s'; - $param[]=$type; - } - if($pfid){ - $sql.=' and (pfid = %d)'; - $param[]=$pfid; - $pathkey = DB::result_first("select pathkey from %t where fid = %d",array('resources_path',$pfid)); - $patharr = explode('-',str_replace('_','',$pathkey)); - unset($patharr[0]); - foreach(DB::fetch_all("select fname,fid from %t where fid in(%n)",array('folder',$patharr)) as $v){ - $foldername[] = array('fid'=>$v['fid'],'fname'=>$v['fname']); - } - }else{ - if($orgid){ - if($org=C::t('organization')->fetch($orgid)){ - $fids=array($org['fid']); - foreach(DB::fetch_all("select fid from %t where pfid=%d",array('folder',$org['fid'])) as $value){ - $fids[]=$value['fid']; - } - $sql.=' and pfid IN(%n)'; - $param[]=$fids; - } - }else{ - $flags = array('home','organization'); - $fids = C::t('folder')->fetch_fid_by_flags($flags); - $sql.=' and pfid IN(%n)'; - $param[]=$fids; - } - } - $limitsql = 'limit '.$start .','. $perpage; - if($count=DB::result_first("SELECT COUNT(*) FROM ".DB::table('resources')." WHERE $sql",$param)){ - /*if(ceil($count/$perpage)<$page){ - $page=ceil($count/$perpage); - $start=($page-1)*$perpage; - }*/ - $data=DB::fetch_all("SELECT rid FROM ".DB::table('resources')." WHERE $sql $order $limitsql",$param); - $multi=multi($count, $perpage, $page, $theurl); - } - - $list=array(); - foreach($data as $value){ - if(!$sourcedata=C::t('resources')->fetch_by_rid($value['rid'])){ - continue; - } - $list[]=$sourcedata; - } - if($org=C::t('organization')->fetch($orgid)){ - $orgpath=getPathByOrgid($org['orgid']); - $org['depart']=implode('-',($orgpath)); - }else{ - $org=array(); - $org['depart']=lang('select_a_organization_or_department'); - $org['orgid']=$orgid; - } - /*if ($count > $perpage*$page) { - $nextpage = $page + 1; - } else { - $naxtpage = 0; - }*/ - include template('list'); +} else { + $perpage = 20; + $pfid = isset($_GET['pfid']) ? intval($_GET['pfid']) : ''; + $type = isset($_GET['type']) ? trim($_GET['type']) : ''; + $keyword = isset($_GET['keyword']) ? trim($_GET['keyword']) : ''; + $orgid = isset($_GET['orgid']) ? intval($_GET['orgid']) : ''; + $page = (isset($_GET['page'])) ? intval($_GET['page']) : 1; + $start = ($page - 1) * $perpage; + $gets = array( + 'mod' => 'filemanage', + 'keyword' => $keyword, + 'type' => $_GET['type'], + 'size' => $_GET['size'], + 'dateline' => $_GET['dateline'], + 'orgid' => $orgid, + 'pfid' => $pfid + ); + $theurl = BASESCRIPT . "?" . url_implode($gets); + $refer = $theurl . '&page=' . $page; + if ($_GET['size'] == 'desc') { + $order = 'ORDER BY size DESC'; + } elseif ($_GET['size'] == 'asc') { + $order = 'ORDER BY size ASC'; + } elseif ($_GET['dateline'] == 'asc') { + $order = 'ORDER BY dateline ASC'; + } else { + $_GET['dateline'] = 'desc'; + $order = 'ORDER BY size DESC'; + } + $sql = "type!='app' and type!='shortcut'"; + $foldername = array(); + $param = array(); + if ($keyword) { + $sql .= ' and (name like %s OR username=%s)'; + $param[] = '%' . $keyword . '%'; + $param[] = $keyword; + } + if ($type) { + $sql .= ' and type=%s'; + $param[] = $type; + } + if ($pfid) { + $sql .= ' and (pfid = %d)'; + $param[] = $pfid; + $pathkey = DB::result_first("select pathkey from %t where fid = %d", array('resources_path', $pfid)); + $patharr = explode('-', str_replace('_', '', $pathkey)); + unset($patharr[0]); + foreach (DB::fetch_all("select fname,fid from %t where fid in(%n)", array('folder', $patharr)) as $v) { + $foldername[] = array('fid' => $v['fid'], 'fname' => $v['fname']); + } + } else { + if ($orgid) { + if ($org = C::t('organization')->fetch($orgid)) { + $fids = array($org['fid']); + foreach (DB::fetch_all("select fid from %t where pfid=%d", array('folder', $org['fid'])) as $value) { + $fids[] = $value['fid']; + } + $sql .= ' and pfid IN(%n)'; + $param[] = $fids; + } + }/*else{ + $sql .= ' and pfid > 0'; + }*//* else { + $flags = array('home', 'organization'); + $fids = C::t('folder')->fetch_fid_by_flags($flags); + $sql .= ' and pfid IN(%n)'; + $param[] = $fids; + }*/ + } + $limitsql = 'limit ' . $start . ',' . $perpage; + if ($count = DB::result_first("SELECT COUNT(*) FROM " . DB::table('resources') . " WHERE $sql", $param)) { + $data = DB::fetch_all("SELECT rid FROM " . DB::table('resources') . " WHERE $sql $order $limitsql", $param); + $multi = multi($count, $perpage, $page, $theurl); + } + $list = array(); + foreach ($data as $value) { + if (!$sourcedata = C::t('resources')->fetch_by_rid($value['rid'])) { + continue; + } + if($sourcedata['relpath'] == '/'){ + $sourcedata['relpath'] = '回收站'; + } + $list[] = $sourcedata; + } + if ($org = C::t('organization')->fetch($orgid)) { + $orgpath = getPathByOrgid($org['orgid']); + $org['depart'] = implode('-', ($orgpath)); + } else { + $org = array(); + $org['depart'] = lang('select_a_organization_or_department'); + $org['orgid'] = $orgid; + } + /*if ($count > $perpage*$page) { + $nextpage = $page + 1; + } else { + $naxtpage = 0; + }*/ + include template('list'); } ?> diff --git a/admin/filemanage/language/zh-cn/lang.php b/admin/filemanage/language/zh-cn/lang.php index 97e93e1..1cd5544 100644 --- a/admin/filemanage/language/zh-cn/lang.php +++ b/admin/filemanage/language/zh-cn/lang.php @@ -2,6 +2,8 @@ $lang = array ( 'appname' => '文件管理', 'rotation'=>'旋转', - 'checkednum'=>'已选择项' + 'checkednum'=>'已选择项', + 'file_position'=>'文件位置', + 'in_recycle'=>'在回收站', ); ?> \ No newline at end of file diff --git a/admin/filemanage/template/list.htm b/admin/filemanage/template/list.htm index 13aea14..90c85bc 100644 --- a/admin/filemanage/template/list.htm +++ b/admin/filemanage/template/list.htm @@ -80,12 +80,19 @@ + @@ -187,11 +194,6 @@ var page_loading = false; jQuery('.left-drager').leftDrager_layout(); - - - - - function setLoadedNum() { jQuery('.loaded-num').html(jQuery('.list-share .item').length); if(!jQuery('.list-share .more').length) { @@ -243,7 +245,7 @@ var theurl='$theurl'; var param=el.data('key')+'='+ (el.find('.asc').hasClass('desc') ? 'desc' : 'asc'); var regx=new RegExp('&(dateline|size)=(asc|desc)','i'); var url=theurl.replace(regx,'')+'&'+param; - location.href=url; + location.href=correcturl(url); }); jQuery(document).on('click', 'a[data-key=download]', function() { download(this); @@ -256,9 +258,9 @@ var theurl='$theurl'; var url = DZZSCRIPT + '?mod=io&op=download&path=' + li.data('dpath'); if(BROWSER.ie) { - window.open(url); + window.open(correcturl(url)); } else { - window.frames['hideframe'].location = url; + window.frames['hideframe'].location = correcturl(url); } } @@ -349,4 +351,4 @@ function delete_file(){ } - \ No newline at end of file + \ No newline at end of file diff --git a/admin/function/function_admin.php b/admin/function/function_admin.php index f9e9b83..80de883 100644 --- a/admin/function/function_admin.php +++ b/admin/function/function_admin.php @@ -14,7 +14,8 @@ function runquery($sql) { $tablepre = $_G['config']['db'][1]['tablepre']; $dbcharset = $_G['config']['db'][1]['dbcharset']; - $sql = str_replace(array(' dzz_', ' `dzz_',' cdb_', ' `cdb_', ' pre_', ' `pre_'), array(' {tablepre}', ' `{tablepre}',' {tablepre}', ' `{tablepre}', ' {tablepre}', ' `{tablepre}'), $sql); + $sql = str_replace(array(' dzz_', ' `dzz_',' cdb_', ' `cdb_' ), array(' {tablepre}', ' `{tablepre}',' {tablepre}', ' `{tablepre}' ), $sql); + $sql = str_replace("\r", "\n", str_replace(array(' {tablepre}', ' `{tablepre}'), array(' '.$tablepre, ' `'.$tablepre), $sql)); $ret = array(); @@ -162,10 +163,10 @@ function exportdata($name, $filename, $data) { 'Version' => $_G['setting']['version'], 'Time' => dgmdate(TIMESTAMP, 'Y-m-d H:i'), 'From' => $_G['setting']['bbname'].' ('.$_G['siteurl'].')', - 'Data' => exportarray($data, 1) - ); + 'Data' => exportarray($data, 1) + ); $filename = strtolower(str_replace(array('!', ' '), array('', '_'), $name)).'_'.$filename.'.xml'; - $plugin_export = array2xml($root, 1); + $plugin_export = array2xml($root, 1); ob_end_clean(); dheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); dheader('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); @@ -242,8 +243,8 @@ function importByarray($arr,$force=0){ $app['available']=0; $appid=$app['appid']=C::t('app_market')->insert($app,1); } - if($arr['hooks']){//初始化钩子 - C::t('hooks')->insert_by_appid($appid,$arr['hooks']); + if($arr['hooks']){//初始化钩子 + C::t('hooks')->insert_by_appid($appid,$arr['hooks'],$arr['_attributes']['hooks']); } if($appid){ C::t('app_open')->insert_by_exts($appid,($app['fileext']?explode(',',$app['fileext']):array())); diff --git a/admin/member/template/profile.htm b/admin/member/template/profile.htm index 50e8c78..146f58f 100644 --- a/admin/member/template/profile.htm +++ b/admin/member/template/profile.htm @@ -35,22 +35,22 @@
-
+ diff --git a/admin/member/template/profileset.htm b/admin/member/template/profileset.htm index 4f439fa..8a2c265 100644 --- a/admin/member/template/profileset.htm +++ b/admin/member/template/profileset.htm @@ -49,11 +49,11 @@
@@ -74,7 +74,7 @@
- + @@ -89,9 +89,9 @@ @@ -112,7 +112,7 @@ - + + + +
+
\ No newline at end of file diff --git a/core/template/default/common/mobile_simple_start.htm b/core/template/default/common/mobile_simple_start.htm index aa61a7f..a688e24 100644 --- a/core/template/default/common/mobile_simple_start.htm +++ b/core/template/default/common/mobile_simple_start.htm @@ -14,8 +14,10 @@ - + - \ No newline at end of file + + + \ No newline at end of file diff --git a/dzz/attach/saveto.php b/dzz/attach/saveto.php index b88b0ea..a902325 100644 --- a/dzz/attach/saveto.php +++ b/dzz/attach/saveto.php @@ -50,8 +50,8 @@ if($_GET['type']=='link'){ if(isset($icoarr['error'])) topshowmessage($icoarr['error']); include template('common/header_simple'); echo ""; include template('common/footer'); exit(); diff --git a/dzz/comment/ajax.php b/dzz/comment/ajax.php index b155b7d..f32f8b0 100644 --- a/dzz/comment/ajax.php +++ b/dzz/comment/ajax.php @@ -87,7 +87,7 @@ if (submitcheck('replysubmit')) { } elseif ($do == 'getcomment') { - $id = trim($_GET['id'], 60); + $id = getstr($_GET['id'], 60); $idtype = trim($_GET['idtype']); $page = empty($_GET['page']) ? 1 : intval($_GET['page']); $perpage = 10; diff --git a/dzz/comment/images/comment.css b/dzz/comment/images/comment.css index 9286086..b36e736 100644 --- a/dzz/comment/images/comment.css +++ b/dzz/comment/images/comment.css @@ -514,7 +514,9 @@ a.ui-artZoom-hide:hover span, ._tt_tasklist li .ui-artZoom-hide.title_tttl:hover .item_afed{ padding-bottom:10px; } - +.item_afed:hover { + background-color: #FBFBFB; +} .lquote_mmfed { width: 16px; height: 11px; @@ -754,7 +756,6 @@ a.ui-artZoom-hide:hover span, ._tt_tasklist li .ui-artZoom-hide.title_tttl:hover } .img_pfed .txt_ipfed { padding: 2px 5px; - font: 12px/14px Verdana, "\5B8B\4F53", "\65B0\5B8B\4F53", sans-serif; border: 1px solid #aaa; display: inline-block } @@ -767,12 +768,8 @@ a.ui-artZoom-hide:hover span, ._tt_tasklist li .ui-artZoom-hide.title_tttl:hover display: inline-block } .img_pfed .min_ipfed img { - max-width: 120px; - max-height: 80px -} -* .img_pfed .min_ipfed img{ - width: expression(this.width > 120 && this.width>=this.height ? 120: true); - height: expression(this.height > 80 && this.width<=this.height ? 80 : true); + max-width: 100%; + /*max-height: 80px*/ } .name_pfed { diff --git a/dzz/comment/saveto.php b/dzz/comment/saveto.php index e1e933f..b58aaec 100644 --- a/dzz/comment/saveto.php +++ b/dzz/comment/saveto.php @@ -10,29 +10,12 @@ if (!defined('IN_DZZ')) { exit('Access Denied'); } -if (empty($_G['uid'])) { - include template('common/header_reload'); - echo ""; - include template('common/footer_reload'); - exit(''.lang('need_login').''); -} + $qid = intval($_GET['qid']); $attach = C::t('comment_attach') -> fetch_by_qid($qid); if (!$attach) { topshowmessage(lang('attachment_nonexistence')); }$attach['filename'] = $attach['title']; -$pfid = DB::result_first("select fid from %t where flag='document' and uid= %d", array('folder', $_G['uid'])); +$pfid = $_GET['fid']; $icoarr = io_dzz::uploadToattachment($attach, $pfid); -if (isset($icoarr['error'])) - topshowmessage($icoarr['error']); -include template('common/header_simple'); -echo ""; -include template('common/footer'); -exit(); -?> +exit(json_encode($icoarr)); diff --git a/dzz/comment/scripts/comment.js b/dzz/comment/scripts/comment.js index 39dfb56..934fe31 100644 --- a/dzz/comment/scripts/comment.js +++ b/dzz/comment/scripts/comment.js @@ -14,7 +14,7 @@ for(var i in arr['attachs']){ html+='
'; if(attach.type=='image'){ html+='
'; - html+='
'+attach['title']+'
'; + html+='
'+attach['title']+'
'; html+='
'; html+='
'+attach['title']+'('+attach['filesize']+')'; html+='

'; @@ -23,7 +23,7 @@ for(var i in arr['attachs']){ }else{ html+=' '+__lang.download+''; } - html+=' '+__lang.js_saved_my_documents+' '; + html+=' '+__lang.js_saved_my_documents+' '; html+='

'; html+='
'; }else if(attach.type=='video'){ @@ -71,7 +71,7 @@ for(var i in arr['attachs']){ html+='
'; html+='
'; html+=' '; @@ -100,7 +100,7 @@ for(var i in arr['attachs']){ jQuery('#message_'+tid).css({'height':25}); jQuery('#attachmentViewBox_'+tid).empty(); //location.hash='#comment_'+arr['cid']; - + jQuery('#comment_'+arr['cid']+' img[data-original]').dzzthumb(); try{ callback_by_comment('comment_'+arr['cid'],'add'); }catch(e){} @@ -126,7 +126,7 @@ function feed_reply(arr){ html+='
'; if(attach.type=='image'){ html+='
'; - html+='
'+attach['title']+'
'; + html+='
'+attach['title']+'
'; html+='
'; html+='
'+attach['title']+'('+attach['filesize']+')'; html+='

'; @@ -144,7 +144,7 @@ function feed_reply(arr){ html+='

'+attach['title']+'

'; html+='

'; html+=' '+__lang.preview+''; - html+=' '+__lang.js_saved_my_documents+' '; + // html+=' '+__lang.js_saved_my_documents+' '; html+='

'; html+='
'; }else if(attach.type=='dzzdoc' || attach.type=='link'){ @@ -179,7 +179,7 @@ function feed_reply(arr){ html+='
'; html+='
    '; if(arr['haveperm']>0){ - html+='
  • '+__lang.edit+'
  • '; + // html+='
  • '+__lang.edit+'
  • '; html+='
  • '+__lang.delete+'
  • '; } html+='
  • '+__lang.reply+'
  • '; @@ -213,6 +213,7 @@ function feed_reply(arr){ jQuery('#reply_publish_'+arr['pcid']).slideUp(500); jQuery('#attachmentViewBox_'+arr['pcid']).empty(); //location.hash=('#comment_'+arr['pcid']); + jQuery('#comment_'+arr['cid']+' img[data-original]').dzzthumb(); } function getReplyForm(tid,pid,allowattach,allowat,allowsmiley){ @@ -321,8 +322,16 @@ function feed_downAttach(qid){ } function feed_attach_saveto(qid){ var url=DZZSCRIPT+'?mod=comment&op=saveto&qid='+qid; - if(!window.frames['hidefram']) jQuery('').appendTo('body'); - window.frames['hideframe'].location=url; + showWindow('saveto','index.php?mod=system&op=filewindow&type=2','get','0',function(fid,data){ + jQuery.post(url,{fid:fid},function(json){ + if(json.error){ + showmessage(json.error,'danger',3000,1); + }else{ + showmessage(__lang.savetosuccess+data.relativepath+json.filename,'success',3000,1); + } + },'json'); + }); + } function feed_attach_preview(qid){ @@ -333,6 +342,10 @@ function feed_attach_preview(qid){ window.frames['hideframe'].location=url; } } +function feed_attach_del(qid){ + var url=DZZSCRIPT+'?mod=comment&op=delete&qid='+qid; + +} function check_attach_share_tid(tid){ if(!tid) tid='0'; @@ -361,13 +374,18 @@ function removeAttach(el,tid){ function uploadfrom_desktop(tid){ if(!tid) tid='0'; try{ - parent.OpenFile('open',__lang.open_file,{attach:[__lang.typename_attach,['ATTACH','IMAGE','DOCUMENT','VIDEO','LINK','DZZDOC'],''],image:[__lang.type_image+'(*.jpg,*.jpeg,*.png,*.gif)',['IMAGE','JPG','JPEG','PNG','GIF'],'']},{bz:'',multiple:true},function(data){//只打开本地盘 - var datas=[]; - if(data.params.multiple){ - datas=data.icodata - }else{ - datas=[data.icodata]; - } + var openexts = { + attach:[__lang.typename_attach,["ATTACH","IMAGE","DOCUMENT","VIDEO","LINK","DZZDOC"],""], + image:[__lang.typename_image+"(*.jpg,*.jpeg,*.png,*.gif)",["IMAGE","JPG","JPEG","PNG","GIF"],""] + }; + var exts=JSON.stringify(openexts); + exts = exts.replace(/\"/g,'"'); + exts = exts.replace(/\(/g,'|'); + exts = exts.replace(/\)/g,'$'); + exts = encodeURIComponent(exts); + showWindow('openfile', 'index.php?mod=system&op=filewindow&handlekey=svaefile&mulitype=1&exts='+exts+'&callback=opencallback', 'get', '0',function(data){//只打开本地盘 + var datas=data; + for(var i in datas){ var arr=datas[i]; @@ -403,7 +421,7 @@ function uploadfrom_desktop(tid){ } }); }catch(e){ - alert(__lang.please_use_desktop); + } } diff --git a/dzz/comment/template/publish_form.htm b/dzz/comment/template/publish_form.htm index 14bfc48..68a036b 100644 --- a/dzz/comment/template/publish_form.htm +++ b/dzz/comment/template/publish_form.htm @@ -53,7 +53,7 @@
- +
diff --git a/dzz/comment/template/reply_form.htm b/dzz/comment/template/reply_form.htm index 5181c14..8f284cd 100644 --- a/dzz/comment/template/reply_form.htm +++ b/dzz/comment/template/reply_form.htm @@ -54,7 +54,7 @@
diff --git a/dzz/comment/template/reply_item.htm b/dzz/comment/template/reply_item.htm index 6d92c00..924b4c5 100644 --- a/dzz/comment/template/reply_item.htm +++ b/dzz/comment/template/reply_item.htm @@ -25,11 +25,11 @@
@@ -70,7 +70,7 @@ ($attach[downloads]{lang degree}) - + {lang js_saved_my_documents}

diff --git a/dzz/comment/template/thread_item.htm b/dzz/comment/template/thread_item.htm index 9c7c858..8e6621c 100644 --- a/dzz/comment/template/thread_item.htm +++ b/dzz/comment/template/thread_item.htm @@ -23,7 +23,7 @@ {lang download} ($attach[downloads]{lang degree}) - + {lang js_saved_my_documents}

@@ -62,7 +62,7 @@ {lang download} ($attach[downloads]{lang degree}) - + {lang js_saved_my_documents}

diff --git a/dzz/config/config-sample.php b/dzz/config/config-sample.php index 2ae7cdc..d90e3e7 100644 --- a/dzz/config/config-sample.php +++ b/dzz/config/config-sample.php @@ -3,7 +3,7 @@ return array( /*是否有访问权限,0=>任何人都可访问,1=>需登录可访问,2=>管理员可访问,3=>创始人可访问;默认值为1*/ 'allow_view'=>1, 'allow_robot'=>false,//是否允许机器人爬取 - /*此三项配置如果未配置,将读取系统默认配置访问index*/ + /*此三项配置如果未配置,将读取系统默认配置访问*/ 'default_mod'=>'index',//默认应用CONFIG DEFAULT_MOD 'default_op' => 'index',//CONFIG DEFAULT_OP 'dafault_action' => 'index',//CONFIG DAFAULT_ACTION @@ -12,5 +12,5 @@ return array( * 2.数组格式array('file_name'=>'test','file_folder'=>'fun','mod_name'=>'test'),将会加载test模块下的fun下的test.php * 此配置默认为空 */ - 'loadFile'=>'', + 'libfile'=>'', ); \ No newline at end of file diff --git a/dzz/images/default/icodefault.png b/dzz/images/default/icodefault.png index 5f5716e3e842b7213452625531449e3dc3d11462..d3e0498252319f7594f564c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`ZL!Ai z#tX+x#|3VE{_vTphgrzbLI@b6`5*u8uW-KU(!>8kVUq?Qb}8~ zZk1fsFcy-Q|1<>6zA)f zae0NR$T(fq%&MHudz_c*a__vbIBO^~LsgClG17L95F%BP^X9c9rX`fRL0>UcdCt1& zvDR>$J4Ofa!j+0mZFq4KIbXLN8pRc3uvapcP2gY>I2r}~M3UQa3D!D%UZBmRm%=@K z3OCAp!~gP+{`RF+VClyL7DQYy#stEJ#jr!^`NCl_X(`Dncff5ImR(*=nJUP`vBUmh zt~^AEWtYzzt|4nI;@)|re%LCC^ue~@7$Yvlv_7q*u|}tNEk;~=K40cL;)TBtvK^yR z^v-|&(#eBrS&LQunQfQbgUb;y!L;d_SmJQkGkN~Ecm~UV8ErI{-BPZ zMCdW@-T`&FzaifLhWg8o<749TF=@qr$uCq zb_aO%%ym3n?P2d*dDi}l+A~0&vi1y+r>s2#<0C~#VGeDlQ_6(4xtUUwdDQnLF cdCJ=V4}UO`z$Tw6SO5S307*qoM6N<$g2#vN%K!iX literal 0 HcmV?d00001 diff --git a/dzz/images/extimg/jpeg.png b/dzz/images/extimg/jpeg.png new file mode 100644 index 0000000000000000000000000000000000000000..35d68acc32c2e11577c8ad5f31f918469ae98d41 GIT binary patch literal 11302 zcmV+>EZNhEP)h)^VHhDNImXJ&Ux6e``eXLpX<2G&05Rv|Nig)AHVl|zxTfb z_qP_(G|knjs^*`2lz$D{lM3iT+kX+;hV4oz%Ccm=UcU?+0gC|;({F`anPB`?0d(2j4ehA};+yE)8^f_7$YG<9JWP>L}CQe_~Q0F&|0?jK0G?6JakVQ+Q;{5dKdUPkd;SYh{svQ zXT-O+?_uZ0i%_VG`}Ug)&<7E((NO5bLmx0MA3zbQ@?Dohu3$81C1X;6kDxVlPQW`H z7u$38hOaAd&hBD9aAv|#Ck8xR%yr`(M8Tl`p46EJO1^GV#!!-t!hN$H`&jpa6 z#3QMs&42q1_{|q#Vxchbs|)x)--X|J3BLCUe6j!&;pJl(XYkrpcx5h8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xI9axQ>Ba$@O-q$)ip)^vmb10I zjUa@;%6Y6YD6hyf%d{*ga!qCw8qL|J<8W3HV-)MLn)!6Xtjy`W%+1f{Q{Fln@xu@9 za&Osi{lKtTwVW+`Y}PRu6^u)RJ)Us;gO;JGl#lP8bGuPYiVSNF-g$`;nWpQUyt0poj!Is>qJzvLDo_ME?$XE{O_ga%YuPwYNE2ag@2KmR!^sHOJKn!}O4s!$qbY1d zo*N2lh#_$2{sLp|?ynD|SXkzUNs*Hqi?&iFKHYRu=_PVJo3LCre0*}wuYdUl^V0IY zw{KAg&$!5NKJxPO6Rg!#MaFv5@P~i$HrI}(TtBRM>!l;!{`em2wr4UfsWQ!`ZL!Ai z#tX+x#|3VE{_vTphgrzbLI@b6`5*u8uW-KU(!>8kVUq?Qb}8~ zZk1fsFcy-Q|1<>6zA)f zae0NR$T(fq%&MHudz_c*a__vbIBO^~LsgClG17L95F%BP^X9c9rX`fRL0>UcdCt1& zvDR>$J4Ofa!j+0mZFq4KIbXLN8pRc3uvapcP2gY>I2r}~M3UQa3D!D%UZBmRm%=@K z3OCAp!~gP+{`RF+VClyL7DQYy#stEJ#jr!^`NCl_X(`Dncff5ImR(*=nJUP`vBUmh zt~^AEWtYzzt|4nI;@)|re%LCC^ue~@7$Yvlv_7q*u|}tNEk;~=K40cL;)TBtvK^yR z^v-|&(#eBrS&LQunQfQbgUb;y!L;d_SmJQkGkN~Ecm~UV8ErI{-BPZ zMCdW@-T`&FzaifLhWg8o<749TF=@qr$uCq zb_aO%%ym3n?P2d*dDi}l+A~0&vi1y+r>s2#<0C~#VGeDlQ_6(4xtUUwdDQnLF cdCJ=V4}UO`z$Tw6SO5S307*qoM6N<$g2#vN%K!iX literal 0 HcmV?d00001 diff --git a/dzz/images/extimg/jpg.png b/dzz/images/extimg/jpg.png new file mode 100644 index 0000000000000000000000000000000000000000..35d68acc32c2e11577c8ad5f31f918469ae98d41 GIT binary patch literal 11302 zcmV+>EZNhEP)h)^VHhDNImXJ&Ux6e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BtvK^yR z^v-|&(#eBrS&LQunQfQbgUb;y!L;d_SmJQkGkN~Ecm~UV8ErI{-BPZ zMCdW@-T`&FzaifLhWg8o<749TF=@qr$uCq zb_aO%%ym3n?P2d*dDi}l+A~0&vi1y+r>s2#<0C~#VGeDlQ_6(4xtUUwdDQnLF cdCJ=V4}UO`z$Tw6SO5S307*qoM6N<$g2#vN%K!iX literal 0 HcmV?d00001 diff --git a/dzz/images/extimg/png.png b/dzz/images/extimg/png.png new file mode 100644 index 0000000000000000000000000000000000000000..35d68acc32c2e11577c8ad5f31f918469ae98d41 GIT binary patch literal 11302 zcmV+>EZNhEP)h)^VHhDNImXJ&Ux6e``eXLpX<2G&05Rv|Nig)AHVl|zxTfb z_qP_(G|knjs^*`2lz$D{lM3iT+kX+;hV4oz%Ccm=UcU?+0gC|;({F`anPB`?0d(2j4ehA};+yE)8^f_7$YG<9JWP>L}CQe_~Q0F&|0?jK0G?6JakVQ+Q;{5dKdUPkd;SYh{svQ zXT-O+?_uZ0i%_VG`}Ug)&<7E((NO5bLmx0MA3zbQ@?Dohu3$81C1X;6kDxVlPQW`H z7u$38hOaAd&hBD9aAv|#Ck8xR%yr`(M8Tl`p46EJO1^GV#!!-t!hN$H`&jpa6 z#3QMs&42q1_{|q#Vxchbs|)x)--X|J3BLCUe6j!&;pJl(XYkrpcx5h8`1&D?3ITO$ z;jD+_5=!8cbJ%3CXrM9B;E3U~R%lDNm z!VKRw2}?tsK^>tF@Zur7a0n-B7?tqq6}Y{Iw;On22EXwfm<)b!4@v{2hUez+KYasU zs^G^yK{REVO_s`(YQpR89q97)L!glNr zwvxvJVzmHbe+htW{XWUhE3pi#MIn5Iwoid_IA_nbX$96mRfu1|GJ|Ue&<40Rg|9vj zWdY6$a0@T{+5m6O#fq+sU|z^|fAcylYWQ!zDlYEdegI#)4(BbrcMmolym}0iIsC_) zuxJG|?`0eyR-J26q9RHAXL4EAK&F227BaA)0T7$CHzL}VTd|H1p%|EEOjeT4vl_}w zV#VP^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!{`em2wr4UfsWQ!`ZL!Ai z#tX+x#|3VE{_vTphgrzbLI@b6`5*u8uW-KU(!>8kVUq?Qb}8~ zZk1fsFcy-Q|1<>6zA)f zae0NR$T(fq%&MHudz_c*a__vbIBO^~LsgClG17L95F%BP^X9c9rX`fRL0>UcdCt1& zvDR>$J4Ofa!j+0mZFq4KIbXLN8pRc3uvapcP2gY>I2r}~M3UQa3D!D%UZBmRm%=@K z3OCAp!~gP+{`RF+VClyL7DQYy#stEJ#jr!^`NCl_X(`Dncff5ImR(*=nJUP`vBUmh zt~^AEWtYzzt|4nI;@)|re%LCC^ue~@7$Yvlv_7q*u|}tNEk;~=K40cL;)TBtvK^yR z^v-|&(#eBrS&LQunQfQbgUb;y!L;d_SmJQkGkN~Ecm~UV8ErI{-BPZ zMCdW@-T`&FzaifLhWg8o<749TF=@qr$uCq zb_aO%%ym3n?P2d*dDi}l+A~0&vi1y+r>s2#<0C~#VGeDlQ_6(4xtUUwdDQnLF cdCJ=V4}UO`z$Tw6SO5S307*qoM6N<$g2#vN%K!iX literal 0 HcmV?d00001 diff --git a/dzz/images/newfile/excel.xlsx b/dzz/images/newfile/excel.xlsx index a82d514eed94a2571833f1fbdeb8fc06425ff66e..f906bbec2414cdc7e2780a4511a7cd9ccc25e16a 100644 GIT binary patch delta 7051 zcmb7pbx>T(xAou>AUF&j26uONch_J+f@=seFhK%gf(#G{?(Q0#;1Jw`TX2`)@{xP% zd-whBAFtl)s?*h{dY$f5yI1eMdv&I2j~=gvG6Et#02zP^003SAdZa{A?co4`C?o&? z4}c19EbZd#Y2)l^uH)-!<6+A7&dHG~8xg*y5@8T7RznE%W&qUkIldH6(O$|6*L@mFnO`GNQ(;u!a4tv&UaL}4>JGP>+ zL9D5K-ie>0ca`6>pF6{m%ol*0AA^9@lTYMM1gWRN~8Kn z>jOiwL|4#)X?y^Yck`lfecmph`F2(M%BoaRl{Y=>vFhhDec3uu*wGh z%stp>3V1d#e-~5yqoB&cL^46Yho$XYxqrXotKT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f%kg)1#SE5X+%(#qnKP>NgGM-Ivl$tE_ zQ!9wLzFCV3<-rU;)5wM=hk0OvF-R_XDAULGD({vTd?ZbT1yFU>L}akLFSClYV6wGW zfJ0ckS^PB^aT|x8kBE4mL4PYz+V#@$6)T)(QZD@3^ecoR=B{Q{TQrjbj&F-jz6)!* z%C8n<0~ZiT77Kd~^~oSEBbkB@6A9gDVjd{$)z*%?AQH>^D(_WY-qA}HGK>o4r&3I_ zTf!MiMK$Si%?@!a>bW5LlS1VUUQ!*rnKjBhQR&Rdv$htkH*J_4WP87mlINmILQyAH z*lV14EFkC6romYKoJ=0O`*R$_>IU2!4WqE4cKT?fltiE!3Qr1t6ychcE3t&m%=z@` zl^Rm*RB?etZ?pArloK?tj@CDKaw?~1rnLv%HRGMR^%}P~m}+Rc^X6uDpMMwfbUEeh zu^W!AWf#R~{W`U$SmuKc7UxT^1To~6_05&hoE@62@u-Yv(OH>;E$_|>@BDa4Ep@bS|eZ>c!3EFE&`b1 z`K#q7zy$D^5{9q|1hBRVdnT{{pa#7=xgE29!0(gsNPdTmQRM%9GAWSP^Y3-WXx#5d z-qwl7Y_xzU{X2P&YW(k`SpnIA-#}yZp!Y)yVX6%L#|K<^{yQ3@Yz`)a)xj}vQ6LHA zJNcU?(yrTsm63MFAHn2*_Paa4oxpeUHwA?~# z1?S%<7tsC=8Ka2|CWCc_F+Erg#Gij^jXgX2uF5c&2bL4X@F;+}3H$PP#6`h8us|V( zN5-~4Z)YzClC!@kyTUuuDI;2HK9oSgXnxE-ei zy(;OK0&qv2W-Cy8-Iyz$VKEPyf?gXZy z6MDO3a3;kr;h%@FFoYzNe;m*PR|6cy1Gr|h3-}>a11|n!002`M0)fN#w86J<0J!*%w`hBdV '选定{n}个对象({size})', 'bottom_leftinfo' => '{n}个对象({size})共{total}个对象', - 'please_use_desktop' => '请在桌面内使用!', + 'please_use_desktop' => '请在桌面内使用!', 'share_the' => '分享了', 'js_a_file' => '个文件', 'js_now_email' => '现在去邮箱', @@ -181,8 +181,13 @@ $lang = array( 'folder_to_lowerfolder_failure' => '不能移动文件夹到自己的下级文件夹中', 'image_desc_default' => '{username}上传于{dateline}', 'notice' => '通知', + 'finish' => '完成', 'degree_exhaust' => '次数用尽', + 'to_of_completed' => '待完成', + 'over_of_date' => '已完成', 'out_of_date' => '已过期', + 'out_of_pigeonhole' => '已归档', + 'out_of_delete' => '已删除', 'normal' => '正常', 'been_blocked' => '已屏蔽', 'tips' => '技巧提示', @@ -241,8 +246,9 @@ $lang = array( 'app_not_exist' => '应用不存在', 'newtopic' => '创建话题', - 'js_saved_my_documents' => '保存到我的文档', - 'saved_my_documents' => '已保存到我的文档!', + 'js_saved_my_documents' => '保存', + 'saved_my_documents' => '已保存!', + 'at_saved_my_documents' => '已保存到我的文档!', 'successfully_added_desktop' => '“ 成功添加到桌面“我的文档”中!', 'pack_up' => '收起', 'rotation' => '旋转', @@ -262,6 +268,7 @@ $lang = array( 'discuss_nonentity_del' => '评论不存在或已删除', 'need_login' => '需要登录', 'app_not_support_open_alone' => '此应用不支持单独打开', + 'related' => '动态', 'has_not_related' => '还没有相关的动态', 'has_not_related1' => '没有相关的动态', 'unallocated_space' => '未分配空间', @@ -308,6 +315,7 @@ $lang = array( 'simple_mp3_player' => '简易mp3播放器', 'copyright' => '版权', 'start' => '开始', + 'start_search' => '开始搜索', 'space_usage' => '空间使用', 'no_disturbing' => '免打扰', 'no_disturbing1' => '免打扰模式', @@ -462,8 +470,9 @@ $lang = array( 'pictures' => '图片', 'document' => '文档', 'all_type' => '全部类型', - 'please_select_file' => '请选择文件', 'some_day_after' => '{day}天后', 'within_a_day' => '1天内', + + 'savetosuccess'=>' 保存成功,文件路径: ' ); ?> diff --git a/dzz/shares/images/mobile/password.css b/dzz/shares/images/mobile/password.css index 5c4806b..b9b2a70 100644 --- a/dzz/shares/images/mobile/password.css +++ b/dzz/shares/images/mobile/password.css @@ -125,3 +125,6 @@ ul,ul li{ position: fixed; box-shadow: 0px 0px 6px 0px rgba(0, 0, 0, 0.1); } +.weui-cells_checkbox .weui-check:checked+.weui-icon-checked:before{ + color: #4c8afb; +} diff --git a/dzz/shares/index.php b/dzz/shares/index.php index b10721c..4ea0843 100644 --- a/dzz/shares/index.php +++ b/dzz/shares/index.php @@ -48,6 +48,7 @@ if ($do == 'adddowns') { } dsetcookie('pass_' . $sid, authcode($_GET['password'], 'ENCODE')); } else { + $rightpassword = dzzdecode($share['password']); if ($ismobile) { include template('mobile/share_password'); } else { diff --git a/dzz/shares/save.php b/dzz/shares/save.php index 0873416..7150234 100644 --- a/dzz/shares/save.php +++ b/dzz/shares/save.php @@ -42,7 +42,12 @@ if(!$doing){ $data['error'][$fid] = lang('no_privilege'); $data['msg'][$fid] = 'error'; $data['name'][$fid] = ''; - exit(json_encode($data)); + if(isset($_GET['token'])){ + exit(json_encode(array('error'=>lang('no_privilege')))); + }else{ + exit(json_encode($data)); + } + } $totalsize = 0; diff --git a/dzz/shares/scripts/mobile/share.js b/dzz/shares/scripts/mobile/share.js index dc10880..37e0279 100644 --- a/dzz/shares/scripts/mobile/share.js +++ b/dzz/shares/scripts/mobile/share.js @@ -13,6 +13,7 @@ $(document).off('tap.openfile').on('tap.openfile', '.filelist', function () { return false; } else { if (is_wxwork) { + var href = obj.data('href'); window.location.href = href; return false; } else { diff --git a/dzz/shares/template/header_left.htm b/dzz/shares/template/header_left.htm index 6a73a8d..583507a 100644 --- a/dzz/shares/template/header_left.htm +++ b/dzz/shares/template/header_left.htm @@ -1 +1 @@ -
{$shareusername}{lang de}{lang file_share}
+
{$share[username]}{lang de}{lang file_share}
diff --git a/dzz/shares/template/list.htm b/dzz/shares/template/list.htm index 3475e1e..076d028 100644 --- a/dzz/shares/template/list.htm +++ b/dzz/shares/template/list.htm @@ -589,13 +589,12 @@ location.href = '$_G[siteurl]user.php?mod=login'; return false; } - /*jQuery.post('{MOD_URL}&do=adddowns&sid={$_GET[sid]}', function(data) { - if(data['success']) {*/ - //var userhref = 'index.php?mod=system&op=selposition&handlekey=seldir&allowcreate=1&callback=save_file'; - var userhref = 'index.php?mod=system&op=filewindow&handlekey=seldir&range=group,home&type=0&allowcreate=1&callback=save_file'; - showWindow('seldir', userhref, 'get', '0'); - /* } - }, 'json');*/ + jQuery.post('{MOD_URL}&do=adddowns&sid={$_GET[sid]}', function(data) { + if(data['success']) { + var userhref = 'index.php?mod=system&op=filewindow&handlekey=svaefile&type=2&perm=write&allowcreate=1&callback=save_file'; + showWindow('seldir', userhref, 'get', '0'); + } + }, 'json'); return false; }) //点击空白处,取消全选 @@ -610,17 +609,14 @@ }) function allsave(obj) { - if (uid == 0) { location.href = '$_G[siteurl]user.php?mod=login'; return false; } - var userhref = 'index.php?mod=system&op=selposition&handlekey=seldir&allowcreate=1&callback=saveall_file'; + var userhref = 'index.php?mod=system&op=filewindow&type=2&perm=write&allowcreate=1&callback=saveall_file'; showWindow('seldir', userhref, 'get', '0'); } function saveall_file(fid) { - //var rids = $('#allsave').data('allrids'); - return false var rids = []; jQuery('div[data-value="true"]').each(function () { rids.push(jQuery(this).data('dpath')); diff --git a/dzz/shares/template/mobile/list.htm b/dzz/shares/template/mobile/list.htm index 2048512..e63e160 100644 --- a/dzz/shares/template/mobile/list.htm +++ b/dzz/shares/template/mobile/list.htm @@ -58,7 +58,7 @@ -
+

$v[name]

@@ -97,8 +97,13 @@ + diff --git a/dzz/shares/template/password.htm b/dzz/shares/template/password.htm index 32bbb96..c7a3962 100644 --- a/dzz/shares/template/password.htm +++ b/dzz/shares/template/password.htm @@ -1,26 +1,19 @@ - - - - - - {lang password_share} - - - - - + - - + +
{eval echo avatar_block($share['uid']);} {$share[username]}{lang password_share_to}
- +

{lang password_share_lable}

diff --git a/dzz/system/css/mobile/mobile_member.css b/dzz/system/css/mobile/mobile_member.css index 96e4c81..0184456 100644 --- a/dzz/system/css/mobile/mobile_member.css +++ b/dzz/system/css/mobile/mobile_member.css @@ -395,6 +395,7 @@ ul,li,ul li{ color: #999999; font-size: 0.7rem; padding: 0.5rem; + margin-top: 1.8rem; } .weui-cell__search { background-color: #ffc107; diff --git a/dzz/system/css/select-file.css b/dzz/system/css/select-file.css index 386e656..320c7d4 100644 --- a/dzz/system/css/select-file.css +++ b/dzz/system/css/select-file.css @@ -198,14 +198,18 @@ li{ } } /*内容上部分开始*/ -/*.select-fileall{ - overflow: hidden; +.modal-footer { + padding: 10px 15px; } -.select-filetop{ +.select-fileall{ + padding:0 15px +} +/*.select-filetop{ overflow: hidden; }*/ .select-filetop{ position: relative; + padding:0 10px; } .select-address{ -webkit-box-sizing: border-box; @@ -222,7 +226,7 @@ li{ width: 100%; height:34px; line-height: 34px; - margin-bottom: 17px; + margin-right: 100px; padding-right: 10px; } diff --git a/dzz/system/css/selfilewindow.css b/dzz/system/css/selfilewindow.css index 264229f..0e9413e 100644 --- a/dzz/system/css/selfilewindow.css +++ b/dzz/system/css/selfilewindow.css @@ -17,8 +17,8 @@ margin: 0px 25px; } #seluser_dropdown_menu{ - padding-left: 1.78rem; - padding-right: 1.78rem; + /*padding-left: 1.78rem; + padding-right: 1.78rem;*/ } .jstree-default .jstree-wholerow{ height: 2.14rem; diff --git a/dzz/system/fileselection.php b/dzz/system/fileselection.php index 5d770fa..5437772 100644 --- a/dzz/system/fileselection.php +++ b/dzz/system/fileselection.php @@ -8,7 +8,7 @@ $uid = $_G['uid']; include libfile('function/filerouterule'); $do = isset($_GET['do']) ? trim($_GET['do']):''; $callback = isset($_GET['callback']) ? $_GET['callback'] : 'callback_selectposition';//回调函数名称 -$allowcreate = isset($_GET['allowcreate']) ? intval($_GET['allowcreate']):1;//是否允许新建文件夹 +$allowcreate = isset($_GET['allowcreate']) ? intval($_GET['allowcreate']):1;//是否允许新建文件夹,默认允许 //获取配置设置值 $explorer_setting = get_resources_some_setting(); $range = isset($_GET['range']) ? trim($_GET['range']):'';//指定范围 @@ -17,6 +17,8 @@ $type = isset($_GET['type']) ? intval($_GET['type']):0;//2,选择位置;1, $exttype = isset($_GET['exttype']) ? trim($_GET['exttype']):'';//类型范围 $filename = isset($_GET['filename'])?trim($_GET['filename']):''; $token = isset($_GET['token']) ? trim($_GET['token']):'';//调用地方传递参数,将原样返回给回调函数 +$perm = isset($_GET['perm']) ? trim($_GET['perm']):'';//权限判断值:比如 write,判断是否有写入权限;再如,write,copy,判断是否有写入和copy权限(即多个权限用逗号分隔) +$mulitype = isset($_GET['mulitype']) ? intval($_GET['mulitype']):0;//0,不允许多选;1,允许多选 if($type == 1){ $rid = isset($_GET['rid']) ? trim($_GET['rid']):''; $savefile = array(); @@ -33,8 +35,10 @@ $gets = array( 'rid'=>$rid, 'filename'=>$filename, 'range'=>$range, - 'defaultselect'=>$defaultselect, + 'defaultselect'=>$defaultselect['hash'], 'exttype'=>$exttype, + 'mulitype'=>$mulitype, + 'perm'=>$perm ); $urldefined= '&'. url_implode($gets); $allowvisit = array('file','listtree','explorerfile','json','ajax','dzzcp','save'); diff --git a/dzz/system/fileselection/explorerfile.php b/dzz/system/fileselection/explorerfile.php index 8b5f588..801d446 100644 --- a/dzz/system/fileselection/explorerfile.php +++ b/dzz/system/fileselection/explorerfile.php @@ -5,82 +5,81 @@ * Date: 2017/8/29 * Time: 10:43 */ -if(!defined('IN_DZZ')) { +if (!defined('IN_DZZ')) { exit('Access Denied'); } -define('CURRENT_PATH','dzz/system'); -$operation = empty($_GET['operation'])?'':$_GET['operation']; -$uid =isset($_GET['uid'])?intval($_GET['uid']):$_G['uid']; +define('CURRENT_PATH', 'dzz/system'); +$operation = empty($_GET['operation']) ? '' : $_GET['operation']; +$uid = isset($_GET['uid']) ? intval($_GET['uid']) : $_G['uid']; -if($operation == 'filelist'){ - $perpage=isset($_GET['perpage'])?intval($_GET['perpage']):100;//默认每页条数 - $page = empty($_GET['page'])?1:intval($_GET['page']);//页码数 - $start = ($page-1)*$perpage;//开始条数 - $total=0;//总条数 - $disp=intval($_GET['disp']); - $sid=empty($_GET['sid'])?0:$_GET['sid'];//id - $bz=empty($_GET['bz'])?'':urldecode($_GET['bz']); - $marker=empty($_GET['marker'])?'':trim($_GET['marker']); - $data=array(); - - if($bz){//云盘查询 - $asc=intval($_GET['asc']); - list($prex,$id)=explode('-',$sid); +if ($operation == 'filelist') { + $perpage = isset($_GET['perpage']) ? intval($_GET['perpage']) : 100;//默认每页条数 + $page = empty($_GET['page']) ? 1 : intval($_GET['page']);//页码数 + $start = ($page - 1) * $perpage;//开始条数 + $total = 0;//总条数 + $disp = intval($_GET['disp']); + $sid = empty($_GET['sid']) ? 0 : $_GET['sid'];//id + $bz = empty($_GET['bz']) ? '' : urldecode($_GET['bz']); + $marker = empty($_GET['marker']) ? '' : trim($_GET['marker']); + $data = array(); + $permfilter = isset($_GET['permfilter']) ? trim($_GET['permfilter']) : ''; + if ($bz) {//云盘查询 + $asc = intval($_GET['asc']); + list($prex, $id) = explode('-', $sid); $disp = intval($_GET['disp']) ? intval($_GET['disp']) : 0;//文件排序 - $order=$asc>0?'asc':"desc"; - switch($_GET['disp']){ + $order = $asc > 0 ? 'asc' : "desc"; + switch ($_GET['disp']) { case 0: - $by='name'; + $by = 'name'; break; case 1: - $by='size'; + $by = 'size'; break; case 2 : - $by= array('type', 'ext'); + $by = array('type', 'ext'); break; case 3: - $by='dateline'; + $by = 'dateline'; break; } - $limit=$start.'-'.($start+$perpage); - if(strpos($bz,'ALIOSS')===0 || strpos($bz,'JSS')===0 || strpos($bz,'qiniu')===0){ - $order=$marker; - $limit=$perpage; - }elseif( strpos($bz,'OneDrive')===0){ - $limit=$perpage; - $force=$marker; + $limit = $start . '-' . ($start + $perpage); + if (strpos($bz, 'ALIOSS') === 0 || strpos($bz, 'JSS') === 0 || strpos($bz, 'qiniu') === 0) { + $order = $marker; + $limit = $perpage; + } elseif (strpos($bz, 'OneDrive') === 0) { + $limit = $perpage; + $force = $marker; } - $icosdata=IO::listFiles($path,$by,$order,$limit,$force); + $icosdata = IO::listFiles($path, $by, $order, $limit, $force); - if($icosdata['error']){ + if ($icosdata['error']) { exit(json_encode($icosdata)); } - $folderdata=array(); - $ignore=0; - foreach($icosdata as $key => $value){ - if($value['error']){ + $folderdata = array(); + $ignore = 0; + foreach ($icosdata as $key => $value) { + if ($value['error']) { $ignore++; continue; } - if($value['type']=='folder'){ - $folder=IO::getFolderByIcosdata($value); - $folderdata[$folder['fid']]=$folder; + if ($value['type'] == 'folder') { + $folder = IO::getFolderByIcosdata($value); + $folderdata[$folder['fid']] = $folder; } - if(strpos($bz,'ftp')===false){ - if(trim($value['path'],'/')==trim($path,'/')){ + if (strpos($bz, 'ftp') === false) { + if (trim($value['path'], '/') == trim($path, '/')) { $ignore++; continue; } } - $userdata[$value['uid']]=$value['username']; - $data[$key]=$value; + $userdata[$value['uid']] = $value['username']; + $data[$key] = $value; } - $bz=($bz); - } - else { + $bz = ($bz); + } else { list($prex, $id) = explode('-', $sid); if ($prex == 'f') { $arr = array(); @@ -92,17 +91,17 @@ if($operation == 'filelist'){ $folder['iconview'] = (isset($_GET['iconview']) ? intval($_GET['iconview']) : intval($folder['iconview']));//排列方式 $conditions = array(); $keyword = isset($_GET['keyword']) ? urldecode($_GET['keyword']) : ''; - $exts = isset($_GET['exts']) ? trim($_GET['exts']):''; - if($exts){ - $extsarr = explode(',',$exts); - $conditions['ext'] = array($extsarr,'in','and'); + $exts = isset($_GET['exts']) ? trim($_GET['exts']) : ''; + if ($exts) { + $extsarr = explode(',', $exts); + $conditions['ext'] = array($extsarr, 'in', 'and'); } - if($keyword){ - $conditions['name'] = array($keyword,'like','and'); + if ($keyword) { + $conditions['name'] = array($keyword, 'like', 'and'); } $conditions['mustdition'] = "or (flag = 'folder')"; - $asc = isset($_GET['asc'])?intval($_GET['asc']):1; + $asc = isset($_GET['asc']) ? intval($_GET['asc']) : 1; $order = $asc > 0 ? 'ASC' : "DESC"; @@ -121,13 +120,16 @@ if($operation == 'filelist'){ break; } - $folder['perm'] = perm_check::getPerm($folder['fid']);//获取文件权限 - foreach(C::t('resources')->fetch_all_by_pfid($folder['fid'], $conditions, $perpage, $orderby, $order, $start) as $v){ - if($v['type'] == 'image'){ - $v['img'] = DZZSCRIPT.'?mod=io&op=thumbnail&width=100&height=90&path=' . dzzencode('attach::' . $v['aid']); + foreach (C::t('resources')->fetch_all_by_pfid($folder['fid'], $conditions, $perpage, $orderby, $order, $start) as $v) { + if ($v['type'] != 'folder' && $permfilter && $v['gid']) { + if (filter_permdata($permfilter, $folder['perm'], $v, $uid)) { + continue; + } + } + if ($v['type'] == 'image') { + $v['img'] = DZZSCRIPT . '?mod=io&op=thumbnail&width=100&height=90&path=' . dzzencode('attach::' . $v['aid']); } - $data[$v['rid']] = $v; } $folderdata[$folder['fid']] = $folder;//文件夹信息 @@ -135,32 +137,62 @@ if($operation == 'filelist'){ } } } - if(count($data) >= $perpage){ - $total = $start + $perpage*2 -1; - }else{ + if (count($data) >= $perpage) { + $total = $start + $perpage * 2 - 1; + } else { $total = $start + count($data); } //$total=$count;//总条数 - if(!$json_data=json_encode($data)) $data=array(); - if(!$json_data=json_encode($folderdata)) $folderdata=array(); + if (!$json_data = json_encode($data)) $data = array(); + if (!$json_data = json_encode($folderdata)) $folderdata = array(); //返回数据 - $return=array( - 'sid'=>$sid, - 'total'=>$total, - 'data'=>$data?$data:array(), - - 'folderdata'=>$folderdata?$folderdata:array(), - 'param'=>array( - 'disp'=>$folder['disp'], - 'view'=>$folder['iconview'], - 'page'=>$page, - 'perpage'=>$perpage, - 'bz'=>$bz, - 'total'=>$total, - 'asc'=>$asc, - 'keyword'=>$keyword, - 'localsearch'=>$bz?1:0 + $return = array( + 'sid' => $sid, + 'total' => $total, + 'data' => $data ? $data : array(), + + 'folderdata' => $folderdata ? $folderdata : array(), + 'param' => array( + 'disp' => $folder['disp'], + 'view' => $folder['iconview'], + 'page' => $page, + 'perpage' => $perpage, + 'bz' => $bz, + 'total' => $total, + 'asc' => $asc, + 'keyword' => $keyword, + 'localsearch' => $bz ? 1 : 0 ) ); exit(json_encode($return)); +} +function filter_permdata($permfilter, $perm, $data, $uid){ + $powerarr = perm_binPerm::getPowerArr(); + $specialperm = array('read', 'edit', 'delete', 'download', 'copy'); + $noperm = false; + if (!C::t('organization_admin')->chk_memberperm($data['gid'], $uid)) { + $permfilterarr = explode(',', $permfilter); + foreach ($permfilterarr as $val) { + if ($val == 'write') $val = 'edit'; + if (in_array($val, $specialperm)) { + if ($uid == $data['uid']) { + if (!($powerarr[$val . '1'] & $perm)) { + $noperm = true; + break; + } + } else { + if (!($powerarr[$val . '2'] & $perm)) { + $noperm = true; + break; + } + } + } else { + if (!($powerarr[$val] & $perm)) { + $noperm = true; + break; + } + } + } + } + return $noperm; } \ No newline at end of file diff --git a/dzz/system/fileselection/file.php b/dzz/system/fileselection/file.php index 193f53e..ce728bc 100644 --- a/dzz/system/fileselection/file.php +++ b/dzz/system/fileselection/file.php @@ -11,15 +11,6 @@ if (!defined('IN_DZZ')) { $operation = (isset($_GET['operation'])) ? trim($_GET['operation']) : ''; $gid = isset($_GET['gid']) ? intval($_GET['gid']) : ''; $fid = isset($_GET['fid']) ? intval($_GET['fid']) : ''; -//如果未接收到gid,fid按默认选中项获取数据 -if (!$gid && !$fid) { - if (isset($defaultselect['gid'])) { - $gid = $defaultselect['gid']; - $fid = isset($defaultselect['fid']) ? $defaultselect['fid'] : ''; - } else { - $fid = isset($defaultselect['fid']) ? $defaultselect['fid'] : ''; - } -} if ($gid) { if (!$group = C::t('organization')->fetch($gid)) { showmessage(lang('no_group'), dreferer()); diff --git a/dzz/system/fileselection/json.php b/dzz/system/fileselection/json.php index 4797f49..e08ac69 100644 --- a/dzz/system/fileselection/json.php +++ b/dzz/system/fileselection/json.php @@ -132,5 +132,8 @@ if($exttype){ } $data['allowselecttype'] = json_decode($exttype); $data['defaultfilename'] = isset($filename) ? $filename:''; +$data['defaultselect'] = $_GET['defaultselect']; +$data['allowcreate'] = $_GET['allowcreate']; +$data['permfilter'] = $_GET['perm']; echo json_encode($data); exit(); diff --git a/dzz/system/fileselection/listtree.php b/dzz/system/fileselection/listtree.php index a144b20..6aae32e 100644 --- a/dzz/system/fileselection/listtree.php +++ b/dzz/system/fileselection/listtree.php @@ -10,7 +10,7 @@ if (!C::t('folder')->check_home_by_uid($uid)) { } $id = isset($_GET['id']) ? $_GET['id'] : ''; $operation = $_GET['operation'] ? $_GET['operation'] : ''; -$ismobile = helper_browser::ismobile(); +$range = isset($_GET['range']) ? trim($_GET['range']):'';//指定范围 $data = array(); $powerarr = perm_binPerm::getPowerArr(); if ($operation == 'get_children') { diff --git a/dzz/system/filewindow.php b/dzz/system/filewindow.php index 965d342..697559e 100644 --- a/dzz/system/filewindow.php +++ b/dzz/system/filewindow.php @@ -3,13 +3,13 @@ if (!defined('IN_DZZ')) { exit('Access Denied'); } $callback = isset($_GET['callback']) ? $_GET['callback'] : 'callbak_openfile';//回调函数名称 -$allowcreate = isset($_GET['allowcreate']) ? intval($_GET['allowcreate']):0;//是否允许新建 -$fids = isset($_GET['selfids']) ? $_GET['selfids']:'';//指定文件夹id +$allowcreate = isset($_GET['allowcreate']) ? intval($_GET['allowcreate']):1;//是否允许新建,默认允许 $selrange = isset($_GET['range']) ? urldecode(trim($_GET['range'])):'';//指定范围 $defaultselect = isset($_GET['defaultsel']) ? $_GET['defaultsel']:'';//默认选中 $type = isset($_GET['type']) ? intval($_GET['type']):0;//0,选择文件;1,保存文件;2,另存为 $mulitype = isset($_GET['mulitype']) ? intval($_GET['mulitype']):0;//0,不允许多选;1,允许多选 $exttype = isset($_GET['exts']) ? trim($_GET['exts']):'';//类型范围 +$perm = isset($_GET['perm']) ? trim($_GET['perm']):'';//权限判断值:比如 write,判断是否有写入权限;再如,write,copy,判断是否有写入和copy权限(即多个权限用逗号分隔) $rid = isset($_GET['rid']) ? trim($_GET['rid']) : '';//文件id(需用dzzencode加密) $filename = isset($_GET['filename']) ? trim($_GET['filename']) :''; $token = isset($_GET['token']) ? trim($_GET['token']):'';//调用地方传递参数,将原样返回给回调函数 @@ -23,10 +23,11 @@ $gets = array( 'rid'=>$rid, 'filename'=>$filename, 'range'=>$selrange, - 'defaultselect'=>$defaultselect, + 'defaultsel'=>$defaultselect, 'exttype'=>$exttype, 'mulitype'=>$mulitype, - 'token'=>$token + 'token'=>$token, + 'perm'=>$perm ); $theurl = MOD_URL . "&op=fileselection&callback=".$callback.'&'. url_implode($gets); include template('selectfile'); diff --git a/dzz/system/function/function_filerouterule.php b/dzz/system/function/function_filerouterule.php index a504fc6..9fe1aeb 100644 --- a/dzz/system/function/function_filerouterule.php +++ b/dzz/system/function/function_filerouterule.php @@ -45,6 +45,13 @@ function filerouteParse($path){ } } } + if(isset($arr['gid']) && $arr['gid']){ + $arr['hash'] = 'group&do=file&gid='.$arr['gid'].(isset($arr['fid']) ? '&fid='.$arr['fid']:''); + }elseif(isset($arr['fid']) && $arr['fid']){ + $arr['hash'] = 'home&do=file&fid='.$arr['fid']; + }else{ + $arr['hash'] = ''; + } return $arr; } diff --git a/dzz/system/mobilefileselection/file.php b/dzz/system/mobilefileselection/file.php index 407e1a2..63657e7 100644 --- a/dzz/system/mobilefileselection/file.php +++ b/dzz/system/mobilefileselection/file.php @@ -62,9 +62,9 @@ if ($keyword) { //类型筛选 if ($exts) { - if($exts == 'folder'){ + if ($exts == 'folder') { $conditions['type'] = array('folder', '=', 'and'); - }else{ + } else { $extarr = explode(',', $exts); $conditions['ext'] = array($extarr, 'in', 'and'); } @@ -160,6 +160,17 @@ $next = false; if (count($data) + count($groups) >= $perpage) { $next = $page + 1; } +$createFolderPerm = false; +if($gid){ + if ($folder['ismoderator']) { + $createFolderPerm = true; + } else { + $$createFolderPerm = perm_binPerm::havePower('folder', $folder['perm_inherit']) ? true:false; + } +}else{ + $createFolderPerm = true; +} + //返回数据 $return = array('fid' => $fid, 'data' => $data ? $data : array(), 'param' => array( 'perpage' => $perpage, @@ -172,7 +183,8 @@ $return = array('fid' => $fid, 'data' => $data ? $data : array(), 'param' => arr 'gid' => $gid, 'datatotal' => (count($data) + count($groups) + $datastart), 'groupnext' => $gropunext, - 'localsearch' => $bz ? 1 : 0 + 'localsearch' => $bz ? 1 : 0, + 'createFolderPerm'=>$createFolderPerm ) ); $params = json_encode($return['param']); diff --git a/dzz/system/orgtree.php b/dzz/system/orgtree.php index 448a44a..c8d26f6 100644 --- a/dzz/system/orgtree.php +++ b/dzz/system/orgtree.php @@ -35,15 +35,12 @@ if($_GET['do']=='orgtree'){ $data=array(); if($_GET['id']=='#'){ if($_G['adminid']!=1 && $moderator) $topids=C::t('organization_admin')->fetch_toporgids_by_uid($_G['uid']); - foreach(C::t('organization')->fetch_all_by_forgid($id) as $value){ + foreach(C::t('organization')->fetch_all_by_forgid($id,false,-1) as $value){ if($_G['adminid']!=1 && $moderator && !in_array($value['orgid'],$topids)) continue; - switch($value['type']){ - case '1'://是群组 - if($range==1) continue; - break; - case '0'://是机构和部门 - if($range==2) continue; - break; + if($value['type']=='1' && $range==1){ + continue; + }elseif($value['type']=='0' && $range==2){ + continue; } if(!$moderator || C::t('organization_admin')->ismoderator_by_uid_orgid($value['orgid'],$_G['uid'])){ $orgdisable=false; @@ -72,7 +69,6 @@ if($_GET['do']=='orgtree'){ $data[]=array('id'=>'other','text'=>$zero,'state'=>array('disabled'=>$disable),"type"=>($type=="disabled")?$type:'default','children'=>true); } - }else{ //获取用户列表 if($_GET['id']=='other'){//无机构用户 diff --git a/dzz/system/positionlist.php b/dzz/system/positionlist.php index b94c6dc..5b08818 100644 --- a/dzz/system/positionlist.php +++ b/dzz/system/positionlist.php @@ -5,6 +5,7 @@ if (!defined('IN_DZZ')) { global $_G; Hook::listen('check_login');//检查是否登录,未登录跳转到登录界面 $uid = $_G['uid']; +include libfile('function/filerouterule'); if(!C::t('folder')->check_home_by_uid($uid)){ C::t('folder')->fetch_home_by_uid($uid); } @@ -18,7 +19,9 @@ $selhome = isset($_GET['selhome']) ? $_GET['selhome']:0;//展示网盘0不展示 $selorg = isset($_GET['selorg']) ? $_GET['selorg']:0;//展示机构0不展示 $selgroup = isset($_GET['selgroup']) ? $_GET['$selgroup']:0;//展示群组0不展示 $range = isset($_GET['range']) ? $_GET['range']:0;//是否限制展示0不限定 -$ismobile=helper_browser::ismobile(); +//默认选中,支持路径如:我的网盘/xxx,群组xxx/xxx,群组或机构|xxx,群组或机构|xxx/新建文件夹 +$defaultselect = isset($_GET['defaultsel']) ? filerouteParse(trim($_GET['defaultsel'])):filerouteParse('我的网盘'); +$defaultjson = json_encode($defaultselect); $data = array(); $powerarr = perm_binPerm::getPowerArr(); if ($do == 'get_children') { diff --git a/dzz/system/scripts/_perm.js b/dzz/system/scripts/_perm.js index 8d1bff4..dd6d678 100644 --- a/dzz/system/scripts/_perm.js +++ b/dzz/system/scripts/_perm.js @@ -49,7 +49,7 @@ _explorer.FolderSPower=function(power,action){//判断有无权限; }; if(action=='copy') action='delete'; if(parseInt(actionArr[action])<1) return true; - //权限比较时,进行与操作,得到0的话,表示没有权限 + //权限比较时,进行与操作,得到0的话,表示没有权限 if( (power & parseInt(actionArr[action])) == parseInt(actionArr[action]) ) return false; return true; } @@ -145,7 +145,6 @@ _explorer.Permission_Container=function(action,fid){ if(_explorer.myuid==_explorer.sourcedata.folder[fid].uid) action+='1'; else action+='2'; } - return _explorer.isPower(perm,action); } diff --git a/dzz/system/scripts/contextmenu.js b/dzz/system/scripts/contextmenu.js index 4a64900..2c90a55 100644 --- a/dzz/system/scripts/contextmenu.js +++ b/dzz/system/scripts/contextmenu.js @@ -36,6 +36,10 @@ _contextmenu.right_ico = function (e, rid) { if (obj.type == 'shortcut' || obj.type == 'storage' || obj.type == 'pan' || _explorer.myuid < 1) { el.find('.shortcut').remove(); } + //如果是选择位置则只保留新建文件夹菜单 + if(_explorer.type == 2){ + el.find('.download,.cut,.copy,.delete').remove(); + } //判断copy if (!_explorer.Permission('copy', obj)) { el.find('.copy').remove(); diff --git a/dzz/system/scripts/explorer.js b/dzz/system/scripts/explorer.js index 72abc12..a2dd50b 100644 --- a/dzz/system/scripts/explorer.js +++ b/dzz/system/scripts/explorer.js @@ -13,17 +13,29 @@ _explorer = function (json) { _explorer.formhash = json.formhash; //FORMHASH _explorer.extopen = json.extopen || {}; //打开方式信息 _explorer.sourcedata = json.sourcedata || []; //所有文件信息 - _explorer.type = json.fileselectiontype || 0;//文件选择类型,0为选择文件,1为保存文件 + _explorer.type = json.fileselectiontype || 0;//文件选择类型,0为选择文件,1为保存文件,2选择位置 + _explorer.defaultselect = json.defaultselect; + _explorer.allowcreate = json.allowcreate; _explorer.mulitype = json.mulitype || 0;//是否允许多选,默认不允许 - _explorer.allowselecttype = json.allowselecttype || '';//允许筛选文件类型 + _explorer.permfilter = json.permfilter || '';//文件检索写入权限过滤 + //如果是保存文件并且未带入权限过滤参数,强制过滤写入权限 + if(_explorer.type == 1){ + _explorer.permfilter = (json.permfilter) ? json.permfilter:'write'; + } + //如果是选择位置 + if (_explorer.type == 2) { + _explorer.allowselecttype = {'folder': ['文件夹', ['folder'], 'selected']}; + } else { + _explorer.allowselecttype = json.allowselecttype || '';//允许筛选文件类型 + } //默认筛选文件类型 - if(json.allowselecttype){ - for(var o in json.allowselecttype){ - if(json.allowselecttype[o][2] == 'selected'){ + if (json.allowselecttype) { + for (var o in json.allowselecttype) { + if (json.allowselecttype[o][2] == 'selected') { _explorer.defaultexttype = json.allowselecttype[o][1].join(',').toLowerCase(); } } - }else{ + } else { _explorer.defaultexttype = ''; } _explorer.defaultfilename = json.defaultfilename || ''; @@ -42,7 +54,6 @@ _explorer.getConfig = function (url, callback) { new _explorer(json); _explorer.hashHandler(); _explorer.initEvents(); - //_explorer.infoPanel(); if (typeof callback === "function") { callback(json); } @@ -61,7 +72,6 @@ _explorer.initEvents = function () { //初始化页面事件 //右侧加载完成事件 $(document).off('ajaxLoad.middleContent').on('ajaxLoad.middleContent', function () { -// _explorer.Scroll($('.scroll-y')); var hash = location.hash.replace(/^#/i, ''); var op = hash.replace(/&(.+?)$/ig, ''); //(hash,'op'); _explorer.topNav_init(); @@ -72,19 +82,52 @@ _explorer.initEvents = function () { //初始化页面事件 } }); }; -_explorer.set_address = function(path){ +_explorer.createMenuSwidth = function (fid) { + //判断新建和上传图标显示 + var folderperm = false;//文件夹权限 + var uploadperm = false;//上传权限 + if(_explorer.allowcreate){ + //文件夹权限(判断是否有文件夹权限如果没有隐藏文件夹相关新建上传),如果是选择位置隐藏新建文件 + if (!_explorer.Permission_Container('upload', fid) || _explorer.type == 2) { + $('#createmenu').find('li').not('.folderPermMust').addClass('hide'); + } else { + $('#createmenu').find('li').not('.folderPermMust').removeClass('hide'); + folderperm = true; + } + if (!_explorer.Permission_Container('folder', fid)) { //其它类型新建权限,如果无权限,隐藏文件相关权限 + jQuery('#createmenu').find('li.folderPermMust').addClass('hide'); + } else { + jQuery('#createmenu').find('li.folderPermMust').removeClass('hide'); + uploadperm = true; + } + if (folderperm || uploadperm) { //如果没有文件夹权限和文件权限,隐藏新建上传菜单 + $('#createmenu').removeClass('hide'); + $('#exampleColorDropdown2').removeClass('hide'); + } else { + $('#createmenu').addClass('hide'); + $('#exampleColorDropdown2').addClass('hide'); + } + //去掉多余的分割线 + $('.divider').each(function(){ + if($(this).prev('li:visible').length < 1){ + $(this).remove(); + } + }) + } +} +_explorer.set_address = function (path) { var pathstr = path; $('.select-address input.inputaddress').val(pathstr); var patharr = pathstr.split('\\'); var address_html = ''; - for(var o in patharr){ - address_html += '
  • '+patharr[o]+'
  • '; + for (var o in patharr) { + address_html += '
  • ' + patharr[o] + '
  • '; } $('.select-address div.address-field').html(address_html); } _explorer.address_resize = function (dir) { var container = jQuery('.address-container'); - var address = jQuery('.address-field'); + var address = jQuery('.address-field'); var cwidth = container.width(); var speed = cwidth; var awidth = 0; @@ -151,7 +194,7 @@ _explorer.address_resize = function (dir) { _explorer.topNav_init = function () { /*页面地址栏相关事件*/ - $(document).off('click.address-left-arrow').on('click.address-left-arrow','.address-left-arrow', function () { + $(document).off('click.address-left-arrow').on('click.address-left-arrow', '.address-left-arrow', function () { _explorer.address_resize('left'); return false; }); @@ -163,7 +206,7 @@ _explorer.topNav_init = function () { //点击路径切栏切换位置 $(document).off('click.routes').on('click.routes', '.address-container .routes', function () { var path = ''; - var text = $(this).text().replace(/(^\s*)|(\s*$)/g,''); + var text = $(this).text().replace(/(^\s*)|(\s*$)/g, ''); var textprefix = /[::]/; var prefix = ''; var textarr = []; @@ -174,7 +217,7 @@ _explorer.topNav_init = function () { } $(this).closest('li').prevAll().find('a').each(function () { - path += $(this).text().replace(/(^\s*)|(\s*$)/g,'') + '/'; + path += $(this).text().replace(/(^\s*)|(\s*$)/g, '') + '/'; }); path += text; //path = path.replace(/>/g,'/'); @@ -272,7 +315,7 @@ _explorer.routerule = function (path, prefix) { var hash = ''; if (!isNaN(parseInt(data.success['gid']))) { hash = 'group&gid=' + data.success['gid'] + (data.success['fid'] ? '&fid=' + data.success['fid'] : ''); - }else { + } else { hash = 'home&fid=' + data.success['fid']; } location.hash = hash; @@ -283,9 +326,9 @@ _explorer.routerule = function (path, prefix) { _explorer.hashHandler = function () { //处理页面hash变化 var hash = location.hash; hash = hash.replace(/^#/i, ''); - _explorer.jstree_select(hash); if (!hash) { - hash = 'home=1'; + hash = _explorer.defaultselect; + _explorer.jstree_select(hash); } if (hash === _explorer.hash) { return false; @@ -323,7 +366,7 @@ _explorer.jstree_select = function (hash) { if (!hash) { hash = location.hash.replace('#', ''); } - if(!hash){ + if (!hash) { hash = $('#position').find("li[flag='home']").attr('hashs'); } var op = hash.replace(/&(.+?)$/ig, ''); //(hash,'op'); @@ -334,8 +377,8 @@ _explorer.jstree_select = function (hash) { } else if (op === 'home') { _explorer.open_node_by_id(fid); } /*else if (op === 'mygroup') { - $('#position').jstree(true).select_node('#group'); - }*/ else { + $('#position').jstree(true).select_node('#group'); + }*/ else { if ($('#position').length > 0) { $('#position').jstree(true).deselect_all(); } diff --git a/dzz/system/scripts/mobile/file_keep.js b/dzz/system/scripts/mobile/file_keep.js index c69af76..7405e24 100644 --- a/dzz/system/scripts/mobile/file_keep.js +++ b/dzz/system/scripts/mobile/file_keep.js @@ -51,6 +51,11 @@ _filemanage.initEvents = function () { //初始化页面事件 if (hash.indexOf('search') == 0) { $('#footermenu').html(''); } else if (_filemanage.fid) { + if(_filemanage.dataparam.createFolderPerm){ + $('#footer_menu').find('.filelistmenu .new-folder').removeClass('hide'); + }else{ + $('#footer_menu').find('.filelistmenu .new-folder').addClass('hide'); + } $('#footermenu').html($('#footer_menu').find('.filelistmenu').html()); } else { $('#footermenu').html($('#footer_menu').find('.formatmenu').html()); @@ -87,7 +92,7 @@ _filemanage.initEvents = function () { //初始化页面事件 if (_filemanage.dataparam.page) { $.post(_filemanage.appUrl + '&do=' + _filemanage.hash, _filemanage.dataparam, function (data) { $('#containsdata').html(data); - $('#middleconMenu .filelist').append($('#containsdata').find('.datacontent').html()); + $('#middleconMenu .filelist').append($('#containsdata').find('.weui-cells__margin_footer').html()); $('#containsdata').empty(); if (!_filemanage.dataparam.page) { loading = false; @@ -129,6 +134,9 @@ _filemanage.hashHandler = function () { //处理页面hash变化 }; _filemanage.getContent = function (hash, container) { //处理页面加载 var url = _filemanage.appUrl + '&do=' + hash; + if(url.indexOf('?') == -1){ + url = url.replace('&','?'); + } _filemanage.dataparam = {}; if (_filemanage.defaultexttype) { _filemanage.dataparam.exts = _filemanage.defaultexttype; @@ -139,9 +147,15 @@ _filemanage.getContent = function (hash, container) { //处理页面加载 if ($('#containsdata').find('.addresscontent').length) { $('#addressdata').html($('#containsdata').find('.addresscontent').html()); $('#addressdata').removeClass('hide'); - }else if(_filemanage.hash.indexOf('search') == 0){ + }else if( _filemanage.hash.indexOf('home') == 0){ $('#addressdata').html(''); - $('#addressdata').removeClass('hide'); + $('#addressdata').removeClass('hide'); + } + if(_filemanage.hash.indexOf('search') == 0){ + $('.weui-file-keep').addClass('hide'); + $('#addressdata').addClass('hide'); + }else{ + $('.weui-file-keep').removeClass('hide'); } $('#containsdata').empty(); $(document).trigger('ajaxLoad.middleContent', [hash]); diff --git a/dzz/system/scripts/select-file.js b/dzz/system/scripts/select-file.js index 7cde104..cae463f 100644 --- a/dzz/system/scripts/select-file.js +++ b/dzz/system/scripts/select-file.js @@ -382,7 +382,6 @@ _selectfile.prototype.CreateIcos = function (data, flag) { jQuery('#' + containerid).find('.emptyPage').remove(); } }; - _selectfile.changefileName = function(rid){ var filename = ''; if(!rid){ @@ -405,6 +404,7 @@ _selectfile.getData = function (url, callback) { for (var fid in json.folderdata) { _explorer.sourcedata.folder[fid] = json.folderdata[fid]; } + _explorer.createMenuSwidth(_selectfile.fid); var obj = null; if (json.param.page > 1) { obj = _selectfile.cons[json.sid]; diff --git a/dzz/system/scripts/selorguser.js b/dzz/system/scripts/selorguser.js index 025c5bc..56a8c89 100644 --- a/dzz/system/scripts/selorguser.js +++ b/dzz/system/scripts/selorguser.js @@ -22,6 +22,9 @@ selorg.add=function(ctrlid,vals){ } selorg.set(ctrlid); + try{ + update_selected_sum(); + }catch(e){} }; //删除 @@ -32,6 +35,9 @@ selorg.del=function(ctrlid,vals){ } } selorg.set(ctrlid); + try{ + update_selected_sum(); + }catch(e){} }; //设置输入框的值 @@ -48,6 +54,9 @@ selorg.set=function(ctrlid){ jQuery(obj).parent().remove(); selorg.set(ctrlid); try{window.frames[ctrlid+'_iframe'].selectorg_remove(unsel_val);}catch(e){} + try{ + update_selected_sum(); + }catch(e){} }; selorg.search=function(ctrlid,obj){ try{window.frames[ctrlid+'_iframe'].selectorg_search(obj.value);}catch(e){} diff --git a/dzz/system/selposition.php b/dzz/system/selposition.php index 7c88e92..24d5ecd 100644 --- a/dzz/system/selposition.php +++ b/dzz/system/selposition.php @@ -2,6 +2,7 @@ if (!defined('IN_DZZ')) { exit('Access Denied'); } +include libfile('function/filerouterule'); $savefile = isset($_GET['savefile']) ? intval($_GET['savefile']) : 0;//是否直接保存文件 $callback = isset($_GET['callback']) ? $_GET['callback'] : 'callback_selectposition';//回调函数名称 $allowcreate = isset($_GET['allowcreate']) ? intval($_GET['allowcreate']):0;//是否允许新建文件夹 @@ -10,6 +11,8 @@ $selhome = isset($_GET['selhome']) ? $_GET['selhome']:0;//展示网盘0不展示 $selorg = isset($_GET['selorg']) ? $_GET['selorg']:0;//展示机构0不展示 $selgroup = isset($_GET['selgroup']) ? $_GET['selgroup']:0;//展示群组0不展示 $range = isset($_GET['range']) ? $_GET['range']:0;//是否限制展示0不限定 +//默认选中,支持路径如:我的网盘/xxx,群组xxx/xxx,群组或机构|xxx,群组或机构|xxx/新建文件夹 +$defaultselect = isset($_GET['defaultsel']) ? trim($_GET['defaultsel']):''; $gets = array( 'allowcreate' => $allowcreate, 'nosearch' => 1, @@ -18,7 +21,8 @@ $gets = array( 'selhome'=>$selhome, 'selorg'=>$selorg, 'selgroup'=>$selgroup, - 'range'=>$range + 'range'=>$range, + 'defaultsel'=>$defaultselect ); $theurl = MOD_URL . "&op=positionlist&callback=".$callback.'&'. url_implode($gets); include template('selposition'); diff --git a/dzz/system/template/filelist.htm b/dzz/system/template/filelist.htm index ecdc0e8..1530ba4 100644 --- a/dzz/system/template/filelist.htm +++ b/dzz/system/template/filelist.htm @@ -6,11 +6,7 @@ @@ -35,19 +32,19 @@
    \ No newline at end of file diff --git a/dzz/system/template/mobilefileselection/footer_menu.htm b/dzz/system/template/mobilefileselection/footer_menu.htm index 015ccd7..314e4f8 100644 --- a/dzz/system/template/mobilefileselection/footer_menu.htm +++ b/dzz/system/template/mobilefileselection/footer_menu.htm @@ -36,7 +36,7 @@

    搜索

    - +

    刷新

    +
    +
    -
    - \ No newline at end of file + + +
    \ No newline at end of file diff --git a/dzz/system/template/mobilefileselection/index.htm b/dzz/system/template/mobilefileselection/index.htm index 8d80eee..1db1c6b 100644 --- a/dzz/system/template/mobilefileselection/index.htm +++ b/dzz/system/template/mobilefileselection/index.htm @@ -16,7 +16,8 @@
    -
    另存为选择文件选择位置 +
    另存为选择文件选择位置 +
    确定
    @@ -25,7 +26,7 @@
    -
    +
    @@ -50,41 +51,44 @@
    @@ -147,7 +150,7 @@ }, 'data': function (node, cb) { var self = this; - $.getJSON('index.php?mod=system&op=positionlist&do=get_children&range={$range}&selhome={$selhome}&selorg={$selorg}&selgroup={$selgroup}', {'id': node.id}, function (json) { + $.getJSON('index.php?mod=system&op=positionlist&do=get_children&range={$range}&selhome={$selhome}&selorg={$selorg}&selgroup={$selgroup}&defaultsel={$defaultselect}', {'id': node.id}, function (json) { cb.call(this, json); }); } @@ -181,6 +184,8 @@ }, }, "plugins": ['types', 'search', 'wholerow'] + }).on("ready.jstree", function () { + init_selected(); }); $('#position').off('select_node.jstree').on('select_node.jstree', function (e, data) { @@ -194,16 +199,16 @@ var fid = node.li_attr.fid; } var nummatch = /^\d+$/; - if(nummatch.test(fid)){ - $.post('index.php?mod=system&op=positionlist&do=checkupload',{'fid':fid},function(data){ - if(data['perm']){ + if (nummatch.test(fid)) { + $.post('index.php?mod=system&op=positionlist&do=checkupload', {'fid': fid}, function (data) { + if (data['perm']) { $('#' + ctrlid).val(fid); - }else{ + } else { inst.deselect_node(node); $('#' + ctrlid).val(''); } - },'json') - }else{ + }, 'json') + } else { inst.deselect_node(node); $('#' + ctrlid).val(''); } @@ -211,26 +216,80 @@ return false; }); }); + function init_selected() { + var inst = $('#position').jstree(true); + if(!defaultjson.gid){ + defaultjson.gid = 0; + } + if(!defaultjson.fid){ + defaultjson.fid = 0; + } + open_node_by_id(defaultjson.gid,defaultjson.fid); + } + function open_node_by_id(gid, fid) { + var inst = $('#position').jstree(true); + var node = null; + if (fid) { + node = inst.get_node('#f_' + fid) || inst.get_node('#u_' + fid); + } else if (gid) { + node = inst.get_node('#g_' + gid) || inst.get_node('#gid_' + gid); + } else { + inst.deselect_all(); + return; + } + if (node) { + inst.deselect_all(); + var selects = inst.get_selected(); + for (var i = 0; i < selects.length; i++) { + if (selects[i] === node.id) { + continue; + } + inst.deselect_node('#' + selects[i]); + } + inst.select_node(node); + } else { + $.post('index.php?mod=system&op=positionlist&do=getParentsArr', { + 'fid': fid, + 'gid': gid + }, function (data) { + var node = inst.get_node('#' + data[0]); + open_node_bg(inst, node, data); + }, 'json'); + } + } + function open_node_bg(inst, node, arr) { + inst.open_node(node, function (node) { + var i = jQuery.inArray(node.id, arr); + if (i < arr.length && i > -1 && document.getElementById(arr[i + 1])) { + open_node_bg(inst, document.getElementById(arr[i + 1]), arr); + } else { + inst.deselect_all(); + inst.select_node(node); + } + }); + }; + + function createNewFolder() { var inst = $('#position').jstree(true); var id = $('#position').jstree("get_selected"); console.log(id); - if(id.length < 1){ - showmessage(__lang.please_select_dir,'danger',2000,1); + if (id.length < 1) { + showmessage(__lang.please_select_dir, 'danger', 2000, 1); return false; - }else{ + } else { var pnode = inst.get_node(id); } var fid = ''; if (!pnode.li_attr.fid) { var replacematch = /^([a-z]|[A-Z])+_/; - fid = pnode.id.replace(replacematch, ''); + fid = pnode.id.replace(replacematch, ''); } else { fid = pnode.li_attr.fid; } if (!fid) { - showmessage(__lang.please_select_dir,'danger',2000,1); + showmessage(__lang.please_select_dir, 'danger', 2000, 1); return false; } else { $.post('index.php?mod=system&op=positionlist&do=getfoldername', {'fid': fid}, function (data) { @@ -246,7 +305,7 @@ $('#new_folder').css({'position': 'relative'}); var html = '
    ' + '' + - '' + '
    '; $('#new_folder').append(html); }); - }else{ + } else { // showDialog(data['error']); - showmessage(data['error'],"danger",2000,1); + showmessage(data['error'], "danger", 2000, 1); } }, 'json'); return false; } } - function realcreate(obj, node,parentnode) { + function realcreate(obj, node, parentnode) { var inst = $('#position').jstree(true); var pnode = inst.get_node(parentnode); var fid = ''; @@ -277,20 +336,23 @@ var fname = $(obj).closest('.layer').find('.nameinput').val(); var empty = /^\s*$/; if (empty.test(fname)) { - showmessage(__lang.name_cannot_empty,"danger",2000,1); + showmessage(__lang.name_cannot_empty, "danger", 2000, 1); return false; } - $.post('index.php?mod=system&op=positionlist&do=creatnewfolder',{'fid':fid,'foldername':fname},function(data){ - if(data['msg'] == 'success'){ + $.post('index.php?mod=system&op=positionlist&do=creatnewfolder', { + 'fid': fid, + 'foldername': fname + }, function (data) { + if (data['msg'] == 'success') { inst.rename_node(node, fname); - inst.set_id(node, 'f_'+data.fid); + inst.set_id(node, 'f_' + data.fid); $(obj).closest('.layer').remove(); inst.deselect_node(parentnode); inst.select_node(node); - }else { - showmessage(data['error'],"danger",2000,1); + } else { + showmessage(data['error'], "danger", 2000, 1); } - },'json'); + }, 'json'); return false; } function canclecreate(obj, node) { @@ -298,28 +360,28 @@ $(obj).closest('.layer').remove(); inst.delete_node(node); } - function submitdata(){ - var fid = $('#'+ctrlid).val(); - if(!fid){ + function submitdata() { + var fid = $('#' + ctrlid).val(); + if (!fid) { // showDialog(__lang.please_select_dir); - showmessage(__lang.please_select_dir,"danger",2000,1); + showmessage(__lang.please_select_dir, "danger", 2000, 1); return false; - }else{ - $.post(MOD_URL+'&op=positionlist&do=geffolderinfo',{'fid':fid},function(data){ - if(parent.$callback){ - parent.$callback(fid,data); - }else{ - opened.$callback(fid,data); + } else { + $.post(MOD_URL + '&op=positionlist&do=geffolderinfo', {'fid': fid}, function (data) { + if (parent.$callback) { + parent.$callback(fid, data); + } else { + opened.$callback(fid, data); } hide_window(); - },'json') + }, 'json') } return false; } - function hide_window(){ - if(opened){ + function hide_window() { + if (opened) { window.close(); - }else{ + } else { parent.hide_window(); } } @@ -328,10 +390,14 @@ diff --git a/dzz/system/template/selectfile.htm b/dzz/system/template/selectfile.htm index 636da25..9f3782f 100644 --- a/dzz/system/template/selectfile.htm +++ b/dzz/system/template/selectfile.htm @@ -18,6 +18,5 @@ hideWindow("$_GET['handlekey']"); return false; } - \ No newline at end of file diff --git a/dzz/system/template/selorguser.htm b/dzz/system/template/selorguser.htm index f66bb62..b65c44b 100644 --- a/dzz/system/template/selorguser.htm +++ b/dzz/system/template/selorguser.htm @@ -115,7 +115,7 @@ +
    {lang dev_desc}
    +*/ +$lang = array ( + 'appname'=>'测试' ,//应用名称 统一用 appname + 'menu_setting'=>'设置' ,//菜单类 的语言 统一 以 menu_ 开头 + + 'field_subtitle'=>'副标题' ,//字段类 的语言 统一 以 field_ 开头 + + 'field_subtitle_tip'=>'副标题说明' ,//字段说明类 的语言 统一 以 在字段的基础上以_info 结束 + + 'info_test_desc' =>'这里编写自己的模板代码

    默认已经引入了:jQuery 1.10bootstrap V3 cssdzz.api.js', //说明类 的语言 统一 以 info_开头 + 'info_title1'=>'应用开发示例', + + 'button_setting'=>'保存',//按钮类 的语言 统一 以 button_ 开头 + 'info_test_hook_one'=>'我是一个钩子调用程序,哪儿需要,哪儿调用-1',//按钮类 的语言 统一 以 button_ 开头 + 'info_test_hook_two'=>'我是一个钩子调用程序,哪儿需要,哪儿调用-2'//按钮类 的语言 统一 以 button_ 开头 +); +?> \ No newline at end of file diff --git a/dzz/test/template/admin.htm b/dzz/test/template/admin.htm new file mode 100644 index 0000000..84d4d62 --- /dev/null +++ b/dzz/test/template/admin.htm @@ -0,0 +1,121 @@ + + + + + + + + + + + + +
    +
    + +
    +
    +
    +
    +
    +
    +
    + +
    + + + +
    +
    {lang field_subtitle}:
    +
    + + {lang field_subtitle_tip}
    +
    + +
    +
    + +
    +
    + + +
    +
    +
    + + + + + + \ No newline at end of file diff --git a/dzz/test/template/header_left.htm b/dzz/test/template/header_left.htm new file mode 100644 index 0000000..8e94919 --- /dev/null +++ b/dzz/test/template/header_left.htm @@ -0,0 +1,8 @@ + \ No newline at end of file diff --git a/dzz/test/template/index.htm b/dzz/test/template/index.htm new file mode 100644 index 0000000..fbf8087 --- /dev/null +++ b/dzz/test/template/index.htm @@ -0,0 +1,19 @@ + + + + + +
    +
    + {lang info_test_desc} +
    +
    + {$teststring} +
    +
    + +
    + + +
    + \ No newline at end of file diff --git a/dzz/test/template/left.htm b/dzz/test/template/left.htm new file mode 100644 index 0000000..dabac56 --- /dev/null +++ b/dzz/test/template/left.htm @@ -0,0 +1,5 @@ + \ No newline at end of file diff --git a/dzz/test/uninstall.php b/dzz/test/uninstall.php new file mode 100644 index 0000000..c709f53 --- /dev/null +++ b/dzz/test/uninstall.php @@ -0,0 +1,24 @@ + \ No newline at end of file diff --git a/install/data/install.sql b/install/data/install.sql index 4cf65ed..54cfd5f 100644 --- a/install/data/install.sql +++ b/install/data/install.sql @@ -661,12 +661,12 @@ CREATE TABLE dzz_organization ( `desc` varchar(200) NOT NULL DEFAULT '' COMMENT '群组描述', groupback int(11) unsigned NOT NULL COMMENT '群组背景图', aid varchar(30) NOT NULL default '' COMMENT '群组缩略图,可以是aid,也可以是颜色值', - manageon tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '群組管理员开启关闭0关闭,1开启', + manageon tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '群組管理员开启关闭0关闭,1开启', syatemon tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '系统管理员开启群组,关闭群组,0关闭,1开启', diron tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '群组管理员共享目录开启,0关闭,1开启', extraspace int(11) unsigned NOT NULL DEFAULT '0' COMMENT '机构群组额外空间大小', buyspace int(11) unsigned NOT NULL DEFAULT '0' COMMENT '购买空间', - ` allotspace` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '分配空间大小', + `allotspace` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '分配空间大小', PRIMARY KEY (orgid), KEY disp (disp), KEY pathkey (pathkey), @@ -1068,7 +1068,7 @@ CREATE TABLE dzz_usergroup ( groupid smallint(6) unsigned NOT NULL AUTO_INCREMENT, radminid tinyint(3) NOT NULL DEFAULT '0', `type` enum('system','special','member') NOT NULL DEFAULT 'member', - system varchar(255) NOT NULL DEFAULT 'private', + `system` varchar(255) NOT NULL DEFAULT 'private', grouptitle varchar(255) NOT NULL DEFAULT '', creditshigher int(10) NOT NULL DEFAULT '0', creditslower int(10) NOT NULL DEFAULT '0', @@ -1159,28 +1159,6 @@ CREATE TABLE dzz_user_profile_setting ( PRIMARY KEY (fieldid) ) ENGINE=MyISAM; - -DROP TABLE IF EXISTS dzz_user_salf; -CREATE TABLE dzz_user_salf ( - keyid varchar(15) NOT NULL DEFAULT '', - tokenid varchar(255) NOT NULL DEFAULT '', - `date` int(11) unsigned NOT NULL, - expire int(10) NOT NULL, - refreshtoken varchar(255) NOT NULL DEFAULT '', - uid int(11) unsigned NOT NULL, - PRIMARY KEY (uid) -) ENGINE=MyISAM; - -DROP TABLE IF EXISTS dzz_user_sdk; -CREATE TABLE dzz_user_sdk ( - `key` varchar(30) NOT NULL DEFAULT '', - secret varchar(30) NOT NULL, - `host` varchar(50) NOT NULL DEFAULT '', - backurl text NOT NULL, - usename varchar(120) NOT NULL DEFAULT '', - PRIMARY KEY (`key`) -) ENGINE=MyISAM; - DROP TABLE IF EXISTS dzz_user_status; CREATE TABLE dzz_user_status ( uid int(10) unsigned NOT NULL, diff --git a/install/data/install_data.sql b/install/data/install_data.sql index 8883721..fdc0c87 100644 --- a/install/data/install_data.sql +++ b/install/data/install_data.sql @@ -69,7 +69,7 @@ INSERT INTO `dzz_icon` VALUES(6, 'localhost', 'mod=discuss', 'discuss', 'icon/20 INSERT INTO `dzz_cron` VALUES(1, 1, 'system', '每月通知清理', 'cron_clean_notification_month.php', 1393646860, 0, -1, 1, 5, '0'); INSERT INTO `dzz_cron` VALUES(3, 1, 'system', '每周清理缓存文件', 'cron_cache_cleanup_week.php', 1395635931, 0, 1, -1, 5, '0'); INSERT INTO `dzz_cron` VALUES(4, 0, 'system', '每周清理缓存缩略图', 'cron_imgcache_cleanup_week.php', 1395635931,0, 1, -1, 5, '0'); -INSERT INTO `dzz_cron` VALUES(5, 0, 'system', '每月清除未用附件', 'cron_clean_copys0_attachment_by_month.php', 1395388548,0, -1, 1, 4, '30'); +INSERT INTO `dzz_cron` VALUES(5, 0, 'system', '每月清除未用附件', 'cron_clean_copys0_attachment_by_month.php', 1395388548,0, -1, -1, -1, '5 10 15 20 25 30 35 40 45 50 55'); INSERT INTO `dzz_cron` VALUES(6, 0, 'system', '定时备份数据库', 'cron_database_backup.php', 1460797274, 1460840400, 0, -1, 5, '0'); -- @@ -95,7 +95,6 @@ INSERT INTO `dzz_hooks` (`id`, `app_market_id`, `name`, `description`, `type`, ` (8, 0, 'app_run', '', 1, 0, 'core\\dzz\\apprun', 1, 0), (9, 0, 'mod_run', '', 1, 0, 'core\\dzz\\modrun', 1,0), (10, 0, 'adminlogin', '', 1, 0, 'admin\\login\\classes\\adminlogin', 1, 0), -(11, 0, 'login_mod', '', 1, 0, 'user\\qq\\classes\\qqlogin', 1, 0), (12, 0, 'mod_start', '', 1, 0, 'core\\dzz\\modroute', 1, 0), (13, 0, 'login_check', '', 1, 0, 'user\\login\\classes\\logincheck|user', 1, 0), (14, 0, 'login_valchk', '', 1, 0, 'user\\login\\classes\\loginvalchk|user/login', 1, 0), @@ -166,7 +165,7 @@ INSERT INTO `dzz_setting` VALUES('regname', 'register'); INSERT INTO `dzz_setting` VALUES('bbrules', '0'); INSERT INTO `dzz_setting` VALUES('bbrulesforce', '0'); INSERT INTO `dzz_setting` VALUES('bbrulestxt', ''); -INSERT INTO `dzz_setting` VALUES('seccodedata', 'a:13:{s:4:"type";s:1:"0";s:5:"width";s:3:"150";s:6:"height";s:2:"40";s:7:"scatter";s:1:"0";s:10:"background";s:1:"1";s:10:"adulterate";s:1:"1";s:3:"ttf";s:1:"1";s:5:"angle";s:1:"0";s:7:"warping";s:1:"0";s:5:"color";s:1:"1";s:4:"size";s:1:"0";s:6:"shadow";s:1:"1";s:8:"animator";s:1:"1";}'); +INSERT INTO `dzz_setting` VALUES('seccodedata', 'a:13:{s:4:"type";s:1:"0";s:5:"width";s:3:"150";s:6:"height";s:2:"34";s:7:"scatter";s:1:"0";s:10:"background";s:1:"1";s:10:"adulterate";s:1:"1";s:3:"ttf";s:1:"1";s:5:"angle";s:1:"0";s:7:"warping";s:1:"0";s:5:"color";s:1:"1";s:4:"size";s:1:"0";s:6:"shadow";s:1:"1";s:8:"animator";s:1:"1";}'); INSERT INTO `dzz_setting` VALUES('bbname', 'dzzoffice'); INSERT INTO `dzz_setting` VALUES('pwlength', '0'); INSERT INTO `dzz_setting` VALUES('strongpw', 'a:0:{}'); diff --git a/oauth.php b/oauth.php index 43cfa78..d45735b 100644 --- a/oauth.php +++ b/oauth.php @@ -10,7 +10,7 @@ define('APPTYPEID', 9); define('CURSCRIPT', 'dzz'); define('DZZSCRIPT', 'index.php'); -require './core/class/class_core.php'; +require __DIR__.'/core/coreBase.php'; $dzz = C::app(); $dzz->cachelist =array(); $dzz->init(); diff --git a/static/css/app_manage.css b/static/css/app_manage.css index 18df7ad..6b97cb3 100644 --- a/static/css/app_manage.css +++ b/static/css/app_manage.css @@ -383,7 +383,6 @@ position: absolute; top: 0; right: 10px; - display: inline-block; width: 36px; text-align: center; font-size: 22px; @@ -803,8 +802,4 @@ button.input-search-drop { .bs-container>.bs-left-container{ display:none ; } - .bs-container>.left-drager{ - display:none ; - } - } diff --git a/static/css/common.css b/static/css/common.css index 173a449..20a5a0e 100644 --- a/static/css/common.css +++ b/static/css/common.css @@ -877,14 +877,6 @@ dl>dd{ } /*input样式开始*/ -.body-content{ - display:flex; - /*padding-top: 50px;*/ -} -.body-content .black-content{ - flex: 1; - padding: 0 10px; -} .input-black{ position: relative; margin-bottom: 50px; @@ -899,7 +891,7 @@ dl>dd{ margin: 0; padding-right: 15px; } -.input-black .input-animate{ +.input-animate{ position: relative; background: transparent; background-image: -webkit-gradient(linear, left top, left bottom, from(#4c89fb), to(#4c89fb)), -webkit-gradient(linear, left top, left bottom, from(#e6e8eb), to(#e6e8eb)); @@ -921,7 +913,7 @@ dl>dd{ height: auto; } -.input-black .input-animate.animate{ +.input-animate.animate{ -webkit-background-size: 100% 1px, 100% 1px; background-size: 100% 1px, 100% 1px; -webkit-transition-duration: .1s; @@ -932,7 +924,9 @@ dl>dd{ background-image: -o-linear-gradient(#4c89fb, #4c89fb), -o-linear-gradient(#e6e8eb, #e6e8eb); background-image: linear-gradient(#4c89fb, #4c89fb), linear-gradient(#e6e8eb, #e6e8eb); } -.input-black .input-animate .input-icon{ + +.input-black .input-animate .input-icon, +.input-black.input-animate .input-icon{ position: absolute; right: 0; bottom: 5px; @@ -944,7 +938,9 @@ dl>dd{ opacity: 0.5; height: 34px; } -.input-black .input-animate .form-control{ +.input-black .input-animate .form-control, +.input-black.input-animate .form-control +{ border: 0; width: 100%; height: 30px; @@ -952,21 +948,26 @@ dl>dd{ padding:5px 0; box-shadow: none; } -.input-black .input-animate textarea.form-control{ +.input-black .input-animate textarea.form-control, +.input-black.input-animate textarea.form-control +{ height: 30px; vertical-align: top; max-height: 80px; } -.input-black .input-animate .form-control:focus{ +.input-black .input-animate .form-control:focus, +.input-black.input-animate .form-control:focus +{ border: 0; outline: 0; width: 100%; } -.input-black.disabled .input-animate .form-control{ +.input-black.disabled .input-animate .form-control, +.input-black.disabled.input-animate .form-control{ background: transparent; cursor: not-allowed; } -.input-black .input-animate .form-control[disabled],.input-black .input-animate .form-control[readonly], fieldset[disabled] .form-control{ +.form-control[disabled], .form-control[readonly], fieldset[disabled] .form-control{ background: transparent; } .input-black .form-control-file{ diff --git a/static/dzzicon/fonts/dzz.eot b/static/dzzicon/fonts/dzz.eot index 9584cd09826e1de9040dbdd0d159b06b60e3e69a..0429a8ccd471d32c12bcd2040384e2d872047c89 100644 GIT binary patch delta 604 zcmYjMO=uHQ5T4nWCQXYpi`{Pg#Z7{dMxjmIB*JQQ@F0peH&764h{cpO?P3GwP{})p z6e>bkD^2m}#l%A)JxLLfT7({?$fjOJFbFmD;-Q9aoiqoX$H$v*zHi>l+xd>GKheEf z0Pq#c?zn5Oy)a)+JrsWdz#3s9o6neX`peDor<0{4pCh*cun1tRt3>YBCS?ZHU++j61 z5)a4Jm=u$G)S#*a+>$sr6jP#cRm6mxkQElukt6anKLGAjgVAVEfKYV5N|mYu!eR-r zL>8W|avlvi&~aeesn&RnHUoP;PbK?>b*H(k zHBi^qt*z63>q^q!_sIEC(QMQ&w=6TMTDLA;@UU<~Mj5Sd?6_BNXv=t2bGRjro+xo! zs~obv-|$t2OrrV_MUhzb#}uVHv+g>pELYykXkrF{|`p}`SdgNU3{kwsdMUE O_3PoF&HAwU0sjJ(9I9LZ delta 270 zcmdn;lJU)BMz%MF3=AHH6WPpICjR2#pXg97_=16fVGj@|BSl1^RR`Fywv!n$ee=SW&=miQyUpLw*BLy+U4MZt6@g&fh@(0-$_bL4I)w12a&D zp-=-P&%n$)IhoOc@!;eojNXg~H-BI>%v5Fs$^bDx&##H`{5D@1xPjII!FBa_Ko3Fa s$scmf8INt&$dh2+98%cFC + + + + + \ No newline at end of file diff --git a/static/dzzicon/fonts/dzz.ttf b/static/dzzicon/fonts/dzz.ttf index 055bde77b648d686c4bafc78fde2cb8318d0b30d..3c8ddbdcbd325062196dcd53b90fc752d80c4c8c 100644 GIT binary patch delta 619 zcmYk4O=uHQ5P)a)wfQS0#&(++J#?GkiV>P7Zj#DMJqU_Fc+lijFiWjTldg%ThX_iZ zAR;KDE|n&D5X6HCNFf)I;;9s&2NB)0XAj1MhF&~K>FOj!a2~_FZ)VO2F`4^cdpC5L^b?;&xTIGEKJ%40CsA-)U1j?5QkCbdt}kLLizW!hv( z*UClMfEK`w)3jjpnx@ZI&p5YVZfk zAV4s(QzuW|0%5U&SfLc2s&gI*TF}kFlvQu=1{DedBtc{i!;yHskL}K>1{(xm3c!i7 z-HWnpcoLJYRjXZ7TbNW=jXN=)QH%Rrx2Mt1R>pm-NOqs5K)_9SN<9c&5=VQYZ<)q2~G~e9PAEE!~ edu2qqrMy!%dwZ_K7y3?J5sZoJL(P|kSNIol&8Cb1 delta 273 zcmbR6g7L&7#(D-u1_lOhh6V;^1_S?KeItG$wiiH=JwTk0oSRr69(LJ-fq_v5$PYu%FjE=i48 z-_5bnQ9z(koB(HMb_4Re^ZiT5e5G%bIjsPIS=t!4@TcEh&S(pkwnp*3zqm8Ax2}`c z0MK7p?B9$`WT&)i0J$Q0;ufBA`*D^;(w}DJj~{bi=@2)5KmYP!gPB!KS{o` zg21v$S+XQqPny@hU@$iUc~i! z8Ba}@L|`x?)S`saFXp!9knk@%m!HXk77N!k_R5#YhSn zB1^O1z|3kW8Vv~$j_y@SshS|Hln_f~Vd*Mk(Xa`Y1Jh=;#%fKvsQ@XE#2OzTes)mo zuIUao2tg9SfwJ9?vdlFxz&A$%PN8A8R@Ek^)CQlw65wAG-o88L=Zb1z>P(xTlcEUx z*YHWZC@1{rNA5a0;7B#qRXnenj3=c-Gt5vcoye-KLq=Q?TJ*Er0R2+TL!T1t4R%+$ z!Hm78c-&+(gchUc05h0rV5HL*2yp+w&d;kZ^#?e6=rI6WNu%%I%(rI}xKR)52ShLJ nG9vXKdR?7+gafBvD?a76@=E#8$+-dVyS)a2)oJzb`KR~?E10lA delta 309 zcmccff^o`YMzL~#H#Y`G1|TS$!oUrtJs21#JC=w|)Dfn?#tLP9T09lhv4FCWD diff --git a/static/dzzicon/icon.css b/static/dzzicon/icon.css index 6285726..7bb674a 100644 --- a/static/dzzicon/icon.css +++ b/static/dzzicon/icon.css @@ -1,10 +1,10 @@ @font-face { font-family: 'dzz'; - src: url('fonts/dzz.eot?dvx94x'); - src: url('fonts/dzz.eot?dvx94x#iefix') format('embedded-opentype'), - url('fonts/dzz.ttf?dvx94x') format('truetype'), - url('fonts/dzz.woff?dvx94x') format('woff'), - url('fonts/dzz.svg?dvx94x#icomoon') format('svg'); + src: url('fonts/dzz.eot?ox885g'); + src: url('fonts/dzz.eot?ox885g#iefix') format('embedded-opentype'), + url('fonts/dzz.ttf?ox885g') format('truetype'), + url('fonts/dzz.woff?ox885g') format('woff'), + url('fonts/dzz.svg?ox885g#icomoon') format('svg'); font-weight: normal; font-style: normal; } @@ -621,3 +621,18 @@ .dzz-archive3:before { content: "\e9c1"; } +.dzz-photo-add:before { + content: "\e9c2"; +} +.dzz-photo-check-cirlce:before { + content: "\e9c3"; +} +.dzz-photo-check-outline:before { + content: "\e9c4"; +} +.dzz-photo-check-fill:before { + content: "\e9c5"; +} +.dzz-photo-text:before { + content: "\e9c6"; +} diff --git a/static/jquery_file_upload/jquery.fileupload.js b/static/jquery_file_upload/jquery.fileupload.js index b1b05ab..ae9acbb 100644 --- a/static/jquery_file_upload/jquery.fileupload.js +++ b/static/jquery_file_upload/jquery.fileupload.js @@ -1231,11 +1231,16 @@ } if (dataTransfer && dataTransfer.files && dataTransfer.files.length) { e.preventDefault(); + data.files=[]; this._getDroppedFiles(dataTransfer).always(function (files) { - data.files = files; - // if (that._trigger('drop', e, data) !== false) { - that._onAdd(e, data); - // } + for(var i=0;i= + 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) + } + + // helper function for tests, so they check for different APIs + function unregisterTouchEvents(){ + if (!initialized) return + $(document).off(eventMap.down, down) + .off(eventMap.up, up) + .off(eventMap.move, move) + .off(eventMap.cancel, cancelAll) + $(window).off('scroll', cancelAll) + cancelAll() + initialized = false + } + + function setup(__eventMap){ + var now, delta, deltaX = 0, deltaY = 0, firstTouch, _isPointerType + + unregisterTouchEvents() + + eventMap = (__eventMap && ('down' in __eventMap)) ? __eventMap : + ('ontouchstart' in document ? + { 'down': 'touchstart', 'up': 'touchend', + 'move': 'touchmove', 'cancel': 'touchcancel' } : + 'onpointerdown' in document ? + { 'down': 'pointerdown', 'up': 'pointerup', + 'move': 'pointermove', 'cancel': 'pointercancel' } : + 'onmspointerdown' in document ? + { 'down': 'MSPointerDown', 'up': 'MSPointerUp', + 'move': 'MSPointerMove', 'cancel': 'MSPointerCancel' } : false) + + // No API availables for touch events + if (!eventMap) return + + 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) + } + }) + } + + down = function(e){ + if((_isPointerType = isPointerEventType(e, 'down')) && + !isPrimaryTouch(e)) return + firstTouch = _isPointerType ? e :((e.touches) ? e.touches[0]:e.originalEvent.changedTouches[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 = jQuery('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) + } + + move = function(e){ + if((_isPointerType = isPointerEventType(e, 'move')) && + !isPrimaryTouch(e)) return + firstTouch = _isPointerType ? e :((e.touches) ? e.touches[0]:e.originalEvent.changedTouches[0]) + cancelLongTap() + touch.x2 = firstTouch.pageX + touch.y2 = firstTouch.pageY + + deltaX += Math.abs(touch.x1 - touch.x2) + deltaY += Math.abs(touch.y1 - touch.y2) + } + + up = 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() { + if (touch.el){ + 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 = jQuery.Event('tap') + event.cancelTouch = cancelAll + // [by paper] fix -> "TypeError: 'undefined' is not an object (evaluating 'touch.el.trigger'), when double tap + if (touch.el) 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 + } + + jQuery(document).on(eventMap.up, up) + .on(eventMap.down, down) + .on(eventMap.move, move) + + // when the browser window loses focus, + // for example when a modal dialog is shown, + // cancel all ongoing events + jQuery(document).on(eventMap.cancel, cancelAll) + + // scrolling the window indicates intention of the user + // to scroll, not tap or swipe, so cancel all ongoing events + jQuery(window).on('scroll', cancelAll) + + initialized = true + } + + ;['swipe', 'swipeLeft', 'swipeRight', 'swipeUp', 'swipeDown', + 'doubleTap', 'tap', 'singleTap', 'longTap'].forEach(function(eventName){ + jQuery.fn[eventName] = function(callback){return this.on(eventName, callback) } + /*jQuery.fn[eventName] = function(callback){ + return jQuery(document).off(eventName).on(eventName,this,callback) + }*/ + }) + + jQuery.touch = { setup: setup } + + jQuery(document).ready(setup) +})(jQuery) diff --git a/static/jquery_weui/js/jquery-weui.js b/static/jquery_weui/js/jquery-weui.js new file mode 100644 index 0000000..3ba54c3 --- /dev/null +++ b/static/jquery_weui/js/jquery-weui.js @@ -0,0 +1,6441 @@ +/** +* jQuery WeUI V1.2.0 +* By 言川 +* http://lihongxun945.github.io/jquery-weui/ + */ +/* global $:true */ +/* global WebKitCSSMatrix:true */ + +(function($) { + "use strict"; + + $.fn.transitionEnd = function(callback) { + var events = ['webkitTransitionEnd', 'transitionend', 'oTransitionEnd', 'MSTransitionEnd', 'msTransitionEnd'], + i, dom = this; + + function fireCallBack(e) { + /*jshint validthis:true */ + if (e.target !== this) return; + callback.call(this, e); + for (i = 0; i < events.length; i++) { + dom.off(events[i], fireCallBack); + } + } + if (callback) { + for (i = 0; i < events.length; i++) { + dom.on(events[i], fireCallBack); + } + } + return this; + }; + + $.support = (function() { + var support = { + touch: !!(('ontouchstart' in window) || window.DocumentTouch && document instanceof window.DocumentTouch) + }; + return support; + })(); + + $.touchEvents = { + start: $.support.touch ? 'touchstart' : 'mousedown', + move: $.support.touch ? 'touchmove' : 'mousemove', + end: $.support.touch ? 'touchend' : 'mouseup' + }; + + $.getTouchPosition = function(e) { + e = e.originalEvent || e; //jquery wrap the originevent + if(e.type === 'touchstart' || e.type === 'touchmove' || e.type === 'touchend') { + return { + x: e.targetTouches[0].pageX, + y: e.targetTouches[0].pageY + }; + } else { + return { + x: e.pageX, + y: e.pageY + }; + } + }; + + $.fn.scrollHeight = function() { + return this[0].scrollHeight; + }; + + $.fn.transform = function(transform) { + for (var i = 0; i < this.length; i++) { + var elStyle = this[i].style; + elStyle.webkitTransform = elStyle.MsTransform = elStyle.msTransform = elStyle.MozTransform = elStyle.OTransform = elStyle.transform = transform; + } + return this; + }; + $.fn.transition = function(duration) { + if (typeof duration !== 'string') { + duration = duration + 'ms'; + } + for (var i = 0; i < this.length; i++) { + var elStyle = this[i].style; + elStyle.webkitTransitionDuration = elStyle.MsTransitionDuration = elStyle.msTransitionDuration = elStyle.MozTransitionDuration = elStyle.OTransitionDuration = elStyle.transitionDuration = duration; + } + return this; + }; + + $.getTranslate = function (el, axis) { + var matrix, curTransform, curStyle, transformMatrix; + + // automatic axis detection + if (typeof axis === 'undefined') { + axis = 'x'; + } + + curStyle = window.getComputedStyle(el, null); + if (window.WebKitCSSMatrix) { + // Some old versions of Webkit choke when 'none' is passed; pass + // empty string instead in this case + transformMatrix = new WebKitCSSMatrix(curStyle.webkitTransform === 'none' ? '' : curStyle.webkitTransform); + } + else { + transformMatrix = curStyle.MozTransform || curStyle.OTransform || curStyle.MsTransform || curStyle.msTransform || curStyle.transform || curStyle.getPropertyValue('transform').replace('translate(', 'matrix(1, 0, 0, 1,'); + matrix = transformMatrix.toString().split(','); + } + + if (axis === 'x') { + //Latest Chrome and webkits Fix + if (window.WebKitCSSMatrix) + curTransform = transformMatrix.m41; + //Crazy IE10 Matrix + else if (matrix.length === 16) + curTransform = parseFloat(matrix[12]); + //Normal Browsers + else + curTransform = parseFloat(matrix[4]); + } + if (axis === 'y') { + //Latest Chrome and webkits Fix + if (window.WebKitCSSMatrix) + curTransform = transformMatrix.m42; + //Crazy IE10 Matrix + else if (matrix.length === 16) + curTransform = parseFloat(matrix[13]); + //Normal Browsers + else + curTransform = parseFloat(matrix[5]); + } + + return curTransform || 0; + }; + $.requestAnimationFrame = function (callback) { + if (window.requestAnimationFrame) return window.requestAnimationFrame(callback); + else if (window.webkitRequestAnimationFrame) return window.webkitRequestAnimationFrame(callback); + else if (window.mozRequestAnimationFrame) return window.mozRequestAnimationFrame(callback); + else { + return window.setTimeout(callback, 1000 / 60); + } + }; + + $.cancelAnimationFrame = function (id) { + if (window.cancelAnimationFrame) return window.cancelAnimationFrame(id); + else if (window.webkitCancelAnimationFrame) return window.webkitCancelAnimationFrame(id); + else if (window.mozCancelAnimationFrame) return window.mozCancelAnimationFrame(id); + else { + return window.clearTimeout(id); + } + }; + + $.fn.join = function(arg) { + return this.toArray().join(arg); + } +})($); + +/*=========================== + Template7 Template engine + ===========================*/ +/* global $:true */ +/* jshint unused:false */ +/* jshint forin:false */ ++function ($) { + "use strict"; + $.Template7 = $.t7 = (function () { + function isArray(arr) { + return Object.prototype.toString.apply(arr) === '[object Array]'; + } + function isObject(obj) { + return obj instanceof Object; + } + function isFunction(func) { + return typeof func === 'function'; + } + var cache = {}; + function helperToSlices(string) { + var helperParts = string.replace(/[{}#}]/g, '').split(' '); + var slices = []; + var shiftIndex, i, j; + for (i = 0; i < helperParts.length; i++) { + var part = helperParts[i]; + if (i === 0) slices.push(part); + else { + if (part.indexOf('"') === 0) { + // Plain String + if (part.match(/"/g).length === 2) { + // One word string + slices.push(part); + } + else { + // Find closed Index + shiftIndex = 0; + for (j = i + 1; j < helperParts.length; j++) { + part += ' ' + helperParts[j]; + if (helperParts[j].indexOf('"') >= 0) { + shiftIndex = j; + slices.push(part); + break; + } + } + if (shiftIndex) i = shiftIndex; + } + } + else { + if (part.indexOf('=') > 0) { + // Hash + var hashParts = part.split('='); + var hashName = hashParts[0]; + var hashContent = hashParts[1]; + if (hashContent.match(/"/g).length !== 2) { + shiftIndex = 0; + for (j = i + 1; j < helperParts.length; j++) { + hashContent += ' ' + helperParts[j]; + if (helperParts[j].indexOf('"') >= 0) { + shiftIndex = j; + break; + } + } + if (shiftIndex) i = shiftIndex; + } + var hash = [hashName, hashContent.replace(/"/g,'')]; + slices.push(hash); + } + else { + // Plain variable + slices.push(part); + } + } + } + } + return slices; + } + function stringToBlocks(string) { + var blocks = [], i, j, k; + if (!string) return []; + var _blocks = string.split(/({{[^{^}]*}})/); + for (i = 0; i < _blocks.length; i++) { + var block = _blocks[i]; + if (block === '') continue; + if (block.indexOf('{{') < 0) { + blocks.push({ + type: 'plain', + content: block + }); + } + else { + if (block.indexOf('{/') >= 0) { + continue; + } + if (block.indexOf('{#') < 0 && block.indexOf(' ') < 0 && block.indexOf('else') < 0) { + // Simple variable + blocks.push({ + type: 'variable', + contextName: block.replace(/[{}]/g, '') + }); + continue; + } + // Helpers + var helperSlices = helperToSlices(block); + var helperName = helperSlices[0]; + var helperContext = []; + var helperHash = {}; + for (j = 1; j < helperSlices.length; j++) { + var slice = helperSlices[j]; + if (isArray(slice)) { + // Hash + helperHash[slice[0]] = slice[1] === 'false' ? false : slice[1]; + } + else { + helperContext.push(slice); + } + } + + if (block.indexOf('{#') >= 0) { + // Condition/Helper + var helperStartIndex = i; + var helperContent = ''; + var elseContent = ''; + var toSkip = 0; + var shiftIndex; + var foundClosed = false, foundElse = false, foundClosedElse = false, depth = 0; + for (j = i + 1; j < _blocks.length; j++) { + if (_blocks[j].indexOf('{{#') >= 0) { + depth ++; + } + if (_blocks[j].indexOf('{{/') >= 0) { + depth --; + } + if (_blocks[j].indexOf('{{#' + helperName) >= 0) { + helperContent += _blocks[j]; + if (foundElse) elseContent += _blocks[j]; + toSkip ++; + } + else if (_blocks[j].indexOf('{{/' + helperName) >= 0) { + if (toSkip > 0) { + toSkip--; + helperContent += _blocks[j]; + if (foundElse) elseContent += _blocks[j]; + } + else { + shiftIndex = j; + foundClosed = true; + break; + } + } + else if (_blocks[j].indexOf('else') >= 0 && depth === 0) { + foundElse = true; + } + else { + if (!foundElse) helperContent += _blocks[j]; + if (foundElse) elseContent += _blocks[j]; + } + + } + if (foundClosed) { + if (shiftIndex) i = shiftIndex; + blocks.push({ + type: 'helper', + helperName: helperName, + contextName: helperContext, + content: helperContent, + inverseContent: elseContent, + hash: helperHash + }); + } + } + else if (block.indexOf(' ') > 0) { + blocks.push({ + type: 'helper', + helperName: helperName, + contextName: helperContext, + hash: helperHash + }); + } + } + } + return blocks; + } + var Template7 = function (template) { + var t = this; + t.template = template; + + function getCompileFn(block, depth) { + if (block.content) return compile(block.content, depth); + else return function () {return ''; }; + } + function getCompileInverse(block, depth) { + if (block.inverseContent) return compile(block.inverseContent, depth); + else return function () {return ''; }; + } + function getCompileVar(name, ctx) { + var variable, parts, levelsUp = 0, initialCtx = ctx; + if (name.indexOf('../') === 0) { + levelsUp = name.split('../').length - 1; + var newDepth = ctx.split('_')[1] - levelsUp; + ctx = 'ctx_' + (newDepth >= 1 ? newDepth : 1); + parts = name.split('../')[levelsUp].split('.'); + } + else if (name.indexOf('@global') === 0) { + ctx = '$.Template7.global'; + parts = name.split('@global.')[1].split('.'); + } + else if (name.indexOf('@root') === 0) { + ctx = 'ctx_1'; + parts = name.split('@root.')[1].split('.'); + } + else { + parts = name.split('.'); + } + variable = ctx; + for (var i = 0; i < parts.length; i++) { + var part = parts[i]; + if (part.indexOf('@') === 0) { + if (i > 0) { + variable += '[(data && data.' + part.replace('@', '') + ')]'; + } + else { + variable = '(data && data.' + name.replace('@', '') + ')'; + } + } + else { + if (isFinite(part)) { + variable += '[' + part + ']'; + } + else { + if (part.indexOf('this') === 0) { + variable = part.replace('this', ctx); + } + else { + variable += '.' + part; + } + } + } + } + + return variable; + } + function getCompiledArguments(contextArray, ctx) { + var arr = []; + for (var i = 0; i < contextArray.length; i++) { + if (contextArray[i].indexOf('"') === 0) arr.push(contextArray[i]); + else { + arr.push(getCompileVar(contextArray[i], ctx)); + } + } + return arr.join(', '); + } + function compile(template, depth) { + depth = depth || 1; + template = template || t.template; + if (typeof template !== 'string') { + throw new Error('Template7: Template must be a string'); + } + var blocks = stringToBlocks(template); + if (blocks.length === 0) { + return function () { return ''; }; + } + var ctx = 'ctx_' + depth; + var resultString = '(function (' + ctx + ', data) {\n'; + if (depth === 1) { + resultString += 'function isArray(arr){return Object.prototype.toString.apply(arr) === \'[object Array]\';}\n'; + resultString += 'function isFunction(func){return (typeof func === \'function\');}\n'; + resultString += 'function c(val, ctx) {if (typeof val !== "undefined") {if (isFunction(val)) {return val.call(ctx);} else return val;} else return "";}\n'; + } + resultString += 'var r = \'\';\n'; + var i, j, context; + for (i = 0; i < blocks.length; i++) { + var block = blocks[i]; + // Plain block + if (block.type === 'plain') { + resultString += 'r +=\'' + (block.content).replace(/\r/g, '\\r').replace(/\n/g, '\\n').replace(/'/g, '\\' + '\'') + '\';'; + continue; + } + var variable, compiledArguments; + // Variable block + if (block.type === 'variable') { + variable = getCompileVar(block.contextName, ctx); + resultString += 'r += c(' + variable + ', ' + ctx + ');'; + } + // Helpers block + if (block.type === 'helper') { + if (block.helperName in t.helpers) { + compiledArguments = getCompiledArguments(block.contextName, ctx); + resultString += 'r += ($.Template7.helpers.' + block.helperName + ').call(' + ctx + ', ' + (compiledArguments && (compiledArguments + ', ')) +'{hash:' + JSON.stringify(block.hash) + ', data: data || {}, fn: ' + getCompileFn(block, depth+1) + ', inverse: ' + getCompileInverse(block, depth+1) + ', root: ctx_1});'; + } + else { + if (block.contextName.length > 0) { + throw new Error('Template7: Missing helper: "' + block.helperName + '"'); + } + else { + variable = getCompileVar(block.helperName, ctx); + resultString += 'if (' + variable + ') {'; + resultString += 'if (isArray(' + variable + ')) {'; + resultString += 'r += ($.Template7.helpers.each).call(' + ctx + ', ' + variable + ', {hash:' + JSON.stringify(block.hash) + ', data: data || {}, fn: ' + getCompileFn(block, depth+1) + ', inverse: ' + getCompileInverse(block, depth+1) + ', root: ctx_1});'; + resultString += '}else {'; + resultString += 'r += ($.Template7.helpers.with).call(' + ctx + ', ' + variable + ', {hash:' + JSON.stringify(block.hash) + ', data: data || {}, fn: ' + getCompileFn(block, depth+1) + ', inverse: ' + getCompileInverse(block, depth+1) + ', root: ctx_1});'; + resultString += '}}'; + } + } + } + } + resultString += '\nreturn r;})'; + return eval.call(window, resultString); + } + t.compile = function (template) { + if (!t.compiled) { + t.compiled = compile(template); + } + return t.compiled; + }; + }; + Template7.prototype = { + options: {}, + helpers: { + 'if': function (context, options) { + if (isFunction(context)) { context = context.call(this); } + if (context) { + return options.fn(this, options.data); + } + else { + return options.inverse(this, options.data); + } + }, + 'unless': function (context, options) { + if (isFunction(context)) { context = context.call(this); } + if (!context) { + return options.fn(this, options.data); + } + else { + return options.inverse(this, options.data); + } + }, + 'each': function (context, options) { + var ret = '', i = 0; + if (isFunction(context)) { context = context.call(this); } + if (isArray(context)) { + if (options.hash.reverse) { + context = context.reverse(); + } + for (i = 0; i < context.length; i++) { + ret += options.fn(context[i], {first: i === 0, last: i === context.length - 1, index: i}); + } + if (options.hash.reverse) { + context = context.reverse(); + } + } + else { + for (var key in context) { + i++; + ret += options.fn(context[key], {key: key}); + } + } + if (i > 0) return ret; + else return options.inverse(this); + }, + 'with': function (context, options) { + if (isFunction(context)) { context = context.call(this); } + return options.fn(context); + }, + 'join': function (context, options) { + if (isFunction(context)) { context = context.call(this); } + return context.join(options.hash.delimiter || options.hash.delimeter); + }, + 'js': function (expression, options) { + var func; + if (expression.indexOf('return')>=0) { + func = '(function(){'+expression+'})'; + } + else { + func = '(function(){return ('+expression+')})'; + } + return eval.call(this, func).call(this); + }, + 'js_compare': function (expression, options) { + var func; + if (expression.indexOf('return')>=0) { + func = '(function(){'+expression+'})'; + } + else { + func = '(function(){return ('+expression+')})'; + } + var condition = eval.call(this, func).call(this); + if (condition) { + return options.fn(this, options.data); + } + else { + return options.inverse(this, options.data); + } + } + } + }; + var t7 = function (template, data) { + if (arguments.length === 2) { + var instance = new Template7(template); + var rendered = instance.compile()(data); + instance = null; + return (rendered); + } + else return new Template7(template); + }; + t7.registerHelper = function (name, fn) { + Template7.prototype.helpers[name] = fn; + }; + t7.unregisterHelper = function (name) { + Template7.prototype.helpers[name] = undefined; + delete Template7.prototype.helpers[name]; + }; + + t7.compile = function (template, options) { + var instance = new Template7(template, options); + return instance.compile(); + }; + + t7.options = Template7.prototype.options; + t7.helpers = Template7.prototype.helpers; + return t7; + })(); +}($); + +/*! Hammer.JS - v2.0.8 - 2016-04-23 + * http://hammerjs.github.io/ + * + * Copyright (c) 2016 Jorik Tangelder; + * Licensed under the MIT license */ +(function(window, document, exportName, undefined) { + 'use strict'; + +var VENDOR_PREFIXES = ['', 'webkit', 'Moz', 'MS', 'ms', 'o']; +var TEST_ELEMENT = document.createElement('div'); + +var TYPE_FUNCTION = 'function'; + +var round = Math.round; +var abs = Math.abs; +var now = Date.now; + +/** + * set a timeout with a given scope + * @param {Function} fn + * @param {Number} timeout + * @param {Object} context + * @returns {number} + */ +function setTimeoutContext(fn, timeout, context) { + return setTimeout(bindFn(fn, context), timeout); +} + +/** + * if the argument is an array, we want to execute the fn on each entry + * if it aint an array we don't want to do a thing. + * this is used by all the methods that accept a single and array argument. + * @param {*|Array} arg + * @param {String} fn + * @param {Object} [context] + * @returns {Boolean} + */ +function invokeArrayArg(arg, fn, context) { + if (Array.isArray(arg)) { + each(arg, context[fn], context); + return true; + } + return false; +} + +/** + * walk objects and arrays + * @param {Object} obj + * @param {Function} iterator + * @param {Object} context + */ +function each(obj, iterator, context) { + var i; + + if (!obj) { + return; + } + + if (obj.forEach) { + obj.forEach(iterator, context); + } else if (obj.length !== undefined) { + i = 0; + while (i < obj.length) { + iterator.call(context, obj[i], i, obj); + i++; + } + } else { + for (i in obj) { + obj.hasOwnProperty(i) && iterator.call(context, obj[i], i, obj); + } + } +} + +/** + * wrap a method with a deprecation warning and stack trace + * @param {Function} method + * @param {String} name + * @param {String} message + * @returns {Function} A new function wrapping the supplied method. + */ +function deprecate(method, name, message) { + var deprecationMessage = 'DEPRECATED METHOD: ' + name + '\n' + message + ' AT \n'; + return function() { + var e = new Error('get-stack-trace'); + var stack = e && e.stack ? e.stack.replace(/^[^\(]+?[\n$]/gm, '') + .replace(/^\s+at\s+/gm, '') + .replace(/^Object.\s*\(/gm, '{anonymous}()@') : 'Unknown Stack Trace'; + + var log = window.console && (window.console.warn || window.console.log); + if (log) { + log.call(window.console, deprecationMessage, stack); + } + return method.apply(this, arguments); + }; +} + +/** + * extend object. + * means that properties in dest will be overwritten by the ones in src. + * @param {Object} target + * @param {...Object} objects_to_assign + * @returns {Object} target + */ +var assign; +if (typeof Object.assign !== 'function') { + assign = function assign(target) { + if (target === undefined || target === null) { + throw new TypeError('Cannot convert undefined or null to object'); + } + + var output = Object(target); + for (var index = 1; index < arguments.length; index++) { + var source = arguments[index]; + if (source !== undefined && source !== null) { + for (var nextKey in source) { + if (source.hasOwnProperty(nextKey)) { + output[nextKey] = source[nextKey]; + } + } + } + } + return output; + }; +} else { + assign = Object.assign; +} + +/** + * extend object. + * means that properties in dest will be overwritten by the ones in src. + * @param {Object} dest + * @param {Object} src + * @param {Boolean} [merge=false] + * @returns {Object} dest + */ +var extend = deprecate(function extend(dest, src, merge) { + var keys = Object.keys(src); + var i = 0; + while (i < keys.length) { + if (!merge || (merge && dest[keys[i]] === undefined)) { + dest[keys[i]] = src[keys[i]]; + } + i++; + } + return dest; +}, 'extend', 'Use `assign`.'); + +/** + * merge the values from src in the dest. + * means that properties that exist in dest will not be overwritten by src + * @param {Object} dest + * @param {Object} src + * @returns {Object} dest + */ +var merge = deprecate(function merge(dest, src) { + return extend(dest, src, true); +}, 'merge', 'Use `assign`.'); + +/** + * simple class inheritance + * @param {Function} child + * @param {Function} base + * @param {Object} [properties] + */ +function inherit(child, base, properties) { + var baseP = base.prototype, + childP; + + childP = child.prototype = Object.create(baseP); + childP.constructor = child; + childP._super = baseP; + + if (properties) { + assign(childP, properties); + } +} + +/** + * simple function bind + * @param {Function} fn + * @param {Object} context + * @returns {Function} + */ +function bindFn(fn, context) { + return function boundFn() { + return fn.apply(context, arguments); + }; +} + +/** + * let a boolean value also be a function that must return a boolean + * this first item in args will be used as the context + * @param {Boolean|Function} val + * @param {Array} [args] + * @returns {Boolean} + */ +function boolOrFn(val, args) { + if (typeof val == TYPE_FUNCTION) { + return val.apply(args ? args[0] || undefined : undefined, args); + } + return val; +} + +/** + * use the val2 when val1 is undefined + * @param {*} val1 + * @param {*} val2 + * @returns {*} + */ +function ifUndefined(val1, val2) { + return (val1 === undefined) ? val2 : val1; +} + +/** + * addEventListener with multiple events at once + * @param {EventTarget} target + * @param {String} types + * @param {Function} handler + */ +function addEventListeners(target, types, handler) { + each(splitStr(types), function(type) { + target.addEventListener(type, handler, false); + }); +} + +/** + * removeEventListener with multiple events at once + * @param {EventTarget} target + * @param {String} types + * @param {Function} handler + */ +function removeEventListeners(target, types, handler) { + each(splitStr(types), function(type) { + target.removeEventListener(type, handler, false); + }); +} + +/** + * find if a node is in the given parent + * @method hasParent + * @param {HTMLElement} node + * @param {HTMLElement} parent + * @return {Boolean} found + */ +function hasParent(node, parent) { + while (node) { + if (node == parent) { + return true; + } + node = node.parentNode; + } + return false; +} + +/** + * small indexOf wrapper + * @param {String} str + * @param {String} find + * @returns {Boolean} found + */ +function inStr(str, find) { + return str.indexOf(find) > -1; +} + +/** + * split string on whitespace + * @param {String} str + * @returns {Array} words + */ +function splitStr(str) { + return str.trim().split(/\s+/g); +} + +/** + * find if a array contains the object using indexOf or a simple polyFill + * @param {Array} src + * @param {String} find + * @param {String} [findByKey] + * @return {Boolean|Number} false when not found, or the index + */ +function inArray(src, find, findByKey) { + if (src.indexOf && !findByKey) { + return src.indexOf(find); + } else { + var i = 0; + while (i < src.length) { + if ((findByKey && src[i][findByKey] == find) || (!findByKey && src[i] === find)) { + return i; + } + i++; + } + return -1; + } +} + +/** + * convert array-like objects to real arrays + * @param {Object} obj + * @returns {Array} + */ +function toArray(obj) { + return Array.prototype.slice.call(obj, 0); +} + +/** + * unique array with objects based on a key (like 'id') or just by the array's value + * @param {Array} src [{id:1},{id:2},{id:1}] + * @param {String} [key] + * @param {Boolean} [sort=False] + * @returns {Array} [{id:1},{id:2}] + */ +function uniqueArray(src, key, sort) { + var results = []; + var values = []; + var i = 0; + + while (i < src.length) { + var val = key ? src[i][key] : src[i]; + if (inArray(values, val) < 0) { + results.push(src[i]); + } + values[i] = val; + i++; + } + + if (sort) { + if (!key) { + results = results.sort(); + } else { + results = results.sort(function sortUniqueArray(a, b) { + return a[key] > b[key]; + }); + } + } + + return results; +} + +/** + * get the prefixed property + * @param {Object} obj + * @param {String} property + * @returns {String|Undefined} prefixed + */ +function prefixed(obj, property) { + var prefix, prop; + var camelProp = property[0].toUpperCase() + property.slice(1); + + var i = 0; + while (i < VENDOR_PREFIXES.length) { + prefix = VENDOR_PREFIXES[i]; + prop = (prefix) ? prefix + camelProp : property; + + if (prop in obj) { + return prop; + } + i++; + } + return undefined; +} + +/** + * get a unique id + * @returns {number} uniqueId + */ +var _uniqueId = 1; +function uniqueId() { + return _uniqueId++; +} + +/** + * get the window object of an element + * @param {HTMLElement} element + * @returns {DocumentView|Window} + */ +function getWindowForElement(element) { + var doc = element.ownerDocument || element; + return (doc.defaultView || doc.parentWindow || window); +} + +var MOBILE_REGEX = /mobile|tablet|ip(ad|hone|od)|android/i; + +var SUPPORT_TOUCH = ('ontouchstart' in window); +var SUPPORT_POINTER_EVENTS = prefixed(window, 'PointerEvent') !== undefined; +var SUPPORT_ONLY_TOUCH = SUPPORT_TOUCH && MOBILE_REGEX.test(navigator.userAgent); + +var INPUT_TYPE_TOUCH = 'touch'; +var INPUT_TYPE_PEN = 'pen'; +var INPUT_TYPE_MOUSE = 'mouse'; +var INPUT_TYPE_KINECT = 'kinect'; + +var COMPUTE_INTERVAL = 25; + +var INPUT_START = 1; +var INPUT_MOVE = 2; +var INPUT_END = 4; +var INPUT_CANCEL = 8; + +var DIRECTION_NONE = 1; +var DIRECTION_LEFT = 2; +var DIRECTION_RIGHT = 4; +var DIRECTION_UP = 8; +var DIRECTION_DOWN = 16; + +var DIRECTION_HORIZONTAL = DIRECTION_LEFT | DIRECTION_RIGHT; +var DIRECTION_VERTICAL = DIRECTION_UP | DIRECTION_DOWN; +var DIRECTION_ALL = DIRECTION_HORIZONTAL | DIRECTION_VERTICAL; + +var PROPS_XY = ['x', 'y']; +var PROPS_CLIENT_XY = ['clientX', 'clientY']; + +/** + * create new input type manager + * @param {Manager} manager + * @param {Function} callback + * @returns {Input} + * @constructor + */ +function Input(manager, callback) { + var self = this; + this.manager = manager; + this.callback = callback; + this.element = manager.element; + this.target = manager.options.inputTarget; + + // smaller wrapper around the handler, for the scope and the enabled state of the manager, + // so when disabled the input events are completely bypassed. + this.domHandler = function(ev) { + if (boolOrFn(manager.options.enable, [manager])) { + self.handler(ev); + } + }; + + this.init(); + +} + +Input.prototype = { + /** + * should handle the inputEvent data and trigger the callback + * @virtual + */ + handler: function() { }, + + /** + * bind the events + */ + init: function() { + this.evEl && addEventListeners(this.element, this.evEl, this.domHandler); + this.evTarget && addEventListeners(this.target, this.evTarget, this.domHandler); + this.evWin && addEventListeners(getWindowForElement(this.element), this.evWin, this.domHandler); + }, + + /** + * unbind the events + */ + destroy: function() { + this.evEl && removeEventListeners(this.element, this.evEl, this.domHandler); + this.evTarget && removeEventListeners(this.target, this.evTarget, this.domHandler); + this.evWin && removeEventListeners(getWindowForElement(this.element), this.evWin, this.domHandler); + } +}; + +/** + * create new input type manager + * called by the Manager constructor + * @param {Hammer} manager + * @returns {Input} + */ +function createInputInstance(manager) { + var Type; + var inputClass = manager.options.inputClass; + + if (inputClass) { + Type = inputClass; + } else if (SUPPORT_POINTER_EVENTS) { + Type = PointerEventInput; + } else if (SUPPORT_ONLY_TOUCH) { + Type = TouchInput; + } else if (!SUPPORT_TOUCH) { + Type = MouseInput; + } else { + Type = TouchMouseInput; + } + return new (Type)(manager, inputHandler); +} + +/** + * handle input events + * @param {Manager} manager + * @param {String} eventType + * @param {Object} input + */ +function inputHandler(manager, eventType, input) { + var pointersLen = input.pointers.length; + var changedPointersLen = input.changedPointers.length; + var isFirst = (eventType & INPUT_START && (pointersLen - changedPointersLen === 0)); + var isFinal = (eventType & (INPUT_END | INPUT_CANCEL) && (pointersLen - changedPointersLen === 0)); + + input.isFirst = !!isFirst; + input.isFinal = !!isFinal; + + if (isFirst) { + manager.session = {}; + } + + // source event is the normalized value of the domEvents + // like 'touchstart, mouseup, pointerdown' + input.eventType = eventType; + + // compute scale, rotation etc + computeInputData(manager, input); + + // emit secret event + manager.emit('hammer.input', input); + + manager.recognize(input); + manager.session.prevInput = input; +} + +/** + * extend the data with some usable properties like scale, rotate, velocity etc + * @param {Object} manager + * @param {Object} input + */ +function computeInputData(manager, input) { + var session = manager.session; + var pointers = input.pointers; + var pointersLength = pointers.length; + + // store the first input to calculate the distance and direction + if (!session.firstInput) { + session.firstInput = simpleCloneInputData(input); + } + + // to compute scale and rotation we need to store the multiple touches + if (pointersLength > 1 && !session.firstMultiple) { + session.firstMultiple = simpleCloneInputData(input); + } else if (pointersLength === 1) { + session.firstMultiple = false; + } + + var firstInput = session.firstInput; + var firstMultiple = session.firstMultiple; + var offsetCenter = firstMultiple ? firstMultiple.center : firstInput.center; + + var center = input.center = getCenter(pointers); + input.timeStamp = now(); + input.deltaTime = input.timeStamp - firstInput.timeStamp; + + input.angle = getAngle(offsetCenter, center); + input.distance = getDistance(offsetCenter, center); + + computeDeltaXY(session, input); + input.offsetDirection = getDirection(input.deltaX, input.deltaY); + + var overallVelocity = getVelocity(input.deltaTime, input.deltaX, input.deltaY); + input.overallVelocityX = overallVelocity.x; + input.overallVelocityY = overallVelocity.y; + input.overallVelocity = (abs(overallVelocity.x) > abs(overallVelocity.y)) ? overallVelocity.x : overallVelocity.y; + + input.scale = firstMultiple ? getScale(firstMultiple.pointers, pointers) : 1; + input.rotation = firstMultiple ? getRotation(firstMultiple.pointers, pointers) : 0; + + input.maxPointers = !session.prevInput ? input.pointers.length : ((input.pointers.length > + session.prevInput.maxPointers) ? input.pointers.length : session.prevInput.maxPointers); + + computeIntervalInputData(session, input); + + // find the correct target + var target = manager.element; + if (hasParent(input.srcEvent.target, target)) { + target = input.srcEvent.target; + } + input.target = target; +} + +function computeDeltaXY(session, input) { + var center = input.center; + var offset = session.offsetDelta || {}; + var prevDelta = session.prevDelta || {}; + var prevInput = session.prevInput || {}; + + if (input.eventType === INPUT_START || prevInput.eventType === INPUT_END) { + prevDelta = session.prevDelta = { + x: prevInput.deltaX || 0, + y: prevInput.deltaY || 0 + }; + + offset = session.offsetDelta = { + x: center.x, + y: center.y + }; + } + + input.deltaX = prevDelta.x + (center.x - offset.x); + input.deltaY = prevDelta.y + (center.y - offset.y); +} + +/** + * velocity is calculated every x ms + * @param {Object} session + * @param {Object} input + */ +function computeIntervalInputData(session, input) { + var last = session.lastInterval || input, + deltaTime = input.timeStamp - last.timeStamp, + velocity, velocityX, velocityY, direction; + + if (input.eventType != INPUT_CANCEL && (deltaTime > COMPUTE_INTERVAL || last.velocity === undefined)) { + var deltaX = input.deltaX - last.deltaX; + var deltaY = input.deltaY - last.deltaY; + + var v = getVelocity(deltaTime, deltaX, deltaY); + velocityX = v.x; + velocityY = v.y; + velocity = (abs(v.x) > abs(v.y)) ? v.x : v.y; + direction = getDirection(deltaX, deltaY); + + session.lastInterval = input; + } else { + // use latest velocity info if it doesn't overtake a minimum period + velocity = last.velocity; + velocityX = last.velocityX; + velocityY = last.velocityY; + direction = last.direction; + } + + input.velocity = velocity; + input.velocityX = velocityX; + input.velocityY = velocityY; + input.direction = direction; +} + +/** + * create a simple clone from the input used for storage of firstInput and firstMultiple + * @param {Object} input + * @returns {Object} clonedInputData + */ +function simpleCloneInputData(input) { + // make a simple copy of the pointers because we will get a reference if we don't + // we only need clientXY for the calculations + var pointers = []; + var i = 0; + while (i < input.pointers.length) { + pointers[i] = { + clientX: round(input.pointers[i].clientX), + clientY: round(input.pointers[i].clientY) + }; + i++; + } + + return { + timeStamp: now(), + pointers: pointers, + center: getCenter(pointers), + deltaX: input.deltaX, + deltaY: input.deltaY + }; +} + +/** + * get the center of all the pointers + * @param {Array} pointers + * @return {Object} center contains `x` and `y` properties + */ +function getCenter(pointers) { + var pointersLength = pointers.length; + + // no need to loop when only one touch + if (pointersLength === 1) { + return { + x: round(pointers[0].clientX), + y: round(pointers[0].clientY) + }; + } + + var x = 0, y = 0, i = 0; + while (i < pointersLength) { + x += pointers[i].clientX; + y += pointers[i].clientY; + i++; + } + + return { + x: round(x / pointersLength), + y: round(y / pointersLength) + }; +} + +/** + * calculate the velocity between two points. unit is in px per ms. + * @param {Number} deltaTime + * @param {Number} x + * @param {Number} y + * @return {Object} velocity `x` and `y` + */ +function getVelocity(deltaTime, x, y) { + return { + x: x / deltaTime || 0, + y: y / deltaTime || 0 + }; +} + +/** + * get the direction between two points + * @param {Number} x + * @param {Number} y + * @return {Number} direction + */ +function getDirection(x, y) { + if (x === y) { + return DIRECTION_NONE; + } + + if (abs(x) >= abs(y)) { + return x < 0 ? DIRECTION_LEFT : DIRECTION_RIGHT; + } + return y < 0 ? DIRECTION_UP : DIRECTION_DOWN; +} + +/** + * calculate the absolute distance between two points + * @param {Object} p1 {x, y} + * @param {Object} p2 {x, y} + * @param {Array} [props] containing x and y keys + * @return {Number} distance + */ +function getDistance(p1, p2, props) { + if (!props) { + props = PROPS_XY; + } + var x = p2[props[0]] - p1[props[0]], + y = p2[props[1]] - p1[props[1]]; + + return Math.sqrt((x * x) + (y * y)); +} + +/** + * calculate the angle between two coordinates + * @param {Object} p1 + * @param {Object} p2 + * @param {Array} [props] containing x and y keys + * @return {Number} angle + */ +function getAngle(p1, p2, props) { + if (!props) { + props = PROPS_XY; + } + var x = p2[props[0]] - p1[props[0]], + y = p2[props[1]] - p1[props[1]]; + return Math.atan2(y, x) * 180 / Math.PI; +} + +/** + * calculate the rotation degrees between two pointersets + * @param {Array} start array of pointers + * @param {Array} end array of pointers + * @return {Number} rotation + */ +function getRotation(start, end) { + return getAngle(end[1], end[0], PROPS_CLIENT_XY) + getAngle(start[1], start[0], PROPS_CLIENT_XY); +} + +/** + * calculate the scale factor between two pointersets + * no scale is 1, and goes down to 0 when pinched together, and bigger when pinched out + * @param {Array} start array of pointers + * @param {Array} end array of pointers + * @return {Number} scale + */ +function getScale(start, end) { + return getDistance(end[0], end[1], PROPS_CLIENT_XY) / getDistance(start[0], start[1], PROPS_CLIENT_XY); +} + +var MOUSE_INPUT_MAP = { + mousedown: INPUT_START, + mousemove: INPUT_MOVE, + mouseup: INPUT_END +}; + +var MOUSE_ELEMENT_EVENTS = 'mousedown'; +var MOUSE_WINDOW_EVENTS = 'mousemove mouseup'; + +/** + * Mouse events input + * @constructor + * @extends Input + */ +function MouseInput() { + this.evEl = MOUSE_ELEMENT_EVENTS; + this.evWin = MOUSE_WINDOW_EVENTS; + + this.pressed = false; // mousedown state + + Input.apply(this, arguments); +} + +inherit(MouseInput, Input, { + /** + * handle mouse events + * @param {Object} ev + */ + handler: function MEhandler(ev) { + var eventType = MOUSE_INPUT_MAP[ev.type]; + + // on start we want to have the left mouse button down + if (eventType & INPUT_START && ev.button === 0) { + this.pressed = true; + } + + if (eventType & INPUT_MOVE && ev.which !== 1) { + eventType = INPUT_END; + } + + // mouse must be down + if (!this.pressed) { + return; + } + + if (eventType & INPUT_END) { + this.pressed = false; + } + + this.callback(this.manager, eventType, { + pointers: [ev], + changedPointers: [ev], + pointerType: INPUT_TYPE_MOUSE, + srcEvent: ev + }); + } +}); + +var POINTER_INPUT_MAP = { + pointerdown: INPUT_START, + pointermove: INPUT_MOVE, + pointerup: INPUT_END, + pointercancel: INPUT_CANCEL, + pointerout: INPUT_CANCEL +}; + +// in IE10 the pointer types is defined as an enum +var IE10_POINTER_TYPE_ENUM = { + 2: INPUT_TYPE_TOUCH, + 3: INPUT_TYPE_PEN, + 4: INPUT_TYPE_MOUSE, + 5: INPUT_TYPE_KINECT // see https://twitter.com/jacobrossi/status/480596438489890816 +}; + +var POINTER_ELEMENT_EVENTS = 'pointerdown'; +var POINTER_WINDOW_EVENTS = 'pointermove pointerup pointercancel'; + +// IE10 has prefixed support, and case-sensitive +if (window.MSPointerEvent && !window.PointerEvent) { + POINTER_ELEMENT_EVENTS = 'MSPointerDown'; + POINTER_WINDOW_EVENTS = 'MSPointerMove MSPointerUp MSPointerCancel'; +} + +/** + * Pointer events input + * @constructor + * @extends Input + */ +function PointerEventInput() { + this.evEl = POINTER_ELEMENT_EVENTS; + this.evWin = POINTER_WINDOW_EVENTS; + + Input.apply(this, arguments); + + this.store = (this.manager.session.pointerEvents = []); +} + +inherit(PointerEventInput, Input, { + /** + * handle mouse events + * @param {Object} ev + */ + handler: function PEhandler(ev) { + var store = this.store; + var removePointer = false; + + var eventTypeNormalized = ev.type.toLowerCase().replace('ms', ''); + var eventType = POINTER_INPUT_MAP[eventTypeNormalized]; + var pointerType = IE10_POINTER_TYPE_ENUM[ev.pointerType] || ev.pointerType; + + var isTouch = (pointerType == INPUT_TYPE_TOUCH); + + // get index of the event in the store + var storeIndex = inArray(store, ev.pointerId, 'pointerId'); + + // start and mouse must be down + if (eventType & INPUT_START && (ev.button === 0 || isTouch)) { + if (storeIndex < 0) { + store.push(ev); + storeIndex = store.length - 1; + } + } else if (eventType & (INPUT_END | INPUT_CANCEL)) { + removePointer = true; + } + + // it not found, so the pointer hasn't been down (so it's probably a hover) + if (storeIndex < 0) { + return; + } + + // update the event in the store + store[storeIndex] = ev; + + this.callback(this.manager, eventType, { + pointers: store, + changedPointers: [ev], + pointerType: pointerType, + srcEvent: ev + }); + + if (removePointer) { + // remove from the store + store.splice(storeIndex, 1); + } + } +}); + +var SINGLE_TOUCH_INPUT_MAP = { + touchstart: INPUT_START, + touchmove: INPUT_MOVE, + touchend: INPUT_END, + touchcancel: INPUT_CANCEL +}; + +var SINGLE_TOUCH_TARGET_EVENTS = 'touchstart'; +var SINGLE_TOUCH_WINDOW_EVENTS = 'touchstart touchmove touchend touchcancel'; + +/** + * Touch events input + * @constructor + * @extends Input + */ +function SingleTouchInput() { + this.evTarget = SINGLE_TOUCH_TARGET_EVENTS; + this.evWin = SINGLE_TOUCH_WINDOW_EVENTS; + this.started = false; + + Input.apply(this, arguments); +} + +inherit(SingleTouchInput, Input, { + handler: function TEhandler(ev) { + var type = SINGLE_TOUCH_INPUT_MAP[ev.type]; + + // should we handle the touch events? + if (type === INPUT_START) { + this.started = true; + } + + if (!this.started) { + return; + } + + var touches = normalizeSingleTouches.call(this, ev, type); + + // when done, reset the started state + if (type & (INPUT_END | INPUT_CANCEL) && touches[0].length - touches[1].length === 0) { + this.started = false; + } + + this.callback(this.manager, type, { + pointers: touches[0], + changedPointers: touches[1], + pointerType: INPUT_TYPE_TOUCH, + srcEvent: ev + }); + } +}); + +/** + * @this {TouchInput} + * @param {Object} ev + * @param {Number} type flag + * @returns {undefined|Array} [all, changed] + */ +function normalizeSingleTouches(ev, type) { + var all = toArray(ev.touches); + var changed = toArray(ev.changedTouches); + + if (type & (INPUT_END | INPUT_CANCEL)) { + all = uniqueArray(all.concat(changed), 'identifier', true); + } + + return [all, changed]; +} + +var TOUCH_INPUT_MAP = { + touchstart: INPUT_START, + touchmove: INPUT_MOVE, + touchend: INPUT_END, + touchcancel: INPUT_CANCEL +}; + +var TOUCH_TARGET_EVENTS = 'touchstart touchmove touchend touchcancel'; + +/** + * Multi-user touch events input + * @constructor + * @extends Input + */ +function TouchInput() { + this.evTarget = TOUCH_TARGET_EVENTS; + this.targetIds = {}; + + Input.apply(this, arguments); +} + +inherit(TouchInput, Input, { + handler: function MTEhandler(ev) { + var type = TOUCH_INPUT_MAP[ev.type]; + var touches = getTouches.call(this, ev, type); + if (!touches) { + return; + } + + this.callback(this.manager, type, { + pointers: touches[0], + changedPointers: touches[1], + pointerType: INPUT_TYPE_TOUCH, + srcEvent: ev + }); + } +}); + +/** + * @this {TouchInput} + * @param {Object} ev + * @param {Number} type flag + * @returns {undefined|Array} [all, changed] + */ +function getTouches(ev, type) { + var allTouches = toArray(ev.touches); + var targetIds = this.targetIds; + + // when there is only one touch, the process can be simplified + if (type & (INPUT_START | INPUT_MOVE) && allTouches.length === 1) { + targetIds[allTouches[0].identifier] = true; + return [allTouches, allTouches]; + } + + var i, + targetTouches, + changedTouches = toArray(ev.changedTouches), + changedTargetTouches = [], + target = this.target; + + // get target touches from touches + targetTouches = allTouches.filter(function(touch) { + return hasParent(touch.target, target); + }); + + // collect touches + if (type === INPUT_START) { + i = 0; + while (i < targetTouches.length) { + targetIds[targetTouches[i].identifier] = true; + i++; + } + } + + // filter changed touches to only contain touches that exist in the collected target ids + i = 0; + while (i < changedTouches.length) { + if (targetIds[changedTouches[i].identifier]) { + changedTargetTouches.push(changedTouches[i]); + } + + // cleanup removed touches + if (type & (INPUT_END | INPUT_CANCEL)) { + delete targetIds[changedTouches[i].identifier]; + } + i++; + } + + if (!changedTargetTouches.length) { + return; + } + + return [ + // merge targetTouches with changedTargetTouches so it contains ALL touches, including 'end' and 'cancel' + uniqueArray(targetTouches.concat(changedTargetTouches), 'identifier', true), + changedTargetTouches + ]; +} + +/** + * Combined touch and mouse input + * + * Touch has a higher priority then mouse, and while touching no mouse events are allowed. + * This because touch devices also emit mouse events while doing a touch. + * + * @constructor + * @extends Input + */ + +var DEDUP_TIMEOUT = 2500; +var DEDUP_DISTANCE = 25; + +function TouchMouseInput() { + Input.apply(this, arguments); + + var handler = bindFn(this.handler, this); + this.touch = new TouchInput(this.manager, handler); + this.mouse = new MouseInput(this.manager, handler); + + this.primaryTouch = null; + this.lastTouches = []; +} + +inherit(TouchMouseInput, Input, { + /** + * handle mouse and touch events + * @param {Hammer} manager + * @param {String} inputEvent + * @param {Object} inputData + */ + handler: function TMEhandler(manager, inputEvent, inputData) { + var isTouch = (inputData.pointerType == INPUT_TYPE_TOUCH), + isMouse = (inputData.pointerType == INPUT_TYPE_MOUSE); + + if (isMouse && inputData.sourceCapabilities && inputData.sourceCapabilities.firesTouchEvents) { + return; + } + + // when we're in a touch event, record touches to de-dupe synthetic mouse event + if (isTouch) { + recordTouches.call(this, inputEvent, inputData); + } else if (isMouse && isSyntheticEvent.call(this, inputData)) { + return; + } + + this.callback(manager, inputEvent, inputData); + }, + + /** + * remove the event listeners + */ + destroy: function destroy() { + this.touch.destroy(); + this.mouse.destroy(); + } +}); + +function recordTouches(eventType, eventData) { + if (eventType & INPUT_START) { + this.primaryTouch = eventData.changedPointers[0].identifier; + setLastTouch.call(this, eventData); + } else if (eventType & (INPUT_END | INPUT_CANCEL)) { + setLastTouch.call(this, eventData); + } +} + +function setLastTouch(eventData) { + var touch = eventData.changedPointers[0]; + + if (touch.identifier === this.primaryTouch) { + var lastTouch = {x: touch.clientX, y: touch.clientY}; + this.lastTouches.push(lastTouch); + var lts = this.lastTouches; + var removeLastTouch = function() { + var i = lts.indexOf(lastTouch); + if (i > -1) { + lts.splice(i, 1); + } + }; + setTimeout(removeLastTouch, DEDUP_TIMEOUT); + } +} + +function isSyntheticEvent(eventData) { + var x = eventData.srcEvent.clientX, y = eventData.srcEvent.clientY; + for (var i = 0; i < this.lastTouches.length; i++) { + var t = this.lastTouches[i]; + var dx = Math.abs(x - t.x), dy = Math.abs(y - t.y); + if (dx <= DEDUP_DISTANCE && dy <= DEDUP_DISTANCE) { + return true; + } + } + return false; +} + +var PREFIXED_TOUCH_ACTION = prefixed(TEST_ELEMENT.style, 'touchAction'); +var NATIVE_TOUCH_ACTION = PREFIXED_TOUCH_ACTION !== undefined; + +// magical touchAction value +var TOUCH_ACTION_COMPUTE = 'compute'; +var TOUCH_ACTION_AUTO = 'auto'; +var TOUCH_ACTION_MANIPULATION = 'manipulation'; // not implemented +var TOUCH_ACTION_NONE = 'none'; +var TOUCH_ACTION_PAN_X = 'pan-x'; +var TOUCH_ACTION_PAN_Y = 'pan-y'; +var TOUCH_ACTION_MAP = getTouchActionProps(); + +/** + * Touch Action + * sets the touchAction property or uses the js alternative + * @param {Manager} manager + * @param {String} value + * @constructor + */ +function TouchAction(manager, value) { + this.manager = manager; + this.set(value); +} + +TouchAction.prototype = { + /** + * set the touchAction value on the element or enable the polyfill + * @param {String} value + */ + set: function(value) { + // find out the touch-action by the event handlers + if (value == TOUCH_ACTION_COMPUTE) { + value = this.compute(); + } + + if (NATIVE_TOUCH_ACTION && this.manager.element.style && TOUCH_ACTION_MAP[value]) { + this.manager.element.style[PREFIXED_TOUCH_ACTION] = value; + } + this.actions = value.toLowerCase().trim(); + }, + + /** + * just re-set the touchAction value + */ + update: function() { + this.set(this.manager.options.touchAction); + }, + + /** + * compute the value for the touchAction property based on the recognizer's settings + * @returns {String} value + */ + compute: function() { + var actions = []; + each(this.manager.recognizers, function(recognizer) { + if (boolOrFn(recognizer.options.enable, [recognizer])) { + actions = actions.concat(recognizer.getTouchAction()); + } + }); + return cleanTouchActions(actions.join(' ')); + }, + + /** + * this method is called on each input cycle and provides the preventing of the browser behavior + * @param {Object} input + */ + preventDefaults: function(input) { + var srcEvent = input.srcEvent; + var direction = input.offsetDirection; + + // if the touch action did prevented once this session + if (this.manager.session.prevented) { + srcEvent.preventDefault(); + return; + } + + var actions = this.actions; + var hasNone = inStr(actions, TOUCH_ACTION_NONE) && !TOUCH_ACTION_MAP[TOUCH_ACTION_NONE]; + var hasPanY = inStr(actions, TOUCH_ACTION_PAN_Y) && !TOUCH_ACTION_MAP[TOUCH_ACTION_PAN_Y]; + var hasPanX = inStr(actions, TOUCH_ACTION_PAN_X) && !TOUCH_ACTION_MAP[TOUCH_ACTION_PAN_X]; + + if (hasNone) { + //do not prevent defaults if this is a tap gesture + + var isTapPointer = input.pointers.length === 1; + var isTapMovement = input.distance < 2; + var isTapTouchTime = input.deltaTime < 250; + + if (isTapPointer && isTapMovement && isTapTouchTime) { + return; + } + } + + if (hasPanX && hasPanY) { + // `pan-x pan-y` means browser handles all scrolling/panning, do not prevent + return; + } + + if (hasNone || + (hasPanY && direction & DIRECTION_HORIZONTAL) || + (hasPanX && direction & DIRECTION_VERTICAL)) { + return this.preventSrc(srcEvent); + } + }, + + /** + * call preventDefault to prevent the browser's default behavior (scrolling in most cases) + * @param {Object} srcEvent + */ + preventSrc: function(srcEvent) { + this.manager.session.prevented = true; + srcEvent.preventDefault(); + } +}; + +/** + * when the touchActions are collected they are not a valid value, so we need to clean things up. * + * @param {String} actions + * @returns {*} + */ +function cleanTouchActions(actions) { + // none + if (inStr(actions, TOUCH_ACTION_NONE)) { + return TOUCH_ACTION_NONE; + } + + var hasPanX = inStr(actions, TOUCH_ACTION_PAN_X); + var hasPanY = inStr(actions, TOUCH_ACTION_PAN_Y); + + // if both pan-x and pan-y are set (different recognizers + // for different directions, e.g. horizontal pan but vertical swipe?) + // we need none (as otherwise with pan-x pan-y combined none of these + // recognizers will work, since the browser would handle all panning + if (hasPanX && hasPanY) { + return TOUCH_ACTION_NONE; + } + + // pan-x OR pan-y + if (hasPanX || hasPanY) { + return hasPanX ? TOUCH_ACTION_PAN_X : TOUCH_ACTION_PAN_Y; + } + + // manipulation + if (inStr(actions, TOUCH_ACTION_MANIPULATION)) { + return TOUCH_ACTION_MANIPULATION; + } + + return TOUCH_ACTION_AUTO; +} + +function getTouchActionProps() { + if (!NATIVE_TOUCH_ACTION) { + return false; + } + var touchMap = {}; + var cssSupports = window.CSS && window.CSS.supports; + ['auto', 'manipulation', 'pan-y', 'pan-x', 'pan-x pan-y', 'none'].forEach(function(val) { + + // If css.supports is not supported but there is native touch-action assume it supports + // all values. This is the case for IE 10 and 11. + touchMap[val] = cssSupports ? window.CSS.supports('touch-action', val) : true; + }); + return touchMap; +} + +/** + * Recognizer flow explained; * + * All recognizers have the initial state of POSSIBLE when a input session starts. + * The definition of a input session is from the first input until the last input, with all it's movement in it. * + * Example session for mouse-input: mousedown -> mousemove -> mouseup + * + * On each recognizing cycle (see Manager.recognize) the .recognize() method is executed + * which determines with state it should be. + * + * If the recognizer has the state FAILED, CANCELLED or RECOGNIZED (equals ENDED), it is reset to + * POSSIBLE to give it another change on the next cycle. + * + * Possible + * | + * +-----+---------------+ + * | | + * +-----+-----+ | + * | | | + * Failed Cancelled | + * +-------+------+ + * | | + * Recognized Began + * | + * Changed + * | + * Ended/Recognized + */ +var STATE_POSSIBLE = 1; +var STATE_BEGAN = 2; +var STATE_CHANGED = 4; +var STATE_ENDED = 8; +var STATE_RECOGNIZED = STATE_ENDED; +var STATE_CANCELLED = 16; +var STATE_FAILED = 32; + +/** + * Recognizer + * Every recognizer needs to extend from this class. + * @constructor + * @param {Object} options + */ +function Recognizer(options) { + this.options = assign({}, this.defaults, options || {}); + + this.id = uniqueId(); + + this.manager = null; + + // default is enable true + this.options.enable = ifUndefined(this.options.enable, true); + + this.state = STATE_POSSIBLE; + + this.simultaneous = {}; + this.requireFail = []; +} + +Recognizer.prototype = { + /** + * @virtual + * @type {Object} + */ + defaults: {}, + + /** + * set options + * @param {Object} options + * @return {Recognizer} + */ + set: function(options) { + assign(this.options, options); + + // also update the touchAction, in case something changed about the directions/enabled state + this.manager && this.manager.touchAction.update(); + return this; + }, + + /** + * recognize simultaneous with an other recognizer. + * @param {Recognizer} otherRecognizer + * @returns {Recognizer} this + */ + recognizeWith: function(otherRecognizer) { + if (invokeArrayArg(otherRecognizer, 'recognizeWith', this)) { + return this; + } + + var simultaneous = this.simultaneous; + otherRecognizer = getRecognizerByNameIfManager(otherRecognizer, this); + if (!simultaneous[otherRecognizer.id]) { + simultaneous[otherRecognizer.id] = otherRecognizer; + otherRecognizer.recognizeWith(this); + } + return this; + }, + + /** + * drop the simultaneous link. it doesnt remove the link on the other recognizer. + * @param {Recognizer} otherRecognizer + * @returns {Recognizer} this + */ + dropRecognizeWith: function(otherRecognizer) { + if (invokeArrayArg(otherRecognizer, 'dropRecognizeWith', this)) { + return this; + } + + otherRecognizer = getRecognizerByNameIfManager(otherRecognizer, this); + delete this.simultaneous[otherRecognizer.id]; + return this; + }, + + /** + * recognizer can only run when an other is failing + * @param {Recognizer} otherRecognizer + * @returns {Recognizer} this + */ + requireFailure: function(otherRecognizer) { + if (invokeArrayArg(otherRecognizer, 'requireFailure', this)) { + return this; + } + + var requireFail = this.requireFail; + otherRecognizer = getRecognizerByNameIfManager(otherRecognizer, this); + if (inArray(requireFail, otherRecognizer) === -1) { + requireFail.push(otherRecognizer); + otherRecognizer.requireFailure(this); + } + return this; + }, + + /** + * drop the requireFailure link. it does not remove the link on the other recognizer. + * @param {Recognizer} otherRecognizer + * @returns {Recognizer} this + */ + dropRequireFailure: function(otherRecognizer) { + if (invokeArrayArg(otherRecognizer, 'dropRequireFailure', this)) { + return this; + } + + otherRecognizer = getRecognizerByNameIfManager(otherRecognizer, this); + var index = inArray(this.requireFail, otherRecognizer); + if (index > -1) { + this.requireFail.splice(index, 1); + } + return this; + }, + + /** + * has require failures boolean + * @returns {boolean} + */ + hasRequireFailures: function() { + return this.requireFail.length > 0; + }, + + /** + * if the recognizer can recognize simultaneous with an other recognizer + * @param {Recognizer} otherRecognizer + * @returns {Boolean} + */ + canRecognizeWith: function(otherRecognizer) { + return !!this.simultaneous[otherRecognizer.id]; + }, + + /** + * You should use `tryEmit` instead of `emit` directly to check + * that all the needed recognizers has failed before emitting. + * @param {Object} input + */ + emit: function(input) { + var self = this; + var state = this.state; + + function emit(event) { + self.manager.emit(event, input); + } + + // 'panstart' and 'panmove' + if (state < STATE_ENDED) { + emit(self.options.event + stateStr(state)); + } + + emit(self.options.event); // simple 'eventName' events + + if (input.additionalEvent) { // additional event(panleft, panright, pinchin, pinchout...) + emit(input.additionalEvent); + } + + // panend and pancancel + if (state >= STATE_ENDED) { + emit(self.options.event + stateStr(state)); + } + }, + + /** + * Check that all the require failure recognizers has failed, + * if true, it emits a gesture event, + * otherwise, setup the state to FAILED. + * @param {Object} input + */ + tryEmit: function(input) { + if (this.canEmit()) { + return this.emit(input); + } + // it's failing anyway + this.state = STATE_FAILED; + }, + + /** + * can we emit? + * @returns {boolean} + */ + canEmit: function() { + var i = 0; + while (i < this.requireFail.length) { + if (!(this.requireFail[i].state & (STATE_FAILED | STATE_POSSIBLE))) { + return false; + } + i++; + } + return true; + }, + + /** + * update the recognizer + * @param {Object} inputData + */ + recognize: function(inputData) { + // make a new copy of the inputData + // so we can change the inputData without messing up the other recognizers + var inputDataClone = assign({}, inputData); + + // is is enabled and allow recognizing? + if (!boolOrFn(this.options.enable, [this, inputDataClone])) { + this.reset(); + this.state = STATE_FAILED; + return; + } + + // reset when we've reached the end + if (this.state & (STATE_RECOGNIZED | STATE_CANCELLED | STATE_FAILED)) { + this.state = STATE_POSSIBLE; + } + + this.state = this.process(inputDataClone); + + // the recognizer has recognized a gesture + // so trigger an event + if (this.state & (STATE_BEGAN | STATE_CHANGED | STATE_ENDED | STATE_CANCELLED)) { + this.tryEmit(inputDataClone); + } + }, + + /** + * return the state of the recognizer + * the actual recognizing happens in this method + * @virtual + * @param {Object} inputData + * @returns {Const} STATE + */ + process: function(inputData) { }, // jshint ignore:line + + /** + * return the preferred touch-action + * @virtual + * @returns {Array} + */ + getTouchAction: function() { }, + + /** + * called when the gesture isn't allowed to recognize + * like when another is being recognized or it is disabled + * @virtual + */ + reset: function() { } +}; + +/** + * get a usable string, used as event postfix + * @param {Const} state + * @returns {String} state + */ +function stateStr(state) { + if (state & STATE_CANCELLED) { + return 'cancel'; + } else if (state & STATE_ENDED) { + return 'end'; + } else if (state & STATE_CHANGED) { + return 'move'; + } else if (state & STATE_BEGAN) { + return 'start'; + } + return ''; +} + +/** + * direction cons to string + * @param {Const} direction + * @returns {String} + */ +function directionStr(direction) { + if (direction == DIRECTION_DOWN) { + return 'down'; + } else if (direction == DIRECTION_UP) { + return 'up'; + } else if (direction == DIRECTION_LEFT) { + return 'left'; + } else if (direction == DIRECTION_RIGHT) { + return 'right'; + } + return ''; +} + +/** + * get a recognizer by name if it is bound to a manager + * @param {Recognizer|String} otherRecognizer + * @param {Recognizer} recognizer + * @returns {Recognizer} + */ +function getRecognizerByNameIfManager(otherRecognizer, recognizer) { + var manager = recognizer.manager; + if (manager) { + return manager.get(otherRecognizer); + } + return otherRecognizer; +} + +/** + * This recognizer is just used as a base for the simple attribute recognizers. + * @constructor + * @extends Recognizer + */ +function AttrRecognizer() { + Recognizer.apply(this, arguments); +} + +inherit(AttrRecognizer, Recognizer, { + /** + * @namespace + * @memberof AttrRecognizer + */ + defaults: { + /** + * @type {Number} + * @default 1 + */ + pointers: 1 + }, + + /** + * Used to check if it the recognizer receives valid input, like input.distance > 10. + * @memberof AttrRecognizer + * @param {Object} input + * @returns {Boolean} recognized + */ + attrTest: function(input) { + var optionPointers = this.options.pointers; + return optionPointers === 0 || input.pointers.length === optionPointers; + }, + + /** + * Process the input and return the state for the recognizer + * @memberof AttrRecognizer + * @param {Object} input + * @returns {*} State + */ + process: function(input) { + var state = this.state; + var eventType = input.eventType; + + var isRecognized = state & (STATE_BEGAN | STATE_CHANGED); + var isValid = this.attrTest(input); + + // on cancel input and we've recognized before, return STATE_CANCELLED + if (isRecognized && (eventType & INPUT_CANCEL || !isValid)) { + return state | STATE_CANCELLED; + } else if (isRecognized || isValid) { + if (eventType & INPUT_END) { + return state | STATE_ENDED; + } else if (!(state & STATE_BEGAN)) { + return STATE_BEGAN; + } + return state | STATE_CHANGED; + } + return STATE_FAILED; + } +}); + +/** + * Pan + * Recognized when the pointer is down and moved in the allowed direction. + * @constructor + * @extends AttrRecognizer + */ +function PanRecognizer() { + AttrRecognizer.apply(this, arguments); + + this.pX = null; + this.pY = null; +} + +inherit(PanRecognizer, AttrRecognizer, { + /** + * @namespace + * @memberof PanRecognizer + */ + defaults: { + event: 'pan', + threshold: 10, + pointers: 1, + direction: DIRECTION_ALL + }, + + getTouchAction: function() { + var direction = this.options.direction; + var actions = []; + if (direction & DIRECTION_HORIZONTAL) { + actions.push(TOUCH_ACTION_PAN_Y); + } + if (direction & DIRECTION_VERTICAL) { + actions.push(TOUCH_ACTION_PAN_X); + } + return actions; + }, + + directionTest: function(input) { + var options = this.options; + var hasMoved = true; + var distance = input.distance; + var direction = input.direction; + var x = input.deltaX; + var y = input.deltaY; + + // lock to axis? + if (!(direction & options.direction)) { + if (options.direction & DIRECTION_HORIZONTAL) { + direction = (x === 0) ? DIRECTION_NONE : (x < 0) ? DIRECTION_LEFT : DIRECTION_RIGHT; + hasMoved = x != this.pX; + distance = Math.abs(input.deltaX); + } else { + direction = (y === 0) ? DIRECTION_NONE : (y < 0) ? DIRECTION_UP : DIRECTION_DOWN; + hasMoved = y != this.pY; + distance = Math.abs(input.deltaY); + } + } + input.direction = direction; + return hasMoved && distance > options.threshold && direction & options.direction; + }, + + attrTest: function(input) { + return AttrRecognizer.prototype.attrTest.call(this, input) && + (this.state & STATE_BEGAN || (!(this.state & STATE_BEGAN) && this.directionTest(input))); + }, + + emit: function(input) { + + this.pX = input.deltaX; + this.pY = input.deltaY; + + var direction = directionStr(input.direction); + + if (direction) { + input.additionalEvent = this.options.event + direction; + } + this._super.emit.call(this, input); + } +}); + +/** + * Pinch + * Recognized when two or more pointers are moving toward (zoom-in) or away from each other (zoom-out). + * @constructor + * @extends AttrRecognizer + */ +function PinchRecognizer() { + AttrRecognizer.apply(this, arguments); +} + +inherit(PinchRecognizer, AttrRecognizer, { + /** + * @namespace + * @memberof PinchRecognizer + */ + defaults: { + event: 'pinch', + threshold: 0, + pointers: 2 + }, + + getTouchAction: function() { + return [TOUCH_ACTION_NONE]; + }, + + attrTest: function(input) { + return this._super.attrTest.call(this, input) && + (Math.abs(input.scale - 1) > this.options.threshold || this.state & STATE_BEGAN); + }, + + emit: function(input) { + if (input.scale !== 1) { + var inOut = input.scale < 1 ? 'in' : 'out'; + input.additionalEvent = this.options.event + inOut; + } + this._super.emit.call(this, input); + } +}); + +/** + * Press + * Recognized when the pointer is down for x ms without any movement. + * @constructor + * @extends Recognizer + */ +function PressRecognizer() { + Recognizer.apply(this, arguments); + + this._timer = null; + this._input = null; +} + +inherit(PressRecognizer, Recognizer, { + /** + * @namespace + * @memberof PressRecognizer + */ + defaults: { + event: 'press', + pointers: 1, + time: 251, // minimal time of the pointer to be pressed + threshold: 9 // a minimal movement is ok, but keep it low + }, + + getTouchAction: function() { + return [TOUCH_ACTION_AUTO]; + }, + + process: function(input) { + var options = this.options; + var validPointers = input.pointers.length === options.pointers; + var validMovement = input.distance < options.threshold; + var validTime = input.deltaTime > options.time; + + this._input = input; + + // we only allow little movement + // and we've reached an end event, so a tap is possible + if (!validMovement || !validPointers || (input.eventType & (INPUT_END | INPUT_CANCEL) && !validTime)) { + this.reset(); + } else if (input.eventType & INPUT_START) { + this.reset(); + this._timer = setTimeoutContext(function() { + this.state = STATE_RECOGNIZED; + this.tryEmit(); + }, options.time, this); + } else if (input.eventType & INPUT_END) { + return STATE_RECOGNIZED; + } + return STATE_FAILED; + }, + + reset: function() { + clearTimeout(this._timer); + }, + + emit: function(input) { + if (this.state !== STATE_RECOGNIZED) { + return; + } + + if (input && (input.eventType & INPUT_END)) { + this.manager.emit(this.options.event + 'up', input); + } else { + this._input.timeStamp = now(); + this.manager.emit(this.options.event, this._input); + } + } +}); + +/** + * Rotate + * Recognized when two or more pointer are moving in a circular motion. + * @constructor + * @extends AttrRecognizer + */ +function RotateRecognizer() { + AttrRecognizer.apply(this, arguments); +} + +inherit(RotateRecognizer, AttrRecognizer, { + /** + * @namespace + * @memberof RotateRecognizer + */ + defaults: { + event: 'rotate', + threshold: 0, + pointers: 2 + }, + + getTouchAction: function() { + return [TOUCH_ACTION_NONE]; + }, + + attrTest: function(input) { + return this._super.attrTest.call(this, input) && + (Math.abs(input.rotation) > this.options.threshold || this.state & STATE_BEGAN); + } +}); + +/** + * Swipe + * Recognized when the pointer is moving fast (velocity), with enough distance in the allowed direction. + * @constructor + * @extends AttrRecognizer + */ +function SwipeRecognizer() { + AttrRecognizer.apply(this, arguments); +} + +inherit(SwipeRecognizer, AttrRecognizer, { + /** + * @namespace + * @memberof SwipeRecognizer + */ + defaults: { + event: 'swipe', + threshold: 10, + velocity: 0.3, + direction: DIRECTION_HORIZONTAL | DIRECTION_VERTICAL, + pointers: 1 + }, + + getTouchAction: function() { + return PanRecognizer.prototype.getTouchAction.call(this); + }, + + attrTest: function(input) { + var direction = this.options.direction; + var velocity; + + if (direction & (DIRECTION_HORIZONTAL | DIRECTION_VERTICAL)) { + velocity = input.overallVelocity; + } else if (direction & DIRECTION_HORIZONTAL) { + velocity = input.overallVelocityX; + } else if (direction & DIRECTION_VERTICAL) { + velocity = input.overallVelocityY; + } + + return this._super.attrTest.call(this, input) && + direction & input.offsetDirection && + input.distance > this.options.threshold && + input.maxPointers == this.options.pointers && + abs(velocity) > this.options.velocity && input.eventType & INPUT_END; + }, + + emit: function(input) { + var direction = directionStr(input.offsetDirection); + if (direction) { + this.manager.emit(this.options.event + direction, input); + } + + this.manager.emit(this.options.event, input); + } +}); + +/** + * A tap is ecognized when the pointer is doing a small tap/click. Multiple taps are recognized if they occur + * between the given interval and position. The delay option can be used to recognize multi-taps without firing + * a single tap. + * + * The eventData from the emitted event contains the property `tapCount`, which contains the amount of + * multi-taps being recognized. + * @constructor + * @extends Recognizer + */ +function TapRecognizer() { + Recognizer.apply(this, arguments); + + // previous time and center, + // used for tap counting + this.pTime = false; + this.pCenter = false; + + this._timer = null; + this._input = null; + this.count = 0; +} + +inherit(TapRecognizer, Recognizer, { + /** + * @namespace + * @memberof PinchRecognizer + */ + defaults: { + event: 'tap', + pointers: 1, + taps: 1, + interval: 300, // max time between the multi-tap taps + time: 250, // max time of the pointer to be down (like finger on the screen) + threshold: 9, // a minimal movement is ok, but keep it low + posThreshold: 10 // a multi-tap can be a bit off the initial position + }, + + getTouchAction: function() { + return [TOUCH_ACTION_MANIPULATION]; + }, + + process: function(input) { + var options = this.options; + + var validPointers = input.pointers.length === options.pointers; + var validMovement = input.distance < options.threshold; + var validTouchTime = input.deltaTime < options.time; + + this.reset(); + + if ((input.eventType & INPUT_START) && (this.count === 0)) { + return this.failTimeout(); + } + + // we only allow little movement + // and we've reached an end event, so a tap is possible + if (validMovement && validTouchTime && validPointers) { + if (input.eventType != INPUT_END) { + return this.failTimeout(); + } + + var validInterval = this.pTime ? (input.timeStamp - this.pTime < options.interval) : true; + var validMultiTap = !this.pCenter || getDistance(this.pCenter, input.center) < options.posThreshold; + + this.pTime = input.timeStamp; + this.pCenter = input.center; + + if (!validMultiTap || !validInterval) { + this.count = 1; + } else { + this.count += 1; + } + + this._input = input; + + // if tap count matches we have recognized it, + // else it has began recognizing... + var tapCount = this.count % options.taps; + if (tapCount === 0) { + // no failing requirements, immediately trigger the tap event + // or wait as long as the multitap interval to trigger + if (!this.hasRequireFailures()) { + return STATE_RECOGNIZED; + } else { + this._timer = setTimeoutContext(function() { + this.state = STATE_RECOGNIZED; + this.tryEmit(); + }, options.interval, this); + return STATE_BEGAN; + } + } + } + return STATE_FAILED; + }, + + failTimeout: function() { + this._timer = setTimeoutContext(function() { + this.state = STATE_FAILED; + }, this.options.interval, this); + return STATE_FAILED; + }, + + reset: function() { + clearTimeout(this._timer); + }, + + emit: function() { + if (this.state == STATE_RECOGNIZED) { + this._input.tapCount = this.count; + this.manager.emit(this.options.event, this._input); + } + } +}); + +/** + * Simple way to create a manager with a default set of recognizers. + * @param {HTMLElement} element + * @param {Object} [options] + * @constructor + */ +function Hammer(element, options) { + options = options || {}; + options.recognizers = ifUndefined(options.recognizers, Hammer.defaults.preset); + return new Manager(element, options); +} + +/** + * @const {string} + */ +Hammer.VERSION = '2.0.8'; + +/** + * default settings + * @namespace + */ +Hammer.defaults = { + /** + * set if DOM events are being triggered. + * But this is slower and unused by simple implementations, so disabled by default. + * @type {Boolean} + * @default false + */ + domEvents: false, + + /** + * The value for the touchAction property/fallback. + * When set to `compute` it will magically set the correct value based on the added recognizers. + * @type {String} + * @default compute + */ + touchAction: TOUCH_ACTION_COMPUTE, + + /** + * @type {Boolean} + * @default true + */ + enable: true, + + /** + * EXPERIMENTAL FEATURE -- can be removed/changed + * Change the parent input target element. + * If Null, then it is being set the to main element. + * @type {Null|EventTarget} + * @default null + */ + inputTarget: null, + + /** + * force an input class + * @type {Null|Function} + * @default null + */ + inputClass: null, + + /** + * Default recognizer setup when calling `Hammer()` + * When creating a new Manager these will be skipped. + * @type {Array} + */ + preset: [ + // RecognizerClass, options, [recognizeWith, ...], [requireFailure, ...] + [RotateRecognizer, {enable: false}], + [PinchRecognizer, {enable: false}, ['rotate']], + [SwipeRecognizer, {direction: DIRECTION_HORIZONTAL}], + [PanRecognizer, {direction: DIRECTION_HORIZONTAL}, ['swipe']], + [TapRecognizer], + [TapRecognizer, {event: 'doubletap', taps: 2}, ['tap']], + [PressRecognizer] + ], + + /** + * Some CSS properties can be used to improve the working of Hammer. + * Add them to this method and they will be set when creating a new Manager. + * @namespace + */ + cssProps: { + /** + * Disables text selection to improve the dragging gesture. Mainly for desktop browsers. + * @type {String} + * @default 'none' + */ + userSelect: 'none', + + /** + * Disable the Windows Phone grippers when pressing an element. + * @type {String} + * @default 'none' + */ + touchSelect: 'none', + + /** + * Disables the default callout shown when you touch and hold a touch target. + * On iOS, when you touch and hold a touch target such as a link, Safari displays + * a callout containing information about the link. This property allows you to disable that callout. + * @type {String} + * @default 'none' + */ + touchCallout: 'none', + + /** + * Specifies whether zooming is enabled. Used by IE10> + * @type {String} + * @default 'none' + */ + contentZooming: 'none', + + /** + * Specifies that an entire element should be draggable instead of its contents. Mainly for desktop browsers. + * @type {String} + * @default 'none' + */ + userDrag: 'none', + + /** + * Overrides the highlight color shown when the user taps a link or a JavaScript + * clickable element in iOS. This property obeys the alpha value, if specified. + * @type {String} + * @default 'rgba(0,0,0,0)' + */ + tapHighlightColor: 'rgba(0,0,0,0)' + } +}; + +var STOP = 1; +var FORCED_STOP = 2; + +/** + * Manager + * @param {HTMLElement} element + * @param {Object} [options] + * @constructor + */ +function Manager(element, options) { + this.options = assign({}, Hammer.defaults, options || {}); + + this.options.inputTarget = this.options.inputTarget || element; + + this.handlers = {}; + this.session = {}; + this.recognizers = []; + this.oldCssProps = {}; + + this.element = element; + this.input = createInputInstance(this); + this.touchAction = new TouchAction(this, this.options.touchAction); + + toggleCssProps(this, true); + + each(this.options.recognizers, function(item) { + var recognizer = this.add(new (item[0])(item[1])); + item[2] && recognizer.recognizeWith(item[2]); + item[3] && recognizer.requireFailure(item[3]); + }, this); +} + +Manager.prototype = { + /** + * set options + * @param {Object} options + * @returns {Manager} + */ + set: function(options) { + assign(this.options, options); + + // Options that need a little more setup + if (options.touchAction) { + this.touchAction.update(); + } + if (options.inputTarget) { + // Clean up existing event listeners and reinitialize + this.input.destroy(); + this.input.target = options.inputTarget; + this.input.init(); + } + return this; + }, + + /** + * stop recognizing for this session. + * This session will be discarded, when a new [input]start event is fired. + * When forced, the recognizer cycle is stopped immediately. + * @param {Boolean} [force] + */ + stop: function(force) { + this.session.stopped = force ? FORCED_STOP : STOP; + }, + + /** + * run the recognizers! + * called by the inputHandler function on every movement of the pointers (touches) + * it walks through all the recognizers and tries to detect the gesture that is being made + * @param {Object} inputData + */ + recognize: function(inputData) { + var session = this.session; + if (session.stopped) { + return; + } + + // run the touch-action polyfill + this.touchAction.preventDefaults(inputData); + + var recognizer; + var recognizers = this.recognizers; + + // this holds the recognizer that is being recognized. + // so the recognizer's state needs to be BEGAN, CHANGED, ENDED or RECOGNIZED + // if no recognizer is detecting a thing, it is set to `null` + var curRecognizer = session.curRecognizer; + + // reset when the last recognizer is recognized + // or when we're in a new session + if (!curRecognizer || (curRecognizer && curRecognizer.state & STATE_RECOGNIZED)) { + curRecognizer = session.curRecognizer = null; + } + + var i = 0; + while (i < recognizers.length) { + recognizer = recognizers[i]; + + // find out if we are allowed try to recognize the input for this one. + // 1. allow if the session is NOT forced stopped (see the .stop() method) + // 2. allow if we still haven't recognized a gesture in this session, or the this recognizer is the one + // that is being recognized. + // 3. allow if the recognizer is allowed to run simultaneous with the current recognized recognizer. + // this can be setup with the `recognizeWith()` method on the recognizer. + if (session.stopped !== FORCED_STOP && ( // 1 + !curRecognizer || recognizer == curRecognizer || // 2 + recognizer.canRecognizeWith(curRecognizer))) { // 3 + recognizer.recognize(inputData); + } else { + recognizer.reset(); + } + + // if the recognizer has been recognizing the input as a valid gesture, we want to store this one as the + // current active recognizer. but only if we don't already have an active recognizer + if (!curRecognizer && recognizer.state & (STATE_BEGAN | STATE_CHANGED | STATE_ENDED)) { + curRecognizer = session.curRecognizer = recognizer; + } + i++; + } + }, + + /** + * get a recognizer by its event name. + * @param {Recognizer|String} recognizer + * @returns {Recognizer|Null} + */ + get: function(recognizer) { + if (recognizer instanceof Recognizer) { + return recognizer; + } + + var recognizers = this.recognizers; + for (var i = 0; i < recognizers.length; i++) { + if (recognizers[i].options.event == recognizer) { + return recognizers[i]; + } + } + return null; + }, + + /** + * add a recognizer to the manager + * existing recognizers with the same event name will be removed + * @param {Recognizer} recognizer + * @returns {Recognizer|Manager} + */ + add: function(recognizer) { + if (invokeArrayArg(recognizer, 'add', this)) { + return this; + } + + // remove existing + var existing = this.get(recognizer.options.event); + if (existing) { + this.remove(existing); + } + + this.recognizers.push(recognizer); + recognizer.manager = this; + + this.touchAction.update(); + return recognizer; + }, + + /** + * remove a recognizer by name or instance + * @param {Recognizer|String} recognizer + * @returns {Manager} + */ + remove: function(recognizer) { + if (invokeArrayArg(recognizer, 'remove', this)) { + return this; + } + + recognizer = this.get(recognizer); + + // let's make sure this recognizer exists + if (recognizer) { + var recognizers = this.recognizers; + var index = inArray(recognizers, recognizer); + + if (index !== -1) { + recognizers.splice(index, 1); + this.touchAction.update(); + } + } + + return this; + }, + + /** + * bind event + * @param {String} events + * @param {Function} handler + * @returns {EventEmitter} this + */ + on: function(events, handler) { + if (events === undefined) { + return; + } + if (handler === undefined) { + return; + } + + var handlers = this.handlers; + each(splitStr(events), function(event) { + handlers[event] = handlers[event] || []; + handlers[event].push(handler); + }); + return this; + }, + + /** + * unbind event, leave emit blank to remove all handlers + * @param {String} events + * @param {Function} [handler] + * @returns {EventEmitter} this + */ + off: function(events, handler) { + if (events === undefined) { + return; + } + + var handlers = this.handlers; + each(splitStr(events), function(event) { + if (!handler) { + delete handlers[event]; + } else { + handlers[event] && handlers[event].splice(inArray(handlers[event], handler), 1); + } + }); + return this; + }, + + /** + * emit event to the listeners + * @param {String} event + * @param {Object} data + */ + emit: function(event, data) { + // we also want to trigger dom events + if (this.options.domEvents) { + triggerDomEvent(event, data); + } + + // no handlers, so skip it all + var handlers = this.handlers[event] && this.handlers[event].slice(); + if (!handlers || !handlers.length) { + return; + } + + data.type = event; + data.preventDefault = function() { + data.srcEvent.preventDefault(); + }; + + var i = 0; + while (i < handlers.length) { + handlers[i](data); + i++; + } + }, + + /** + * destroy the manager and unbinds all events + * it doesn't unbind dom events, that is the user own responsibility + */ + destroy: function() { + this.element && toggleCssProps(this, false); + + this.handlers = {}; + this.session = {}; + this.input.destroy(); + this.element = null; + } +}; + +/** + * add/remove the css properties as defined in manager.options.cssProps + * @param {Manager} manager + * @param {Boolean} add + */ +function toggleCssProps(manager, add) { + var element = manager.element; + if (!element.style) { + return; + } + var prop; + each(manager.options.cssProps, function(value, name) { + prop = prefixed(element.style, name); + if (add) { + manager.oldCssProps[prop] = element.style[prop]; + element.style[prop] = value; + } else { + element.style[prop] = manager.oldCssProps[prop] || ''; + } + }); + if (!add) { + manager.oldCssProps = {}; + } +} + +/** + * trigger dom event + * @param {String} event + * @param {Object} data + */ +function triggerDomEvent(event, data) { + var gestureEvent = document.createEvent('Event'); + gestureEvent.initEvent(event, true, true); + gestureEvent.gesture = data; + data.target.dispatchEvent(gestureEvent); +} + +assign(Hammer, { + INPUT_START: INPUT_START, + INPUT_MOVE: INPUT_MOVE, + INPUT_END: INPUT_END, + INPUT_CANCEL: INPUT_CANCEL, + + STATE_POSSIBLE: STATE_POSSIBLE, + STATE_BEGAN: STATE_BEGAN, + STATE_CHANGED: STATE_CHANGED, + STATE_ENDED: STATE_ENDED, + STATE_RECOGNIZED: STATE_RECOGNIZED, + STATE_CANCELLED: STATE_CANCELLED, + STATE_FAILED: STATE_FAILED, + + DIRECTION_NONE: DIRECTION_NONE, + DIRECTION_LEFT: DIRECTION_LEFT, + DIRECTION_RIGHT: DIRECTION_RIGHT, + DIRECTION_UP: DIRECTION_UP, + DIRECTION_DOWN: DIRECTION_DOWN, + DIRECTION_HORIZONTAL: DIRECTION_HORIZONTAL, + DIRECTION_VERTICAL: DIRECTION_VERTICAL, + DIRECTION_ALL: DIRECTION_ALL, + + Manager: Manager, + Input: Input, + TouchAction: TouchAction, + + TouchInput: TouchInput, + MouseInput: MouseInput, + PointerEventInput: PointerEventInput, + TouchMouseInput: TouchMouseInput, + SingleTouchInput: SingleTouchInput, + + Recognizer: Recognizer, + AttrRecognizer: AttrRecognizer, + Tap: TapRecognizer, + Pan: PanRecognizer, + Swipe: SwipeRecognizer, + Pinch: PinchRecognizer, + Rotate: RotateRecognizer, + Press: PressRecognizer, + + on: addEventListeners, + off: removeEventListeners, + each: each, + merge: merge, + extend: extend, + assign: assign, + inherit: inherit, + bindFn: bindFn, + prefixed: prefixed +}); + +// this prevents errors when Hammer is loaded in the presence of an AMD +// style loader but by script tag, not by the loader. +var freeGlobal = (typeof window !== 'undefined' ? window : (typeof self !== 'undefined' ? self : {})); // jshint ignore:line +freeGlobal.Hammer = Hammer; + +if (typeof define === 'function' && define.amd) { + define(function() { + return Hammer; + }); +} else if (typeof module != 'undefined' && module.exports) { + module.exports = Hammer; +} else { + window[exportName] = Hammer; +} + +})(window, document, 'Hammer'); + ++ function($) { + "use strict"; + + var defaults; + + $.modal = function(params, onOpen) { + params = $.extend({}, defaults, params); + + + var buttons = params.buttons; + + var buttonsHtml = buttons.map(function(d, i) { + return '' + d.text + ''; + }).join(""); + + var tpl = '
    ' + + '
    ' + params.title + '
    ' + + ( params.text ? '
    '+params.text+'
    ' : '')+ + '
    ' + buttonsHtml + '
    ' + + '
    '; + + var dialog = $.openModal(tpl, onOpen); + + dialog.find(".weui-dialog__btn").each(function(i, e) { + var el = $(e); + el.click(function() { + //先关闭对话框,再调用回调函数 + if(params.autoClose) $.closeModal(); + + if(buttons[i].onClick) { + buttons[i].onClick.call(dialog); + } + }); + }); + + return dialog; + }; + + $.openModal = function(tpl, onOpen) { + var mask = $("
    ").appendTo(document.body); + mask.show(); + + var dialog = $(tpl).appendTo(document.body); + + if (onOpen) { + dialog.transitionEnd(function () { + onOpen.call(dialog); + }); + } + + dialog.show(); + mask.addClass("weui-mask--visible"); + dialog.addClass("weui-dialog--visible"); + + + return dialog; + } + + $.closeModal = function() { + $(".weui-mask--visible").removeClass("weui-mask--visible").transitionEnd(function() { + $(this).remove(); + }); + $(".weui-dialog--visible").removeClass("weui-dialog--visible").transitionEnd(function() { + $(this).remove(); + }); + }; + + $.alert = function(text, title, onOK) { + var config; + if (typeof text === 'object') { + config = text; + } else { + if (typeof title === 'function') { + onOK = arguments[1]; + title = undefined; + } + + config = { + text: text, + title: title, + onOK: onOK + } + } + return $.modal({ + text: config.text, + title: config.title, + buttons: [{ + text: defaults.buttonOK, + className: "primary", + onClick: config.onOK + }] + }); + } + + $.confirm = function(text, title, onOK, onCancel) { + var config; + if (typeof text === 'object') { + config = text + } else { + if (typeof title === 'function') { + onCancel = arguments[2]; + onOK = arguments[1]; + title = undefined; + } + + config = { + text: text, + title: title, + onOK: onOK, + onCancel: onCancel + } + } + return $.modal({ + text: config.text, + title: config.title, + buttons: [ + { + text: defaults.buttonCancel, + className: "default", + onClick: config.onCancel + }, + { + text: defaults.buttonOK, + className: "primary", + onClick: config.onOK + }] + }); + }; + + //如果参数过多,建议通过 config 对象进行配置,而不是传入多个参数。 + $.prompt = function(text, title, onOK, onCancel, input) { + var config; + if (typeof text === 'object') { + config = text; + } else { + if (typeof title === 'function') { + input = arguments[3]; + onCancel = arguments[2]; + onOK = arguments[1]; + title = undefined; + } + config = { + text: text, + title: title, + input: input, + onOK: onOK, + onCancel: onCancel, + empty: false //allow empty + } + } + + var modal = $.modal({ + text: '

    '+(config.text || '')+'

    ', + title: config.title, + autoClose: false, + buttons: [ + { + text: defaults.buttonCancel, + className: "default", + onClick: function () { + $.closeModal(); + config.onCancel && config.onCancel.call(modal); + } + }, + { + text: defaults.buttonOK, + className: "primary", + onClick: function() { + var input = $("#weui-prompt-input").val(); + if (!config.empty && (input === "" || input === null)) { + modal.find('.weui-prompt-input').focus()[0].select(); + return false; + } + $.closeModal(); + config.onOK && config.onOK.call(modal, input); + } + }] + }, function () { + this.find('.weui-prompt-input').focus()[0].select(); + }); + + return modal; + }; + + //如果参数过多,建议通过 config 对象进行配置,而不是传入多个参数。 + $.login = function(text, title, onOK, onCancel, username, password) { + var config; + if (typeof text === 'object') { + config = text; + } else { + if (typeof title === 'function') { + password = arguments[4]; + username = arguments[3]; + onCancel = arguments[2]; + onOK = arguments[1]; + title = undefined; + } + config = { + text: text, + title: title, + username: username, + password: password, + onOK: onOK, + onCancel: onCancel + } + } + + var modal = $.modal({ + text: '

    '+(config.text || '')+'

    ' + + '' + + '', + title: config.title, + autoClose: false, + buttons: [ + { + text: defaults.buttonCancel, + className: "default", + onClick: function () { + $.closeModal(); + config.onCancel && config.onCancel.call(modal); + } + }, { + text: defaults.buttonOK, + className: "primary", + onClick: function() { + var username = $("#weui-prompt-username").val(); + var password = $("#weui-prompt-password").val(); + if (!config.empty && (username === "" || username === null)) { + modal.find('#weui-prompt-username').focus()[0].select(); + return false; + } + if (!config.empty && (password === "" || password === null)) { + modal.find('#weui-prompt-password').focus()[0].select(); + return false; + } + $.closeModal(); + config.onOK && config.onOK.call(modal, username, password); + } + }] + }, function () { + this.find('#weui-prompt-username').focus()[0].select(); + }); + + return modal; + }; + + defaults = $.modal.prototype.defaults = { + title: "提示", + text: undefined, + buttonOK: "确定", + buttonCancel: "取消", + buttons: [{ + text: "确定", + className: "primary" + }], + autoClose: true //点击按钮自动关闭对话框,如果你不希望点击按钮就关闭对话框,可以把这个设置为false + }; + +}($); + ++ function($) { + "use strict"; + + var defaults; + + var show = function(html, className) { + className = className || ""; + var mask = $("
    ").appendTo(document.body); + + var tpl = '
    ' + html + '
    '; + var dialog = $(tpl).appendTo(document.body); + + dialog.addClass("weui-toast--visible"); + dialog.show(); + }; + + var hide = function(callback) { + $(".weui-mask_transparent").remove(); + $(".weui-toast--visible").removeClass("weui-toast--visible").transitionEnd(function() { + var $this = $(this); + $this.remove(); + callback && callback($this); + }); + } + + $.toast = function(text, style, callback) { + if(typeof style === "function") { + callback = style; + } + var className, iconClassName = 'weui-icon-success-no-circle'; + var duration = toastDefaults.duration; + if(style == "cancel") { + className = "weui-toast_cancel"; + iconClassName = 'weui-icon-cancel' + } else if(style == "forbidden") { + className = "weui-toast--forbidden"; + iconClassName = 'weui-icon-warn' + } else if(style == "text") { + className = "weui-toast--text"; + } else if(typeof style === typeof 1) { + duration = style + } + show('

    ' + (text || "已经完成") + '

    ', className); + + setTimeout(function() { + hide(callback); + }, duration); + } + + $.showLoading = function(text) { + var html = '
    '; + html += ''; + html += '
    '; + html += '

    ' + (text || "数据加载中") + '

    '; + show(html, 'weui_loading_toast'); + } + + $.hideLoading = function() { + hide(); + } + + var toastDefaults = $.toast.prototype.defaults = { + duration: 2500 + } + +}($); + ++ function($) { + "use strict"; + + var defaults; + + var show = function(params) { + + var mask = $("
    ").appendTo(document.body); + + var actions = params.actions || []; + + var actionsHtml = actions.map(function(d, i) { + return '
    ' + d.text + '
    '; + }).join(""); + + var titleHtml = ""; + + if (params.title) { + titleHtml = '

    ' + params.title + '

    '; + } + + var tpl = '
    '+ + titleHtml + + '
    '+ + actionsHtml + + '
    '+ + '
    '+ + '
    取消
    '+ + '
    '+ + '
    '; + var dialog = $(tpl).appendTo(document.body); + + dialog.find(".weui-actionsheet__menu .weui-actionsheet__cell, .weui-actionsheet__action .weui-actionsheet__cell").each(function(i, e) { + $(e).click(function() { + $.closeActions(); + params.onClose && params.onClose(); + if(actions[i] && actions[i].onClick) { + actions[i].onClick(); + } + }) + }); + + mask.show(); + dialog.show(); + mask.addClass("weui-mask--visible"); + dialog.addClass("weui-actionsheet_toggle"); + }; + + var hide = function() { + $(".weui-mask").removeClass("weui-mask--visible").transitionEnd(function() { + $(this).remove(); + }); + $(".weui-actionsheet").removeClass("weui-actionsheet_toggle").transitionEnd(function() { + $(this).remove(); + }); + } + + $.actions = function(params) { + params = $.extend({}, defaults, params); + show(params); + } + + $.closeActions = function() { + hide(); + } + + $(document).on("click", ".weui-actions_mask", function() { + $.closeActions(); + }); + + var defaults = $.actions.prototype.defaults = { + title: undefined, + onClose: undefined, + /*actions: [{ + text: "菜单", + className: "color-danger", + onClick: function() { + console.log(1); + } + },{ + text: "菜单2", + className: "color-success", + onClick: function() { + console.log(2); + } + }]*/ + } + +}($); + +/* =============================================================================== +************ Pull to refreh ************ +=============================================================================== */ +/* global $:true */ + ++function ($) { + "use strict"; + + var PTR = function(el, opt) { + if (typeof opt === typeof function () {}) { + opt = { + onRefresh: opt + } + } + if (typeof opt === typeof 'a') { + opt = undefined + } + this.opt = $.extend(PTR.defaults, opt || {}); + this.container = $(el); + this.attachEvents(); + } + + PTR.defaults = { + distance: 50, + onRefresh: undefined, + onPull: undefined + } + + PTR.prototype.touchStart = function(e) { + if(this.container.hasClass("refreshing")) return; + var p = $.getTouchPosition(e); + this.start = p; + this.diffX = this.diffY = 0; + }; + + PTR.prototype.touchMove= function(e) { + if(this.container.hasClass("refreshing")) return; + if(!this.start) return false; + if(this.container.scrollTop() > 0) return; + var p = $.getTouchPosition(e); + this.diffX = p.x - this.start.x; + this.diffY = p.y - this.start.y; + if (Math.abs(this.diffX) > Math.abs(this.diffY)) return true; // 说明是左右方向的拖动 + if(this.diffY < 0) return; + this.container.addClass("touching"); + e.preventDefault(); + e.stopPropagation(); + this.diffY = Math.pow(this.diffY, 0.75); + this.container.css("transform", "translate3d(0, "+this.diffY+"px, 0)"); + this.triggerPull(this.diffY) + }; + PTR.prototype.touchEnd = function() { + this.start = false; + if(this.diffY <= 0 || this.container.hasClass("refreshing")) return; + this.container.removeClass("touching"); + this.container.removeClass("pull-down pull-up"); + this.container.css("transform", ""); + if(Math.abs(this.diffY) <= this.opt.distance) { + } else { + this.triggerPullToRefresh(); + } + }; + + PTR.prototype.triggerPullToRefresh = function() { + this.triggerPull(this.opt.distance) + this.container.removeClass('pull-up').addClass("refreshing"); + if (this.opt.onRefresh) { + this.opt.onRefresh.call(this) + } + this.container.trigger("pull-to-refresh"); + } + + PTR.prototype.triggerPull = function(diffY) { + + if(diffY < this.opt.distance) { + this.container.removeClass("pull-up").addClass("pull-down"); + } else { + this.container.removeClass("pull-down").addClass("pull-up"); + } + + if (this.opt.onPull) { + this.opt.onPull.call(this, Math.floor(diffY / this.opt.distance * 100)) + } + this.container.trigger("pull"); + } + + PTR.prototype.pullToRefreshDone = function() { + this.container.removeClass("refreshing"); + } + + PTR.prototype.attachEvents = function() { + var el = this.container; + el.addClass("weui-pull-to-refresh"); + el.on($.touchEvents.start, $.proxy(this.touchStart, this)); + el.on($.touchEvents.move, $.proxy(this.touchMove, this)); + el.on($.touchEvents.end, $.proxy(this.touchEnd, this)); + }; + + var pullToRefreshDone = function(el) { + $(el).removeClass("refreshing"); + } + + $.fn.pullToRefresh = function(opt) { + return this.each(function() { + var $this = $(this) + var ptr = $this.data('ptr') + if (!ptr) $this.data('ptr', ptr = new PTR(this, opt)) + if (typeof opt === typeof 'a') { + ptr[opt].call(ptr) + } + }); + } + + $.fn.pullToRefreshDone = function() { + return this.each(function() { + pullToRefreshDone(this); + }); + } + +}($); + +/* =============================================================================== +************ Infinite ************ +=============================================================================== */ +/* global $:true */ ++function ($) { + "use strict"; + + // fix https://github.com/lihongxun945/jquery-weui/issues/442 + // chrome will always return 0, when use document.body.scrollTop + // https://stackoverflow.com/questions/43717316/google-chrome-document-body-scrolltop-always-returns-0 + var getOffset = function (container) { + var tagName = container[0].tagName.toUpperCase() + var scrollTop + if (tagName === 'BODY' || tagName === 'HTML') { + scrollTop = container.scrollTop() || $(window).scrollTop() + } else { + scrollTop = container.scrollTop() + } + var offset = container.scrollHeight() - ($(window).height() + scrollTop) + console.log(offset) + return offset + } + + var Infinite = function(el, distance) { + this.container = $(el); + this.container.data("infinite", this); + this.distance = distance || 50; + this.attachEvents(); + } + + Infinite.prototype.scroll = function() { + var container = this.container; + this._check(); + } + + Infinite.prototype.attachEvents = function(off) { + var el = this.container; + var scrollContainer = (el[0].tagName.toUpperCase() === "BODY" ? $(document) : el); + scrollContainer[off ? "off" : "on"]("scroll", $.proxy(this.scroll, this)); + }; + Infinite.prototype.detachEvents = function(off) { + this.attachEvents(true); + } + Infinite.prototype._check = function() { + var offset = getOffset(this.container); + if(Math.abs(offset) <= this.distance) { + this.container.trigger("infinite"); + } + } + + var infinite = function(el) { + attachEvents(el); + } + + $.fn.infinite = function(distance) { + return this.each(function() { + new Infinite(this, distance); + }); + } + $.fn.destroyInfinite = function() { + return this.each(function() { + var infinite = $(this).data("infinite"); + if(infinite && infinite.detachEvents) infinite.detachEvents(); + }); + } + +}($); + +/* global $:true */ ++function ($) { + "use strict"; + + var ITEM_ON = "weui-bar__item--on"; + + var showTab = function(a) { + var $a = $(a); + if($a.hasClass(ITEM_ON)) return; + var href = $a.attr("href"); + + if(!/^#/.test(href)) return ; + + $a.parent().find("."+ITEM_ON).removeClass(ITEM_ON); + $a.addClass(ITEM_ON); + + var bd = $a.parents(".weui-tab").find(".weui-tab__bd"); + + bd.find(".weui-tab__bd-item--active").removeClass("weui-tab__bd-item--active"); + + $(href).addClass("weui-tab__bd-item--active"); + } + + $.showTab = showTab; + + $(document).on("click", ".weui-navbar__item, .weui-tabbar__item", function(e) { + var $a = $(e.currentTarget); + var href = $a.attr("href"); + if($a.hasClass(ITEM_ON)) return; + if(!/^#/.test(href)) return; + + e.preventDefault(); + + showTab($a); + }); + +}($); + +/* global $:true */ ++ function($) { + "use strict"; + + $(document).on("click touchstart", ".weui-search-bar__label", function(e) { + $(e.target).parents(".weui-search-bar").addClass("weui-search-bar_focusing").find('input').focus(); + }) + /* + .on("blur", ".weui-search-bar__input", function(e) { + var $input = $(e.target); + if(!$input.val()) $input.parents(".weui-search-bar").removeClass("weui-search-bar_focusing"); + }) + */ + .on("click", ".weui-search-bar__cancel-btn", function(e) { + var $input = $(e.target).parents(".weui-search-bar").removeClass("weui-search-bar_focusing").find(".weui-search-bar__input").val("").blur(); + }) + .on("click", ".weui-icon-clear", function(e) { + var $input = $(e.target).parents(".weui-search-bar").find(".weui-search-bar__input").val("").focus(); + }); + +}($); + +/*=========================== +Device/OS Detection +===========================*/ +/* global $:true */ +;(function ($) { + "use strict"; + var device = {}; + var ua = navigator.userAgent; + + var android = ua.match(/(Android);?[\s\/]+([\d.]+)?/); + var ipad = ua.match(/(iPad).*OS\s([\d_]+)/); + var ipod = ua.match(/(iPod)(.*OS\s([\d_]+))?/); + var iphone = !ipad && ua.match(/(iPhone\sOS)\s([\d_]+)/); + + device.ios = device.android = device.iphone = device.ipad = device.androidChrome = false; + + // Android + if (android) { + device.os = 'android'; + device.osVersion = android[2]; + device.android = true; + device.androidChrome = ua.toLowerCase().indexOf('chrome') >= 0; + } + if (ipad || iphone || ipod) { + device.os = 'ios'; + device.ios = true; + } + // iOS + if (iphone && !ipod) { + device.osVersion = iphone[2].replace(/_/g, '.'); + device.iphone = true; + } + if (ipad) { + device.osVersion = ipad[2].replace(/_/g, '.'); + device.ipad = true; + } + if (ipod) { + device.osVersion = ipod[3] ? ipod[3].replace(/_/g, '.') : null; + device.iphone = true; + } + // iOS 8+ changed UA + if (device.ios && device.osVersion && ua.indexOf('Version/') >= 0) { + if (device.osVersion.split('.')[0] === '10') { + device.osVersion = ua.toLowerCase().split('version/')[1].split(' ')[0]; + } + } + + // Webview + device.webView = (iphone || ipad || ipod) && ua.match(/.*AppleWebKit(?!.*Safari)/i); + + // Minimal UI + if (device.os && device.os === 'ios') { + var osVersionArr = device.osVersion.split('.'); + device.minimalUi = !device.webView && + (ipod || iphone) && + (osVersionArr[0] * 1 === 7 ? osVersionArr[1] * 1 >= 1 : osVersionArr[0] * 1 > 7) && + $('meta[name="viewport"]').length > 0 && $('meta[name="viewport"]').attr('content').indexOf('minimal-ui') >= 0; + } + + // Check for status bar and fullscreen app mode + var windowWidth = $(window).width(); + var windowHeight = $(window).height(); + device.statusBar = false; + if (device.webView && (windowWidth * windowHeight === screen.width * screen.height)) { + device.statusBar = true; + } + else { + device.statusBar = false; + } + + // Classes + var classNames = []; + + // Pixel Ratio + device.pixelRatio = window.devicePixelRatio || 1; + classNames.push('pixel-ratio-' + Math.floor(device.pixelRatio)); + if (device.pixelRatio >= 2) { + classNames.push('retina'); + } + + // OS classes + if (device.os) { + classNames.push(device.os, device.os + '-' + device.osVersion.split('.')[0], device.os + '-' + device.osVersion.replace(/\./g, '-')); + if (device.os === 'ios') { + var major = parseInt(device.osVersion.split('.')[0], 10); + for (var i = major - 1; i >= 6; i--) { + classNames.push('ios-gt-' + i); + } + } + + } + // Status bar classes + if (device.statusBar) { + classNames.push('with-statusbar-overlay'); + } + else { + $('html').removeClass('with-statusbar-overlay'); + } + + // Add html classes + if (classNames.length > 0) $('html').addClass(classNames.join(' ')); + + $.device = device; +})($); + +/*====================================================== +************ Picker ************ +======================================================*/ +/* global $:true */ +/* jshint unused:false */ +/* jshint multistr:true */ ++ function($) { + "use strict"; + var Picker = function (params) { + var p = this; + var defaults = { + updateValuesOnMomentum: false, + updateValuesOnTouchmove: true, + rotateEffect: false, + momentumRatio: 7, + freeMode: false, + // Common settings + scrollToInput: true, + inputReadOnly: true, + toolbar: true, + toolbarCloseText: '完成', + title: '请选择', + toolbarTemplate: '
    \ +
    \ + {{closeText}}\ +

    {{title}}

    \ +
    \ +
    ', + }; + params = params || {}; + for (var def in defaults) { + if (typeof params[def] === 'undefined') { + params[def] = defaults[def]; + } + } + p.params = params; + p.cols = []; + p.initialized = false; + + // Inline flag + p.inline = p.params.container ? true : false; + + // 3D Transforms origin bug, only on safari + var originBug = $.device.ios || (navigator.userAgent.toLowerCase().indexOf('safari') >= 0 && navigator.userAgent.toLowerCase().indexOf('chrome') < 0) && !$.device.android; + + // Should be converted to popover + function isPopover() { + var toPopover = false; + if (!p.params.convertToPopover && !p.params.onlyInPopover) return toPopover; + if (!p.inline && p.params.input) { + if (p.params.onlyInPopover) toPopover = true; + else { + if ($.device.ios) { + toPopover = $.device.ipad ? true : false; + } + else { + if ($(window).width() >= 768) toPopover = true; + } + } + } + return toPopover; + } + function inPopover() { + if (p.opened && p.container && p.container.length > 0 && p.container.parents('.popover').length > 0) return true; + else return false; + } + + // Value + p.setValue = function (arrValues, transition) { + var valueIndex = 0; + for (var i = 0; i < p.cols.length; i++) { + if (p.cols[i] && !p.cols[i].divider) { + p.cols[i].setValue(arrValues[valueIndex], transition); + valueIndex++; + } + } + }; + p.updateValue = function () { + var newValue = []; + var newDisplayValue = []; + for (var i = 0; i < p.cols.length; i++) { + if (!p.cols[i].divider) { + newValue.push(p.cols[i].value); + newDisplayValue.push(p.cols[i].displayValue); + } + } + if (newValue.indexOf(undefined) >= 0) { + return; + } + p.value = newValue; + p.displayValue = newDisplayValue; + if (p.params.onChange) { + p.params.onChange(p, p.value, p.displayValue); + } + if (p.input && p.input.length > 0) { + $(p.input).val(p.params.formatValue ? p.params.formatValue(p, p.value, p.displayValue) : p.value.join(' ')); + $(p.input).trigger('change'); + } + }; + + // Columns Handlers + p.initPickerCol = function (colElement, updateItems) { + var colContainer = $(colElement); + var colIndex = colContainer.index(); + var col = p.cols[colIndex]; + if (col.divider) return; + col.container = colContainer; + col.wrapper = col.container.find('.picker-items-col-wrapper'); + col.items = col.wrapper.find('.picker-item'); + + var i, j; + var wrapperHeight, itemHeight, itemsHeight, minTranslate, maxTranslate; + col.replaceValues = function (values, displayValues) { + col.destroyEvents(); + col.values = values; + col.displayValues = displayValues; + var newItemsHTML = p.columnHTML(col, true); + col.wrapper.html(newItemsHTML); + col.items = col.wrapper.find('.picker-item'); + col.calcSize(); + col.setValue(col.values[0] || '', 0, true); + col.initEvents(); + }; + col.calcSize = function () { + if (!col.values.length) return; + if (p.params.rotateEffect) { + col.container.removeClass('picker-items-col-absolute'); + if (!col.width) col.container.css({width:''}); + } + var colWidth, colHeight; + colWidth = 0; + colHeight = col.container[0].offsetHeight; + wrapperHeight = col.wrapper[0].offsetHeight; + itemHeight = col.items[0].offsetHeight; + itemsHeight = itemHeight * col.items.length; + minTranslate = colHeight / 2 - itemsHeight + itemHeight / 2; + maxTranslate = colHeight / 2 - itemHeight / 2; + if (col.width) { + colWidth = col.width; + if (parseInt(colWidth, 10) === colWidth) colWidth = colWidth + 'px'; + col.container.css({width: colWidth}); + } + if (p.params.rotateEffect) { + if (!col.width) { + col.items.each(function () { + var item = $(this); + item.css({width:'auto'}); + colWidth = Math.max(colWidth, item[0].offsetWidth); + item.css({width:''}); + }); + col.container.css({width: (colWidth + 2) + 'px'}); + } + col.container.addClass('picker-items-col-absolute'); + } + }; + col.calcSize(); + + col.wrapper.transform('translate3d(0,' + maxTranslate + 'px,0)').transition(0); + + + var activeIndex = 0; + var animationFrameId; + + // Set Value Function + col.setValue = function (newValue, transition, valueCallbacks) { + if (typeof transition === 'undefined') transition = ''; + var newActiveIndex = col.wrapper.find('.picker-item[data-picker-value="' + newValue + '"]').index(); + if(typeof newActiveIndex === 'undefined' || newActiveIndex === -1) { + col.value = col.displayValue = newValue; + return; + } + var newTranslate = -newActiveIndex * itemHeight + maxTranslate; + // Update wrapper + col.wrapper.transition(transition); + col.wrapper.transform('translate3d(0,' + (newTranslate) + 'px,0)'); + + // Watch items + if (p.params.updateValuesOnMomentum && col.activeIndex && col.activeIndex !== newActiveIndex ) { + $.cancelAnimationFrame(animationFrameId); + col.wrapper.transitionEnd(function(){ + $.cancelAnimationFrame(animationFrameId); + }); + updateDuringScroll(); + } + + // Update items + col.updateItems(newActiveIndex, newTranslate, transition, valueCallbacks); + }; + + col.updateItems = function (activeIndex, translate, transition, valueCallbacks) { + if (typeof translate === 'undefined') { + translate = $.getTranslate(col.wrapper[0], 'y'); + } + if(typeof activeIndex === 'undefined') activeIndex = -Math.round((translate - maxTranslate)/itemHeight); + if (activeIndex < 0) activeIndex = 0; + if (activeIndex >= col.items.length) activeIndex = col.items.length - 1; + var previousActiveIndex = col.activeIndex; + col.activeIndex = activeIndex; + /* + col.wrapper.find('.picker-selected, .picker-after-selected, .picker-before-selected').removeClass('picker-selected picker-after-selected picker-before-selected'); + + col.items.transition(transition); + var selectedItem = col.items.eq(activeIndex).addClass('picker-selected').transform(''); + var prevItems = selectedItem.prevAll().addClass('picker-before-selected'); + var nextItems = selectedItem.nextAll().addClass('picker-after-selected'); + */ + //去掉 .picker-after-selected, .picker-before-selected 以提高性能 + col.wrapper.find('.picker-selected').removeClass('picker-selected'); + if (p.params.rotateEffect) { + col.items.transition(transition); + } + var selectedItem = col.items.eq(activeIndex).addClass('picker-selected').transform(''); + + if (valueCallbacks || typeof valueCallbacks === 'undefined') { + // Update values + col.value = selectedItem.attr('data-picker-value'); + col.displayValue = col.displayValues ? col.displayValues[activeIndex] : col.value; + // On change callback + if (previousActiveIndex !== activeIndex) { + if (col.onChange) { + col.onChange(p, col.value, col.displayValue); + } + p.updateValue(); + } + } + + // Set 3D rotate effect + if (!p.params.rotateEffect) { + return; + } + var percentage = (translate - (Math.floor((translate - maxTranslate)/itemHeight) * itemHeight + maxTranslate)) / itemHeight; + + col.items.each(function () { + var item = $(this); + var itemOffsetTop = item.index() * itemHeight; + var translateOffset = maxTranslate - translate; + var itemOffset = itemOffsetTop - translateOffset; + var percentage = itemOffset / itemHeight; + + var itemsFit = Math.ceil(col.height / itemHeight / 2) + 1; + + var angle = (-18*percentage); + if (angle > 180) angle = 180; + if (angle < -180) angle = -180; + // Far class + if (Math.abs(percentage) > itemsFit) item.addClass('picker-item-far'); + else item.removeClass('picker-item-far'); + // Set transform + item.transform('translate3d(0, ' + (-translate + maxTranslate) + 'px, ' + (originBug ? -110 : 0) + 'px) rotateX(' + angle + 'deg)'); + }); + }; + + function updateDuringScroll() { + animationFrameId = $.requestAnimationFrame(function () { + col.updateItems(undefined, undefined, 0); + updateDuringScroll(); + }); + } + + // Update items on init + if (updateItems) col.updateItems(0, maxTranslate, 0); + + var allowItemClick = true; + var isTouched, isMoved, touchStartY, touchCurrentY, touchStartTime, touchEndTime, startTranslate, returnTo, currentTranslate, prevTranslate, velocityTranslate, velocityTime; + function handleTouchStart (e) { + if (isMoved || isTouched) return; + e.preventDefault(); + isTouched = true; + var position = $.getTouchPosition(e); + touchStartY = touchCurrentY = position.y; + touchStartTime = (new Date()).getTime(); + + allowItemClick = true; + startTranslate = currentTranslate = $.getTranslate(col.wrapper[0], 'y'); + } + function handleTouchMove (e) { + if (!isTouched) return; + e.preventDefault(); + allowItemClick = false; + var position = $.getTouchPosition(e); + touchCurrentY = position.y; + if (!isMoved) { + // First move + $.cancelAnimationFrame(animationFrameId); + isMoved = true; + startTranslate = currentTranslate = $.getTranslate(col.wrapper[0], 'y'); + col.wrapper.transition(0); + } + e.preventDefault(); + + var diff = touchCurrentY - touchStartY; + currentTranslate = startTranslate + diff; + returnTo = undefined; + + // Normalize translate + if (currentTranslate < minTranslate) { + currentTranslate = minTranslate - Math.pow(minTranslate - currentTranslate, 0.8); + returnTo = 'min'; + } + if (currentTranslate > maxTranslate) { + currentTranslate = maxTranslate + Math.pow(currentTranslate - maxTranslate, 0.8); + returnTo = 'max'; + } + // Transform wrapper + col.wrapper.transform('translate3d(0,' + currentTranslate + 'px,0)'); + + // Update items + col.updateItems(undefined, currentTranslate, 0, p.params.updateValuesOnTouchmove); + + // Calc velocity + velocityTranslate = currentTranslate - prevTranslate || currentTranslate; + velocityTime = (new Date()).getTime(); + prevTranslate = currentTranslate; + } + function handleTouchEnd (e) { + if (!isTouched || !isMoved) { + isTouched = isMoved = false; + return; + } + isTouched = isMoved = false; + col.wrapper.transition(''); + if (returnTo) { + if (returnTo === 'min') { + col.wrapper.transform('translate3d(0,' + minTranslate + 'px,0)'); + } + else col.wrapper.transform('translate3d(0,' + maxTranslate + 'px,0)'); + } + touchEndTime = new Date().getTime(); + var velocity, newTranslate; + if (touchEndTime - touchStartTime > 300) { + newTranslate = currentTranslate; + } + else { + velocity = Math.abs(velocityTranslate / (touchEndTime - velocityTime)); + newTranslate = currentTranslate + velocityTranslate * p.params.momentumRatio; + } + + newTranslate = Math.max(Math.min(newTranslate, maxTranslate), minTranslate); + + // Active Index + var activeIndex = -Math.floor((newTranslate - maxTranslate)/itemHeight); + + // Normalize translate + if (!p.params.freeMode) newTranslate = -activeIndex * itemHeight + maxTranslate; + + // Transform wrapper + col.wrapper.transform('translate3d(0,' + (parseInt(newTranslate,10)) + 'px,0)'); + + // Update items + col.updateItems(activeIndex, newTranslate, '', true); + + // Watch items + if (p.params.updateValuesOnMomentum) { + updateDuringScroll(); + col.wrapper.transitionEnd(function(){ + $.cancelAnimationFrame(animationFrameId); + }); + } + + // Allow click + setTimeout(function () { + allowItemClick = true; + }, 100); + } + + function handleClick(e) { + if (!allowItemClick) return; + $.cancelAnimationFrame(animationFrameId); + /*jshint validthis:true */ + var value = $(this).attr('data-picker-value'); + col.setValue(value); + } + + col.initEvents = function (detach) { + var method = detach ? 'off' : 'on'; + col.container[method]($.touchEvents.start, handleTouchStart); + col.container[method]($.touchEvents.move, handleTouchMove); + col.container[method]($.touchEvents.end, handleTouchEnd); + col.items[method]('click', handleClick); + }; + col.destroyEvents = function () { + col.initEvents(true); + }; + + col.container[0].f7DestroyPickerCol = function () { + col.destroyEvents(); + }; + + col.initEvents(); + + }; + p.destroyPickerCol = function (colContainer) { + colContainer = $(colContainer); + if ('f7DestroyPickerCol' in colContainer[0]) colContainer[0].f7DestroyPickerCol(); + }; + // Resize cols + function resizeCols() { + if (!p.opened) return; + for (var i = 0; i < p.cols.length; i++) { + if (!p.cols[i].divider) { + p.cols[i].calcSize(); + p.cols[i].setValue(p.cols[i].value, 0, false); + } + } + } + $(window).on('resize', resizeCols); + + // HTML Layout + p.columnHTML = function (col, onlyItems) { + var columnItemsHTML = ''; + var columnHTML = ''; + if (col.divider) { + columnHTML += '
    ' + col.content + '
    '; + } + else { + for (var j = 0; j < col.values.length; j++) { + columnItemsHTML += '
    ' + (col.displayValues ? col.displayValues[j] : col.values[j]) + '
    '; + } + columnHTML += '
    ' + columnItemsHTML + '
    '; + } + return onlyItems ? columnItemsHTML : columnHTML; + }; + p.layout = function () { + var pickerHTML = ''; + var pickerClass = ''; + var i; + p.cols = []; + var colsHTML = ''; + for (i = 0; i < p.params.cols.length; i++) { + var col = p.params.cols[i]; + colsHTML += p.columnHTML(p.params.cols[i]); + p.cols.push(col); + } + pickerClass = 'weui-picker-modal picker-columns ' + (p.params.cssClass || '') + (p.params.rotateEffect ? ' picker-3d' : '') + (p.params.cols.length === 1 ? ' picker-columns-single' : ''); + pickerHTML = + '
    ' + + (p.params.toolbar ? p.params.toolbarTemplate.replace(/{{closeText}}/g, p.params.toolbarCloseText).replace(/{{title}}/g, p.params.title) : '') + + '
    ' + + colsHTML + + '
    ' + + '
    ' + + '
    '; + + p.pickerHTML = pickerHTML; + }; + + // Input Events + function openOnInput(e) { + e.preventDefault(); + if (p.opened) return; + p.open(); + if (p.params.scrollToInput && !isPopover()) { + var pageContent = p.input.parents('.content'); + if (pageContent.length === 0) return; + + var paddingTop = parseInt(pageContent.css('padding-top'), 10), + paddingBottom = parseInt(pageContent.css('padding-bottom'), 10), + pageHeight = pageContent[0].offsetHeight - paddingTop - p.container.height(), + pageScrollHeight = pageContent[0].scrollHeight - paddingTop - p.container.height(), + newPaddingBottom; + var inputTop = p.input.offset().top - paddingTop + p.input[0].offsetHeight; + if (inputTop > pageHeight) { + var scrollTop = pageContent.scrollTop() + inputTop - pageHeight; + if (scrollTop + pageHeight > pageScrollHeight) { + newPaddingBottom = scrollTop + pageHeight - pageScrollHeight + paddingBottom; + if (pageHeight === pageScrollHeight) { + newPaddingBottom = p.container.height(); + } + pageContent.css({'padding-bottom': (newPaddingBottom) + 'px'}); + } + pageContent.scrollTop(scrollTop, 300); + } + } + } + function closeOnHTMLClick(e) { + if (inPopover()) return; + if (p.input && p.input.length > 0) { + if (e.target !== p.input[0] && $(e.target).parents('.weui-picker-modal').length === 0) p.close(); + } + else { + if ($(e.target).parents('.weui-picker-modal').length === 0) p.close(); + } + } + + if (p.params.input) { + p.input = $(p.params.input); + if (p.input.length > 0) { + if (p.params.inputReadOnly) p.input.prop('readOnly', true); + if (!p.inline) { + p.input.on('click', openOnInput); + } + if (p.params.inputReadOnly) { + p.input.on('focus mousedown', function (e) { + e.preventDefault(); + }); + } + } + + } + + if (!p.inline) $('html').on('click', closeOnHTMLClick); + + // Open + function onPickerClose() { + p.opened = false; + if (p.input && p.input.length > 0) p.input.parents('.page-content').css({'padding-bottom': ''}); + if (p.params.onClose) p.params.onClose(p); + + // Destroy events + p.container.find('.picker-items-col').each(function () { + p.destroyPickerCol(this); + }); + } + + p.opened = false; + p.open = function () { + var toPopover = isPopover(); + + if (!p.opened) { + + // Layout + p.layout(); + + // Append + if (toPopover) { + p.pickerHTML = '
    ' + p.pickerHTML + '
    '; + p.popover = $.popover(p.pickerHTML, p.params.input, true); + p.container = $(p.popover).find('.weui-picker-modal'); + $(p.popover).on('close', function () { + onPickerClose(); + }); + } + else if (p.inline) { + p.container = $(p.pickerHTML); + p.container.addClass('picker-modal-inline'); + $(p.params.container).append(p.container); + } + else { + p.container = $($.openPicker(p.pickerHTML)); + $(p.container) + .on('close', function () { + onPickerClose(); + }); + } + + // Store picker instance + p.container[0].f7Picker = p; + + // Init Events + p.container.find('.picker-items-col').each(function () { + var updateItems = true; + if ((!p.initialized && p.params.value) || (p.initialized && p.value)) updateItems = false; + p.initPickerCol(this, updateItems); + }); + + // Set value + if (!p.initialized) { + if (p.params.value) { + p.setValue(p.params.value, 0); + } + } + else { + if (p.value) p.setValue(p.value, 0); + } + } + + // Set flag + p.opened = true; + p.initialized = true; + + if (p.params.onOpen) p.params.onOpen(p); + }; + + // Close + p.close = function (force) { + if (!p.opened || p.inline) return; + if (inPopover()) { + $.closePicker(p.popover); + return; + } + else { + $.closePicker(p.container); + return; + } + }; + + // Destroy + p.destroy = function () { + p.close(); + if (p.params.input && p.input.length > 0) { + p.input.off('click focus', openOnInput); + $(p.input).data('picker', null); + } + $('html').off('click', closeOnHTMLClick); + $(window).off('resize', resizeCols); + }; + + if (p.inline) { + p.open(); + } + + return p; + }; + + $(document).on("click", ".close-picker", function() { + var pickerToClose = $('.weui-picker-modal.weui-picker-modal-visible'); + if (pickerToClose.length > 0) { + $.closePicker(pickerToClose); + } + }); + + //修复picker会滚动页面的bug + $(document).on($.touchEvents.move, ".picker-modal-inner", function(e) { + e.preventDefault(); + }); + + + $.openPicker = function(tpl, className, callback) { + + if(typeof className === "function") { + callback = className; + className = undefined; + } + + $.closePicker(); + + var container = $("
    ").appendTo(document.body); + container.show(); + + container.addClass("weui-picker-container-visible"); + + //关于布局的问题,如果直接放在body上,则做动画的时候会撑开body高度而导致滚动条变化。 + var dialog = $(tpl).appendTo(container); + + dialog.width(); //通过取一次CSS值,强制浏览器不能把上下两行代码合并执行,因为合并之后会导致无法出现动画。 + + dialog.addClass("weui-picker-modal-visible"); + + callback && container.on("close", callback); + + return dialog; + } + + $.updatePicker = function(tpl) { + var container = $(".weui-picker-container-visible"); + if(!container[0]) return false; + + container.html(""); + + var dialog = $(tpl).appendTo(container); + + dialog.addClass("weui-picker-modal-visible"); + + return dialog; + } + + $.closePicker = function(container, callback) { + if(typeof container === "function") callback = container; + $(".weui-picker-modal-visible").removeClass("weui-picker-modal-visible").transitionEnd(function() { + $(this).parent().remove(); + callback && callback(); + }).trigger("close"); + }; + + $.fn.picker = function(params) { + var args = arguments; + return this.each(function() { + if(!this) return; + var $this = $(this); + + var picker = $this.data("picker"); + if(!picker) { + params = $.extend({ input: this }, params || {}) // https://github.com/lihongxun945/jquery-weui/issues/432 + var inputValue = $this.val(); + if(params.value === undefined && inputValue !== "") { + params.value = (params.cols && params.cols.length > 1) ? inputValue.split(" ") : [inputValue]; + } + var p = $.extend({input: this}, params); + picker = new Picker(p); + $this.data("picker", picker); + } + if(typeof params === typeof "a") { + picker[params].apply(picker, Array.prototype.slice.call(args, 1)); + } + }); + }; +}($); + +/* global $:true */ ++ function($) { + "use strict"; + + var defaults; + + var selects = []; + + var Select = function(input, config) { + + var self = this; + this.config = config; + + //init empty data + this.data = { + values: '', + titles: '', + origins: [], + length: 0 + }; + + this.$input = $(input); + this.$input.prop("readOnly", true); + + this.initConfig(); + + config = this.config; + + this.$input.click($.proxy(this.open, this)); + selects.push(this) + } + + Select.prototype.initConfig = function() { + this.config = $.extend({}, defaults, this.config); + + var config = this.config; + + if(!config.items || !config.items.length) return; + + config.items = config.items.map(function(d, i) { + if(typeof d == typeof "a") { + return { + title: d, + value: d + }; + } + + return d; + }); + + + this.tpl = $.t7.compile("
    " + config.toolbarTemplate + (config.multi ? config.checkboxTemplate : config.radioTemplate) + "
    "); + + if(config.input !== undefined) this.$input.val(config.input); + + this.parseInitValue(); + + this._init = true; + } + + Select.prototype.updateInputValue = function(values, titles) { + var v, t; + if(this.config.multi) { + v = values.join(this.config.split); + t = titles.join(this.config.split); + } else { + v = values[0]; + t = titles[0]; + } + + //caculate origin data + var origins = []; + + this.config.items.forEach(function(d) { + values.each(function(i, dd) { + if(d.value == dd) origins.push(d); + }); + }); + + this.$input.val(t).data("values", v); + this.$input.attr("value", t).attr("data-values", v); + + var data = { + values: v, + titles: t, + valuesArray: values, + titlesArray: titles, + origins: origins, + length: origins.length + }; + this.data = data; + this.$input.trigger("change", data); + this.config.onChange && this.config.onChange.call(this, data); + } + + Select.prototype.parseInitValue = function() { + var value = this.$input.val(); + var items = this.config.items; + + //如果input为空,只有在第一次初始化的时候才保留默认选择。因为后来就是用户自己取消了全部选择,不能再为他选中默认值。 + if( !this._init && (value === undefined || value == null || value === "")) return; + + var titles = this.config.multi ? value.split(this.config.split) : [value]; + for(var i=0;i this.config.max) { + $.toast("最多只能选择"+this.config.max+"个", "text"); + return false + } + } + } + $.closePicker(function() { + self.onClose(); + callback && callback(); + }); + + return true + } + + Select.prototype.onClose = function() { + this._open = false; + if(this.config.onClose) this.config.onClose(this); + } + + Select.prototype.getHTML = function(callback) { + var config = this.config; + return this.tpl({ + items: config.items, + title: config.title, + closeText: config.closeText + }) + } + + + $.fn.select = function(params, args) { + + return this.each(function() { + var $this = $(this); + if(!$this.data("weui-select")) $this.data("weui-select", new Select(this, params)); + + var select = $this.data("weui-select"); + + if(typeof params === typeof "a") select[params].call(select, args); + + return select; + }); + } + + defaults = $.fn.select.prototype.defaults = { + items: [], + input: undefined, //输入框的初始值 + title: "请选择", + multi: false, + closeText: "确定", + autoClose: true, //是否选择完成后自动关闭,只有单选模式下才有效 + onChange: undefined, //function + beforeClose: undefined, // function 关闭之前,如果返回false则阻止关闭 + onClose: undefined, //function + onOpen: undefined, //function + split: ",", //多选模式下的分隔符 + min: undefined, //多选模式下可用,最少选择数 + max: undefined, //单选模式下可用,最多选择数 + toolbarTemplate: '
    \ +
    \ + {{closeText}}\ +

    {{title}}

    \ +
    \ +
    ', + radioTemplate: + '
    \ + {{#items}}\ + \ + {{/items}}\ +
    ', + checkboxTemplate: + '
    \ + {{#items}}\ + \ + {{/items}}\ +
    ', + } + +}($); + +/*====================================================== +************ Calendar ************ +======================================================*/ +/* global $:true */ +/*jshint unused: false*/ ++function ($) { + "use strict"; + var rtl = false; + var defaults; + var isSameDate = function (a, b) { + var a = new Date(a), + b = new Date(b); + return a.getFullYear() === b.getFullYear() && a.getMonth() === b.getMonth() && a.getDate() === b.getDate() + } + var Calendar = function (params) { + var p = this; + params = params || {}; + for (var def in defaults) { + if (typeof params[def] === 'undefined') { + params[def] = defaults[def]; + } + } + p.params = params; + p.initialized = false; + + // Inline flag + p.inline = p.params.container ? true : false; + + // Is horizontal + p.isH = p.params.direction === 'horizontal'; + + // RTL inverter + var inverter = p.isH ? (rtl ? -1 : 1) : 1; + + // Animating flag + p.animating = false; + + // Should be converted to popover + function isPopover() { + var toPopover = false; + if (!p.params.convertToPopover && !p.params.onlyInPopover) return toPopover; + if (!p.inline && p.params.input) { + if (p.params.onlyInPopover) toPopover = true; + else { + if ($.device.ios) { + toPopover = $.device.ipad ? true : false; + } + else { + if ($(window).width() >= 768) toPopover = true; + } + } + } + return toPopover; + } + function inPopover() { + if (p.opened && p.container && p.container.length > 0 && p.container.parents('.popover').length > 0) return true; + else return false; + } + + // Format date + function formatDate(date) { + date = new Date(date); + var year = date.getFullYear(); + var month = date.getMonth(); + var month1 = month + 1; + var day = date.getDate(); + var weekDay = date.getDay(); + return p.params.dateFormat + .replace(/yyyy/g, year) + .replace(/yy/g, (year + '').substring(2)) + .replace(/mm/g, month1 < 10 ? '0' + month1 : month1) + .replace(/m/g, month1) + .replace(/MM/g, p.params.monthNames[month]) + .replace(/M/g, p.params.monthNamesShort[month]) + .replace(/dd/g, day < 10 ? '0' + day : day) + .replace(/d/g, day) + .replace(/DD/g, p.params.dayNames[weekDay]) + .replace(/D/g, p.params.dayNamesShort[weekDay]); + } + + + // Value + p.addValue = function (value) { + if (p.params.multiple) { + if (!p.value) p.value = []; + var inValuesIndex; + for (var i = 0; i < p.value.length; i++) { + if (isSameDate(value, p.value[i])) { + inValuesIndex = i; + } + } + if (typeof inValuesIndex === 'undefined') { + p.value.push(value); + } + else { + p.value.splice(inValuesIndex, 1); + } + p.updateValue(); + } + else { + p.value = [value]; + p.updateValue(); + } + }; + p.setValue = function (arrValues) { + var date = new Date(arrValues[0]); + p.setYearMonth(date.getFullYear(), date.getMonth()); + p.addValue(+ date); + }; + p.updateValue = function () { + p.wrapper.find('.picker-calendar-day-selected').removeClass('picker-calendar-day-selected'); + var i, inputValue; + for (i = 0; i < p.value.length; i++) { + var valueDate = new Date(p.value[i]); + p.wrapper.find('.picker-calendar-day[data-date="' + valueDate.getFullYear() + '-' + valueDate.getMonth() + '-' + valueDate.getDate() + '"]').addClass('picker-calendar-day-selected'); + } + if (p.params.onChange) { + p.params.onChange(p, p.value.map(formatDate), p.value.map(function (d) { + return + new Date(typeof d === typeof 'a' ? d.split(/\D/).filter(function (a) { return !!a; }).join("-") : d); + })); + } + if (p.input && p.input.length > 0) { + if (p.params.formatValue) inputValue = p.params.formatValue(p, p.value); + else { + inputValue = []; + for (i = 0; i < p.value.length; i++) { + inputValue.push(formatDate(p.value[i])); + } + inputValue = inputValue.join(', '); + } + $(p.input).val(inputValue); + $(p.input).trigger('change'); + } + }; + + // Columns Handlers + p.initCalendarEvents = function () { + var col; + var allowItemClick = true; + var isTouched, isMoved, touchStartX, touchStartY, touchCurrentX, touchCurrentY, touchStartTime, touchEndTime, startTranslate, currentTranslate, wrapperWidth, wrapperHeight, percentage, touchesDiff, isScrolling; + function handleTouchStart (e) { + if (isMoved || isTouched) return; + // e.preventDefault(); + isTouched = true; + var position = $.getTouchPosition(e); + touchStartX = touchCurrentY = position.x; + touchStartY = touchCurrentY = position.y; + touchStartTime = (new Date()).getTime(); + percentage = 0; + allowItemClick = true; + isScrolling = undefined; + startTranslate = currentTranslate = p.monthsTranslate; + } + function handleTouchMove (e) { + if (!isTouched) return; + var position = $.getTouchPosition(e); + touchCurrentX = position.x; + touchCurrentY = position.y; + if (typeof isScrolling === 'undefined') { + isScrolling = !!(isScrolling || Math.abs(touchCurrentY - touchStartY) > Math.abs(touchCurrentX - touchStartX)); + } + if (p.isH && isScrolling) { + isTouched = false; + return; + } + e.preventDefault(); + if (p.animating) { + isTouched = false; + return; + } + allowItemClick = false; + if (!isMoved) { + // First move + isMoved = true; + wrapperWidth = p.wrapper[0].offsetWidth; + wrapperHeight = p.wrapper[0].offsetHeight; + p.wrapper.transition(0); + } + e.preventDefault(); + + touchesDiff = p.isH ? touchCurrentX - touchStartX : touchCurrentY - touchStartY; + percentage = touchesDiff/(p.isH ? wrapperWidth : wrapperHeight); + currentTranslate = (p.monthsTranslate * inverter + percentage) * 100; + + // Transform wrapper + p.wrapper.transform('translate3d(' + (p.isH ? currentTranslate : 0) + '%, ' + (p.isH ? 0 : currentTranslate) + '%, 0)'); + + } + function handleTouchEnd (e) { + if (!isTouched || !isMoved) { + isTouched = isMoved = false; + return; + } + isTouched = isMoved = false; + + touchEndTime = new Date().getTime(); + if (touchEndTime - touchStartTime < 300) { + if (Math.abs(touchesDiff) < 10) { + p.resetMonth(); + } + else if (touchesDiff >= 10) { + if (rtl) p.nextMonth(); + else p.prevMonth(); + } + else { + if (rtl) p.prevMonth(); + else p.nextMonth(); + } + } + else { + if (percentage <= -0.5) { + if (rtl) p.prevMonth(); + else p.nextMonth(); + } + else if (percentage >= 0.5) { + if (rtl) p.nextMonth(); + else p.prevMonth(); + } + else { + p.resetMonth(); + } + } + + // Allow click + setTimeout(function () { + allowItemClick = true; + }, 100); + } + + function handleDayClick(e) { + if (!allowItemClick) return; + var day = $(e.target).parents('.picker-calendar-day'); + if (day.length === 0 && $(e.target).hasClass('picker-calendar-day')) { + day = $(e.target); + } + if (day.length === 0) return; + // if (day.hasClass('picker-calendar-day-selected') && !p.params.multiple) return; + if (day.hasClass('picker-calendar-day-disabled')) return; + if (day.hasClass('picker-calendar-day-next')) p.nextMonth(); + if (day.hasClass('picker-calendar-day-prev')) p.prevMonth(); + var dateYear = day.attr('data-year'); + var dateMonth = day.attr('data-month'); + var dateDay = day.attr('data-day'); + if (p.params.onDayClick) { + p.params.onDayClick(p, day[0], dateYear, dateMonth, dateDay); + } + p.addValue(new Date(dateYear, dateMonth, dateDay).getTime()); + if (p.params.closeOnSelect && !p.params.multiple) p.close(); + } + + p.container.find('.picker-calendar-prev-month').on('click', p.prevMonth); + p.container.find('.picker-calendar-next-month').on('click', p.nextMonth); + p.container.find('.picker-calendar-prev-year').on('click', p.prevYear); + p.container.find('.picker-calendar-next-year').on('click', p.nextYear); + p.wrapper.on('click', handleDayClick); + if (p.params.touchMove) { + p.wrapper.on($.touchEvents.start, handleTouchStart); + p.wrapper.on($.touchEvents.move, handleTouchMove); + p.wrapper.on($.touchEvents.end, handleTouchEnd); + } + + p.container[0].f7DestroyCalendarEvents = function () { + p.container.find('.picker-calendar-prev-month').off('click', p.prevMonth); + p.container.find('.picker-calendar-next-month').off('click', p.nextMonth); + p.container.find('.picker-calendar-prev-year').off('click', p.prevYear); + p.container.find('.picker-calendar-next-year').off('click', p.nextYear); + p.wrapper.off('click', handleDayClick); + if (p.params.touchMove) { + p.wrapper.off($.touchEvents.start, handleTouchStart); + p.wrapper.off($.touchEvents.move, handleTouchMove); + p.wrapper.off($.touchEvents.end, handleTouchEnd); + } + }; + + + }; + p.destroyCalendarEvents = function (colContainer) { + if ('f7DestroyCalendarEvents' in p.container[0]) p.container[0].f7DestroyCalendarEvents(); + }; + + // Calendar Methods + p.daysInMonth = function (date) { + var d = new Date(date); + return new Date(d.getFullYear(), d.getMonth() + 1, 0).getDate(); + }; + p.monthHTML = function (date, offset) { + date = new Date(date); + var year = date.getFullYear(), + month = date.getMonth(), + day = date.getDate(); + if (offset === 'next') { + if (month === 11) date = new Date(year + 1, 0); + else date = new Date(year, month + 1, 1); + } + if (offset === 'prev') { + if (month === 0) date = new Date(year - 1, 11); + else date = new Date(year, month - 1, 1); + } + if (offset === 'next' || offset === 'prev') { + month = date.getMonth(); + year = date.getFullYear(); + } + var daysInPrevMonth = p.daysInMonth(new Date(date.getFullYear(), date.getMonth()).getTime() - 10 * 24 * 60 * 60 * 1000), + daysInMonth = p.daysInMonth(date), + firstDayOfMonthIndex = new Date(date.getFullYear(), date.getMonth()).getDay(); + if (firstDayOfMonthIndex === 0) firstDayOfMonthIndex = 7; + + var dayDate, currentValues = [], i, j, + rows = 6, cols = 7, + monthHTML = '', + dayIndex = 0 + (p.params.firstDay - 1), + today = new Date().setHours(0,0,0,0), + minDate = p.params.minDate ? new Date(p.params.minDate).getTime() : null, + maxDate = p.params.maxDate ? new Date(p.params.maxDate).getTime() : null; + + if (p.value && p.value.length) { + for (i = 0; i < p.value.length; i++) { + currentValues.push(new Date(p.value[i]).setHours(0,0,0,0)); + } + } + + for (i = 1; i <= rows; i++) { + var rowHTML = ''; + var row = i; + for (j = 1; j <= cols; j++) { + var col = j; + dayIndex ++; + var dayNumber = dayIndex - firstDayOfMonthIndex; + var addClass = ''; + if (dayNumber < 0) { + dayNumber = daysInPrevMonth + dayNumber + 1; + addClass += ' picker-calendar-day-prev'; + dayDate = new Date(month - 1 < 0 ? year - 1 : year, month - 1 < 0 ? 11 : month - 1, dayNumber).getTime(); + } + else { + dayNumber = dayNumber + 1; + if (dayNumber > daysInMonth) { + dayNumber = dayNumber - daysInMonth; + addClass += ' picker-calendar-day-next'; + dayDate = new Date(month + 1 > 11 ? year + 1 : year, month + 1 > 11 ? 0 : month + 1, dayNumber).getTime(); + } + else { + dayDate = new Date(year, month, dayNumber).getTime(); + } + } + // Today + if (dayDate === today) addClass += ' picker-calendar-day-today'; + // Selected + if (currentValues.indexOf(dayDate) >= 0) addClass += ' picker-calendar-day-selected'; + // Weekend + if (p.params.weekendDays.indexOf(col - 1) >= 0) { + addClass += ' picker-calendar-day-weekend'; + } + // Disabled + if ((minDate && dayDate < minDate) || (maxDate && dayDate > maxDate)) { + addClass += ' picker-calendar-day-disabled'; + } + + dayDate = new Date(dayDate); + var dayYear = dayDate.getFullYear(); + var dayMonth = dayDate.getMonth(); + rowHTML += '
    '+dayNumber+'
    '; + } + monthHTML += '
    ' + rowHTML + '
    '; + } + monthHTML = '
    ' + monthHTML + '
    '; + return monthHTML; + }; + p.animating = false; + p.updateCurrentMonthYear = function (dir) { + if (typeof dir === 'undefined') { + p.currentMonth = parseInt(p.months.eq(1).attr('data-month'), 10); + p.currentYear = parseInt(p.months.eq(1).attr('data-year'), 10); + } + else { + p.currentMonth = parseInt(p.months.eq(dir === 'next' ? (p.months.length - 1) : 0).attr('data-month'), 10); + p.currentYear = parseInt(p.months.eq(dir === 'next' ? (p.months.length - 1) : 0).attr('data-year'), 10); + } + p.container.find('.current-month-value').text(p.params.monthNames[p.currentMonth]); + p.container.find('.current-year-value').text(p.currentYear); + + }; + p.onMonthChangeStart = function (dir) { + p.updateCurrentMonthYear(dir); + p.months.removeClass('picker-calendar-month-current picker-calendar-month-prev picker-calendar-month-next'); + var currentIndex = dir === 'next' ? p.months.length - 1 : 0; + + p.months.eq(currentIndex).addClass('picker-calendar-month-current'); + p.months.eq(dir === 'next' ? currentIndex - 1 : currentIndex + 1).addClass(dir === 'next' ? 'picker-calendar-month-prev' : 'picker-calendar-month-next'); + + if (p.params.onMonthYearChangeStart) { + p.params.onMonthYearChangeStart(p, p.currentYear, p.currentMonth); + } + }; + p.onMonthChangeEnd = function (dir, rebuildBoth) { + p.animating = false; + var nextMonthHTML, prevMonthHTML, newMonthHTML; + p.wrapper.find('.picker-calendar-month:not(.picker-calendar-month-prev):not(.picker-calendar-month-current):not(.picker-calendar-month-next)').remove(); + + if (typeof dir === 'undefined') { + dir = 'next'; + rebuildBoth = true; + } + if (!rebuildBoth) { + newMonthHTML = p.monthHTML(new Date(p.currentYear, p.currentMonth), dir); + } + else { + p.wrapper.find('.picker-calendar-month-next, .picker-calendar-month-prev').remove(); + prevMonthHTML = p.monthHTML(new Date(p.currentYear, p.currentMonth), 'prev'); + nextMonthHTML = p.monthHTML(new Date(p.currentYear, p.currentMonth), 'next'); + } + if (dir === 'next' || rebuildBoth) { + p.wrapper.append(newMonthHTML || nextMonthHTML); + } + if (dir === 'prev' || rebuildBoth) { + p.wrapper.prepend(newMonthHTML || prevMonthHTML); + } + p.months = p.wrapper.find('.picker-calendar-month'); + p.setMonthsTranslate(p.monthsTranslate); + if (p.params.onMonthAdd) { + p.params.onMonthAdd(p, dir === 'next' ? p.months.eq(p.months.length - 1)[0] : p.months.eq(0)[0]); + } + if (p.params.onMonthYearChangeEnd) { + p.params.onMonthYearChangeEnd(p, p.currentYear, p.currentMonth); + } + }; + p.setMonthsTranslate = function (translate) { + translate = translate || p.monthsTranslate || 0; + if (typeof p.monthsTranslate === 'undefined') p.monthsTranslate = translate; + p.months.removeClass('picker-calendar-month-current picker-calendar-month-prev picker-calendar-month-next'); + var prevMonthTranslate = -(translate + 1) * 100 * inverter; + var currentMonthTranslate = -translate * 100 * inverter; + var nextMonthTranslate = -(translate - 1) * 100 * inverter; + p.months.eq(0).transform('translate3d(' + (p.isH ? prevMonthTranslate : 0) + '%, ' + (p.isH ? 0 : prevMonthTranslate) + '%, 0)').addClass('picker-calendar-month-prev'); + p.months.eq(1).transform('translate3d(' + (p.isH ? currentMonthTranslate : 0) + '%, ' + (p.isH ? 0 : currentMonthTranslate) + '%, 0)').addClass('picker-calendar-month-current'); + p.months.eq(2).transform('translate3d(' + (p.isH ? nextMonthTranslate : 0) + '%, ' + (p.isH ? 0 : nextMonthTranslate) + '%, 0)').addClass('picker-calendar-month-next'); + }; + p.nextMonth = function (transition) { + if (typeof transition === 'undefined' || typeof transition === 'object') { + transition = ''; + if (!p.params.animate) transition = 0; + } + var nextMonth = parseInt(p.months.eq(p.months.length - 1).attr('data-month'), 10); + var nextYear = parseInt(p.months.eq(p.months.length - 1).attr('data-year'), 10); + var nextDate = new Date(nextYear, nextMonth); + var nextDateTime = nextDate.getTime(); + var transitionEndCallback = p.animating ? false : true; + if (p.params.maxDate) { + if (nextDateTime > new Date(p.params.maxDate).getTime()) { + return p.resetMonth(); + } + } + p.monthsTranslate --; + if (nextMonth === p.currentMonth) { + var nextMonthTranslate = -(p.monthsTranslate) * 100 * inverter; + var nextMonthHTML = $(p.monthHTML(nextDateTime, 'next')).transform('translate3d(' + (p.isH ? nextMonthTranslate : 0) + '%, ' + (p.isH ? 0 : nextMonthTranslate) + '%, 0)').addClass('picker-calendar-month-next'); + p.wrapper.append(nextMonthHTML[0]); + p.months = p.wrapper.find('.picker-calendar-month'); + if (p.params.onMonthAdd) { + p.params.onMonthAdd(p, p.months.eq(p.months.length - 1)[0]); + } + } + p.animating = true; + p.onMonthChangeStart('next'); + var translate = (p.monthsTranslate * 100) * inverter; + + p.wrapper.transition(transition).transform('translate3d(' + (p.isH ? translate : 0) + '%, ' + (p.isH ? 0 : translate) + '%, 0)'); + if (transitionEndCallback) { + p.wrapper.transitionEnd(function () { + p.onMonthChangeEnd('next'); + }); + } + if (!p.params.animate) { + p.onMonthChangeEnd('next'); + } + }; + p.prevMonth = function (transition) { + if (typeof transition === 'undefined' || typeof transition === 'object') { + transition = ''; + if (!p.params.animate) transition = 0; + } + var prevMonth = parseInt(p.months.eq(0).attr('data-month'), 10); + var prevYear = parseInt(p.months.eq(0).attr('data-year'), 10); + var prevDate = new Date(prevYear, prevMonth + 1, -1); + var prevDateTime = prevDate.getTime(); + var transitionEndCallback = p.animating ? false : true; + if (p.params.minDate) { + if (prevDateTime < new Date(p.params.minDate).getTime()) { + return p.resetMonth(); + } + } + p.monthsTranslate ++; + if (prevMonth === p.currentMonth) { + var prevMonthTranslate = -(p.monthsTranslate) * 100 * inverter; + var prevMonthHTML = $(p.monthHTML(prevDateTime, 'prev')).transform('translate3d(' + (p.isH ? prevMonthTranslate : 0) + '%, ' + (p.isH ? 0 : prevMonthTranslate) + '%, 0)').addClass('picker-calendar-month-prev'); + p.wrapper.prepend(prevMonthHTML[0]); + p.months = p.wrapper.find('.picker-calendar-month'); + if (p.params.onMonthAdd) { + p.params.onMonthAdd(p, p.months.eq(0)[0]); + } + } + p.animating = true; + p.onMonthChangeStart('prev'); + var translate = (p.monthsTranslate * 100) * inverter; + p.wrapper.transition(transition).transform('translate3d(' + (p.isH ? translate : 0) + '%, ' + (p.isH ? 0 : translate) + '%, 0)'); + if (transitionEndCallback) { + p.wrapper.transitionEnd(function () { + p.onMonthChangeEnd('prev'); + }); + } + if (!p.params.animate) { + p.onMonthChangeEnd('prev'); + } + }; + p.resetMonth = function (transition) { + if (typeof transition === 'undefined') transition = ''; + var translate = (p.monthsTranslate * 100) * inverter; + p.wrapper.transition(transition).transform('translate3d(' + (p.isH ? translate : 0) + '%, ' + (p.isH ? 0 : translate) + '%, 0)'); + }; + p.setYearMonth = function (year, month, transition) { + if (typeof year === 'undefined') year = p.currentYear; + if (typeof month === 'undefined') month = p.currentMonth; + if (typeof transition === 'undefined' || typeof transition === 'object') { + transition = ''; + if (!p.params.animate) transition = 0; + } + var targetDate; + if (year < p.currentYear) { + targetDate = new Date(year, month + 1, -1).getTime(); + } + else { + targetDate = new Date(year, month).getTime(); + } + if (p.params.maxDate && targetDate > new Date(p.params.maxDate).getTime()) { + return false; + } + if (p.params.minDate && targetDate < new Date(p.params.minDate).getTime()) { + return false; + } + var currentDate = new Date(p.currentYear, p.currentMonth).getTime(); + var dir = targetDate > currentDate ? 'next' : 'prev'; + var newMonthHTML = p.monthHTML(new Date(year, month)); + p.monthsTranslate = p.monthsTranslate || 0; + var prevTranslate = p.monthsTranslate; + var monthTranslate, wrapperTranslate; + var transitionEndCallback = p.animating ? false : true; + if (targetDate > currentDate) { + // To next + p.monthsTranslate --; + if (!p.animating) p.months.eq(p.months.length - 1).remove(); + p.wrapper.append(newMonthHTML); + p.months = p.wrapper.find('.picker-calendar-month'); + monthTranslate = -(prevTranslate - 1) * 100 * inverter; + p.months.eq(p.months.length - 1).transform('translate3d(' + (p.isH ? monthTranslate : 0) + '%, ' + (p.isH ? 0 : monthTranslate) + '%, 0)').addClass('picker-calendar-month-next'); + } + else { + // To prev + p.monthsTranslate ++; + if (!p.animating) p.months.eq(0).remove(); + p.wrapper.prepend(newMonthHTML); + p.months = p.wrapper.find('.picker-calendar-month'); + monthTranslate = -(prevTranslate + 1) * 100 * inverter; + p.months.eq(0).transform('translate3d(' + (p.isH ? monthTranslate : 0) + '%, ' + (p.isH ? 0 : monthTranslate) + '%, 0)').addClass('picker-calendar-month-prev'); + } + if (p.params.onMonthAdd) { + p.params.onMonthAdd(p, dir === 'next' ? p.months.eq(p.months.length - 1)[0] : p.months.eq(0)[0]); + } + p.animating = true; + p.onMonthChangeStart(dir); + wrapperTranslate = (p.monthsTranslate * 100) * inverter; + p.wrapper.transition(transition).transform('translate3d(' + (p.isH ? wrapperTranslate : 0) + '%, ' + (p.isH ? 0 : wrapperTranslate) + '%, 0)'); + if (transitionEndCallback) { + p.wrapper.transitionEnd(function () { + p.onMonthChangeEnd(dir, true); + }); + } + if (!p.params.animate) { + p.onMonthChangeEnd(dir); + } + }; + p.nextYear = function () { + p.setYearMonth(p.currentYear + 1); + }; + p.prevYear = function () { + p.setYearMonth(p.currentYear - 1); + }; + + + // HTML Layout + p.layout = function () { + var pickerHTML = ''; + var pickerClass = ''; + var i; + + var layoutDate = p.value && p.value.length ? p.value[0] : new Date().setHours(0,0,0,0); + var prevMonthHTML = p.monthHTML(layoutDate, 'prev'); + var currentMonthHTML = p.monthHTML(layoutDate); + var nextMonthHTML = p.monthHTML(layoutDate, 'next'); + var monthsHTML = '
    ' + (prevMonthHTML + currentMonthHTML + nextMonthHTML) + '
    '; + // Week days header + var weekHeaderHTML = ''; + if (p.params.weekHeader) { + for (i = 0; i < 7; i++) { + var weekDayIndex = (i + p.params.firstDay > 6) ? (i - 7 + p.params.firstDay) : (i + p.params.firstDay); + var dayName = p.params.dayNamesShort[weekDayIndex]; + weekHeaderHTML += '
    ' + dayName + '
    '; + + } + weekHeaderHTML = '
    ' + weekHeaderHTML + '
    '; + } + pickerClass = 'weui-picker-calendar ' + (p.params.cssClass || ''); + if(!p.inline) pickerClass = 'weui-picker-modal ' + pickerClass; + var toolbarHTML = p.params.toolbar ? p.params.toolbarTemplate.replace(/{{closeText}}/g, p.params.toolbarCloseText) : ''; + if (p.params.toolbar) { + toolbarHTML = p.params.toolbarTemplate + .replace(/{{closeText}}/g, p.params.toolbarCloseText) + .replace(/{{monthPicker}}/g, (p.params.monthPicker ? p.params.monthPickerTemplate : '')) + .replace(/{{yearPicker}}/g, (p.params.yearPicker ? p.params.yearPickerTemplate : '')); + } + + pickerHTML = + '
    ' + + toolbarHTML + + '
    ' + + weekHeaderHTML + + monthsHTML + + '
    ' + + '
    '; + + + p.pickerHTML = pickerHTML; + }; + + // Input Events + function openOnInput(e) { + e.preventDefault(); + if (p.opened) return; + p.open(); + if (p.params.scrollToInput && !isPopover()) { + var pageContent = p.input.parents('.page-content'); + if (pageContent.length === 0) return; + + var paddingTop = parseInt(pageContent.css('padding-top'), 10), + paddingBottom = parseInt(pageContent.css('padding-bottom'), 10), + pageHeight = pageContent[0].offsetHeight - paddingTop - p.container.height(), + pageScrollHeight = pageContent[0].scrollHeight - paddingTop - p.container.height(), + newPaddingBottom; + + var inputTop = p.input.offset().top - paddingTop + p.input[0].offsetHeight; + if (inputTop > pageHeight) { + var scrollTop = pageContent.scrollTop() + inputTop - pageHeight; + if (scrollTop + pageHeight > pageScrollHeight) { + newPaddingBottom = scrollTop + pageHeight - pageScrollHeight + paddingBottom; + if (pageHeight === pageScrollHeight) { + newPaddingBottom = p.container.height(); + } + pageContent.css({'padding-bottom': (newPaddingBottom) + 'px'}); + } + pageContent.scrollTop(scrollTop, 300); + } + } + } + function closeOnHTMLClick(e) { + if (inPopover()) return; + if (p.input && p.input.length > 0) { + if (e.target !== p.input[0] && $(e.target).parents('.weui-picker-modal').length === 0) p.close(); + } + else { + if ($(e.target).parents('.weui-picker-modal').length === 0) p.close(); + } + } + + if (p.params.input) { + p.input = $(p.params.input); + if (p.input.length > 0) { + if (p.params.inputReadOnly) p.input.prop('readOnly', true); + if (!p.inline) { + p.input.on('click', openOnInput); + } + if (p.params.inputReadOnly) { + p.input.on('focus mousedown', function (e) { + e.preventDefault(); + }); + } + } + + } + + //iphone 上无法正确触发 click,会导致点击外面无法关闭 + if (!p.inline) $(document).on('click touchend', closeOnHTMLClick); + + // Open + function onPickerClose() { + p.opened = false; + if (p.input && p.input.length > 0) p.input.parents('.page-content').css({'padding-bottom': ''}); + if (p.params.onClose) p.params.onClose(p); + + // Destroy events + p.destroyCalendarEvents(); + } + + p.opened = false; + p.open = function () { + var toPopover = isPopover() && false; + var updateValue = false; + if (!p.opened) { + // Set date value + if (!p.value) { + if (p.params.value) { + p.value = p.params.value; + updateValue = true; + } + } + + // Layout + p.layout(); + + // Append + if (toPopover) { + p.pickerHTML = '
    ' + p.pickerHTML + '
    '; + p.popover = $.popover(p.pickerHTML, p.params.input, true); + p.container = $(p.popover).find('.weui-picker-modal'); + $(p.popover).on('close', function () { + onPickerClose(); + }); + } + else if (p.inline) { + p.container = $(p.pickerHTML); + p.container.addClass('picker-modal-inline'); + $(p.params.container).append(p.container); + } + else { + p.container = $($.openPicker(p.pickerHTML)); + $(p.container) + .on('close', function () { + onPickerClose(); + }); + } + + // Store calendar instance + p.container[0].f7Calendar = p; + p.wrapper = p.container.find('.picker-calendar-months-wrapper'); + + // Months + p.months = p.wrapper.find('.picker-calendar-month'); + + // Update current month and year + p.updateCurrentMonthYear(); + + // Set initial translate + p.monthsTranslate = 0; + p.setMonthsTranslate(); + + // Init events + p.initCalendarEvents(); + + // Update input value + if (updateValue) p.updateValue(); + + } + + // Set flag + p.opened = true; + p.initialized = true; + if (p.params.onMonthAdd) { + p.months.each(function () { + p.params.onMonthAdd(p, this); + }); + } + if (p.params.onOpen) p.params.onOpen(p); + }; + + // Close + p.close = function () { + if (!p.opened || p.inline) return; + p.animating = false; //有可能还有动画没做完,因此animating设置还没改。 + if (inPopover()) { + $.closePicker(p.popover); + return; + } + else { + $.closePicker(p.container); + return; + } + }; + + // Destroy + p.destroy = function () { + p.close(); + if (p.params.input && p.input.length > 0) { + p.input.off('click focus', openOnInput); + p.input.data("calendar", null); + } + $('html').off('click', closeOnHTMLClick); + }; + + if (p.inline) { + p.open(); + } + + return p; + }; + + var format = function(d) { + return d < 10 ? "0"+d : d; + } + + + $.fn.calendar = function (params, args) { + params = params || {}; + return this.each(function() { + var $this = $(this); + if(!$this[0]) return; + var p = {}; + if($this[0].tagName.toUpperCase() === "INPUT") { + p.input = $this; + } else { + p.container = $this; + } + + var calendar = $this.data("calendar"); + + if(!calendar) { + if(typeof params === typeof "a") { + } else { + if(!params.value && $this.val()) params.value = [$this.val()]; + //默认显示今天 + if(!params.value) { + var today = new Date(); + params.value = [today.getFullYear() + "/" + format(today.getMonth() + 1) + "/" + format(today.getDate())]; + } + calendar = $this.data("calendar", new Calendar($.extend(p, params))); + } + } + + if(typeof params === typeof "a") { + calendar[params].call(calendar, args); + } + }); + }; + + defaults = $.fn.calendar.prototype.defaults = { + value: undefined, // 通过JS赋值,注意是数组 + monthNames: ['一月', '二月', '三月', '四月', '五月', '六月', '七月', '八月', '九月', '十月', '十一月', '十二月'], + monthNamesShort: ['一月', '二月', '三月', '四月', '五月', '六月', '七月', '八月', '九月', '十月', '十一月', '十二月'], + dayNames: ['周日', '周一', '周二', '周三', '周四', '周五', '周六'], + dayNamesShort: ['周日', '周一', '周二', '周三', '周四', '周五', '周六'], + firstDay: 1, // First day of the week, Monday + weekendDays: [0, 6], // Sunday and Saturday + multiple: false, + dateFormat: 'yyyy/mm/dd', + direction: 'horizontal', // or 'vertical' + minDate: null, + maxDate: null, + touchMove: true, + animate: true, + closeOnSelect: true, + monthPicker: true, + monthPickerTemplate: + '
    ' + + '' + + '
    ' + + '' + + '
    ', + yearPicker: true, + yearPickerTemplate: + '
    ' + + '' + + '' + + '' + + '
    ', + weekHeader: true, + // Common settings + scrollToInput: true, + inputReadOnly: true, + convertToPopover: true, + onlyInPopover: false, + toolbar: true, + toolbarCloseText: 'Done', + toolbarTemplate: + '
    ' + + '
    ' + + '{{yearPicker}}' + + '{{monthPicker}}' + + // '{{closeText}}' + + '
    ' + + '
    ', + /* Callbacks + onMonthAdd + onChange + onOpen + onClose + onDayClick + onMonthYearChangeStart + onMonthYearChangeEnd + */ + }; + +}($); + +/* global $:true */ +/* jshint unused:false*/ + ++ function($) { + "use strict"; + + + var defaults; + + var formatNumber = function (n) { + return n < 10 ? "0" + n : n; + } + + var Datetime = function(input, params) { + this.input = $(input); + this.params = params || {}; + + this.initMonthes = params.monthes + + this.initYears = params.years + + var p = $.extend({}, params, this.getConfig()); + $(this.input).picker(p); + } + + Datetime.prototype = { + getDays : function(max) { + var days = []; + for(var i=1; i<= (max||31);i++) { + days.push(i < 10 ? "0"+i : i); + } + return days; + }, + + getDaysByMonthAndYear : function(month, year) { + var int_d = new Date(year, parseInt(month)+1-1, 1); + var d = new Date(int_d - 1); + return this.getDays(d.getDate()); + }, + getConfig: function() { + var today = new Date(), + params = this.params, + self = this, + lastValidValues; + + var config = { + rotateEffect: false, //为了性能 + cssClass: 'datetime-picker', + + value: [today.getFullYear(), formatNumber(today.getMonth()+1), formatNumber(today.getDate()), formatNumber(today.getHours()), (formatNumber(today.getMinutes()))], + + onChange: function (picker, values, displayValues) { + var cols = picker.cols; + var days = self.getDaysByMonthAndYear(values[1], values[0]); + var currentValue = values[2]; + if(currentValue > days.length) currentValue = days.length; + picker.cols[4].setValue(currentValue); + + //check min and max + var current = new Date(values[0]+'-'+values[1]+'-'+values[2]); + var valid = true; + if(params.min) { + var min = new Date(typeof params.min === "function" ? params.min() : params.min); + + if(current < +min) { + picker.setValue(lastValidValues); + valid = false; + } + } + if(params.max) { + var max = new Date(typeof params.max === "function" ? params.max() : params.max); + if(current > +max) { + picker.setValue(lastValidValues); + valid = false; + } + } + + valid && (lastValidValues = values); + + if (self.params.onChange) { + self.params.onChange.apply(this, arguments); + } + }, + + formatValue: function (p, values, displayValues) { + return self.params.format(p, values, displayValues); + }, + + cols: [ + { + values: this.initYears + }, + { + divider: true, // 这是一个分隔符 + content: params.yearSplit + }, + { + values: this.initMonthes + }, + { + divider: true, // 这是一个分隔符 + content: params.monthSplit + }, + { + values: (function () { + var dates = []; + for (var i=1; i<=31; i++) dates.push(formatNumber(i)); + return dates; + })() + }, + + ] + } + + if (params.dateSplit) { + config.cols.push({ + divider: true, + content: params.dateSplit + }) + } + + config.cols.push({ + divider: true, + content: params.datetimeSplit + }) + + var times = self.params.times(); + if (times && times.length) { + config.cols = config.cols.concat(times); + } + + var inputValue = this.input.val(); + if(inputValue) config.value = params.parse(inputValue); + if(this.params.value) { + this.input.val(this.params.value); + config.value = params.parse(this.params.value); + } + + return config; + } + } + + $.fn.datetimePicker = function(params) { + params = $.extend({}, defaults, params); + return this.each(function() { + if(!this) return; + var $this = $(this); + var datetime = $this.data("datetime"); + if(!datetime) $this.data("datetime", new Datetime(this, params)); + return datetime; + }); + }; + + defaults = $.fn.datetimePicker.prototype.defaults = { + input: undefined, // 默认值 + min: undefined, // YYYY-MM-DD 最大最小值只比较年月日,不比较时分秒 + max: undefined, // YYYY-MM-DD + yearSplit: '-', + monthSplit: '-', + dateSplit: '', // 默认为空 + datetimeSplit: ' ', // 日期和时间之间的分隔符,不可为空 + monthes: ('01 02 03 04 05 06 07 08 09 10 11 12').split(' '), + years: (function () { + var arr = []; + for (var i = 1950; i <= 2030; i++) { arr.push(i); } + return arr; + })(), + times: function () { + return [ // 自定义的时间 + { + values: (function () { + var hours = []; + for (var i=0; i<24; i++) hours.push(formatNumber(i)); + return hours; + })() + }, + { + divider: true, // 这是一个分隔符 + content: ':' + }, + { + values: (function () { + var minutes = []; + for (var i=0; i<60; i++) minutes.push(formatNumber(i)); + return minutes; + })() + } + ]; + }, + format: function (p, values) { // 数组转换成字符串 + return p.cols.map(function (col) { + return col.value || col.content; + }).join(''); + }, + parse: function (str) { + // 把字符串转换成数组,用来解析初始值 + // 如果你的定制的初始值格式无法被这个默认函数解析,请自定义这个函数。比如你的时间是 '子时' 那么默认情况这个'时'会被当做分隔符而导致错误,所以你需要自己定义parse函数 + // 默认兼容的分隔符 + var t = str.split(this.datetimeSplit); + return t[0].split(/\D/).concat(t[1].split(/:|时|分|秒/)).filter(function (d) { + return !!d; + }) + } + } + +}($); + +/*====================================================== +************ Picker ************ +======================================================*/ +/* global $:true */ + ++ function($) { + "use strict"; + + + //Popup 和 picker 之类的不要共用一个弹出方法,因为这样会导致 在 popup 中再弹出 picker 的时候会有问题。 + + $.openPopup = function(popup, className) { + + $.closePopup(); + + popup = $(popup); + popup.show(); + popup.width(); + popup.addClass("weui-popup__container--visible"); + var modal = popup.find(".weui-popup__modal"); + modal.width(); + modal.transitionEnd(function() { + modal.trigger("open"); + }); + } + + + $.closePopup = function(container, remove) { + container = $(container || ".weui-popup__container--visible"); + container.find('.weui-popup__modal').transitionEnd(function() { + var $this = $(this); + $this.trigger("close"); + container.hide(); + remove && container.remove(); + }) + container.removeClass("weui-popup__container--visible") + }; + + + $(document).on("click", ".close-popup, .weui-popup__overlay", function() { + $.closePopup(); + }) + .on("click", ".open-popup", function() { + $($(this).data("target")).popup(); + }) + .on("click", ".weui-popup__container", function(e) { + if($(e.target).hasClass("weui-popup__container")) $.closePopup(); + }) + + $.fn.popup = function() { + return this.each(function() { + $.openPopup(this); + }); + }; + +}($); + +/* =============================================================================== +************ Notification ************ +=============================================================================== */ +/* global $:true */ ++function ($) { + "use strict"; + + var noti, defaults, timeout, start, diffX, diffY; + + var touchStart = function(e) { + var p = $.getTouchPosition(e); + start = p; + diffX = diffY = 0; + noti.addClass("touching"); + }; + var touchMove = function(e) { + if(!start) return false; + e.preventDefault(); + e.stopPropagation(); + var p = $.getTouchPosition(e); + diffX = p.x - start.x; + diffY = p.y - start.y; + if(diffY > 0) { + diffY = Math.sqrt(diffY); + } + + noti.css("transform", "translate3d(0, "+diffY+"px, 0)"); + }; + var touchEnd = function() { + noti.removeClass("touching"); + noti.attr("style", ""); + if(diffY < 0 && (Math.abs(diffY) > noti.height()*0.38)) { + $.closeNotification(); + } + + if(Math.abs(diffX) <= 1 && Math.abs(diffY) <= 1) { + noti.trigger("noti-click"); + } + + start = false; + }; + + var attachEvents = function(el) { + el.on($.touchEvents.start, touchStart); + el.on($.touchEvents.move, touchMove); + el.on($.touchEvents.end, touchEnd); + }; + + $.notification = $.noti = function(params) { + params = $.extend({}, defaults, params); + noti = $(".weui-notification"); + if(!noti[0]) { // create a new notification + noti = $('
    ').appendTo(document.body); + attachEvents(noti); + } + + noti.off("noti-click"); //the click event is not correct sometime: it will trigger when user is draging. + if(params.onClick) noti.on("noti-click", function() { + params.onClick(params.data); + }); + + noti.html($.t7.compile(params.tpl)(params)); + + noti.show(); + + noti.addClass("weui-notification--in"); + noti.data("params", params); + + var startTimeout = function() { + if(timeout) { + clearTimeout(timeout); + timeout = null; + } + + timeout = setTimeout(function() { + if(noti.hasClass("weui-notification--touching")) { + startTimeout(); + } else { + $.closeNotification(); + } + }, params.time); + }; + + startTimeout(); + + }; + + $.closeNotification = function() { + timeout && clearTimeout(timeout); + timeout = null; + var noti = $(".weui-notification").removeClass("weui-notification--in").transitionEnd(function() { + $(this).remove(); + }); + + if(noti[0]) { + var params = $(".weui-notification").data("params"); + if(params && params.onClose) { + params.onClose(params.data); + } + } + }; + + defaults = $.noti.prototype.defaults = { + title: undefined, + text: undefined, + media: undefined, + time: 4000, + onClick: undefined, + onClose: undefined, + data: undefined, + tpl: '
    ' + + '{{#if media}}
    {{media}}
    {{/if}}' + + '
    ' + + '{{#if title}}
    {{title}}
    {{/if}}' + + '{{#if text}}
    {{text}}
    {{/if}}' + + '
    ' + + '
    ' + + '
    ' + }; + +}($); + ++ function($) { + "use strict"; + + var timeout; + + $.toptip = function(text, duration, type) { + if(!text) return; + if(typeof duration === typeof "a") { + type = duration; + duration = undefined; + } + duration = duration || 3000; + var className = type ? 'bg-' + type : 'bg-danger'; + var $t = $('.weui-toptips').remove(); + $t = $('
    ').appendTo(document.body); + $t.html(text); + $t[0].className = 'weui-toptips ' + className + + clearTimeout(timeout); + + if(!$t.hasClass('weui-toptips_visible')) { + $t.show().width(); + $t.addClass('weui-toptips_visible'); + } + + timeout = setTimeout(function() { + $t.removeClass('weui-toptips_visible').transitionEnd(function() { + $t.remove(); + }); + }, duration); + } +}($); + +/* global $:true */ ++ function($) { + "use strict"; + var Slider = function (container, arg) { + this.container = $(container); + this.handler = this.container.find('.weui-slider__handler') + this.track = this.container.find('.weui-slider__track') + this.value = this.container.find('.weui-slider-box__value') + this.bind() + if (typeof arg === 'function') { + this.callback = arg + } + } + + Slider.prototype.bind = function () { + this.container + .on($.touchEvents.start, $.proxy(this.touchStart, this)) + .on($.touchEvents.end, $.proxy(this.touchEnd, this)); + $(document.body).on($.touchEvents.move, $.proxy(this.touchMove, this)) // move even outside container + } + + Slider.prototype.touchStart = function (e) { + e.preventDefault() + this.start = $.getTouchPosition(e) + this.width = this.container.find('.weui-slider__inner').width() + this.left = parseInt(this.container.find('.weui-slider__handler').css('left')) + this.touching = true + } + + Slider.prototype.touchMove = function (e) { + if (!this.touching) return true + var p = $.getTouchPosition(e) + var distance = p.x - this.start.x + var left = distance + this.left + var per = parseInt(left / this.width * 100) + if (per < 0) per = 0 + if (per > 100) per = 100 + this.handler.css('left', per + '%') + this.track.css('width', per + '%') + this.value.text(per) + this.callback && this.callback.call(this, per) + this.container.trigger('change', per) + } + + Slider.prototype.touchEnd = function (e) { + this.touching = false + } + + $.fn.slider = function (arg) { + this.each(function () { + var $this = $(this) + var slider = $this.data('slider') + if (slider) return slider; + else $this.data('slider', new Slider(this, arg)) + }) + } +}($); + +/* =============================================================================== +************ Swipeout ************ +=============================================================================== */ +/* global $:true */ + ++function ($) { + "use strict"; + + var cache = []; + var TOUCHING = 'swipeout-touching' + + var Swipeout = function(el) { + this.container = $(el); + this.mover = this.container.find('>.weui-cell__bd') + this.attachEvents(); + cache.push(this) + } + + Swipeout.prototype.touchStart = function(e) { + var p = $.getTouchPosition(e); + this.container.addClass(TOUCHING); + this.start = p; + this.startX = 0; + this.startTime = + new Date; + var transform = this.mover.css('transform').match(/-?[\d\.]+/g) + if (transform && transform.length) this.startX = parseInt(transform[4]) + this.diffX = this.diffY = 0; + this._closeOthers() + this.limit = this.container.find('>.weui-cell__ft').width() || 68; // 因为有的时候初始化的时候元素是隐藏的(比如在对话框内),所以在touchstart的时候计算宽度而不是初始化的时候 + }; + + Swipeout.prototype.touchMove= function(e) { + if(!this.start) return true; + var p = $.getTouchPosition(e); + this.diffX = p.x - this.start.x; + this.diffY = p.y - this.start.y; + if (Math.abs(this.diffX) < Math.abs(this.diffY)) { // 说明是上下方向在拖动 + this.close() + this.start = false + return true; + } + e.preventDefault(); + e.stopPropagation(); + var x = this.diffX + this.startX + if (x > 0) x = 0; + if (Math.abs(x) > this.limit) x = - (Math.pow(-(x+this.limit), .7) + this.limit) + this.mover.css("transform", "translate3d("+x+"px, 0, 0)"); + }; + Swipeout.prototype.touchEnd = function() { + if (!this.start) return true; + this.start = false; + var x = this.diffX + this.startX + var t = new Date - this.startTime; + if (this.diffX < -5 && t < 200) { // 向左快速滑动,则打开 + this.open() + } else if (this.diffX >= 0 && t < 200) { // 向右快速滑动,或者单击,则关闭 + this.close() + } else if (x > 0 || -x <= this.limit / 2) { + this.close() + } else { + this.open() + } + }; + + + Swipeout.prototype.close = function() { + this.container.removeClass(TOUCHING); + this.mover.css("transform", "translate3d(0, 0, 0)"); + this.container.trigger('swipeout-close'); + } + + Swipeout.prototype.open = function() { + this.container.removeClass(TOUCHING); + this._closeOthers() + this.mover.css("transform", "translate3d(" + (-this.limit) + "px, 0, 0)"); + this.container.trigger('swipeout-open'); + } + + Swipeout.prototype.attachEvents = function() { + var el = this.mover; + el.on($.touchEvents.start, $.proxy(this.touchStart, this)); + el.on($.touchEvents.move, $.proxy(this.touchMove, this)); + el.on($.touchEvents.end, $.proxy(this.touchEnd, this)); + } + Swipeout.prototype._closeOthers = function() { + //close others + var self = this + cache.forEach(function (s) { + if (s !== self) s.close() + }) + } + + var swipeout = function(el) { + return new Swipeout(el); + }; + + $.fn.swipeout = function (arg) { + return this.each(function() { + var $this = $(this) + var s = $this.data('swipeout') || swipeout(this); + $this.data('swipeout', s); + + if (typeof arg === typeof 'a') { + s[arg]() + } + }); + } + + $('.weui-cell_swiped').swipeout() // auto init +}($); diff --git a/static/js/common.js b/static/js/common.js index 52eacaa..7217737 100644 --- a/static/js/common.js +++ b/static/js/common.js @@ -235,7 +235,8 @@ function mb_strlen(str) { function mb_cutstr(str, maxlen, dot) { var len = 0; var ret = ''; - var dot = !dot ? '...' : dot; + var dot = (dot != '' && !dot) ? '...' : dot; + maxlen = maxlen - dot.length; for(var i = 0; i < str.length; i++) { len += str.charCodeAt(i) < 0 || str.charCodeAt(i) > 255 ? (charset == 'utf-8' ? 3 : 2) : 1; @@ -2032,7 +2033,7 @@ function Confirm(msg,callback) showDialog(msg, 'confirm', __lang.confirm_message, callback, 1); }; -function showWindow(k, url, mode, cache, menuv) { +function showWindow(k, url, mode, cache, showWindow_callback) { mode = isUndefined(mode) ? 'get' : mode; cache = isUndefined(cache) ? 1 : cache; var menuid = 'fwin_' + k; @@ -2128,6 +2129,8 @@ function showWindow(k, url, mode, cache, menuv) { } else { show(); } + + if(typeof showWindow_callback == 'function') window.showWindow_callback=showWindow_callback; doane(); } @@ -2498,8 +2501,13 @@ var AttachEvent=function(e,el){ function dfire(e){ jQuery(document).trigger(e); } - - +/*修复url 没有?的时候第一个&改为?*/ +function correcturl(url){ + if(url && url.indexOf('?')===-1){ + url=url.replace(/&/i,'?'); + } + return url; +} diff --git a/static/js/input_field.js b/static/js/input_field.js index 0510d62..fb37c11 100644 --- a/static/js/input_field.js +++ b/static/js/input_field.js @@ -2,23 +2,35 @@ var InputAnimate = {}; (function($){ InputAnimate.init = function(obj){ var self = this; + self.what = true; self.box = obj; - self.label = self.box.find('.input-label'); - var length = obj.find('.input-animate').length; - if(self.box.hasClass('disabled')){//需要disabled时 - self.box.find('input.form-control,button.form-control,textarea.form-control,select.form-control,.tagsinput input').attr("disabled",true); + if(obj.hasClass('input-animate')){ + self.what = false; } - obj.find('.input-animate').each(function(i){ - var inputs = $(this).find('input.form-control,button.form-control,textarea.form-control,select.form-control,.tagsinput input'); - if(self.box.hasClass('input-float')){//是否为float样式 - self.float_style(inputs); - self.float_change(inputs); - }else if(self.box.hasClass('input-fixation') && (i == 0)){//是否为Fixation样式 - self.fixation_style($(this)); + self.inputs = self.box.find('input.form-control,button.form-control,textarea.form-control,select.form-control,.tagsinput input'); + if(!self.inputs.length)return false; + if(self.what){ + self.label = self.box.find('.input-label'); + var length = obj.find('.input-animate').length; + if(self.box.hasClass('disabled')){//需要disabled时 + self.box.find('input.form-control,button.form-control,textarea.form-control,select.form-control,.tagsinput input').attr("disabled",true); } - self.input_style($(this),inputs,i,length); - self.input_event($(this),inputs);//绑定事件 - }) + obj.find('.input-animate').each(function(i){ + var inputs = $(this).find('input.form-control,button.form-control,textarea.form-control,select.form-control,.tagsinput input'); + if(self.box.hasClass('input-float')){//是否为float样式 + self.float_style(inputs); + self.float_change(inputs); + }else if(self.box.hasClass('input-fixation') && (i == 0)){//是否为Fixation样式 + self.fixation_style($(this)); + } + self.input_style($(this),inputs,i,length); + self.input_event($(this),inputs);//绑定事件 + }) + }else{ + self.input_style(self.box,self.inputs,1,2); + self.input_event(self.box,self.inputs);//绑定事件 + } + } InputAnimate.float_style = function(obj){ var self = this; @@ -73,11 +85,12 @@ var InputAnimate = {}; $(this).closest('.input-animate').removeClass('animate'); }); - self.label.on('click',function(){ - $(this).siblings('.input-animate').click(); - }) - - } + if(self.label){ + self.label.on('click',function(){ + $(this).siblings('.input-animate').click(); + }); + } + }; InputAnimate.float_change = function(obj){ obj.change(function(){ if($(this).closest('.tagsinput').length && $(this).closest('.input-animate').find('input.form-control').val()){//兼容tagsinput @@ -88,11 +101,11 @@ var InputAnimate = {}; $(this).closest('.input-black').removeClass('focus'); } }); - } + }; $(document).ready(function(){ $('.input-black').each(function() { InputAnimate.init($(this)); - }) - }) + }); + }); })(jQuery); \ No newline at end of file diff --git a/static/js/jquery.leftDrager.js b/static/js/jquery.leftDrager.js index 0c17ab8..f06eea1 100644 --- a/static/js/jquery.leftDrager.js +++ b/static/js/jquery.leftDrager.js @@ -22,15 +22,12 @@ var dragerWidth=$this.width(); var $leftContainer=$('.bs-left-container'); var $mainContainer=$('.bs-main-container'); - var isTopFixed=jQuery('.bs-top-container').hasClass('.navbar-fixed-top'); var oleft=((options.cookieid && getcookie(options.cookieid+'_width'))?parseInt(getcookie(options.cookieid+'_width')):$leftContainer.outerWidth(true))|| 0; var left=oleft; - var headerHeight=jQuery('.bs-top-container').outerHeight(true); var clientWidth = document.documentElement.clientWidth; - var clientHeight = document.documentElement.clientHeight; var setPosition=function(xx,flag){ xx=xx*1; - if(flag==true){ + if(flag===true){ if(xx<10){ left=oleft; dragerClick('hide'); @@ -47,61 +44,72 @@ } left=xx; - if(flag==true) oleft=left; + if(flag===true){ + oleft=left; + } $leftContainer.css('width',left); $mainContainer.css('marginLeft',left); var currentRightWidth = mainWidth - xx; $mainContainer.trigger('leftDrager_layout.changeWidthValue',[currentRightWidth]); $this.css('left',left); - - if(options.cookieid) setcookie(options.cookieid+'_width',left,options.cookietime); - } - var dragerClick=function(flag){ - if(flag=='hide'){ + if(options.cookieid){ + setcookie(options.cookieid+'_width',left,options.cookietime); + } + }; + var dragerClick=function(flag,nocookie){ + if(flag==='hide'){ $leftContainer.css('display','none'); $mainContainer.css('marginLeft',0); - $this.css('left',0).css('cursor','default'); - if(options.cookieid) setcookie(options.cookieid+'_isshow','hide',options.cookietime); + $this.css({'left':0,'cursor':'default'}); + if(options.cookieid && !nocookie) setcookie(options.cookieid+'_isshow','hide',options.cookietime); jQuery('.left-drager-op').addClass('left-drager-op2'); - }else if(flag=='show'){ - $leftContainer.css('display','block'); + }else if(flag==='show'){ + $leftContainer.css({width:left,'display':'block'}); $mainContainer.css('marginLeft',document.documentElement.clientWidthclientWidth) xx=clientWidth+ox-width; - if(xx-ox<=0) xx=ox; + if((xx-ox+width)>clientWidth){ + xx=clientWidth+ox-width; + } + if(xx-ox<=0){ + xx=ox; + } setPosition(xx-ox); }); $(document).mouseup(function(e) { $(document).off('mouseup').off('mousemove'); var xx=e.clientX; - if((xx-ox+width)>clientWidth) xx=clientWidth+ox-width; - if(xx-ox<=0) xx=ox; + if((xx-ox+width)>clientWidth){ + xx=clientWidth+ox-width; + } + if(xx-ox<=0){ + xx=ox; + } setPosition(xx-ox,true); }); }); - } + }; var Layout=function(){ var headerHeight=jQuery('.bs-top-container').outerHeight(true); @@ -110,89 +118,69 @@ jQuery('.bs-container').css('padding-top',isTopFixed?headerHeight:0); jQuery('.bs-left-container,.bs-main-container,.left-drager').css('height',clientHeight-headerHeight); jQuery('.left-drager,.bs-left-container').css('top',isTopFixed?headerHeight:0); - if(typeof(resizefunc)=='function') resizefunc(); + if(typeof(resizefunc)==='function'){ + resizefunc(); + } leftHide(); - } + }; var leftHide=function(){ if(document.documentElement.clientWidth'); - var sub_height = $this.find('.left-drager-sub').outerHeight(); - var width = $this.find('.left-drager-op').outerWidth(); -// nav.css('padding-left',width); - $this.find('.left-drager-op').css({'height':nav_height,'padding-top':(nav_height-sub_height)/2}); - - } - - } - var Cleate_Result = function(e){ - // 创建水波div - var _this = $this; - var px = e.clientX; - var py = e.clientY; - var id=parseInt(Math.random()*1000); - _this.find('.left-drager-op').append('
    '); - setTimeout(function(){ - _this.find('#wb_'+id).remove() - },500) - } - var Icon_trigger = function(){ - if($this.find('.left-drager-op').hasClass('left-drager-op1')){ - $this.find('.left-drager-sub').removeClass('left-setTimeout'); - $this.find('.left-drager-sub').html(''); - $this.find('.left-drager-sub').addClass('left-setTimeout1'); - + if(options.cookieid && getcookie(options.cookieid+'_isshow')){ + var isshow=getcookie(options.cookieid+'_isshow'); + if(isshow==='hide'){ + dragerClick('hide',true); + }else{ + dragerClick('show',true); + } }else{ - $this.find('.left-drager-sub').removeClass('left-setTimeout1'); - $this.find('.left-drager-sub').html(''); - $this.find('.left-drager-sub').addClass('left-setTimeout'); + dragerClick('show',true); } - - } + } + }; + var init=function(){ - var clientWidth = document.documentElement.clientWidth; - //Icon_location(); Layout(); - $this.find('.left-drager-op').off('click').on('click',function(e){ - //Cleate_Result(e); + $this.find('.left-drager-op').off('click').on('click',function(){ dragerClick(); - //Icon_trigger(); - }); + jQuery('.leftTopmenu.left-drager-op').off('click').on('click',function(){ + + if($leftContainer.width()<10 || $leftContainer.is(':hidden')){ + dragerClick('hide'); + }else{ + dragerClick('show'); + } + return false; + }); + var isshow=''; if(options.cookieid && getcookie(options.cookieid+'_isshow')){ - var isshow=getcookie(options.cookieid+'_isshow'); - if(isshow=='hide'){ - dragerClick('hide'); + isshow=getcookie(options.cookieid+'_isshow'); + if(isshow==='hide'){ + dragerClick('hide',true); }else{ - setPosition(left); + + dragerClick('show'); } }else{ - if($leftContainer.width()<10){ + if($leftContainer.width()<10 || $leftContainer.is(':hidden')){ dragerClick('hide'); }else{ - setPosition(left); + dragerClick('show'); } } - - - dragging(); var resizeTimer=null; window.onresize=function(){ - if(resizeTimer) window.clearTimeout(resizeTimer); + if(resizeTimer){ + window.clearTimeout(resizeTimer); + } window.setTimeout(function(){Layout();},100); - } + }; leftHide(); - } + }; init(); - } + }; })(jQuery); \ No newline at end of file diff --git a/static/swiper/css/swiper.min.css b/static/swiper/css/swiper.min.css new file mode 100644 index 0000000..a44c429 --- /dev/null +++ b/static/swiper/css/swiper.min.css @@ -0,0 +1,12 @@ +/** + * Swiper 4.2.6 + * Most modern mobile touch slider and framework with hardware accelerated transitions + * http://www.idangero.us/swiper/ + * + * Copyright 2014-2018 Vladimir Kharlampidi + * + * Released under the MIT License + * + * Released on: May 1, 2018 + */ +.swiper-container{margin:0 auto;position:relative;overflow:hidden;list-style:none;padding:0;z-index:1}.swiper-container-no-flexbox .swiper-slide{float:left}.swiper-container-vertical>.swiper-wrapper{-webkit-box-orient:vertical;-webkit-box-direction:normal;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column}.swiper-wrapper{position:relative;width:100%;height:100%;z-index:1;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-transition-property:-webkit-transform;transition-property:-webkit-transform;-o-transition-property:transform;transition-property:transform;transition-property:transform,-webkit-transform;-webkit-box-sizing:content-box;box-sizing:content-box}.swiper-container-android .swiper-slide,.swiper-wrapper{-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.swiper-container-multirow>.swiper-wrapper{-webkit-flex-wrap:wrap;-ms-flex-wrap:wrap;flex-wrap:wrap}.swiper-container-free-mode>.swiper-wrapper{-webkit-transition-timing-function:ease-out;-o-transition-timing-function:ease-out;transition-timing-function:ease-out;margin:0 auto}.swiper-slide{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;width:100%;height:100%;position:relative;-webkit-transition-property:-webkit-transform;transition-property:-webkit-transform;-o-transition-property:transform;transition-property:transform;transition-property:transform,-webkit-transform}.swiper-invisible-blank-slide{visibility:hidden}.swiper-container-autoheight,.swiper-container-autoheight .swiper-slide{height:auto}.swiper-container-autoheight .swiper-wrapper{-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start;-webkit-transition-property:height,-webkit-transform;transition-property:height,-webkit-transform;-o-transition-property:transform,height;transition-property:transform,height;transition-property:transform,height,-webkit-transform}.swiper-container-3d{-webkit-perspective:1200px;perspective:1200px}.swiper-container-3d .swiper-cube-shadow,.swiper-container-3d .swiper-slide,.swiper-container-3d .swiper-slide-shadow-bottom,.swiper-container-3d .swiper-slide-shadow-left,.swiper-container-3d .swiper-slide-shadow-right,.swiper-container-3d .swiper-slide-shadow-top,.swiper-container-3d .swiper-wrapper{-webkit-transform-style:preserve-3d;transform-style:preserve-3d}.swiper-container-3d .swiper-slide-shadow-bottom,.swiper-container-3d .swiper-slide-shadow-left,.swiper-container-3d .swiper-slide-shadow-right,.swiper-container-3d .swiper-slide-shadow-top{position:absolute;left:0;top:0;width:100%;height:100%;pointer-events:none;z-index:10}.swiper-container-3d .swiper-slide-shadow-left{background-image:-webkit-gradient(linear,right top,left top,from(rgba(0,0,0,.5)),to(rgba(0,0,0,0)));background-image:-webkit-linear-gradient(right,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:-o-linear-gradient(right,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:linear-gradient(to left,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-container-3d .swiper-slide-shadow-right{background-image:-webkit-gradient(linear,left top,right top,from(rgba(0,0,0,.5)),to(rgba(0,0,0,0)));background-image:-webkit-linear-gradient(left,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:-o-linear-gradient(left,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:linear-gradient(to right,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-container-3d .swiper-slide-shadow-top{background-image:-webkit-gradient(linear,left bottom,left top,from(rgba(0,0,0,.5)),to(rgba(0,0,0,0)));background-image:-webkit-linear-gradient(bottom,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:-o-linear-gradient(bottom,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:linear-gradient(to top,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-container-3d .swiper-slide-shadow-bottom{background-image:-webkit-gradient(linear,left top,left bottom,from(rgba(0,0,0,.5)),to(rgba(0,0,0,0)));background-image:-webkit-linear-gradient(top,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:-o-linear-gradient(top,rgba(0,0,0,.5),rgba(0,0,0,0));background-image:linear-gradient(to bottom,rgba(0,0,0,.5),rgba(0,0,0,0))}.swiper-container-wp8-horizontal,.swiper-container-wp8-horizontal>.swiper-wrapper{-ms-touch-action:pan-y;touch-action:pan-y}.swiper-container-wp8-vertical,.swiper-container-wp8-vertical>.swiper-wrapper{-ms-touch-action:pan-x;touch-action:pan-x}.swiper-button-next,.swiper-button-prev{position:absolute;top:50%;width:27px;height:44px;margin-top:-22px;z-index:10;cursor:pointer;background-size:27px 44px;background-position:center;background-repeat:no-repeat}.swiper-button-next.swiper-button-disabled,.swiper-button-prev.swiper-button-disabled{opacity:.35;cursor:auto;pointer-events:none}.swiper-button-prev,.swiper-container-rtl .swiper-button-next{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M0%2C22L22%2C0l2.1%2C2.1L4.2%2C22l19.9%2C19.9L22%2C44L0%2C22L0%2C22L0%2C22z'%20fill%3D'%23007aff'%2F%3E%3C%2Fsvg%3E");left:10px;right:auto}.swiper-button-next,.swiper-container-rtl .swiper-button-prev{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M27%2C22L27%2C22L5%2C44l-2.1-2.1L22.8%2C22L2.9%2C2.1L5%2C0L27%2C22L27%2C22z'%20fill%3D'%23007aff'%2F%3E%3C%2Fsvg%3E");right:10px;left:auto}.swiper-button-prev.swiper-button-white,.swiper-container-rtl .swiper-button-next.swiper-button-white{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M0%2C22L22%2C0l2.1%2C2.1L4.2%2C22l19.9%2C19.9L22%2C44L0%2C22L0%2C22L0%2C22z'%20fill%3D'%23ffffff'%2F%3E%3C%2Fsvg%3E")}.swiper-button-next.swiper-button-white,.swiper-container-rtl .swiper-button-prev.swiper-button-white{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M27%2C22L27%2C22L5%2C44l-2.1-2.1L22.8%2C22L2.9%2C2.1L5%2C0L27%2C22L27%2C22z'%20fill%3D'%23ffffff'%2F%3E%3C%2Fsvg%3E")}.swiper-button-prev.swiper-button-black,.swiper-container-rtl .swiper-button-next.swiper-button-black{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M0%2C22L22%2C0l2.1%2C2.1L4.2%2C22l19.9%2C19.9L22%2C44L0%2C22L0%2C22L0%2C22z'%20fill%3D'%23000000'%2F%3E%3C%2Fsvg%3E")}.swiper-button-next.swiper-button-black,.swiper-container-rtl .swiper-button-prev.swiper-button-black{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%2027%2044'%3E%3Cpath%20d%3D'M27%2C22L27%2C22L5%2C44l-2.1-2.1L22.8%2C22L2.9%2C2.1L5%2C0L27%2C22L27%2C22z'%20fill%3D'%23000000'%2F%3E%3C%2Fsvg%3E")}.swiper-button-lock{display:none}.swiper-pagination{position:absolute;text-align:center;-webkit-transition:.3s opacity;-o-transition:.3s opacity;transition:.3s opacity;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0);z-index:10}.swiper-pagination.swiper-pagination-hidden{opacity:0}.swiper-container-horizontal>.swiper-pagination-bullets,.swiper-pagination-custom,.swiper-pagination-fraction{bottom:10px;left:0;width:100%}.swiper-pagination-bullets-dynamic{overflow:hidden;font-size:0}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{-webkit-transform:scale(.33);-ms-transform:scale(.33);transform:scale(.33);position:relative}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active{-webkit-transform:scale(1);-ms-transform:scale(1);transform:scale(1)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-main{-webkit-transform:scale(1);-ms-transform:scale(1);transform:scale(1)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-prev{-webkit-transform:scale(.66);-ms-transform:scale(.66);transform:scale(.66)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-prev-prev{-webkit-transform:scale(.33);-ms-transform:scale(.33);transform:scale(.33)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-next{-webkit-transform:scale(.66);-ms-transform:scale(.66);transform:scale(.66)}.swiper-pagination-bullets-dynamic .swiper-pagination-bullet-active-next-next{-webkit-transform:scale(.33);-ms-transform:scale(.33);transform:scale(.33)}.swiper-pagination-bullet{width:8px;height:8px;display:inline-block;border-radius:100%;background:#000;opacity:.2}button.swiper-pagination-bullet{border:none;margin:0;padding:0;-webkit-box-shadow:none;box-shadow:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}.swiper-pagination-clickable .swiper-pagination-bullet{cursor:pointer}.swiper-pagination-bullet-active{opacity:1;background:#007aff}.swiper-container-vertical>.swiper-pagination-bullets{right:10px;top:50%;-webkit-transform:translate3d(0,-50%,0);transform:translate3d(0,-50%,0)}.swiper-container-vertical>.swiper-pagination-bullets .swiper-pagination-bullet{margin:6px 0;display:block}.swiper-container-vertical>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic{top:50%;-webkit-transform:translateY(-50%);-ms-transform:translateY(-50%);transform:translateY(-50%);width:8px}.swiper-container-vertical>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{display:inline-block;-webkit-transition:.2s top,.2s -webkit-transform;transition:.2s top,.2s -webkit-transform;-o-transition:.2s transform,.2s top;transition:.2s transform,.2s top;transition:.2s transform,.2s top,.2s -webkit-transform}.swiper-container-horizontal>.swiper-pagination-bullets .swiper-pagination-bullet{margin:0 4px}.swiper-container-horizontal>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic{left:50%;-webkit-transform:translateX(-50%);-ms-transform:translateX(-50%);transform:translateX(-50%);white-space:nowrap}.swiper-container-horizontal>.swiper-pagination-bullets.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{-webkit-transition:.2s left,.2s -webkit-transform;transition:.2s left,.2s -webkit-transform;-o-transition:.2s transform,.2s left;transition:.2s transform,.2s left;transition:.2s transform,.2s left,.2s -webkit-transform}.swiper-container-horizontal.swiper-container-rtl>.swiper-pagination-bullets-dynamic .swiper-pagination-bullet{-webkit-transition:.2s right,.2s -webkit-transform;transition:.2s right,.2s -webkit-transform;-o-transition:.2s transform,.2s right;transition:.2s transform,.2s right;transition:.2s transform,.2s right,.2s -webkit-transform}.swiper-pagination-progressbar{background:rgba(0,0,0,.25);position:absolute}.swiper-pagination-progressbar .swiper-pagination-progressbar-fill{background:#007aff;position:absolute;left:0;top:0;width:100%;height:100%;-webkit-transform:scale(0);-ms-transform:scale(0);transform:scale(0);-webkit-transform-origin:left top;-ms-transform-origin:left top;transform-origin:left top}.swiper-container-rtl .swiper-pagination-progressbar .swiper-pagination-progressbar-fill{-webkit-transform-origin:right top;-ms-transform-origin:right top;transform-origin:right top}.swiper-container-horizontal>.swiper-pagination-progressbar,.swiper-container-vertical>.swiper-pagination-progressbar.swiper-pagination-progressbar-opposite{width:100%;height:4px;left:0;top:0}.swiper-container-horizontal>.swiper-pagination-progressbar.swiper-pagination-progressbar-opposite,.swiper-container-vertical>.swiper-pagination-progressbar{width:4px;height:100%;left:0;top:0}.swiper-pagination-white .swiper-pagination-bullet-active{background:#fff}.swiper-pagination-progressbar.swiper-pagination-white{background:rgba(255,255,255,.25)}.swiper-pagination-progressbar.swiper-pagination-white .swiper-pagination-progressbar-fill{background:#fff}.swiper-pagination-black .swiper-pagination-bullet-active{background:#000}.swiper-pagination-progressbar.swiper-pagination-black{background:rgba(0,0,0,.25)}.swiper-pagination-progressbar.swiper-pagination-black .swiper-pagination-progressbar-fill{background:#000}.swiper-pagination-lock{display:none}.swiper-scrollbar{border-radius:10px;position:relative;-ms-touch-action:none;background:rgba(0,0,0,.1)}.swiper-container-horizontal>.swiper-scrollbar{position:absolute;left:1%;bottom:3px;z-index:50;height:5px;width:98%}.swiper-container-vertical>.swiper-scrollbar{position:absolute;right:3px;top:1%;z-index:50;width:5px;height:98%}.swiper-scrollbar-drag{height:100%;width:100%;position:relative;background:rgba(0,0,0,.5);border-radius:10px;left:0;top:0}.swiper-scrollbar-cursor-drag{cursor:move}.swiper-scrollbar-lock{display:none}.swiper-zoom-container{width:100%;height:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;text-align:center}.swiper-zoom-container>canvas,.swiper-zoom-container>img,.swiper-zoom-container>svg{max-width:100%;max-height:100%;-o-object-fit:contain;object-fit:contain}.swiper-slide-zoomed{cursor:move}.swiper-lazy-preloader{width:42px;height:42px;position:absolute;left:50%;top:50%;margin-left:-21px;margin-top:-21px;z-index:10;-webkit-transform-origin:50%;-ms-transform-origin:50%;transform-origin:50%;-webkit-animation:swiper-preloader-spin 1s steps(12,end) infinite;animation:swiper-preloader-spin 1s steps(12,end) infinite}.swiper-lazy-preloader:after{display:block;content:'';width:100%;height:100%;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20viewBox%3D'0%200%20120%20120'%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20xmlns%3Axlink%3D'http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink'%3E%3Cdefs%3E%3Cline%20id%3D'l'%20x1%3D'60'%20x2%3D'60'%20y1%3D'7'%20y2%3D'27'%20stroke%3D'%236c6c6c'%20stroke-width%3D'11'%20stroke-linecap%3D'round'%2F%3E%3C%2Fdefs%3E%3Cg%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(30%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(60%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(90%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(120%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(150%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.37'%20transform%3D'rotate(180%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.46'%20transform%3D'rotate(210%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.56'%20transform%3D'rotate(240%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.66'%20transform%3D'rotate(270%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.75'%20transform%3D'rotate(300%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.85'%20transform%3D'rotate(330%2060%2C60)'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");background-position:50%;background-size:100%;background-repeat:no-repeat}.swiper-lazy-preloader-white:after{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg%20viewBox%3D'0%200%20120%20120'%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20xmlns%3Axlink%3D'http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink'%3E%3Cdefs%3E%3Cline%20id%3D'l'%20x1%3D'60'%20x2%3D'60'%20y1%3D'7'%20y2%3D'27'%20stroke%3D'%23fff'%20stroke-width%3D'11'%20stroke-linecap%3D'round'%2F%3E%3C%2Fdefs%3E%3Cg%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(30%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(60%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(90%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(120%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.27'%20transform%3D'rotate(150%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.37'%20transform%3D'rotate(180%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.46'%20transform%3D'rotate(210%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.56'%20transform%3D'rotate(240%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.66'%20transform%3D'rotate(270%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.75'%20transform%3D'rotate(300%2060%2C60)'%2F%3E%3Cuse%20xlink%3Ahref%3D'%23l'%20opacity%3D'.85'%20transform%3D'rotate(330%2060%2C60)'%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E")}@-webkit-keyframes swiper-preloader-spin{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes swiper-preloader-spin{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.swiper-container .swiper-notification{position:absolute;left:0;top:0;pointer-events:none;opacity:0;z-index:-1000}.swiper-container-fade.swiper-container-free-mode .swiper-slide{-webkit-transition-timing-function:ease-out;-o-transition-timing-function:ease-out;transition-timing-function:ease-out}.swiper-container-fade .swiper-slide{pointer-events:none;-webkit-transition-property:opacity;-o-transition-property:opacity;transition-property:opacity}.swiper-container-fade .swiper-slide .swiper-slide{pointer-events:none}.swiper-container-fade .swiper-slide-active,.swiper-container-fade .swiper-slide-active .swiper-slide-active{pointer-events:auto}.swiper-container-cube{overflow:visible}.swiper-container-cube .swiper-slide{pointer-events:none;-webkit-backface-visibility:hidden;backface-visibility:hidden;z-index:1;visibility:hidden;-webkit-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0;width:100%;height:100%}.swiper-container-cube .swiper-slide .swiper-slide{pointer-events:none}.swiper-container-cube.swiper-container-rtl .swiper-slide{-webkit-transform-origin:100% 0;-ms-transform-origin:100% 0;transform-origin:100% 0}.swiper-container-cube .swiper-slide-active,.swiper-container-cube .swiper-slide-active .swiper-slide-active{pointer-events:auto}.swiper-container-cube .swiper-slide-active,.swiper-container-cube .swiper-slide-next,.swiper-container-cube .swiper-slide-next+.swiper-slide,.swiper-container-cube .swiper-slide-prev{pointer-events:auto;visibility:visible}.swiper-container-cube .swiper-slide-shadow-bottom,.swiper-container-cube .swiper-slide-shadow-left,.swiper-container-cube .swiper-slide-shadow-right,.swiper-container-cube .swiper-slide-shadow-top{z-index:0;-webkit-backface-visibility:hidden;backface-visibility:hidden}.swiper-container-cube .swiper-cube-shadow{position:absolute;left:0;bottom:0;width:100%;height:100%;background:#000;opacity:.6;-webkit-filter:blur(50px);filter:blur(50px);z-index:0}.swiper-container-flip{overflow:visible}.swiper-container-flip .swiper-slide{pointer-events:none;-webkit-backface-visibility:hidden;backface-visibility:hidden;z-index:1}.swiper-container-flip .swiper-slide .swiper-slide{pointer-events:none}.swiper-container-flip .swiper-slide-active,.swiper-container-flip .swiper-slide-active .swiper-slide-active{pointer-events:auto}.swiper-container-flip .swiper-slide-shadow-bottom,.swiper-container-flip .swiper-slide-shadow-left,.swiper-container-flip .swiper-slide-shadow-right,.swiper-container-flip .swiper-slide-shadow-top{z-index:0;-webkit-backface-visibility:hidden;backface-visibility:hidden}.swiper-container-coverflow .swiper-wrapper{-ms-perspective:1200px} \ No newline at end of file diff --git a/static/swiper/js/swiper.esm.bundle.js b/static/swiper/js/swiper.esm.bundle.js new file mode 100644 index 0000000..1ea04f7 --- /dev/null +++ b/static/swiper/js/swiper.esm.bundle.js @@ -0,0 +1,6622 @@ +/** + * Swiper 4.2.6 + * Most modern mobile touch slider and framework with hardware accelerated transitions + * http://www.idangero.us/swiper/ + * + * Copyright 2014-2018 Vladimir Kharlampidi + * + * Released under the MIT License + * + * Released on: May 1, 2018 + */ + +import { $, addClass, removeClass, hasClass, toggleClass, attr, removeAttr, data, transform, transition, on, off, trigger, transitionEnd, outerWidth, outerHeight, offset, css, each, html, text, is, index, eq, append, prepend, next, nextAll, prev, prevAll, parent, parents, closest, find, children, remove, add, styles } from 'dom7/dist/dom7.modular'; +import { window, document } from 'ssr-window'; + +const Methods = { + addClass, + removeClass, + hasClass, + toggleClass, + attr, + removeAttr, + data, + transform, + transition, + on, + off, + trigger, + transitionEnd, + outerWidth, + outerHeight, + offset, + css, + each, + html, + text, + is, + index, + eq, + append, + prepend, + next, + nextAll, + prev, + prevAll, + parent, + parents, + closest, + find, + children, + remove, + add, + styles, +}; + +Object.keys(Methods).forEach((methodName) => { + $.fn[methodName] = Methods[methodName]; +}); + +const Utils = { + deleteProps(obj) { + const object = obj; + Object.keys(object).forEach((key) => { + try { + object[key] = null; + } catch (e) { + // no getter for object + } + try { + delete object[key]; + } catch (e) { + // something got wrong + } + }); + }, + nextTick(callback, delay = 0) { + return setTimeout(callback, delay); + }, + now() { + return Date.now(); + }, + getTranslate(el, axis = 'x') { + let matrix; + let curTransform; + let transformMatrix; + + const curStyle = window.getComputedStyle(el, null); + + if (window.WebKitCSSMatrix) { + curTransform = curStyle.transform || curStyle.webkitTransform; + if (curTransform.split(',').length > 6) { + curTransform = curTransform.split(', ').map(a => a.replace(',', '.')).join(', '); + } + // Some old versions of Webkit choke when 'none' is passed; pass + // empty string instead in this case + transformMatrix = new window.WebKitCSSMatrix(curTransform === 'none' ? '' : curTransform); + } else { + transformMatrix = curStyle.MozTransform || curStyle.OTransform || curStyle.MsTransform || curStyle.msTransform || curStyle.transform || curStyle.getPropertyValue('transform').replace('translate(', 'matrix(1, 0, 0, 1,'); + matrix = transformMatrix.toString().split(','); + } + + if (axis === 'x') { + // Latest Chrome and webkits Fix + if (window.WebKitCSSMatrix) curTransform = transformMatrix.m41; + // Crazy IE10 Matrix + else if (matrix.length === 16) curTransform = parseFloat(matrix[12]); + // Normal Browsers + else curTransform = parseFloat(matrix[4]); + } + if (axis === 'y') { + // Latest Chrome and webkits Fix + if (window.WebKitCSSMatrix) curTransform = transformMatrix.m42; + // Crazy IE10 Matrix + else if (matrix.length === 16) curTransform = parseFloat(matrix[13]); + // Normal Browsers + else curTransform = parseFloat(matrix[5]); + } + return curTransform || 0; + }, + parseUrlQuery(url) { + const query = {}; + let urlToParse = url || window.location.href; + let i; + let params; + let param; + let length; + if (typeof urlToParse === 'string' && urlToParse.length) { + urlToParse = urlToParse.indexOf('?') > -1 ? urlToParse.replace(/\S*\?/, '') : ''; + params = urlToParse.split('&').filter(paramsPart => paramsPart !== ''); + length = params.length; + + for (i = 0; i < length; i += 1) { + param = params[i].replace(/#\S+/g, '').split('='); + query[decodeURIComponent(param[0])] = typeof param[1] === 'undefined' ? undefined : decodeURIComponent(param[1]) || ''; + } + } + return query; + }, + isObject(o) { + return typeof o === 'object' && o !== null && o.constructor && o.constructor === Object; + }, + extend(...args) { + const to = Object(args[0]); + for (let i = 1; i < args.length; i += 1) { + const nextSource = args[i]; + if (nextSource !== undefined && nextSource !== null) { + const keysArray = Object.keys(Object(nextSource)); + for (let nextIndex = 0, len = keysArray.length; nextIndex < len; nextIndex += 1) { + const nextKey = keysArray[nextIndex]; + const desc = Object.getOwnPropertyDescriptor(nextSource, nextKey); + if (desc !== undefined && desc.enumerable) { + if (Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) { + Utils.extend(to[nextKey], nextSource[nextKey]); + } else if (!Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) { + to[nextKey] = {}; + Utils.extend(to[nextKey], nextSource[nextKey]); + } else { + to[nextKey] = nextSource[nextKey]; + } + } + } + } + } + return to; + }, +}; + +const Support = (function Support() { + const testDiv = document.createElement('div'); + return { + touch: (window.Modernizr && window.Modernizr.touch === true) || (function checkTouch() { + return !!(('ontouchstart' in window) || (window.DocumentTouch && document instanceof window.DocumentTouch)); + }()), + + pointerEvents: !!(window.navigator.pointerEnabled || window.PointerEvent), + prefixedPointerEvents: !!window.navigator.msPointerEnabled, + + transition: (function checkTransition() { + const style = testDiv.style; + return ('transition' in style || 'webkitTransition' in style || 'MozTransition' in style); + }()), + transforms3d: (window.Modernizr && window.Modernizr.csstransforms3d === true) || (function checkTransforms3d() { + const style = testDiv.style; + return ('webkitPerspective' in style || 'MozPerspective' in style || 'OPerspective' in style || 'MsPerspective' in style || 'perspective' in style); + }()), + + flexbox: (function checkFlexbox() { + const style = testDiv.style; + const styles$$1 = ('alignItems webkitAlignItems webkitBoxAlign msFlexAlign mozBoxAlign webkitFlexDirection msFlexDirection mozBoxDirection mozBoxOrient webkitBoxDirection webkitBoxOrient').split(' '); + for (let i = 0; i < styles$$1.length; i += 1) { + if (styles$$1[i] in style) return true; + } + return false; + }()), + + observer: (function checkObserver() { + return ('MutationObserver' in window || 'WebkitMutationObserver' in window); + }()), + + passiveListener: (function checkPassiveListener() { + let supportsPassive = false; + try { + const opts = Object.defineProperty({}, 'passive', { + // eslint-disable-next-line + get() { + supportsPassive = true; + }, + }); + window.addEventListener('testPassiveListener', null, opts); + } catch (e) { + // No support + } + return supportsPassive; + }()), + + gestures: (function checkGestures() { + return 'ongesturestart' in window; + }()), + }; +}()); + +class SwiperClass { + constructor(params = {}) { + const self = this; + self.params = params; + + // Events + self.eventsListeners = {}; + + if (self.params && self.params.on) { + Object.keys(self.params.on).forEach((eventName) => { + self.on(eventName, self.params.on[eventName]); + }); + } + } + on(events, handler, priority) { + const self = this; + if (typeof handler !== 'function') return self; + const method = priority ? 'unshift' : 'push'; + events.split(' ').forEach((event) => { + if (!self.eventsListeners[event]) self.eventsListeners[event] = []; + self.eventsListeners[event][method](handler); + }); + return self; + } + once(events, handler, priority) { + const self = this; + if (typeof handler !== 'function') return self; + function onceHandler(...args) { + handler.apply(self, args); + self.off(events, onceHandler); + } + return self.on(events, onceHandler, priority); + } + off(events, handler) { + const self = this; + if (!self.eventsListeners) return self; + events.split(' ').forEach((event) => { + if (typeof handler === 'undefined') { + self.eventsListeners[event] = []; + } else { + self.eventsListeners[event].forEach((eventHandler, index$$1) => { + if (eventHandler === handler) { + self.eventsListeners[event].splice(index$$1, 1); + } + }); + } + }); + return self; + } + emit(...args) { + const self = this; + if (!self.eventsListeners) return self; + let events; + let data$$1; + let context; + if (typeof args[0] === 'string' || Array.isArray(args[0])) { + events = args[0]; + data$$1 = args.slice(1, args.length); + context = self; + } else { + events = args[0].events; + data$$1 = args[0].data; + context = args[0].context || self; + } + const eventsArray = Array.isArray(events) ? events : events.split(' '); + eventsArray.forEach((event) => { + if (self.eventsListeners && self.eventsListeners[event]) { + const handlers = []; + self.eventsListeners[event].forEach((eventHandler) => { + handlers.push(eventHandler); + }); + handlers.forEach((eventHandler) => { + eventHandler.apply(context, data$$1); + }); + } + }); + return self; + } + useModulesParams(instanceParams) { + const instance = this; + if (!instance.modules) return; + Object.keys(instance.modules).forEach((moduleName) => { + const module = instance.modules[moduleName]; + // Extend params + if (module.params) { + Utils.extend(instanceParams, module.params); + } + }); + } + useModules(modulesParams = {}) { + const instance = this; + if (!instance.modules) return; + Object.keys(instance.modules).forEach((moduleName) => { + const module = instance.modules[moduleName]; + const moduleParams = modulesParams[moduleName] || {}; + // Extend instance methods and props + if (module.instance) { + Object.keys(module.instance).forEach((modulePropName) => { + const moduleProp = module.instance[modulePropName]; + if (typeof moduleProp === 'function') { + instance[modulePropName] = moduleProp.bind(instance); + } else { + instance[modulePropName] = moduleProp; + } + }); + } + // Add event listeners + if (module.on && instance.on) { + Object.keys(module.on).forEach((moduleEventName) => { + instance.on(moduleEventName, module.on[moduleEventName]); + }); + } + + // Module create callback + if (module.create) { + module.create.bind(instance)(moduleParams); + } + }); + } + static set components(components) { + const Class = this; + if (!Class.use) return; + Class.use(components); + } + static installModule(module, ...params) { + const Class = this; + if (!Class.prototype.modules) Class.prototype.modules = {}; + const name = module.name || (`${Object.keys(Class.prototype.modules).length}_${Utils.now()}`); + Class.prototype.modules[name] = module; + // Prototype + if (module.proto) { + Object.keys(module.proto).forEach((key) => { + Class.prototype[key] = module.proto[key]; + }); + } + // Class + if (module.static) { + Object.keys(module.static).forEach((key) => { + Class[key] = module.static[key]; + }); + } + // Callback + if (module.install) { + module.install.apply(Class, params); + } + return Class; + } + static use(module, ...params) { + const Class = this; + if (Array.isArray(module)) { + module.forEach(m => Class.installModule(m)); + return Class; + } + return Class.installModule(module, ...params); + } +} + +function updateSize () { + const swiper = this; + let width; + let height; + const $el = swiper.$el; + if (typeof swiper.params.width !== 'undefined') { + width = swiper.params.width; + } else { + width = $el[0].clientWidth; + } + if (typeof swiper.params.height !== 'undefined') { + height = swiper.params.height; + } else { + height = $el[0].clientHeight; + } + if ((width === 0 && swiper.isHorizontal()) || (height === 0 && swiper.isVertical())) { + return; + } + + // Subtract paddings + width = width - parseInt($el.css('padding-left'), 10) - parseInt($el.css('padding-right'), 10); + height = height - parseInt($el.css('padding-top'), 10) - parseInt($el.css('padding-bottom'), 10); + + Utils.extend(swiper, { + width, + height, + size: swiper.isHorizontal() ? width : height, + }); +} + +function updateSlides () { + const swiper = this; + const params = swiper.params; + + const { + $wrapperEl, size: swiperSize, rtlTranslate: rtl, wrongRTL, + } = swiper; + const slides = $wrapperEl.children(`.${swiper.params.slideClass}`); + const isVirtual = swiper.virtual && params.virtual.enabled; + const slidesLength = isVirtual ? swiper.virtual.slides.length : slides.length; + let snapGrid = []; + const slidesGrid = []; + const slidesSizesGrid = []; + + let offsetBefore = params.slidesOffsetBefore; + if (typeof offsetBefore === 'function') { + offsetBefore = params.slidesOffsetBefore.call(swiper); + } + + let offsetAfter = params.slidesOffsetAfter; + if (typeof offsetAfter === 'function') { + offsetAfter = params.slidesOffsetAfter.call(swiper); + } + + const previousSlidesLength = slidesLength; + const previousSnapGridLength = swiper.snapGrid.length; + const previousSlidesGridLength = swiper.snapGrid.length; + + let spaceBetween = params.spaceBetween; + let slidePosition = -offsetBefore; + let prevSlideSize = 0; + let index$$1 = 0; + if (typeof swiperSize === 'undefined') { + return; + } + if (typeof spaceBetween === 'string' && spaceBetween.indexOf('%') >= 0) { + spaceBetween = (parseFloat(spaceBetween.replace('%', '')) / 100) * swiperSize; + } + + swiper.virtualSize = -spaceBetween; + + // reset margins + if (rtl) slides.css({ marginLeft: '', marginTop: '' }); + else slides.css({ marginRight: '', marginBottom: '' }); + + let slidesNumberEvenToRows; + if (params.slidesPerColumn > 1) { + if (Math.floor(slidesLength / params.slidesPerColumn) === slidesLength / swiper.params.slidesPerColumn) { + slidesNumberEvenToRows = slidesLength; + } else { + slidesNumberEvenToRows = Math.ceil(slidesLength / params.slidesPerColumn) * params.slidesPerColumn; + } + if (params.slidesPerView !== 'auto' && params.slidesPerColumnFill === 'row') { + slidesNumberEvenToRows = Math.max(slidesNumberEvenToRows, params.slidesPerView * params.slidesPerColumn); + } + } + + // Calc slides + let slideSize; + const slidesPerColumn = params.slidesPerColumn; + const slidesPerRow = slidesNumberEvenToRows / slidesPerColumn; + const numFullColumns = slidesPerRow - ((params.slidesPerColumn * slidesPerRow) - slidesLength); + for (let i = 0; i < slidesLength; i += 1) { + slideSize = 0; + const slide = slides.eq(i); + if (params.slidesPerColumn > 1) { + // Set slides order + let newSlideOrderIndex; + let column; + let row; + if (params.slidesPerColumnFill === 'column') { + column = Math.floor(i / slidesPerColumn); + row = i - (column * slidesPerColumn); + if (column > numFullColumns || (column === numFullColumns && row === slidesPerColumn - 1)) { + row += 1; + if (row >= slidesPerColumn) { + row = 0; + column += 1; + } + } + newSlideOrderIndex = column + ((row * slidesNumberEvenToRows) / slidesPerColumn); + slide + .css({ + '-webkit-box-ordinal-group': newSlideOrderIndex, + '-moz-box-ordinal-group': newSlideOrderIndex, + '-ms-flex-order': newSlideOrderIndex, + '-webkit-order': newSlideOrderIndex, + order: newSlideOrderIndex, + }); + } else { + row = Math.floor(i / slidesPerRow); + column = i - (row * slidesPerRow); + } + slide + .css( + `margin-${swiper.isHorizontal() ? 'top' : 'left'}`, + (row !== 0 && params.spaceBetween) && (`${params.spaceBetween}px`) + ) + .attr('data-swiper-column', column) + .attr('data-swiper-row', row); + } + if (slide.css('display') === 'none') continue; // eslint-disable-line + + if (params.slidesPerView === 'auto') { + const slideStyles = window.getComputedStyle(slide[0], null); + const currentTransform = slide[0].style.transform; + if (currentTransform) { + slide[0].style.transform = 'none'; + } + if (swiper.isHorizontal()) { + slideSize = slide[0].getBoundingClientRect().width + + parseFloat(slideStyles.getPropertyValue('margin-left')) + + parseFloat(slideStyles.getPropertyValue('margin-right')); + } else { + slideSize = slide[0].getBoundingClientRect().height + + parseFloat(slideStyles.getPropertyValue('margin-top')) + + parseFloat(slideStyles.getPropertyValue('margin-bottom')); + } + if (currentTransform) { + slide[0].style.transform = currentTransform; + } + if (params.roundLengths) slideSize = Math.floor(slideSize); + } else { + slideSize = (swiperSize - ((params.slidesPerView - 1) * spaceBetween)) / params.slidesPerView; + if (params.roundLengths) slideSize = Math.floor(slideSize); + + if (slides[i]) { + if (swiper.isHorizontal()) { + slides[i].style.width = `${slideSize}px`; + } else { + slides[i].style.height = `${slideSize}px`; + } + } + } + if (slides[i]) { + slides[i].swiperSlideSize = slideSize; + } + slidesSizesGrid.push(slideSize); + + + if (params.centeredSlides) { + slidePosition = slidePosition + (slideSize / 2) + (prevSlideSize / 2) + spaceBetween; + if (prevSlideSize === 0 && i !== 0) slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; + if (i === 0) slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; + if (Math.abs(slidePosition) < 1 / 1000) slidePosition = 0; + if ((index$$1) % params.slidesPerGroup === 0) snapGrid.push(slidePosition); + slidesGrid.push(slidePosition); + } else { + if ((index$$1) % params.slidesPerGroup === 0) snapGrid.push(slidePosition); + slidesGrid.push(slidePosition); + slidePosition = slidePosition + slideSize + spaceBetween; + } + + swiper.virtualSize += slideSize + spaceBetween; + + prevSlideSize = slideSize; + + index$$1 += 1; + } + swiper.virtualSize = Math.max(swiper.virtualSize, swiperSize) + offsetAfter; + let newSlidesGrid; + + if ( + rtl && wrongRTL && (params.effect === 'slide' || params.effect === 'coverflow')) { + $wrapperEl.css({ width: `${swiper.virtualSize + params.spaceBetween}px` }); + } + if (!Support.flexbox || params.setWrapperSize) { + if (swiper.isHorizontal()) $wrapperEl.css({ width: `${swiper.virtualSize + params.spaceBetween}px` }); + else $wrapperEl.css({ height: `${swiper.virtualSize + params.spaceBetween}px` }); + } + + if (params.slidesPerColumn > 1) { + swiper.virtualSize = (slideSize + params.spaceBetween) * slidesNumberEvenToRows; + swiper.virtualSize = Math.ceil(swiper.virtualSize / params.slidesPerColumn) - params.spaceBetween; + if (swiper.isHorizontal()) $wrapperEl.css({ width: `${swiper.virtualSize + params.spaceBetween}px` }); + else $wrapperEl.css({ height: `${swiper.virtualSize + params.spaceBetween}px` }); + if (params.centeredSlides) { + newSlidesGrid = []; + for (let i = 0; i < snapGrid.length; i += 1) { + if (snapGrid[i] < swiper.virtualSize + snapGrid[0]) newSlidesGrid.push(snapGrid[i]); + } + snapGrid = newSlidesGrid; + } + } + + // Remove last grid elements depending on width + if (!params.centeredSlides) { + newSlidesGrid = []; + for (let i = 0; i < snapGrid.length; i += 1) { + if (snapGrid[i] <= swiper.virtualSize - swiperSize) { + newSlidesGrid.push(snapGrid[i]); + } + } + snapGrid = newSlidesGrid; + if (Math.floor(swiper.virtualSize - swiperSize) - Math.floor(snapGrid[snapGrid.length - 1]) > 1) { + snapGrid.push(swiper.virtualSize - swiperSize); + } + } + if (snapGrid.length === 0) snapGrid = [0]; + + if (params.spaceBetween !== 0) { + if (swiper.isHorizontal()) { + if (rtl) slides.css({ marginLeft: `${spaceBetween}px` }); + else slides.css({ marginRight: `${spaceBetween}px` }); + } else slides.css({ marginBottom: `${spaceBetween}px` }); + } + + Utils.extend(swiper, { + slides, + snapGrid, + slidesGrid, + slidesSizesGrid, + }); + + if (slidesLength !== previousSlidesLength) { + swiper.emit('slidesLengthChange'); + } + if (snapGrid.length !== previousSnapGridLength) { + if (swiper.params.watchOverflow) swiper.checkOverflow(); + swiper.emit('snapGridLengthChange'); + } + if (slidesGrid.length !== previousSlidesGridLength) { + swiper.emit('slidesGridLengthChange'); + } + + if (params.watchSlidesProgress || params.watchSlidesVisibility) { + swiper.updateSlidesOffset(); + } +} + +function updateAutoHeight (speed) { + const swiper = this; + const activeSlides = []; + let newHeight = 0; + let i; + if (typeof speed === 'number') { + swiper.setTransition(speed); + } else if (speed === true) { + swiper.setTransition(swiper.params.speed); + } + // Find slides currently in view + if (swiper.params.slidesPerView !== 'auto' && swiper.params.slidesPerView > 1) { + for (i = 0; i < Math.ceil(swiper.params.slidesPerView); i += 1) { + const index$$1 = swiper.activeIndex + i; + if (index$$1 > swiper.slides.length) break; + activeSlides.push(swiper.slides.eq(index$$1)[0]); + } + } else { + activeSlides.push(swiper.slides.eq(swiper.activeIndex)[0]); + } + + // Find new height from highest slide in view + for (i = 0; i < activeSlides.length; i += 1) { + if (typeof activeSlides[i] !== 'undefined') { + const height = activeSlides[i].offsetHeight; + newHeight = height > newHeight ? height : newHeight; + } + } + + // Update Height + if (newHeight) swiper.$wrapperEl.css('height', `${newHeight}px`); +} + +function updateSlidesOffset () { + const swiper = this; + const slides = swiper.slides; + for (let i = 0; i < slides.length; i += 1) { + slides[i].swiperSlideOffset = swiper.isHorizontal() ? slides[i].offsetLeft : slides[i].offsetTop; + } +} + +function updateSlidesProgress (translate = (this && this.translate) || 0) { + const swiper = this; + const params = swiper.params; + + const { slides, rtlTranslate: rtl } = swiper; + + if (slides.length === 0) return; + if (typeof slides[0].swiperSlideOffset === 'undefined') swiper.updateSlidesOffset(); + + let offsetCenter = -translate; + if (rtl) offsetCenter = translate; + + // Visible Slides + slides.removeClass(params.slideVisibleClass); + + for (let i = 0; i < slides.length; i += 1) { + const slide = slides[i]; + const slideProgress = + ( + (offsetCenter + (params.centeredSlides ? swiper.minTranslate() : 0)) - slide.swiperSlideOffset + ) / (slide.swiperSlideSize + params.spaceBetween); + if (params.watchSlidesVisibility) { + const slideBefore = -(offsetCenter - slide.swiperSlideOffset); + const slideAfter = slideBefore + swiper.slidesSizesGrid[i]; + const isVisible = + (slideBefore >= 0 && slideBefore < swiper.size) || + (slideAfter > 0 && slideAfter <= swiper.size) || + (slideBefore <= 0 && slideAfter >= swiper.size); + if (isVisible) { + slides.eq(i).addClass(params.slideVisibleClass); + } + } + slide.progress = rtl ? -slideProgress : slideProgress; + } +} + +function updateProgress (translate = (this && this.translate) || 0) { + const swiper = this; + const params = swiper.params; + + const translatesDiff = swiper.maxTranslate() - swiper.minTranslate(); + let { progress, isBeginning, isEnd } = swiper; + const wasBeginning = isBeginning; + const wasEnd = isEnd; + if (translatesDiff === 0) { + progress = 0; + isBeginning = true; + isEnd = true; + } else { + progress = (translate - swiper.minTranslate()) / (translatesDiff); + isBeginning = progress <= 0; + isEnd = progress >= 1; + } + Utils.extend(swiper, { + progress, + isBeginning, + isEnd, + }); + + if (params.watchSlidesProgress || params.watchSlidesVisibility) swiper.updateSlidesProgress(translate); + + if (isBeginning && !wasBeginning) { + swiper.emit('reachBeginning toEdge'); + } + if (isEnd && !wasEnd) { + swiper.emit('reachEnd toEdge'); + } + if ((wasBeginning && !isBeginning) || (wasEnd && !isEnd)) { + swiper.emit('fromEdge'); + } + + swiper.emit('progress', progress); +} + +function updateSlidesClasses () { + const swiper = this; + + const { + slides, params, $wrapperEl, activeIndex, realIndex, + } = swiper; + const isVirtual = swiper.virtual && params.virtual.enabled; + + slides.removeClass(`${params.slideActiveClass} ${params.slideNextClass} ${params.slidePrevClass} ${params.slideDuplicateActiveClass} ${params.slideDuplicateNextClass} ${params.slideDuplicatePrevClass}`); + + let activeSlide; + if (isVirtual) { + activeSlide = swiper.$wrapperEl.find(`.${params.slideClass}[data-swiper-slide-index="${activeIndex}"]`); + } else { + activeSlide = slides.eq(activeIndex); + } + + // Active classes + activeSlide.addClass(params.slideActiveClass); + + if (params.loop) { + // Duplicate to all looped slides + if (activeSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(`.${params.slideClass}:not(.${params.slideDuplicateClass})[data-swiper-slide-index="${realIndex}"]`) + .addClass(params.slideDuplicateActiveClass); + } else { + $wrapperEl + .children(`.${params.slideClass}.${params.slideDuplicateClass}[data-swiper-slide-index="${realIndex}"]`) + .addClass(params.slideDuplicateActiveClass); + } + } + // Next Slide + let nextSlide = activeSlide.nextAll(`.${params.slideClass}`).eq(0).addClass(params.slideNextClass); + if (params.loop && nextSlide.length === 0) { + nextSlide = slides.eq(0); + nextSlide.addClass(params.slideNextClass); + } + // Prev Slide + let prevSlide = activeSlide.prevAll(`.${params.slideClass}`).eq(0).addClass(params.slidePrevClass); + if (params.loop && prevSlide.length === 0) { + prevSlide = slides.eq(-1); + prevSlide.addClass(params.slidePrevClass); + } + if (params.loop) { + // Duplicate to all looped slides + if (nextSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(`.${params.slideClass}:not(.${params.slideDuplicateClass})[data-swiper-slide-index="${nextSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicateNextClass); + } else { + $wrapperEl + .children(`.${params.slideClass}.${params.slideDuplicateClass}[data-swiper-slide-index="${nextSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicateNextClass); + } + if (prevSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(`.${params.slideClass}:not(.${params.slideDuplicateClass})[data-swiper-slide-index="${prevSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicatePrevClass); + } else { + $wrapperEl + .children(`.${params.slideClass}.${params.slideDuplicateClass}[data-swiper-slide-index="${prevSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicatePrevClass); + } + } +} + +function updateActiveIndex (newActiveIndex) { + const swiper = this; + const translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate; + const { + slidesGrid, snapGrid, params, activeIndex: previousIndex, realIndex: previousRealIndex, snapIndex: previousSnapIndex, + } = swiper; + let activeIndex = newActiveIndex; + let snapIndex; + if (typeof activeIndex === 'undefined') { + for (let i = 0; i < slidesGrid.length; i += 1) { + if (typeof slidesGrid[i + 1] !== 'undefined') { + if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1] - ((slidesGrid[i + 1] - slidesGrid[i]) / 2)) { + activeIndex = i; + } else if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1]) { + activeIndex = i + 1; + } + } else if (translate >= slidesGrid[i]) { + activeIndex = i; + } + } + // Normalize slideIndex + if (params.normalizeSlideIndex) { + if (activeIndex < 0 || typeof activeIndex === 'undefined') activeIndex = 0; + } + } + if (snapGrid.indexOf(translate) >= 0) { + snapIndex = snapGrid.indexOf(translate); + } else { + snapIndex = Math.floor(activeIndex / params.slidesPerGroup); + } + if (snapIndex >= snapGrid.length) snapIndex = snapGrid.length - 1; + if (activeIndex === previousIndex) { + if (snapIndex !== previousSnapIndex) { + swiper.snapIndex = snapIndex; + swiper.emit('snapIndexChange'); + } + return; + } + + // Get real index + const realIndex = parseInt(swiper.slides.eq(activeIndex).attr('data-swiper-slide-index') || activeIndex, 10); + + Utils.extend(swiper, { + snapIndex, + realIndex, + previousIndex, + activeIndex, + }); + swiper.emit('activeIndexChange'); + swiper.emit('snapIndexChange'); + if (previousRealIndex !== realIndex) { + swiper.emit('realIndexChange'); + } + swiper.emit('slideChange'); +} + +function updateClickedSlide (e) { + const swiper = this; + const params = swiper.params; + const slide = $(e.target).closest(`.${params.slideClass}`)[0]; + let slideFound = false; + if (slide) { + for (let i = 0; i < swiper.slides.length; i += 1) { + if (swiper.slides[i] === slide) slideFound = true; + } + } + + if (slide && slideFound) { + swiper.clickedSlide = slide; + if (swiper.virtual && swiper.params.virtual.enabled) { + swiper.clickedIndex = parseInt($(slide).attr('data-swiper-slide-index'), 10); + } else { + swiper.clickedIndex = $(slide).index(); + } + } else { + swiper.clickedSlide = undefined; + swiper.clickedIndex = undefined; + return; + } + if (params.slideToClickedSlide && swiper.clickedIndex !== undefined && swiper.clickedIndex !== swiper.activeIndex) { + swiper.slideToClickedSlide(); + } +} + +var update = { + updateSize, + updateSlides, + updateAutoHeight, + updateSlidesOffset, + updateSlidesProgress, + updateProgress, + updateSlidesClasses, + updateActiveIndex, + updateClickedSlide, +}; + +function getTranslate (axis = this.isHorizontal() ? 'x' : 'y') { + const swiper = this; + + const { + params, rtlTranslate: rtl, translate, $wrapperEl, + } = swiper; + + if (params.virtualTranslate) { + return rtl ? -translate : translate; + } + + let currentTranslate = Utils.getTranslate($wrapperEl[0], axis); + if (rtl) currentTranslate = -currentTranslate; + + return currentTranslate || 0; +} + +function setTranslate (translate, byController) { + const swiper = this; + const { + rtlTranslate: rtl, params, $wrapperEl, progress, + } = swiper; + let x = 0; + let y = 0; + const z = 0; + + if (swiper.isHorizontal()) { + x = rtl ? -translate : translate; + } else { + y = translate; + } + + if (params.roundLengths) { + x = Math.floor(x); + y = Math.floor(y); + } + + if (!params.virtualTranslate) { + if (Support.transforms3d) $wrapperEl.transform(`translate3d(${x}px, ${y}px, ${z}px)`); + else $wrapperEl.transform(`translate(${x}px, ${y}px)`); + } + + swiper.translate = swiper.isHorizontal() ? x : y; + + // Check if we need to update progress + let newProgress; + const translatesDiff = swiper.maxTranslate() - swiper.minTranslate(); + if (translatesDiff === 0) { + newProgress = 0; + } else { + newProgress = (translate - swiper.minTranslate()) / (translatesDiff); + } + if (newProgress !== progress) { + swiper.updateProgress(translate); + } + + swiper.emit('setTranslate', swiper.translate, byController); +} + +function minTranslate () { + return (-this.snapGrid[0]); +} + +function maxTranslate () { + return (-this.snapGrid[this.snapGrid.length - 1]); +} + +var translate = { + getTranslate, + setTranslate, + minTranslate, + maxTranslate, +}; + +function setTransition (duration, byController) { + const swiper = this; + + swiper.$wrapperEl.transition(duration); + + swiper.emit('setTransition', duration, byController); +} + +function transitionStart (runCallbacks = true, direction) { + const swiper = this; + const { activeIndex, params, previousIndex } = swiper; + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + + let dir = direction; + if (!dir) { + if (activeIndex > previousIndex) dir = 'next'; + else if (activeIndex < previousIndex) dir = 'prev'; + else dir = 'reset'; + } + + swiper.emit('transitionStart'); + + if (runCallbacks && activeIndex !== previousIndex) { + if (dir === 'reset') { + swiper.emit('slideResetTransitionStart'); + return; + } + swiper.emit('slideChangeTransitionStart'); + if (dir === 'next') { + swiper.emit('slideNextTransitionStart'); + } else { + swiper.emit('slidePrevTransitionStart'); + } + } +} + +function transitionEnd$1 (runCallbacks = true, direction) { + const swiper = this; + const { activeIndex, previousIndex } = swiper; + swiper.animating = false; + swiper.setTransition(0); + + let dir = direction; + if (!dir) { + if (activeIndex > previousIndex) dir = 'next'; + else if (activeIndex < previousIndex) dir = 'prev'; + else dir = 'reset'; + } + + swiper.emit('transitionEnd'); + + if (runCallbacks && activeIndex !== previousIndex) { + if (dir === 'reset') { + swiper.emit('slideResetTransitionEnd'); + return; + } + swiper.emit('slideChangeTransitionEnd'); + if (dir === 'next') { + swiper.emit('slideNextTransitionEnd'); + } else { + swiper.emit('slidePrevTransitionEnd'); + } + } +} + +var transition$1 = { + setTransition, + transitionStart, + transitionEnd: transitionEnd$1, +}; + +function slideTo (index$$1 = 0, speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + let slideIndex = index$$1; + if (slideIndex < 0) slideIndex = 0; + + const { + params, snapGrid, slidesGrid, previousIndex, activeIndex, rtlTranslate: rtl, + } = swiper; + if (swiper.animating && params.preventIntercationOnTransition) { + return false; + } + + let snapIndex = Math.floor(slideIndex / params.slidesPerGroup); + if (snapIndex >= snapGrid.length) snapIndex = snapGrid.length - 1; + + if ((activeIndex || params.initialSlide || 0) === (previousIndex || 0) && runCallbacks) { + swiper.emit('beforeSlideChangeStart'); + } + + const translate = -snapGrid[snapIndex]; + + // Update progress + swiper.updateProgress(translate); + + // Normalize slideIndex + if (params.normalizeSlideIndex) { + for (let i = 0; i < slidesGrid.length; i += 1) { + if (-Math.floor(translate * 100) >= Math.floor(slidesGrid[i] * 100)) { + slideIndex = i; + } + } + } + // Directions locks + if (swiper.initialized && slideIndex !== activeIndex) { + if (!swiper.allowSlideNext && translate < swiper.translate && translate < swiper.minTranslate()) { + return false; + } + if (!swiper.allowSlidePrev && translate > swiper.translate && translate > swiper.maxTranslate()) { + if ((activeIndex || 0) !== slideIndex) return false; + } + } + + let direction; + if (slideIndex > activeIndex) direction = 'next'; + else if (slideIndex < activeIndex) direction = 'prev'; + else direction = 'reset'; + + + // Update Index + if ((rtl && -translate === swiper.translate) || (!rtl && translate === swiper.translate)) { + swiper.updateActiveIndex(slideIndex); + // Update Height + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + swiper.updateSlidesClasses(); + if (params.effect !== 'slide') { + swiper.setTranslate(translate); + } + if (direction !== 'reset') { + swiper.transitionStart(runCallbacks, direction); + swiper.transitionEnd(runCallbacks, direction); + } + return false; + } + + if (speed === 0 || !Support.transition) { + swiper.setTransition(0); + swiper.setTranslate(translate); + swiper.updateActiveIndex(slideIndex); + swiper.updateSlidesClasses(); + swiper.emit('beforeTransitionStart', speed, internal); + swiper.transitionStart(runCallbacks, direction); + swiper.transitionEnd(runCallbacks, direction); + } else { + swiper.setTransition(speed); + swiper.setTranslate(translate); + swiper.updateActiveIndex(slideIndex); + swiper.updateSlidesClasses(); + swiper.emit('beforeTransitionStart', speed, internal); + swiper.transitionStart(runCallbacks, direction); + if (!swiper.animating) { + swiper.animating = true; + if (!swiper.onSlideToWrapperTransitionEnd) { + swiper.onSlideToWrapperTransitionEnd = function transitionEnd$$1(e) { + if (!swiper || swiper.destroyed) return; + if (e.target !== this) return; + swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd); + swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd); + swiper.transitionEnd(runCallbacks, direction); + }; + } + swiper.$wrapperEl[0].addEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd); + swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd); + } + } + + return true; +} + +function slideToLoop (index$$1 = 0, speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + let newIndex = index$$1; + if (swiper.params.loop) { + newIndex += swiper.loopedSlides; + } + + return swiper.slideTo(newIndex, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slideNext (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + const { params, animating } = swiper; + if (params.loop) { + if (animating) return false; + swiper.loopFix(); + // eslint-disable-next-line + swiper._clientLeft = swiper.$wrapperEl[0].clientLeft; + return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal); + } + return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slidePrev (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + const { + params, animating, snapGrid, slidesGrid, rtlTranslate, + } = swiper; + + if (params.loop) { + if (animating) return false; + swiper.loopFix(); + // eslint-disable-next-line + swiper._clientLeft = swiper.$wrapperEl[0].clientLeft; + } + const translate = rtlTranslate ? swiper.translate : -swiper.translate; + const currentSnap = snapGrid[snapGrid.indexOf(translate)]; + const prevSnap = snapGrid[snapGrid.indexOf(translate) - 1]; + let prevIndex; + + if (prevSnap) { + prevIndex = slidesGrid.indexOf(prevSnap); + if (prevIndex < 0) prevIndex = swiper.activeIndex - 1; + } + return swiper.slideTo(prevIndex, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slideReset (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + return swiper.slideTo(swiper.activeIndex, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slideToClosest (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + let index$$1 = swiper.activeIndex; + const snapIndex = Math.floor(index$$1 / swiper.params.slidesPerGroup); + + if (snapIndex < swiper.snapGrid.length - 1) { + const translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate; + + const currentSnap = swiper.snapGrid[snapIndex]; + const nextSnap = swiper.snapGrid[snapIndex + 1]; + + if ((translate - currentSnap) > (nextSnap - currentSnap) / 2) { + index$$1 = swiper.params.slidesPerGroup; + } + } + + return swiper.slideTo(index$$1, speed, runCallbacks, internal); +} + +function slideToClickedSlide () { + const swiper = this; + const { params, $wrapperEl } = swiper; + + const slidesPerView = params.slidesPerView === 'auto' ? swiper.slidesPerViewDynamic() : params.slidesPerView; + let slideToIndex = swiper.clickedIndex; + let realIndex; + if (params.loop) { + if (swiper.animating) return; + realIndex = parseInt($(swiper.clickedSlide).attr('data-swiper-slide-index'), 10); + if (params.centeredSlides) { + if ( + (slideToIndex < swiper.loopedSlides - (slidesPerView / 2)) || + (slideToIndex > (swiper.slides.length - swiper.loopedSlides) + (slidesPerView / 2)) + ) { + swiper.loopFix(); + slideToIndex = $wrapperEl + .children(`.${params.slideClass}[data-swiper-slide-index="${realIndex}"]:not(.${params.slideDuplicateClass})`) + .eq(0) + .index(); + + Utils.nextTick(() => { + swiper.slideTo(slideToIndex); + }); + } else { + swiper.slideTo(slideToIndex); + } + } else if (slideToIndex > swiper.slides.length - slidesPerView) { + swiper.loopFix(); + slideToIndex = $wrapperEl + .children(`.${params.slideClass}[data-swiper-slide-index="${realIndex}"]:not(.${params.slideDuplicateClass})`) + .eq(0) + .index(); + + Utils.nextTick(() => { + swiper.slideTo(slideToIndex); + }); + } else { + swiper.slideTo(slideToIndex); + } + } else { + swiper.slideTo(slideToIndex); + } +} + +var slide = { + slideTo, + slideToLoop, + slideNext, + slidePrev, + slideReset, + slideToClosest, + slideToClickedSlide, +}; + +function loopCreate () { + const swiper = this; + const { params, $wrapperEl } = swiper; + // Remove duplicated slides + $wrapperEl.children(`.${params.slideClass}.${params.slideDuplicateClass}`).remove(); + + let slides = $wrapperEl.children(`.${params.slideClass}`); + + if (params.loopFillGroupWithBlank) { + const blankSlidesNum = params.slidesPerGroup - (slides.length % params.slidesPerGroup); + if (blankSlidesNum !== params.slidesPerGroup) { + for (let i = 0; i < blankSlidesNum; i += 1) { + const blankNode = $(document.createElement('div')).addClass(`${params.slideClass} ${params.slideBlankClass}`); + $wrapperEl.append(blankNode); + } + slides = $wrapperEl.children(`.${params.slideClass}`); + } + } + + if (params.slidesPerView === 'auto' && !params.loopedSlides) params.loopedSlides = slides.length; + + swiper.loopedSlides = parseInt(params.loopedSlides || params.slidesPerView, 10); + swiper.loopedSlides += params.loopAdditionalSlides; + if (swiper.loopedSlides > slides.length) { + swiper.loopedSlides = slides.length; + } + + const prependSlides = []; + const appendSlides = []; + slides.each((index$$1, el) => { + const slide = $(el); + if (index$$1 < swiper.loopedSlides) appendSlides.push(el); + if (index$$1 < slides.length && index$$1 >= slides.length - swiper.loopedSlides) prependSlides.push(el); + slide.attr('data-swiper-slide-index', index$$1); + }); + for (let i = 0; i < appendSlides.length; i += 1) { + $wrapperEl.append($(appendSlides[i].cloneNode(true)).addClass(params.slideDuplicateClass)); + } + for (let i = prependSlides.length - 1; i >= 0; i -= 1) { + $wrapperEl.prepend($(prependSlides[i].cloneNode(true)).addClass(params.slideDuplicateClass)); + } +} + +function loopFix () { + const swiper = this; + const { + params, activeIndex, slides, loopedSlides, allowSlidePrev, allowSlideNext, snapGrid, rtlTranslate: rtl, + } = swiper; + let newIndex; + swiper.allowSlidePrev = true; + swiper.allowSlideNext = true; + + const snapTranslate = -snapGrid[activeIndex]; + const diff = snapTranslate - swiper.getTranslate(); + + + // Fix For Negative Oversliding + if (activeIndex < loopedSlides) { + newIndex = (slides.length - (loopedSlides * 3)) + activeIndex; + newIndex += loopedSlides; + const slideChanged = swiper.slideTo(newIndex, 0, false, true); + if (slideChanged && diff !== 0) { + swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff); + } + } else if ((params.slidesPerView === 'auto' && activeIndex >= loopedSlides * 2) || (activeIndex > slides.length - (params.slidesPerView * 2))) { + // Fix For Positive Oversliding + newIndex = -slides.length + activeIndex + loopedSlides; + newIndex += loopedSlides; + const slideChanged = swiper.slideTo(newIndex, 0, false, true); + if (slideChanged && diff !== 0) { + swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff); + } + } + swiper.allowSlidePrev = allowSlidePrev; + swiper.allowSlideNext = allowSlideNext; +} + +function loopDestroy () { + const swiper = this; + const { $wrapperEl, params, slides } = swiper; + $wrapperEl.children(`.${params.slideClass}.${params.slideDuplicateClass}`).remove(); + slides.removeAttr('data-swiper-slide-index'); +} + +var loop = { + loopCreate, + loopFix, + loopDestroy, +}; + +function setGrabCursor (moving) { + const swiper = this; + if (Support.touch || !swiper.params.simulateTouch || (swiper.params.watchOverflow && swiper.isLocked)) return; + const el = swiper.el; + el.style.cursor = 'move'; + el.style.cursor = moving ? '-webkit-grabbing' : '-webkit-grab'; + el.style.cursor = moving ? '-moz-grabbin' : '-moz-grab'; + el.style.cursor = moving ? 'grabbing' : 'grab'; +} + +function unsetGrabCursor () { + const swiper = this; + if (Support.touch || (swiper.params.watchOverflow && swiper.isLocked)) return; + swiper.el.style.cursor = ''; +} + +var grabCursor = { + setGrabCursor, + unsetGrabCursor, +}; + +function appendSlide (slides) { + const swiper = this; + const { $wrapperEl, params } = swiper; + if (params.loop) { + swiper.loopDestroy(); + } + if (typeof slides === 'object' && 'length' in slides) { + for (let i = 0; i < slides.length; i += 1) { + if (slides[i]) $wrapperEl.append(slides[i]); + } + } else { + $wrapperEl.append(slides); + } + if (params.loop) { + swiper.loopCreate(); + } + if (!(params.observer && Support.observer)) { + swiper.update(); + } +} + +function prependSlide (slides) { + const swiper = this; + const { params, $wrapperEl, activeIndex } = swiper; + + if (params.loop) { + swiper.loopDestroy(); + } + let newActiveIndex = activeIndex + 1; + if (typeof slides === 'object' && 'length' in slides) { + for (let i = 0; i < slides.length; i += 1) { + if (slides[i]) $wrapperEl.prepend(slides[i]); + } + newActiveIndex = activeIndex + slides.length; + } else { + $wrapperEl.prepend(slides); + } + if (params.loop) { + swiper.loopCreate(); + } + if (!(params.observer && Support.observer)) { + swiper.update(); + } + swiper.slideTo(newActiveIndex, 0, false); +} + +function removeSlide (slidesIndexes) { + const swiper = this; + const { params, $wrapperEl, activeIndex } = swiper; + + if (params.loop) { + swiper.loopDestroy(); + swiper.slides = $wrapperEl.children(`.${params.slideClass}`); + } + let newActiveIndex = activeIndex; + let indexToRemove; + + if (typeof slidesIndexes === 'object' && 'length' in slidesIndexes) { + for (let i = 0; i < slidesIndexes.length; i += 1) { + indexToRemove = slidesIndexes[i]; + if (swiper.slides[indexToRemove]) swiper.slides.eq(indexToRemove).remove(); + if (indexToRemove < newActiveIndex) newActiveIndex -= 1; + } + newActiveIndex = Math.max(newActiveIndex, 0); + } else { + indexToRemove = slidesIndexes; + if (swiper.slides[indexToRemove]) swiper.slides.eq(indexToRemove).remove(); + if (indexToRemove < newActiveIndex) newActiveIndex -= 1; + newActiveIndex = Math.max(newActiveIndex, 0); + } + + if (params.loop) { + swiper.loopCreate(); + } + + if (!(params.observer && Support.observer)) { + swiper.update(); + } + if (params.loop) { + swiper.slideTo(newActiveIndex + swiper.loopedSlides, 0, false); + } else { + swiper.slideTo(newActiveIndex, 0, false); + } +} + +function removeAllSlides () { + const swiper = this; + + const slidesIndexes = []; + for (let i = 0; i < swiper.slides.length; i += 1) { + slidesIndexes.push(i); + } + swiper.removeSlide(slidesIndexes); +} + +var manipulation = { + appendSlide, + prependSlide, + removeSlide, + removeAllSlides, +}; + +const Device = (function Device() { + const ua = window.navigator.userAgent; + + const device = { + ios: false, + android: false, + androidChrome: false, + desktop: false, + windows: false, + iphone: false, + ipod: false, + ipad: false, + cordova: window.cordova || window.phonegap, + phonegap: window.cordova || window.phonegap, + }; + + const windows = ua.match(/(Windows Phone);?[\s\/]+([\d.]+)?/); // eslint-disable-line + const android = ua.match(/(Android);?[\s\/]+([\d.]+)?/); // eslint-disable-line + const ipad = ua.match(/(iPad).*OS\s([\d_]+)/); + const ipod = ua.match(/(iPod)(.*OS\s([\d_]+))?/); + const iphone = !ipad && ua.match(/(iPhone\sOS|iOS)\s([\d_]+)/); + + + // Windows + if (windows) { + device.os = 'windows'; + device.osVersion = windows[2]; + device.windows = true; + } + // Android + if (android && !windows) { + device.os = 'android'; + device.osVersion = android[2]; + device.android = true; + device.androidChrome = ua.toLowerCase().indexOf('chrome') >= 0; + } + if (ipad || iphone || ipod) { + device.os = 'ios'; + device.ios = true; + } + // iOS + if (iphone && !ipod) { + device.osVersion = iphone[2].replace(/_/g, '.'); + device.iphone = true; + } + if (ipad) { + device.osVersion = ipad[2].replace(/_/g, '.'); + device.ipad = true; + } + if (ipod) { + device.osVersion = ipod[3] ? ipod[3].replace(/_/g, '.') : null; + device.iphone = true; + } + // iOS 8+ changed UA + if (device.ios && device.osVersion && ua.indexOf('Version/') >= 0) { + if (device.osVersion.split('.')[0] === '10') { + device.osVersion = ua.toLowerCase().split('version/')[1].split(' ')[0]; + } + } + + // Desktop + device.desktop = !(device.os || device.android || device.webView); + + // Webview + device.webView = (iphone || ipad || ipod) && ua.match(/.*AppleWebKit(?!.*Safari)/i); + + // Minimal UI + if (device.os && device.os === 'ios') { + const osVersionArr = device.osVersion.split('.'); + const metaViewport = document.querySelector('meta[name="viewport"]'); + device.minimalUi = + !device.webView && + (ipod || iphone) && + (osVersionArr[0] * 1 === 7 ? osVersionArr[1] * 1 >= 1 : osVersionArr[0] * 1 > 7) && + metaViewport && metaViewport.getAttribute('content').indexOf('minimal-ui') >= 0; + } + + // Pixel Ratio + device.pixelRatio = window.devicePixelRatio || 1; + + // Export object + return device; +}()); + +function onTouchStart (event) { + const swiper = this; + const data$$1 = swiper.touchEventsData; + const { params, touches } = swiper; + if (swiper.animating && params.preventIntercationOnTransition) { + return; + } + let e = event; + if (e.originalEvent) e = e.originalEvent; + data$$1.isTouchEvent = e.type === 'touchstart'; + if (!data$$1.isTouchEvent && 'which' in e && e.which === 3) return; + if (data$$1.isTouched && data$$1.isMoved) return; + if (params.noSwiping && $(e.target).closest(params.noSwipingSelector ? params.noSwipingSelector : `.${params.noSwipingClass}`)[0]) { + swiper.allowClick = true; + return; + } + if (params.swipeHandler) { + if (!$(e).closest(params.swipeHandler)[0]) return; + } + + touches.currentX = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX; + touches.currentY = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY; + const startX = touches.currentX; + const startY = touches.currentY; + + // Do NOT start if iOS edge swipe is detected. Otherwise iOS app (UIWebView) cannot swipe-to-go-back anymore + + if ( + Device.ios && + !Device.cordova && + params.iOSEdgeSwipeDetection && + (startX <= params.iOSEdgeSwipeThreshold) && + (startX >= window.screen.width - params.iOSEdgeSwipeThreshold) + ) { + return; + } + + Utils.extend(data$$1, { + isTouched: true, + isMoved: false, + allowTouchCallbacks: true, + isScrolling: undefined, + startMoving: undefined, + }); + + touches.startX = startX; + touches.startY = startY; + data$$1.touchStartTime = Utils.now(); + swiper.allowClick = true; + swiper.updateSize(); + swiper.swipeDirection = undefined; + if (params.threshold > 0) data$$1.allowThresholdMove = false; + if (e.type !== 'touchstart') { + let preventDefault = true; + if ($(e.target).is(data$$1.formElements)) preventDefault = false; + if ( + document.activeElement && + $(document.activeElement).is(data$$1.formElements) && + document.activeElement !== e.target + ) { + document.activeElement.blur(); + } + if (preventDefault && swiper.allowTouchMove) { + e.preventDefault(); + } + } + swiper.emit('touchStart', e); +} + +function onTouchMove (event) { + const swiper = this; + const data$$1 = swiper.touchEventsData; + const { params, touches, rtlTranslate: rtl } = swiper; + let e = event; + if (e.originalEvent) e = e.originalEvent; + if (!data$$1.isTouched) { + if (data$$1.startMoving && data$$1.isScrolling) { + swiper.emit('touchMoveOpposite', e); + } + return; + } + if (data$$1.isTouchEvent && e.type === 'mousemove') return; + const pageX = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX; + const pageY = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY; + if (e.preventedByNestedSwiper) { + touches.startX = pageX; + touches.startY = pageY; + return; + } + if (!swiper.allowTouchMove) { + // isMoved = true; + swiper.allowClick = false; + if (data$$1.isTouched) { + Utils.extend(touches, { + startX: pageX, + startY: pageY, + currentX: pageX, + currentY: pageY, + }); + data$$1.touchStartTime = Utils.now(); + } + return; + } + if (data$$1.isTouchEvent && params.touchReleaseOnEdges && !params.loop) { + if (swiper.isVertical()) { + // Vertical + if ( + (pageY < touches.startY && swiper.translate <= swiper.maxTranslate()) || + (pageY > touches.startY && swiper.translate >= swiper.minTranslate()) + ) { + data$$1.isTouched = false; + data$$1.isMoved = false; + return; + } + } else if ( + (pageX < touches.startX && swiper.translate <= swiper.maxTranslate()) || + (pageX > touches.startX && swiper.translate >= swiper.minTranslate()) + ) { + return; + } + } + if (data$$1.isTouchEvent && document.activeElement) { + if (e.target === document.activeElement && $(e.target).is(data$$1.formElements)) { + data$$1.isMoved = true; + swiper.allowClick = false; + return; + } + } + if (data$$1.allowTouchCallbacks) { + swiper.emit('touchMove', e); + } + if (e.targetTouches && e.targetTouches.length > 1) return; + + touches.currentX = pageX; + touches.currentY = pageY; + + const diffX = touches.currentX - touches.startX; + const diffY = touches.currentY - touches.startY; + + if (typeof data$$1.isScrolling === 'undefined') { + let touchAngle; + if ((swiper.isHorizontal() && touches.currentY === touches.startY) || (swiper.isVertical() && touches.currentX === touches.startX)) { + data$$1.isScrolling = false; + } else { + // eslint-disable-next-line + if ((diffX * diffX) + (diffY * diffY) >= 25) { + touchAngle = (Math.atan2(Math.abs(diffY), Math.abs(diffX)) * 180) / Math.PI; + data$$1.isScrolling = swiper.isHorizontal() ? touchAngle > params.touchAngle : (90 - touchAngle > params.touchAngle); + } + } + } + if (data$$1.isScrolling) { + swiper.emit('touchMoveOpposite', e); + } + if (typeof startMoving === 'undefined') { + if (touches.currentX !== touches.startX || touches.currentY !== touches.startY) { + data$$1.startMoving = true; + } + } + if (data$$1.isScrolling) { + data$$1.isTouched = false; + return; + } + if (!data$$1.startMoving) { + return; + } + swiper.allowClick = false; + e.preventDefault(); + if (params.touchMoveStopPropagation && !params.nested) { + e.stopPropagation(); + } + + if (!data$$1.isMoved) { + if (params.loop) { + swiper.loopFix(); + } + data$$1.startTranslate = swiper.getTranslate(); + swiper.setTransition(0); + if (swiper.animating) { + swiper.$wrapperEl.trigger('webkitTransitionEnd transitionend'); + } + data$$1.allowMomentumBounce = false; + // Grab Cursor + if (params.grabCursor && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) { + swiper.setGrabCursor(true); + } + swiper.emit('sliderFirstMove', e); + } + swiper.emit('sliderMove', e); + data$$1.isMoved = true; + + let diff = swiper.isHorizontal() ? diffX : diffY; + touches.diff = diff; + + diff *= params.touchRatio; + if (rtl) diff = -diff; + + swiper.swipeDirection = diff > 0 ? 'prev' : 'next'; + data$$1.currentTranslate = diff + data$$1.startTranslate; + + let disableParentSwiper = true; + let resistanceRatio = params.resistanceRatio; + if (params.touchReleaseOnEdges) { + resistanceRatio = 0; + } + if ((diff > 0 && data$$1.currentTranslate > swiper.minTranslate())) { + disableParentSwiper = false; + if (params.resistance) data$$1.currentTranslate = (swiper.minTranslate() - 1) + ((-swiper.minTranslate() + data$$1.startTranslate + diff) ** resistanceRatio); + } else if (diff < 0 && data$$1.currentTranslate < swiper.maxTranslate()) { + disableParentSwiper = false; + if (params.resistance) data$$1.currentTranslate = (swiper.maxTranslate() + 1) - ((swiper.maxTranslate() - data$$1.startTranslate - diff) ** resistanceRatio); + } + + if (disableParentSwiper) { + e.preventedByNestedSwiper = true; + } + + // Directions locks + if (!swiper.allowSlideNext && swiper.swipeDirection === 'next' && data$$1.currentTranslate < data$$1.startTranslate) { + data$$1.currentTranslate = data$$1.startTranslate; + } + if (!swiper.allowSlidePrev && swiper.swipeDirection === 'prev' && data$$1.currentTranslate > data$$1.startTranslate) { + data$$1.currentTranslate = data$$1.startTranslate; + } + + + // Threshold + if (params.threshold > 0) { + if (Math.abs(diff) > params.threshold || data$$1.allowThresholdMove) { + if (!data$$1.allowThresholdMove) { + data$$1.allowThresholdMove = true; + touches.startX = touches.currentX; + touches.startY = touches.currentY; + data$$1.currentTranslate = data$$1.startTranslate; + touches.diff = swiper.isHorizontal() ? touches.currentX - touches.startX : touches.currentY - touches.startY; + return; + } + } else { + data$$1.currentTranslate = data$$1.startTranslate; + return; + } + } + + if (!params.followFinger) return; + + // Update active index in free mode + if (params.freeMode || params.watchSlidesProgress || params.watchSlidesVisibility) { + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + if (params.freeMode) { + // Velocity + if (data$$1.velocities.length === 0) { + data$$1.velocities.push({ + position: touches[swiper.isHorizontal() ? 'startX' : 'startY'], + time: data$$1.touchStartTime, + }); + } + data$$1.velocities.push({ + position: touches[swiper.isHorizontal() ? 'currentX' : 'currentY'], + time: Utils.now(), + }); + } + // Update progress + swiper.updateProgress(data$$1.currentTranslate); + // Update translate + swiper.setTranslate(data$$1.currentTranslate); +} + +function onTouchEnd (event) { + const swiper = this; + const data$$1 = swiper.touchEventsData; + + const { + params, touches, rtlTranslate: rtl, $wrapperEl, slidesGrid, snapGrid, + } = swiper; + let e = event; + if (e.originalEvent) e = e.originalEvent; + if (data$$1.allowTouchCallbacks) { + swiper.emit('touchEnd', e); + } + data$$1.allowTouchCallbacks = false; + if (!data$$1.isTouched) { + if (data$$1.isMoved && params.grabCursor) { + swiper.setGrabCursor(false); + } + data$$1.isMoved = false; + data$$1.startMoving = false; + return; + } + // Return Grab Cursor + if (params.grabCursor && data$$1.isMoved && data$$1.isTouched && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) { + swiper.setGrabCursor(false); + } + + // Time diff + const touchEndTime = Utils.now(); + const timeDiff = touchEndTime - data$$1.touchStartTime; + + // Tap, doubleTap, Click + if (swiper.allowClick) { + swiper.updateClickedSlide(e); + swiper.emit('tap', e); + if (timeDiff < 300 && (touchEndTime - data$$1.lastClickTime) > 300) { + if (data$$1.clickTimeout) clearTimeout(data$$1.clickTimeout); + data$$1.clickTimeout = Utils.nextTick(() => { + if (!swiper || swiper.destroyed) return; + swiper.emit('click', e); + }, 300); + } + if (timeDiff < 300 && (touchEndTime - data$$1.lastClickTime) < 300) { + if (data$$1.clickTimeout) clearTimeout(data$$1.clickTimeout); + swiper.emit('doubleTap', e); + } + } + + data$$1.lastClickTime = Utils.now(); + Utils.nextTick(() => { + if (!swiper.destroyed) swiper.allowClick = true; + }); + + if (!data$$1.isTouched || !data$$1.isMoved || !swiper.swipeDirection || touches.diff === 0 || data$$1.currentTranslate === data$$1.startTranslate) { + data$$1.isTouched = false; + data$$1.isMoved = false; + data$$1.startMoving = false; + return; + } + data$$1.isTouched = false; + data$$1.isMoved = false; + data$$1.startMoving = false; + + let currentPos; + if (params.followFinger) { + currentPos = rtl ? swiper.translate : -swiper.translate; + } else { + currentPos = -data$$1.currentTranslate; + } + + if (params.freeMode) { + if (currentPos < -swiper.minTranslate()) { + swiper.slideTo(swiper.activeIndex); + return; + } else if (currentPos > -swiper.maxTranslate()) { + if (swiper.slides.length < snapGrid.length) { + swiper.slideTo(snapGrid.length - 1); + } else { + swiper.slideTo(swiper.slides.length - 1); + } + return; + } + + if (params.freeModeMomentum) { + if (data$$1.velocities.length > 1) { + const lastMoveEvent = data$$1.velocities.pop(); + const velocityEvent = data$$1.velocities.pop(); + + const distance = lastMoveEvent.position - velocityEvent.position; + const time = lastMoveEvent.time - velocityEvent.time; + swiper.velocity = distance / time; + swiper.velocity /= 2; + if (Math.abs(swiper.velocity) < params.freeModeMinimumVelocity) { + swiper.velocity = 0; + } + // this implies that the user stopped moving a finger then released. + // There would be no events with distance zero, so the last event is stale. + if (time > 150 || (Utils.now() - lastMoveEvent.time) > 300) { + swiper.velocity = 0; + } + } else { + swiper.velocity = 0; + } + swiper.velocity *= params.freeModeMomentumVelocityRatio; + + data$$1.velocities.length = 0; + let momentumDuration = 1000 * params.freeModeMomentumRatio; + const momentumDistance = swiper.velocity * momentumDuration; + + let newPosition = swiper.translate + momentumDistance; + if (rtl) newPosition = -newPosition; + + let doBounce = false; + let afterBouncePosition; + const bounceAmount = Math.abs(swiper.velocity) * 20 * params.freeModeMomentumBounceRatio; + let needsLoopFix; + if (newPosition < swiper.maxTranslate()) { + if (params.freeModeMomentumBounce) { + if (newPosition + swiper.maxTranslate() < -bounceAmount) { + newPosition = swiper.maxTranslate() - bounceAmount; + } + afterBouncePosition = swiper.maxTranslate(); + doBounce = true; + data$$1.allowMomentumBounce = true; + } else { + newPosition = swiper.maxTranslate(); + } + if (params.loop && params.centeredSlides) needsLoopFix = true; + } else if (newPosition > swiper.minTranslate()) { + if (params.freeModeMomentumBounce) { + if (newPosition - swiper.minTranslate() > bounceAmount) { + newPosition = swiper.minTranslate() + bounceAmount; + } + afterBouncePosition = swiper.minTranslate(); + doBounce = true; + data$$1.allowMomentumBounce = true; + } else { + newPosition = swiper.minTranslate(); + } + if (params.loop && params.centeredSlides) needsLoopFix = true; + } else if (params.freeModeSticky) { + let nextSlide; + for (let j = 0; j < snapGrid.length; j += 1) { + if (snapGrid[j] > -newPosition) { + nextSlide = j; + break; + } + } + + if (Math.abs(snapGrid[nextSlide] - newPosition) < Math.abs(snapGrid[nextSlide - 1] - newPosition) || swiper.swipeDirection === 'next') { + newPosition = snapGrid[nextSlide]; + } else { + newPosition = snapGrid[nextSlide - 1]; + } + newPosition = -newPosition; + } + if (needsLoopFix) { + swiper.once('transitionEnd', () => { + swiper.loopFix(); + }); + } + // Fix duration + if (swiper.velocity !== 0) { + if (rtl) { + momentumDuration = Math.abs((-newPosition - swiper.translate) / swiper.velocity); + } else { + momentumDuration = Math.abs((newPosition - swiper.translate) / swiper.velocity); + } + } else if (params.freeModeSticky) { + swiper.slideToClosest(); + return; + } + + if (params.freeModeMomentumBounce && doBounce) { + swiper.updateProgress(afterBouncePosition); + swiper.setTransition(momentumDuration); + swiper.setTranslate(newPosition); + swiper.transitionStart(true, swiper.swipeDirection); + swiper.animating = true; + $wrapperEl.transitionEnd(() => { + if (!swiper || swiper.destroyed || !data$$1.allowMomentumBounce) return; + swiper.emit('momentumBounce'); + + swiper.setTransition(params.speed); + swiper.setTranslate(afterBouncePosition); + $wrapperEl.transitionEnd(() => { + if (!swiper || swiper.destroyed) return; + swiper.transitionEnd(); + }); + }); + } else if (swiper.velocity) { + swiper.updateProgress(newPosition); + swiper.setTransition(momentumDuration); + swiper.setTranslate(newPosition); + swiper.transitionStart(true, swiper.swipeDirection); + if (!swiper.animating) { + swiper.animating = true; + $wrapperEl.transitionEnd(() => { + if (!swiper || swiper.destroyed) return; + swiper.transitionEnd(); + }); + } + } else { + swiper.updateProgress(newPosition); + } + + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } else if (params.freeModeSticky) { + swiper.slideToClosest(); + return; + } + + if (!params.freeModeMomentum || timeDiff >= params.longSwipesMs) { + swiper.updateProgress(); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + return; + } + + // Find current slide + let stopIndex = 0; + let groupSize = swiper.slidesSizesGrid[0]; + for (let i = 0; i < slidesGrid.length; i += params.slidesPerGroup) { + if (typeof slidesGrid[i + params.slidesPerGroup] !== 'undefined') { + if (currentPos >= slidesGrid[i] && currentPos < slidesGrid[i + params.slidesPerGroup]) { + stopIndex = i; + groupSize = slidesGrid[i + params.slidesPerGroup] - slidesGrid[i]; + } + } else if (currentPos >= slidesGrid[i]) { + stopIndex = i; + groupSize = slidesGrid[slidesGrid.length - 1] - slidesGrid[slidesGrid.length - 2]; + } + } + + // Find current slide size + const ratio = (currentPos - slidesGrid[stopIndex]) / groupSize; + + if (timeDiff > params.longSwipesMs) { + // Long touches + if (!params.longSwipes) { + swiper.slideTo(swiper.activeIndex); + return; + } + if (swiper.swipeDirection === 'next') { + if (ratio >= params.longSwipesRatio) swiper.slideTo(stopIndex + params.slidesPerGroup); + else swiper.slideTo(stopIndex); + } + if (swiper.swipeDirection === 'prev') { + if (ratio > (1 - params.longSwipesRatio)) swiper.slideTo(stopIndex + params.slidesPerGroup); + else swiper.slideTo(stopIndex); + } + } else { + // Short swipes + if (!params.shortSwipes) { + swiper.slideTo(swiper.activeIndex); + return; + } + if (swiper.swipeDirection === 'next') { + swiper.slideTo(stopIndex + params.slidesPerGroup); + } + if (swiper.swipeDirection === 'prev') { + swiper.slideTo(stopIndex); + } + } +} + +function onResize () { + const swiper = this; + + const { params, el } = swiper; + + if (el && el.offsetWidth === 0) return; + + // Breakpoints + if (params.breakpoints) { + swiper.setBreakpoint(); + } + + // Save locks + const { allowSlideNext, allowSlidePrev, snapGrid } = swiper; + + // Disable locks on resize + swiper.allowSlideNext = true; + swiper.allowSlidePrev = true; + + swiper.updateSize(); + swiper.updateSlides(); + + if (params.freeMode) { + const newTranslate = Math.min(Math.max(swiper.translate, swiper.maxTranslate()), swiper.minTranslate()); + swiper.setTranslate(newTranslate); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + } else { + swiper.updateSlidesClasses(); + if ((params.slidesPerView === 'auto' || params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) { + swiper.slideTo(swiper.slides.length - 1, 0, false, true); + } else { + swiper.slideTo(swiper.activeIndex, 0, false, true); + } + } + // Return locks after resize + swiper.allowSlidePrev = allowSlidePrev; + swiper.allowSlideNext = allowSlideNext; + + if (swiper.params.watchOverflow && snapGrid !== swiper.snapGrid) { + swiper.checkOverflow(); + } +} + +function onClick (e) { + const swiper = this; + if (!swiper.allowClick) { + if (swiper.params.preventClicks) e.preventDefault(); + if (swiper.params.preventClicksPropagation && swiper.animating) { + e.stopPropagation(); + e.stopImmediatePropagation(); + } + } +} + +function attachEvents() { + const swiper = this; + const { + params, touchEvents, el, wrapperEl, + } = swiper; + + { + swiper.onTouchStart = onTouchStart.bind(swiper); + swiper.onTouchMove = onTouchMove.bind(swiper); + swiper.onTouchEnd = onTouchEnd.bind(swiper); + } + + swiper.onClick = onClick.bind(swiper); + + const target = params.touchEventsTarget === 'container' ? el : wrapperEl; + const capture = !!params.nested; + + // Touch Events + { + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.addEventListener(touchEvents.start, swiper.onTouchStart, false); + document.addEventListener(touchEvents.move, swiper.onTouchMove, capture); + document.addEventListener(touchEvents.end, swiper.onTouchEnd, false); + } else { + if (Support.touch) { + const passiveListener = touchEvents.start === 'touchstart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false; + target.addEventListener(touchEvents.start, swiper.onTouchStart, passiveListener); + target.addEventListener(touchEvents.move, swiper.onTouchMove, Support.passiveListener ? { passive: false, capture } : capture); + target.addEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.addEventListener('mousedown', swiper.onTouchStart, false); + document.addEventListener('mousemove', swiper.onTouchMove, capture); + document.addEventListener('mouseup', swiper.onTouchEnd, false); + } + } + // Prevent Links Clicks + if (params.preventClicks || params.preventClicksPropagation) { + target.addEventListener('click', swiper.onClick, true); + } + } + + // Resize handler + swiper.on('resize observerUpdate', onResize, true); +} + +function detachEvents() { + const swiper = this; + + const { + params, touchEvents, el, wrapperEl, + } = swiper; + + const target = params.touchEventsTarget === 'container' ? el : wrapperEl; + const capture = !!params.nested; + + // Touch Events + { + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.removeEventListener(touchEvents.start, swiper.onTouchStart, false); + document.removeEventListener(touchEvents.move, swiper.onTouchMove, capture); + document.removeEventListener(touchEvents.end, swiper.onTouchEnd, false); + } else { + if (Support.touch) { + const passiveListener = touchEvents.start === 'onTouchStart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false; + target.removeEventListener(touchEvents.start, swiper.onTouchStart, passiveListener); + target.removeEventListener(touchEvents.move, swiper.onTouchMove, capture); + target.removeEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.removeEventListener('mousedown', swiper.onTouchStart, false); + document.removeEventListener('mousemove', swiper.onTouchMove, capture); + document.removeEventListener('mouseup', swiper.onTouchEnd, false); + } + } + // Prevent Links Clicks + if (params.preventClicks || params.preventClicksPropagation) { + target.removeEventListener('click', swiper.onClick, true); + } + } + + // Resize handler + swiper.off('resize observerUpdate', onResize); +} + +var events = { + attachEvents, + detachEvents, +}; + +function setBreakpoint () { + const swiper = this; + const { + activeIndex, initialized, loopedSlides = 0, params, + } = swiper; + const breakpoints = params.breakpoints; + if (!breakpoints || (breakpoints && Object.keys(breakpoints).length === 0)) return; + // Set breakpoint for window width and update parameters + const breakpoint = swiper.getBreakpoint(breakpoints); + if (breakpoint && swiper.currentBreakpoint !== breakpoint) { + const breakPointsParams = breakpoint in breakpoints ? breakpoints[breakpoint] : swiper.originalParams; + const needsReLoop = params.loop && (breakPointsParams.slidesPerView !== params.slidesPerView); + + Utils.extend(swiper.params, breakPointsParams); + + Utils.extend(swiper, { + allowTouchMove: swiper.params.allowTouchMove, + allowSlideNext: swiper.params.allowSlideNext, + allowSlidePrev: swiper.params.allowSlidePrev, + }); + + swiper.currentBreakpoint = breakpoint; + + if (needsReLoop && initialized) { + swiper.loopDestroy(); + swiper.loopCreate(); + swiper.updateSlides(); + swiper.slideTo((activeIndex - loopedSlides) + swiper.loopedSlides, 0, false); + } + swiper.emit('breakpoint', breakPointsParams); + } +} + +function getBreakpoint (breakpoints) { + // Get breakpoint for window width + if (!breakpoints) return undefined; + let breakpoint = false; + const points = []; + Object.keys(breakpoints).forEach((point) => { + points.push(point); + }); + points.sort((a, b) => parseInt(a, 10) - parseInt(b, 10)); + for (let i = 0; i < points.length; i += 1) { + const point = points[i]; + if (point >= window.innerWidth && !breakpoint) { + breakpoint = point; + } + } + return breakpoint || 'max'; +} + +var breakpoints = { setBreakpoint, getBreakpoint }; + +const Browser = (function Browser() { + function isSafari() { + const ua = window.navigator.userAgent.toLowerCase(); + return (ua.indexOf('safari') >= 0 && ua.indexOf('chrome') < 0 && ua.indexOf('android') < 0); + } + return { + isIE: !!window.navigator.userAgent.match(/Trident/g) || !!window.navigator.userAgent.match(/MSIE/g), + isSafari: isSafari(), + isUiWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(window.navigator.userAgent), + }; +}()); + +function addClasses () { + const swiper = this; + const { + classNames, params, rtl, $el, + } = swiper; + const suffixes = []; + + suffixes.push(params.direction); + + if (params.freeMode) { + suffixes.push('free-mode'); + } + if (!Support.flexbox) { + suffixes.push('no-flexbox'); + } + if (params.autoHeight) { + suffixes.push('autoheight'); + } + if (rtl) { + suffixes.push('rtl'); + } + if (params.slidesPerColumn > 1) { + suffixes.push('multirow'); + } + if (Device.android) { + suffixes.push('android'); + } + if (Device.ios) { + suffixes.push('ios'); + } + // WP8 Touch Events Fix + if (Browser.isIE && (Support.pointerEvents || Support.prefixedPointerEvents)) { + suffixes.push(`wp8-${params.direction}`); + } + + suffixes.forEach((suffix) => { + classNames.push(params.containerModifierClass + suffix); + }); + + $el.addClass(classNames.join(' ')); +} + +function removeClasses () { + const swiper = this; + const { $el, classNames } = swiper; + + $el.removeClass(classNames.join(' ')); +} + +var classes = { addClasses, removeClasses }; + +function loadImage (imageEl, src, srcset, sizes, checkForComplete, callback) { + let image; + function onReady() { + if (callback) callback(); + } + if (!imageEl.complete || !checkForComplete) { + if (src) { + image = new window.Image(); + image.onload = onReady; + image.onerror = onReady; + if (sizes) { + image.sizes = sizes; + } + if (srcset) { + image.srcset = srcset; + } + if (src) { + image.src = src; + } + } else { + onReady(); + } + } else { + // image already loaded... + onReady(); + } +} + +function preloadImages () { + const swiper = this; + swiper.imagesToLoad = swiper.$el.find('img'); + function onReady() { + if (typeof swiper === 'undefined' || swiper === null || !swiper || swiper.destroyed) return; + if (swiper.imagesLoaded !== undefined) swiper.imagesLoaded += 1; + if (swiper.imagesLoaded === swiper.imagesToLoad.length) { + if (swiper.params.updateOnImagesReady) swiper.update(); + swiper.emit('imagesReady'); + } + } + for (let i = 0; i < swiper.imagesToLoad.length; i += 1) { + const imageEl = swiper.imagesToLoad[i]; + swiper.loadImage( + imageEl, + imageEl.currentSrc || imageEl.getAttribute('src'), + imageEl.srcset || imageEl.getAttribute('srcset'), + imageEl.sizes || imageEl.getAttribute('sizes'), + true, + onReady + ); + } +} + +var images = { + loadImage, + preloadImages, +}; + +function checkOverflow() { + const swiper = this; + const wasLocked = swiper.isLocked; + + swiper.isLocked = swiper.snapGrid.length === 1; + swiper.allowSlideNext = !swiper.isLocked; + swiper.allowSlidePrev = !swiper.isLocked; + + // events + if (wasLocked !== swiper.isLocked) swiper.emit(swiper.isLocked ? 'lock' : 'unlock'); + + if (wasLocked && wasLocked !== swiper.isLocked) { + swiper.isEnd = false; + swiper.navigation.update(); + } +} + +var checkOverflow$1 = { checkOverflow }; + +var defaults = { + init: true, + direction: 'horizontal', + touchEventsTarget: 'container', + initialSlide: 0, + speed: 300, + // + preventIntercationOnTransition: false, + + // To support iOS's swipe-to-go-back gesture (when being used in-app, with UIWebView). + iOSEdgeSwipeDetection: false, + iOSEdgeSwipeThreshold: 20, + + // Free mode + freeMode: false, + freeModeMomentum: true, + freeModeMomentumRatio: 1, + freeModeMomentumBounce: true, + freeModeMomentumBounceRatio: 1, + freeModeMomentumVelocityRatio: 1, + freeModeSticky: false, + freeModeMinimumVelocity: 0.02, + + // Autoheight + autoHeight: false, + + // Set wrapper width + setWrapperSize: false, + + // Virtual Translate + virtualTranslate: false, + + // Effects + effect: 'slide', // 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip' + + // Breakpoints + breakpoints: undefined, + + // Slides grid + spaceBetween: 0, + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerColumnFill: 'column', + slidesPerGroup: 1, + centeredSlides: false, + slidesOffsetBefore: 0, // in px + slidesOffsetAfter: 0, // in px + normalizeSlideIndex: true, + + // Disable swiper and hide navigation when container not overflow + watchOverflow: false, + + // Round length + roundLengths: false, + + // Touches + touchRatio: 1, + touchAngle: 45, + simulateTouch: true, + shortSwipes: true, + longSwipes: true, + longSwipesRatio: 0.5, + longSwipesMs: 300, + followFinger: true, + allowTouchMove: true, + threshold: 0, + touchMoveStopPropagation: true, + touchReleaseOnEdges: false, + + // Unique Navigation Elements + uniqueNavElements: true, + + // Resistance + resistance: true, + resistanceRatio: 0.85, + + // Progress + watchSlidesProgress: false, + watchSlidesVisibility: false, + + // Cursor + grabCursor: false, + + // Clicks + preventClicks: true, + preventClicksPropagation: true, + slideToClickedSlide: false, + + // Images + preloadImages: true, + updateOnImagesReady: true, + + // loop + loop: false, + loopAdditionalSlides: 0, + loopedSlides: null, + loopFillGroupWithBlank: false, + + // Swiping/no swiping + allowSlidePrev: true, + allowSlideNext: true, + swipeHandler: null, // '.swipe-handler', + noSwiping: true, + noSwipingClass: 'swiper-no-swiping', + noSwipingSelector: null, + + // Passive Listeners + passiveListeners: true, + + // NS + containerModifierClass: 'swiper-container-', // NEW + slideClass: 'swiper-slide', + slideBlankClass: 'swiper-slide-invisible-blank', + slideActiveClass: 'swiper-slide-active', + slideDuplicateActiveClass: 'swiper-slide-duplicate-active', + slideVisibleClass: 'swiper-slide-visible', + slideDuplicateClass: 'swiper-slide-duplicate', + slideNextClass: 'swiper-slide-next', + slideDuplicateNextClass: 'swiper-slide-duplicate-next', + slidePrevClass: 'swiper-slide-prev', + slideDuplicatePrevClass: 'swiper-slide-duplicate-prev', + wrapperClass: 'swiper-wrapper', + + // Callbacks + runCallbacksOnInit: true, +}; + +const prototypes = { + update, + translate, + transition: transition$1, + slide, + loop, + grabCursor, + manipulation, + events, + breakpoints, + checkOverflow: checkOverflow$1, + classes, + images, +}; + +const extendedDefaults = {}; + +class Swiper extends SwiperClass { + constructor(...args) { + let el; + let params; + if (args.length === 1 && args[0].constructor && args[0].constructor === Object) { + params = args[0]; + } else { + [el, params] = args; + } + if (!params) params = {}; + + params = Utils.extend({}, params); + if (el && !params.el) params.el = el; + + super(params); + + Object.keys(prototypes).forEach((prototypeGroup) => { + Object.keys(prototypes[prototypeGroup]).forEach((protoMethod) => { + if (!Swiper.prototype[protoMethod]) { + Swiper.prototype[protoMethod] = prototypes[prototypeGroup][protoMethod]; + } + }); + }); + + // Swiper Instance + const swiper = this; + if (typeof swiper.modules === 'undefined') { + swiper.modules = {}; + } + Object.keys(swiper.modules).forEach((moduleName) => { + const module = swiper.modules[moduleName]; + if (module.params) { + const moduleParamName = Object.keys(module.params)[0]; + const moduleParams = module.params[moduleParamName]; + if (typeof moduleParams !== 'object') return; + if (!(moduleParamName in params && 'enabled' in moduleParams)) return; + if (params[moduleParamName] === true) { + params[moduleParamName] = { enabled: true }; + } + if ( + typeof params[moduleParamName] === 'object' && + !('enabled' in params[moduleParamName]) + ) { + params[moduleParamName].enabled = true; + } + if (!params[moduleParamName]) params[moduleParamName] = { enabled: false }; + } + }); + + // Extend defaults with modules params + const swiperParams = Utils.extend({}, defaults); + swiper.useModulesParams(swiperParams); + + // Extend defaults with passed params + swiper.params = Utils.extend({}, swiperParams, extendedDefaults, params); + swiper.originalParams = Utils.extend({}, swiper.params); + swiper.passedParams = Utils.extend({}, params); + + // Save Dom lib + swiper.$ = $; + + // Find el + const $el = $(swiper.params.el); + el = $el[0]; + + if (!el) { + return undefined; + } + + if ($el.length > 1) { + const swipers = []; + $el.each((index$$1, containerEl) => { + const newParams = Utils.extend({}, params, { el: containerEl }); + swipers.push(new Swiper(newParams)); + }); + return swipers; + } + + el.swiper = swiper; + $el.data('swiper', swiper); + + // Find Wrapper + const $wrapperEl = $el.children(`.${swiper.params.wrapperClass}`); + + // Extend Swiper + Utils.extend(swiper, { + $el, + el, + $wrapperEl, + wrapperEl: $wrapperEl[0], + + // Classes + classNames: [], + + // Slides + slides: $(), + slidesGrid: [], + snapGrid: [], + slidesSizesGrid: [], + + // isDirection + isHorizontal() { + return swiper.params.direction === 'horizontal'; + }, + isVertical() { + return swiper.params.direction === 'vertical'; + }, + // RTL + rtl: (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'), + rtlTranslate: swiper.params.direction === 'horizontal' && (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'), + wrongRTL: $wrapperEl.css('display') === '-webkit-box', + + // Indexes + activeIndex: 0, + realIndex: 0, + + // + isBeginning: true, + isEnd: false, + + // Props + translate: 0, + progress: 0, + velocity: 0, + animating: false, + + // Locks + allowSlideNext: swiper.params.allowSlideNext, + allowSlidePrev: swiper.params.allowSlidePrev, + + // Touch Events + touchEvents: (function touchEvents() { + const touch = ['touchstart', 'touchmove', 'touchend']; + let desktop = ['mousedown', 'mousemove', 'mouseup']; + if (Support.pointerEvents) { + desktop = ['pointerdown', 'pointermove', 'pointerup']; + } else if (Support.prefixedPointerEvents) { + desktop = ['MSPointerDown', 'MSPointerMove', 'MSPointerUp']; + } + swiper.touchEventsTouch = { + start: touch[0], + move: touch[1], + end: touch[2], + }; + swiper.touchEventsDesktop = { + start: desktop[0], + move: desktop[1], + end: desktop[2], + }; + return Support.touch || !swiper.params.simulateTouch ? swiper.touchEventsTouch : swiper.touchEventsDesktop; + }()), + touchEventsData: { + isTouched: undefined, + isMoved: undefined, + allowTouchCallbacks: undefined, + touchStartTime: undefined, + isScrolling: undefined, + currentTranslate: undefined, + startTranslate: undefined, + allowThresholdMove: undefined, + // Form elements to match + formElements: 'input, select, option, textarea, button, video', + // Last click time + lastClickTime: Utils.now(), + clickTimeout: undefined, + // Velocities + velocities: [], + allowMomentumBounce: undefined, + isTouchEvent: undefined, + startMoving: undefined, + }, + + // Clicks + allowClick: true, + + // Touches + allowTouchMove: swiper.params.allowTouchMove, + + touches: { + startX: 0, + startY: 0, + currentX: 0, + currentY: 0, + diff: 0, + }, + + // Images + imagesToLoad: [], + imagesLoaded: 0, + + }); + + // Install Modules + swiper.useModules(); + + // Init + if (swiper.params.init) { + swiper.init(); + } + + // Return app instance + return swiper; + } + slidesPerViewDynamic() { + const swiper = this; + const { + params, slides, slidesGrid, size: swiperSize, activeIndex, + } = swiper; + let spv = 1; + if (params.centeredSlides) { + let slideSize = slides[activeIndex].swiperSlideSize; + let breakLoop; + for (let i = activeIndex + 1; i < slides.length; i += 1) { + if (slides[i] && !breakLoop) { + slideSize += slides[i].swiperSlideSize; + spv += 1; + if (slideSize > swiperSize) breakLoop = true; + } + } + for (let i = activeIndex - 1; i >= 0; i -= 1) { + if (slides[i] && !breakLoop) { + slideSize += slides[i].swiperSlideSize; + spv += 1; + if (slideSize > swiperSize) breakLoop = true; + } + } + } else { + for (let i = activeIndex + 1; i < slides.length; i += 1) { + if (slidesGrid[i] - slidesGrid[activeIndex] < swiperSize) { + spv += 1; + } + } + } + return spv; + } + update() { + const swiper = this; + if (!swiper || swiper.destroyed) return; + const { snapGrid, params } = swiper; + // Breakpoints + if (params.breakpoints) { + swiper.setBreakpoint(); + } + swiper.updateSize(); + swiper.updateSlides(); + swiper.updateProgress(); + swiper.updateSlidesClasses(); + + function setTranslate() { + const translateValue = swiper.rtlTranslate ? swiper.translate * -1 : swiper.translate; + const newTranslate = Math.min(Math.max(translateValue, swiper.maxTranslate()), swiper.minTranslate()); + swiper.setTranslate(newTranslate); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + let translated; + if (swiper.params.freeMode) { + setTranslate(); + if (swiper.params.autoHeight) { + swiper.updateAutoHeight(); + } + } else { + if ((swiper.params.slidesPerView === 'auto' || swiper.params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) { + translated = swiper.slideTo(swiper.slides.length - 1, 0, false, true); + } else { + translated = swiper.slideTo(swiper.activeIndex, 0, false, true); + } + if (!translated) { + setTranslate(); + } + } + if (params.watchOverflow && snapGrid !== swiper.snapGrid) { + swiper.checkOverflow(); + } + swiper.emit('update'); + } + init() { + const swiper = this; + if (swiper.initialized) return; + + swiper.emit('beforeInit'); + + // Set breakpoint + if (swiper.params.breakpoints) { + swiper.setBreakpoint(); + } + + // Add Classes + swiper.addClasses(); + + // Create loop + if (swiper.params.loop) { + swiper.loopCreate(); + } + + // Update size + swiper.updateSize(); + + // Update slides + swiper.updateSlides(); + + if (swiper.params.watchOverflow) { + swiper.checkOverflow(); + } + + // Set Grab Cursor + if (swiper.params.grabCursor) { + swiper.setGrabCursor(); + } + + if (swiper.params.preloadImages) { + swiper.preloadImages(); + } + + // Slide To Initial Slide + if (swiper.params.loop) { + swiper.slideTo(swiper.params.initialSlide + swiper.loopedSlides, 0, swiper.params.runCallbacksOnInit); + } else { + swiper.slideTo(swiper.params.initialSlide, 0, swiper.params.runCallbacksOnInit); + } + + // Attach events + swiper.attachEvents(); + + // Init Flag + swiper.initialized = true; + + // Emit + swiper.emit('init'); + } + destroy(deleteInstance = true, cleanStyles = true) { + const swiper = this; + const { + params, $el, $wrapperEl, slides, + } = swiper; + + if (typeof swiper.params === 'undefined' || swiper.destroyed) { + return null; + } + + swiper.emit('beforeDestroy'); + + // Init Flag + swiper.initialized = false; + + // Detach events + swiper.detachEvents(); + + // Destroy loop + if (params.loop) { + swiper.loopDestroy(); + } + + // Cleanup styles + if (cleanStyles) { + swiper.removeClasses(); + $el.removeAttr('style'); + $wrapperEl.removeAttr('style'); + if (slides && slides.length) { + slides + .removeClass([ + params.slideVisibleClass, + params.slideActiveClass, + params.slideNextClass, + params.slidePrevClass, + ].join(' ')) + .removeAttr('style') + .removeAttr('data-swiper-slide-index') + .removeAttr('data-swiper-column') + .removeAttr('data-swiper-row'); + } + } + + swiper.emit('destroy'); + + // Detach emitter events + Object.keys(swiper.eventsListeners).forEach((eventName) => { + swiper.off(eventName); + }); + + if (deleteInstance !== false) { + swiper.$el[0].swiper = null; + swiper.$el.data('swiper', null); + Utils.deleteProps(swiper); + } + swiper.destroyed = true; + + return null; + } + static extendDefaults(newDefaults) { + Utils.extend(extendedDefaults, newDefaults); + } + static get extendedDefaults() { + return extendedDefaults; + } + static get defaults() { + return defaults; + } + static get Class() { + return SwiperClass; + } + static get $() { + return $; + } +} + +var Device$1 = { + name: 'device', + proto: { + device: Device, + }, + static: { + device: Device, + }, +}; + +var Support$1 = { + name: 'support', + proto: { + support: Support, + }, + static: { + support: Support, + }, +}; + +var Browser$1 = { + name: 'browser', + proto: { + browser: Browser, + }, + static: { + browser: Browser, + }, +}; + +var Resize = { + name: 'resize', + create() { + const swiper = this; + Utils.extend(swiper, { + resize: { + resizeHandler() { + if (!swiper || swiper.destroyed || !swiper.initialized) return; + swiper.emit('beforeResize'); + swiper.emit('resize'); + }, + orientationChangeHandler() { + if (!swiper || swiper.destroyed || !swiper.initialized) return; + swiper.emit('orientationchange'); + }, + }, + }); + }, + on: { + init() { + const swiper = this; + // Emit resize + window.addEventListener('resize', swiper.resize.resizeHandler); + + // Emit orientationchange + window.addEventListener('orientationchange', swiper.resize.orientationChangeHandler); + }, + destroy() { + const swiper = this; + window.removeEventListener('resize', swiper.resize.resizeHandler); + window.removeEventListener('orientationchange', swiper.resize.orientationChangeHandler); + }, + }, +}; + +const Observer = { + func: window.MutationObserver || window.WebkitMutationObserver, + attach(target, options = {}) { + const swiper = this; + + const ObserverFunc = Observer.func; + const observer = new ObserverFunc((mutations) => { + mutations.forEach((mutation) => { + swiper.emit('observerUpdate', mutation); + }); + }); + + observer.observe(target, { + attributes: typeof options.attributes === 'undefined' ? true : options.attributes, + childList: typeof options.childList === 'undefined' ? true : options.childList, + characterData: typeof options.characterData === 'undefined' ? true : options.characterData, + }); + + swiper.observer.observers.push(observer); + }, + init() { + const swiper = this; + if (!Support.observer || !swiper.params.observer) return; + if (swiper.params.observeParents) { + const containerParents = swiper.$el.parents(); + for (let i = 0; i < containerParents.length; i += 1) { + swiper.observer.attach(containerParents[i]); + } + } + // Observe container + swiper.observer.attach(swiper.$el[0], { childList: false }); + + // Observe wrapper + swiper.observer.attach(swiper.$wrapperEl[0], { attributes: false }); + }, + destroy() { + const swiper = this; + swiper.observer.observers.forEach((observer) => { + observer.disconnect(); + }); + swiper.observer.observers = []; + }, +}; + +var Observer$1 = { + name: 'observer', + params: { + observer: false, + observeParents: false, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + observer: { + init: Observer.init.bind(swiper), + attach: Observer.attach.bind(swiper), + destroy: Observer.destroy.bind(swiper), + observers: [], + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.observer.init(); + }, + destroy() { + const swiper = this; + swiper.observer.destroy(); + }, + }, +}; + +const Virtual = { + update(force) { + const swiper = this; + const { slidesPerView, slidesPerGroup, centeredSlides } = swiper.params; + const { + from: previousFrom, + to: previousTo, + slides, + slidesGrid: previousSlidesGrid, + renderSlide, + offset: previousOffset, + } = swiper.virtual; + swiper.updateActiveIndex(); + const activeIndex = swiper.activeIndex || 0; + + let offsetProp; + if (swiper.rtlTranslate) offsetProp = 'right'; + else offsetProp = swiper.isHorizontal() ? 'left' : 'top'; + + let slidesAfter; + let slidesBefore; + if (centeredSlides) { + slidesAfter = Math.floor(slidesPerView / 2) + slidesPerGroup; + slidesBefore = Math.floor(slidesPerView / 2) + slidesPerGroup; + } else { + slidesAfter = slidesPerView + (slidesPerGroup - 1); + slidesBefore = slidesPerGroup; + } + const from = Math.max((activeIndex || 0) - slidesBefore, 0); + const to = Math.min((activeIndex || 0) + slidesAfter, slides.length - 1); + const offset$$1 = (swiper.slidesGrid[from] || 0) - (swiper.slidesGrid[0] || 0); + + Utils.extend(swiper.virtual, { + from, + to, + offset: offset$$1, + slidesGrid: swiper.slidesGrid, + }); + + function onRendered() { + swiper.updateSlides(); + swiper.updateProgress(); + swiper.updateSlidesClasses(); + if (swiper.lazy && swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + } + + if (previousFrom === from && previousTo === to && !force) { + if (swiper.slidesGrid !== previousSlidesGrid && offset$$1 !== previousOffset) { + swiper.slides.css(offsetProp, `${offset$$1}px`); + } + swiper.updateProgress(); + return; + } + if (swiper.params.virtual.renderExternal) { + swiper.params.virtual.renderExternal.call(swiper, { + offset: offset$$1, + from, + to, + slides: (function getSlides() { + const slidesToRender = []; + for (let i = from; i <= to; i += 1) { + slidesToRender.push(slides[i]); + } + return slidesToRender; + }()), + }); + onRendered(); + return; + } + const prependIndexes = []; + const appendIndexes = []; + if (force) { + swiper.$wrapperEl.find(`.${swiper.params.slideClass}`).remove(); + } else { + for (let i = previousFrom; i <= previousTo; i += 1) { + if (i < from || i > to) { + swiper.$wrapperEl.find(`.${swiper.params.slideClass}[data-swiper-slide-index="${i}"]`).remove(); + } + } + } + for (let i = 0; i < slides.length; i += 1) { + if (i >= from && i <= to) { + if (typeof previousTo === 'undefined' || force) { + appendIndexes.push(i); + } else { + if (i > previousTo) appendIndexes.push(i); + if (i < previousFrom) prependIndexes.push(i); + } + } + } + appendIndexes.forEach((index$$1) => { + swiper.$wrapperEl.append(renderSlide(slides[index$$1], index$$1)); + }); + prependIndexes.sort((a, b) => a < b).forEach((index$$1) => { + swiper.$wrapperEl.prepend(renderSlide(slides[index$$1], index$$1)); + }); + swiper.$wrapperEl.children('.swiper-slide').css(offsetProp, `${offset$$1}px`); + onRendered(); + }, + renderSlide(slide, index$$1) { + const swiper = this; + const params = swiper.params.virtual; + if (params.cache && swiper.virtual.cache[index$$1]) { + return swiper.virtual.cache[index$$1]; + } + const $slideEl = params.renderSlide + ? $(params.renderSlide.call(swiper, slide, index$$1)) + : $(`
    ${slide}
    `); + if (!$slideEl.attr('data-swiper-slide-index')) $slideEl.attr('data-swiper-slide-index', index$$1); + if (params.cache) swiper.virtual.cache[index$$1] = $slideEl; + return $slideEl; + }, + appendSlide(slide) { + const swiper = this; + swiper.virtual.slides.push(slide); + swiper.virtual.update(true); + }, + prependSlide(slide) { + const swiper = this; + swiper.virtual.slides.unshift(slide); + if (swiper.params.virtual.cache) { + const cache = swiper.virtual.cache; + const newCache = {}; + Object.keys(cache).forEach((cachedIndex) => { + newCache[cachedIndex + 1] = cache[cachedIndex]; + }); + swiper.virtual.cache = newCache; + } + swiper.virtual.update(true); + swiper.slideNext(0); + }, +}; + +var Virtual$1 = { + name: 'virtual', + params: { + virtual: { + enabled: false, + slides: [], + cache: true, + renderSlide: null, + renderExternal: null, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + virtual: { + update: Virtual.update.bind(swiper), + appendSlide: Virtual.appendSlide.bind(swiper), + prependSlide: Virtual.prependSlide.bind(swiper), + renderSlide: Virtual.renderSlide.bind(swiper), + slides: swiper.params.virtual.slides, + cache: {}, + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (!swiper.params.virtual.enabled) return; + swiper.classNames.push(`${swiper.params.containerModifierClass}virtual`); + const overwriteParams = { + watchSlidesProgress: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + + swiper.virtual.update(); + }, + setTranslate() { + const swiper = this; + if (!swiper.params.virtual.enabled) return; + swiper.virtual.update(); + }, + }, +}; + +const Keyboard = { + handle(event) { + const swiper = this; + const { rtlTranslate: rtl } = swiper; + let e = event; + if (e.originalEvent) e = e.originalEvent; // jquery fix + const kc = e.keyCode || e.charCode; + // Directions locks + if (!swiper.allowSlideNext && ((swiper.isHorizontal() && kc === 39) || (swiper.isVertical() && kc === 40))) { + return false; + } + if (!swiper.allowSlidePrev && ((swiper.isHorizontal() && kc === 37) || (swiper.isVertical() && kc === 38))) { + return false; + } + if (e.shiftKey || e.altKey || e.ctrlKey || e.metaKey) { + return undefined; + } + if (document.activeElement && document.activeElement.nodeName && (document.activeElement.nodeName.toLowerCase() === 'input' || document.activeElement.nodeName.toLowerCase() === 'textarea')) { + return undefined; + } + if (swiper.params.keyboard.onlyInViewport && (kc === 37 || kc === 39 || kc === 38 || kc === 40)) { + let inView = false; + // Check that swiper should be inside of visible area of window + if (swiper.$el.parents(`.${swiper.params.slideClass}`).length > 0 && swiper.$el.parents(`.${swiper.params.slideActiveClass}`).length === 0) { + return undefined; + } + const windowWidth = window.innerWidth; + const windowHeight = window.innerHeight; + const swiperOffset = swiper.$el.offset(); + if (rtl) swiperOffset.left -= swiper.$el[0].scrollLeft; + const swiperCoord = [ + [swiperOffset.left, swiperOffset.top], + [swiperOffset.left + swiper.width, swiperOffset.top], + [swiperOffset.left, swiperOffset.top + swiper.height], + [swiperOffset.left + swiper.width, swiperOffset.top + swiper.height], + ]; + for (let i = 0; i < swiperCoord.length; i += 1) { + const point = swiperCoord[i]; + if ( + point[0] >= 0 && point[0] <= windowWidth && + point[1] >= 0 && point[1] <= windowHeight + ) { + inView = true; + } + } + if (!inView) return undefined; + } + if (swiper.isHorizontal()) { + if (kc === 37 || kc === 39) { + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + } + if ((kc === 39 && !rtl) || (kc === 37 && rtl)) swiper.slideNext(); + if ((kc === 37 && !rtl) || (kc === 39 && rtl)) swiper.slidePrev(); + } else { + if (kc === 38 || kc === 40) { + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + } + if (kc === 40) swiper.slideNext(); + if (kc === 38) swiper.slidePrev(); + } + swiper.emit('keyPress', kc); + return undefined; + }, + enable() { + const swiper = this; + if (swiper.keyboard.enabled) return; + $(document).on('keydown', swiper.keyboard.handle); + swiper.keyboard.enabled = true; + }, + disable() { + const swiper = this; + if (!swiper.keyboard.enabled) return; + $(document).off('keydown', swiper.keyboard.handle); + swiper.keyboard.enabled = false; + }, +}; + +var Keyboard$1 = { + name: 'keyboard', + params: { + keyboard: { + enabled: false, + onlyInViewport: true, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + keyboard: { + enabled: false, + enable: Keyboard.enable.bind(swiper), + disable: Keyboard.disable.bind(swiper), + handle: Keyboard.handle.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.keyboard.enabled) { + swiper.keyboard.enable(); + } + }, + destroy() { + const swiper = this; + if (swiper.keyboard.enabled) { + swiper.keyboard.disable(); + } + }, + }, +}; + +function isEventSupported() { + const eventName = 'onwheel'; + let isSupported = eventName in document; + + if (!isSupported) { + const element = document.createElement('div'); + element.setAttribute(eventName, 'return;'); + isSupported = typeof element[eventName] === 'function'; + } + + if (!isSupported && + document.implementation && + document.implementation.hasFeature && + // always returns true in newer browsers as per the standard. + // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature + document.implementation.hasFeature('', '') !== true + ) { + // This is the only way to test support for the `wheel` event in IE9+. + isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); + } + + return isSupported; +} +const Mousewheel = { + lastScrollTime: Utils.now(), + event: (function getEvent() { + if (window.navigator.userAgent.indexOf('firefox') > -1) return 'DOMMouseScroll'; + return isEventSupported() ? 'wheel' : 'mousewheel'; + }()), + normalize(e) { + // Reasonable defaults + const PIXEL_STEP = 10; + const LINE_HEIGHT = 40; + const PAGE_HEIGHT = 800; + + let sX = 0; + let sY = 0; // spinX, spinY + let pX = 0; + let pY = 0; // pixelX, pixelY + + // Legacy + if ('detail' in e) { + sY = e.detail; + } + if ('wheelDelta' in e) { + sY = -e.wheelDelta / 120; + } + if ('wheelDeltaY' in e) { + sY = -e.wheelDeltaY / 120; + } + if ('wheelDeltaX' in e) { + sX = -e.wheelDeltaX / 120; + } + + // side scrolling on FF with DOMMouseScroll + if ('axis' in e && e.axis === e.HORIZONTAL_AXIS) { + sX = sY; + sY = 0; + } + + pX = sX * PIXEL_STEP; + pY = sY * PIXEL_STEP; + + if ('deltaY' in e) { + pY = e.deltaY; + } + if ('deltaX' in e) { + pX = e.deltaX; + } + + if ((pX || pY) && e.deltaMode) { + if (e.deltaMode === 1) { // delta in LINE units + pX *= LINE_HEIGHT; + pY *= LINE_HEIGHT; + } else { // delta in PAGE units + pX *= PAGE_HEIGHT; + pY *= PAGE_HEIGHT; + } + } + + // Fall-back if spin cannot be determined + if (pX && !sX) { + sX = (pX < 1) ? -1 : 1; + } + if (pY && !sY) { + sY = (pY < 1) ? -1 : 1; + } + + return { + spinX: sX, + spinY: sY, + pixelX: pX, + pixelY: pY, + }; + }, + handleMouseEnter() { + const swiper = this; + swiper.mouseEntered = true; + }, + handleMouseLeave() { + const swiper = this; + swiper.mouseEntered = false; + }, + handle(event) { + let e = event; + const swiper = this; + const params = swiper.params.mousewheel; + + if (!swiper.mouseEntered && !params.releaseOnEdges) return true; + + if (e.originalEvent) e = e.originalEvent; // jquery fix + let delta = 0; + const rtlFactor = swiper.rtlTranslate ? -1 : 1; + + const data$$1 = Mousewheel.normalize(e); + + if (params.forceToAxis) { + if (swiper.isHorizontal()) { + if (Math.abs(data$$1.pixelX) > Math.abs(data$$1.pixelY)) delta = data$$1.pixelX * rtlFactor; + else return true; + } else if (Math.abs(data$$1.pixelY) > Math.abs(data$$1.pixelX)) delta = data$$1.pixelY; + else return true; + } else { + delta = Math.abs(data$$1.pixelX) > Math.abs(data$$1.pixelY) ? -data$$1.pixelX * rtlFactor : -data$$1.pixelY; + } + + if (delta === 0) return true; + + if (params.invert) delta = -delta; + + if (!swiper.params.freeMode) { + if (Utils.now() - swiper.mousewheel.lastScrollTime > 60) { + if (delta < 0) { + if ((!swiper.isEnd || swiper.params.loop) && !swiper.animating) { + swiper.slideNext(); + swiper.emit('scroll', e); + } else if (params.releaseOnEdges) return true; + } else if ((!swiper.isBeginning || swiper.params.loop) && !swiper.animating) { + swiper.slidePrev(); + swiper.emit('scroll', e); + } else if (params.releaseOnEdges) return true; + } + swiper.mousewheel.lastScrollTime = (new window.Date()).getTime(); + } else { + // Freemode or scrollContainer: + if (swiper.params.loop) { + swiper.loopFix(); + } + let position = swiper.getTranslate() + (delta * params.sensitivity); + const wasBeginning = swiper.isBeginning; + const wasEnd = swiper.isEnd; + + if (position >= swiper.minTranslate()) position = swiper.minTranslate(); + if (position <= swiper.maxTranslate()) position = swiper.maxTranslate(); + + swiper.setTransition(0); + swiper.setTranslate(position); + swiper.updateProgress(); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + + if ((!wasBeginning && swiper.isBeginning) || (!wasEnd && swiper.isEnd)) { + swiper.updateSlidesClasses(); + } + + if (swiper.params.freeModeSticky) { + clearTimeout(swiper.mousewheel.timeout); + swiper.mousewheel.timeout = Utils.nextTick(() => { + swiper.slideToClosest(); + }, 300); + } + // Emit event + swiper.emit('scroll', e); + + // Stop autoplay + if (swiper.params.autoplay && swiper.params.autoplayDisableOnInteraction) swiper.stopAutoplay(); + // Return page scroll on edge positions + if (position === swiper.minTranslate() || position === swiper.maxTranslate()) return true; + } + + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + return false; + }, + enable() { + const swiper = this; + if (!Mousewheel.event) return false; + if (swiper.mousewheel.enabled) return false; + let target = swiper.$el; + if (swiper.params.mousewheel.eventsTarged !== 'container') { + target = $(swiper.params.mousewheel.eventsTarged); + } + target.on('mouseenter', swiper.mousewheel.handleMouseEnter); + target.on('mouseleave', swiper.mousewheel.handleMouseLeave); + target.on(Mousewheel.event, swiper.mousewheel.handle); + swiper.mousewheel.enabled = true; + return true; + }, + disable() { + const swiper = this; + if (!Mousewheel.event) return false; + if (!swiper.mousewheel.enabled) return false; + let target = swiper.$el; + if (swiper.params.mousewheel.eventsTarged !== 'container') { + target = $(swiper.params.mousewheel.eventsTarged); + } + target.off(Mousewheel.event, swiper.mousewheel.handle); + swiper.mousewheel.enabled = false; + return true; + }, +}; + +var Mousewheel$1 = { + name: 'mousewheel', + params: { + mousewheel: { + enabled: false, + releaseOnEdges: false, + invert: false, + forceToAxis: false, + sensitivity: 1, + eventsTarged: 'container', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + mousewheel: { + enabled: false, + enable: Mousewheel.enable.bind(swiper), + disable: Mousewheel.disable.bind(swiper), + handle: Mousewheel.handle.bind(swiper), + handleMouseEnter: Mousewheel.handleMouseEnter.bind(swiper), + handleMouseLeave: Mousewheel.handleMouseLeave.bind(swiper), + lastScrollTime: Utils.now(), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.mousewheel.enabled) swiper.mousewheel.enable(); + }, + destroy() { + const swiper = this; + if (swiper.mousewheel.enabled) swiper.mousewheel.disable(); + }, + }, +}; + +const Navigation = { + update() { + // Update Navigation Buttons + const swiper = this; + const params = swiper.params.navigation; + + if (swiper.params.loop) return; + const { $nextEl, $prevEl } = swiper.navigation; + + if ($prevEl && $prevEl.length > 0) { + if (swiper.isBeginning) { + $prevEl.addClass(params.disabledClass); + } else { + $prevEl.removeClass(params.disabledClass); + } + $prevEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + } + if ($nextEl && $nextEl.length > 0) { + if (swiper.isEnd) { + $nextEl.addClass(params.disabledClass); + } else { + $nextEl.removeClass(params.disabledClass); + } + $nextEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + } + }, + init() { + const swiper = this; + const params = swiper.params.navigation; + if (!(params.nextEl || params.prevEl)) return; + + let $nextEl; + let $prevEl; + if (params.nextEl) { + $nextEl = $(params.nextEl); + if ( + swiper.params.uniqueNavElements && + typeof params.nextEl === 'string' && + $nextEl.length > 1 && + swiper.$el.find(params.nextEl).length === 1 + ) { + $nextEl = swiper.$el.find(params.nextEl); + } + } + if (params.prevEl) { + $prevEl = $(params.prevEl); + if ( + swiper.params.uniqueNavElements && + typeof params.prevEl === 'string' && + $prevEl.length > 1 && + swiper.$el.find(params.prevEl).length === 1 + ) { + $prevEl = swiper.$el.find(params.prevEl); + } + } + + if ($nextEl && $nextEl.length > 0) { + $nextEl.on('click', (e) => { + e.preventDefault(); + if (swiper.isEnd && !swiper.params.loop) return; + swiper.slideNext(); + }); + } + if ($prevEl && $prevEl.length > 0) { + $prevEl.on('click', (e) => { + e.preventDefault(); + if (swiper.isBeginning && !swiper.params.loop) return; + swiper.slidePrev(); + }); + } + + Utils.extend(swiper.navigation, { + $nextEl, + nextEl: $nextEl && $nextEl[0], + $prevEl, + prevEl: $prevEl && $prevEl[0], + }); + }, + destroy() { + const swiper = this; + const { $nextEl, $prevEl } = swiper.navigation; + if ($nextEl && $nextEl.length) { + $nextEl.off('click'); + $nextEl.removeClass(swiper.params.navigation.disabledClass); + } + if ($prevEl && $prevEl.length) { + $prevEl.off('click'); + $prevEl.removeClass(swiper.params.navigation.disabledClass); + } + }, +}; + +var Navigation$1 = { + name: 'navigation', + params: { + navigation: { + nextEl: null, + prevEl: null, + + hideOnClick: false, + disabledClass: 'swiper-button-disabled', + hiddenClass: 'swiper-button-hidden', + lockClass: 'swiper-button-lock', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + navigation: { + init: Navigation.init.bind(swiper), + update: Navigation.update.bind(swiper), + destroy: Navigation.destroy.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.navigation.init(); + swiper.navigation.update(); + }, + toEdge() { + const swiper = this; + swiper.navigation.update(); + }, + fromEdge() { + const swiper = this; + swiper.navigation.update(); + }, + destroy() { + const swiper = this; + swiper.navigation.destroy(); + }, + click(e) { + const swiper = this; + const { $nextEl, $prevEl } = swiper.navigation; + if ( + swiper.params.navigation.hideOnClick && + !$(e.target).is($prevEl) && + !$(e.target).is($nextEl) + ) { + if ($nextEl) $nextEl.toggleClass(swiper.params.navigation.hiddenClass); + if ($prevEl) $prevEl.toggleClass(swiper.params.navigation.hiddenClass); + } + }, + }, +}; + +const Pagination = { + update() { + // Render || Update Pagination bullets/items + const swiper = this; + const rtl = swiper.rtl; + const params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) return; + const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length; + const $el = swiper.pagination.$el; + // Current/Total + let current; + const total = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length; + if (swiper.params.loop) { + current = Math.ceil((swiper.activeIndex - swiper.loopedSlides) / swiper.params.slidesPerGroup); + if (current > slidesLength - 1 - (swiper.loopedSlides * 2)) { + current -= (slidesLength - (swiper.loopedSlides * 2)); + } + if (current > total - 1) current -= total; + if (current < 0 && swiper.params.paginationType !== 'bullets') current = total + current; + } else if (typeof swiper.snapIndex !== 'undefined') { + current = swiper.snapIndex; + } else { + current = swiper.activeIndex || 0; + } + // Types + if (params.type === 'bullets' && swiper.pagination.bullets && swiper.pagination.bullets.length > 0) { + const bullets = swiper.pagination.bullets; + let firstIndex; + let lastIndex; + let midIndex; + if (params.dynamicBullets) { + swiper.pagination.bulletSize = bullets.eq(0)[swiper.isHorizontal() ? 'outerWidth' : 'outerHeight'](true); + $el.css(swiper.isHorizontal() ? 'width' : 'height', `${swiper.pagination.bulletSize * (params.dynamicMainBullets + 4)}px`); + if (params.dynamicMainBullets > 1 && swiper.previousIndex !== undefined) { + swiper.pagination.dynamicBulletIndex += (current - swiper.previousIndex); + if (swiper.pagination.dynamicBulletIndex > (params.dynamicMainBullets - 1)) { + swiper.pagination.dynamicBulletIndex = params.dynamicMainBullets - 1; + } else if (swiper.pagination.dynamicBulletIndex < 0) { + swiper.pagination.dynamicBulletIndex = 0; + } + } + firstIndex = current - swiper.pagination.dynamicBulletIndex; + lastIndex = firstIndex + (Math.min(bullets.length, params.dynamicMainBullets) - 1); + midIndex = (lastIndex + firstIndex) / 2; + } + bullets.removeClass(`${params.bulletActiveClass} ${params.bulletActiveClass}-next ${params.bulletActiveClass}-next-next ${params.bulletActiveClass}-prev ${params.bulletActiveClass}-prev-prev ${params.bulletActiveClass}-main`); + if ($el.length > 1) { + bullets.each((index$$1, bullet) => { + const $bullet = $(bullet); + const bulletIndex = $bullet.index(); + if (bulletIndex === current) { + $bullet.addClass(params.bulletActiveClass); + } + if (params.dynamicBullets) { + if (bulletIndex >= firstIndex && bulletIndex <= lastIndex) { + $bullet.addClass(`${params.bulletActiveClass}-main`); + } + if (bulletIndex === firstIndex) { + $bullet + .prev() + .addClass(`${params.bulletActiveClass}-prev`) + .prev() + .addClass(`${params.bulletActiveClass}-prev-prev`); + } + if (bulletIndex === lastIndex) { + $bullet + .next() + .addClass(`${params.bulletActiveClass}-next`) + .next() + .addClass(`${params.bulletActiveClass}-next-next`); + } + } + }); + } else { + const $bullet = bullets.eq(current); + $bullet.addClass(params.bulletActiveClass); + if (params.dynamicBullets) { + const $firstDisplayedBullet = bullets.eq(firstIndex); + const $lastDisplayedBullet = bullets.eq(lastIndex); + for (let i = firstIndex; i <= lastIndex; i += 1) { + bullets.eq(i).addClass(`${params.bulletActiveClass}-main`); + } + $firstDisplayedBullet + .prev() + .addClass(`${params.bulletActiveClass}-prev`) + .prev() + .addClass(`${params.bulletActiveClass}-prev-prev`); + $lastDisplayedBullet + .next() + .addClass(`${params.bulletActiveClass}-next`) + .next() + .addClass(`${params.bulletActiveClass}-next-next`); + } + } + if (params.dynamicBullets) { + const dynamicBulletsLength = Math.min(bullets.length, params.dynamicMainBullets + 4); + const bulletsOffset = (((swiper.pagination.bulletSize * dynamicBulletsLength) - (swiper.pagination.bulletSize)) / 2) - (midIndex * swiper.pagination.bulletSize); + const offsetProp = rtl ? 'right' : 'left'; + bullets.css(swiper.isHorizontal() ? offsetProp : 'top', `${bulletsOffset}px`); + } + } + if (params.type === 'fraction') { + $el.find(`.${params.currentClass}`).text(current + 1); + $el.find(`.${params.totalClass}`).text(total); + } + if (params.type === 'progressbar') { + let progressbarDirection; + if (params.progressbarOpposite) { + progressbarDirection = swiper.isHorizontal() ? 'vertical' : 'horizontal'; + } else { + progressbarDirection = swiper.isHorizontal() ? 'horizontal' : 'vertical'; + } + const scale = (current + 1) / total; + let scaleX = 1; + let scaleY = 1; + if (progressbarDirection === 'horizontal') { + scaleX = scale; + } else { + scaleY = scale; + } + $el.find(`.${params.progressbarFillClass}`).transform(`translate3d(0,0,0) scaleX(${scaleX}) scaleY(${scaleY})`).transition(swiper.params.speed); + } + if (params.type === 'custom' && params.renderCustom) { + $el.html(params.renderCustom(swiper, current + 1, total)); + swiper.emit('paginationRender', swiper, $el[0]); + } else { + swiper.emit('paginationUpdate', swiper, $el[0]); + } + $el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + }, + render() { + // Render Container + const swiper = this; + const params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) return; + const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length; + + const $el = swiper.pagination.$el; + let paginationHTML = ''; + if (params.type === 'bullets') { + const numberOfBullets = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length; + for (let i = 0; i < numberOfBullets; i += 1) { + if (params.renderBullet) { + paginationHTML += params.renderBullet.call(swiper, i, params.bulletClass); + } else { + paginationHTML += `<${params.bulletElement} class="${params.bulletClass}">`; + } + } + $el.html(paginationHTML); + swiper.pagination.bullets = $el.find(`.${params.bulletClass}`); + } + if (params.type === 'fraction') { + if (params.renderFraction) { + paginationHTML = params.renderFraction.call(swiper, params.currentClass, params.totalClass); + } else { + paginationHTML = + `` + + ' / ' + + ``; + } + $el.html(paginationHTML); + } + if (params.type === 'progressbar') { + if (params.renderProgressbar) { + paginationHTML = params.renderProgressbar.call(swiper, params.progressbarFillClass); + } else { + paginationHTML = ``; + } + $el.html(paginationHTML); + } + if (params.type !== 'custom') { + swiper.emit('paginationRender', swiper.pagination.$el[0]); + } + }, + init() { + const swiper = this; + const params = swiper.params.pagination; + if (!params.el) return; + + let $el = $(params.el); + if ($el.length === 0) return; + + if ( + swiper.params.uniqueNavElements && + typeof params.el === 'string' && + $el.length > 1 && + swiper.$el.find(params.el).length === 1 + ) { + $el = swiper.$el.find(params.el); + } + + if (params.type === 'bullets' && params.clickable) { + $el.addClass(params.clickableClass); + } + + $el.addClass(params.modifierClass + params.type); + + if (params.type === 'bullets' && params.dynamicBullets) { + $el.addClass(`${params.modifierClass}${params.type}-dynamic`); + swiper.pagination.dynamicBulletIndex = 0; + if (params.dynamicMainBullets < 1) { + params.dynamicMainBullets = 1; + } + } + if (params.type === 'progressbar' && params.progressbarOpposite) { + $el.addClass(params.progressbarOppositeClass); + } + + if (params.clickable) { + $el.on('click', `.${params.bulletClass}`, function onClick(e) { + e.preventDefault(); + let index$$1 = $(this).index() * swiper.params.slidesPerGroup; + if (swiper.params.loop) index$$1 += swiper.loopedSlides; + swiper.slideTo(index$$1); + }); + } + + Utils.extend(swiper.pagination, { + $el, + el: $el[0], + }); + }, + destroy() { + const swiper = this; + const params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) return; + const $el = swiper.pagination.$el; + + $el.removeClass(params.hiddenClass); + $el.removeClass(params.modifierClass + params.type); + if (swiper.pagination.bullets) swiper.pagination.bullets.removeClass(params.bulletActiveClass); + if (params.clickable) { + $el.off('click', `.${params.bulletClass}`); + } + }, +}; + +var Pagination$1 = { + name: 'pagination', + params: { + pagination: { + el: null, + bulletElement: 'span', + clickable: false, + hideOnClick: false, + renderBullet: null, + renderProgressbar: null, + renderFraction: null, + renderCustom: null, + progressbarOpposite: false, + type: 'bullets', // 'bullets' or 'progressbar' or 'fraction' or 'custom' + dynamicBullets: false, + dynamicMainBullets: 1, + bulletClass: 'swiper-pagination-bullet', + bulletActiveClass: 'swiper-pagination-bullet-active', + modifierClass: 'swiper-pagination-', // NEW + currentClass: 'swiper-pagination-current', + totalClass: 'swiper-pagination-total', + hiddenClass: 'swiper-pagination-hidden', + progressbarFillClass: 'swiper-pagination-progressbar-fill', + progressbarOppositeClass: 'swiper-pagination-progressbar-opposite', + clickableClass: 'swiper-pagination-clickable', // NEW + lockClass: 'swiper-pagination-lock', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + pagination: { + init: Pagination.init.bind(swiper), + render: Pagination.render.bind(swiper), + update: Pagination.update.bind(swiper), + destroy: Pagination.destroy.bind(swiper), + dynamicBulletIndex: 0, + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.pagination.init(); + swiper.pagination.render(); + swiper.pagination.update(); + }, + activeIndexChange() { + const swiper = this; + if (swiper.params.loop) { + swiper.pagination.update(); + } else if (typeof swiper.snapIndex === 'undefined') { + swiper.pagination.update(); + } + }, + snapIndexChange() { + const swiper = this; + if (!swiper.params.loop) { + swiper.pagination.update(); + } + }, + slidesLengthChange() { + const swiper = this; + if (swiper.params.loop) { + swiper.pagination.render(); + swiper.pagination.update(); + } + }, + snapGridLengthChange() { + const swiper = this; + if (!swiper.params.loop) { + swiper.pagination.render(); + swiper.pagination.update(); + } + }, + destroy() { + const swiper = this; + swiper.pagination.destroy(); + }, + click(e) { + const swiper = this; + if ( + swiper.params.pagination.el && + swiper.params.pagination.hideOnClick && + swiper.pagination.$el.length > 0 && + !$(e.target).hasClass(swiper.params.pagination.bulletClass) + ) { + swiper.pagination.$el.toggleClass(swiper.params.pagination.hiddenClass); + } + }, + }, +}; + +const Scrollbar = { + setTranslate() { + const swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return; + const { scrollbar, rtlTranslate: rtl, progress } = swiper; + const { + dragSize, trackSize, $dragEl, $el, + } = scrollbar; + const params = swiper.params.scrollbar; + + let newSize = dragSize; + let newPos = (trackSize - dragSize) * progress; + if (rtl) { + newPos = -newPos; + if (newPos > 0) { + newSize = dragSize - newPos; + newPos = 0; + } else if (-newPos + dragSize > trackSize) { + newSize = trackSize + newPos; + } + } else if (newPos < 0) { + newSize = dragSize + newPos; + newPos = 0; + } else if (newPos + dragSize > trackSize) { + newSize = trackSize - newPos; + } + if (swiper.isHorizontal()) { + if (Support.transforms3d) { + $dragEl.transform(`translate3d(${newPos}px, 0, 0)`); + } else { + $dragEl.transform(`translateX(${newPos}px)`); + } + $dragEl[0].style.width = `${newSize}px`; + } else { + if (Support.transforms3d) { + $dragEl.transform(`translate3d(0px, ${newPos}px, 0)`); + } else { + $dragEl.transform(`translateY(${newPos}px)`); + } + $dragEl[0].style.height = `${newSize}px`; + } + if (params.hide) { + clearTimeout(swiper.scrollbar.timeout); + $el[0].style.opacity = 1; + swiper.scrollbar.timeout = setTimeout(() => { + $el[0].style.opacity = 0; + $el.transition(400); + }, 1000); + } + }, + setTransition(duration) { + const swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return; + swiper.scrollbar.$dragEl.transition(duration); + }, + updateSize() { + const swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return; + + const { scrollbar } = swiper; + const { $dragEl, $el } = scrollbar; + + $dragEl[0].style.width = ''; + $dragEl[0].style.height = ''; + const trackSize = swiper.isHorizontal() ? $el[0].offsetWidth : $el[0].offsetHeight; + + const divider = swiper.size / swiper.virtualSize; + const moveDivider = divider * (trackSize / swiper.size); + let dragSize; + if (swiper.params.scrollbar.dragSize === 'auto') { + dragSize = trackSize * divider; + } else { + dragSize = parseInt(swiper.params.scrollbar.dragSize, 10); + } + + if (swiper.isHorizontal()) { + $dragEl[0].style.width = `${dragSize}px`; + } else { + $dragEl[0].style.height = `${dragSize}px`; + } + + if (divider >= 1) { + $el[0].style.display = 'none'; + } else { + $el[0].style.display = ''; + } + if (swiper.params.scrollbarHide) { + $el[0].style.opacity = 0; + } + Utils.extend(scrollbar, { + trackSize, + divider, + moveDivider, + dragSize, + }); + scrollbar.$el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](swiper.params.scrollbar.lockClass); + }, + setDragPosition(e) { + const swiper = this; + const { scrollbar, rtlTranslate: rtl } = swiper; + const { $el, dragSize, trackSize } = scrollbar; + + let pointerPosition; + if (swiper.isHorizontal()) { + pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageX : e.pageX || e.clientX); + } else { + pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageY : e.pageY || e.clientY); + } + let positionRatio; + positionRatio = ((pointerPosition) - $el.offset()[swiper.isHorizontal() ? 'left' : 'top'] - (dragSize / 2)) / (trackSize - dragSize); + positionRatio = Math.max(Math.min(positionRatio, 1), 0); + if (rtl) { + positionRatio = 1 - positionRatio; + } + + const position = swiper.minTranslate() + ((swiper.maxTranslate() - swiper.minTranslate()) * positionRatio); + + swiper.updateProgress(position); + swiper.setTranslate(position); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + }, + onDragStart(e) { + const swiper = this; + const params = swiper.params.scrollbar; + const { scrollbar, $wrapperEl } = swiper; + const { $el, $dragEl } = scrollbar; + swiper.scrollbar.isTouched = true; + e.preventDefault(); + e.stopPropagation(); + + $wrapperEl.transition(100); + $dragEl.transition(100); + scrollbar.setDragPosition(e); + + clearTimeout(swiper.scrollbar.dragTimeout); + + $el.transition(0); + if (params.hide) { + $el.css('opacity', 1); + } + swiper.emit('scrollbarDragStart', e); + }, + onDragMove(e) { + const swiper = this; + const { scrollbar, $wrapperEl } = swiper; + const { $el, $dragEl } = scrollbar; + + if (!swiper.scrollbar.isTouched) return; + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + scrollbar.setDragPosition(e); + $wrapperEl.transition(0); + $el.transition(0); + $dragEl.transition(0); + swiper.emit('scrollbarDragMove', e); + }, + onDragEnd(e) { + const swiper = this; + + const params = swiper.params.scrollbar; + const { scrollbar } = swiper; + const { $el } = scrollbar; + + if (!swiper.scrollbar.isTouched) return; + swiper.scrollbar.isTouched = false; + if (params.hide) { + clearTimeout(swiper.scrollbar.dragTimeout); + swiper.scrollbar.dragTimeout = Utils.nextTick(() => { + $el.css('opacity', 0); + $el.transition(400); + }, 1000); + } + swiper.emit('scrollbarDragEnd', e); + if (params.snapOnRelease) { + swiper.slideToClosest(); + } + }, + enableDraggable() { + const swiper = this; + if (!swiper.params.scrollbar.el) return; + const { + scrollbar, touchEvents, touchEventsDesktop, params, + } = swiper; + const $el = scrollbar.$el; + const target = $el[0]; + const activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false; + const passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false; + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.addEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener); + document.addEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener); + document.addEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener); + } else { + if (Support.touch) { + target.addEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener); + target.addEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener); + target.addEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.addEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener); + document.addEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener); + document.addEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener); + } + } + }, + disableDraggable() { + const swiper = this; + if (!swiper.params.scrollbar.el) return; + const { + scrollbar, touchEvents, touchEventsDesktop, params, + } = swiper; + const $el = scrollbar.$el; + const target = $el[0]; + const activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false; + const passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false; + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.removeEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener); + document.removeEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener); + document.removeEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener); + } else { + if (Support.touch) { + target.removeEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener); + target.removeEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener); + target.removeEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.removeEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener); + document.removeEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener); + document.removeEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener); + } + } + }, + init() { + const swiper = this; + if (!swiper.params.scrollbar.el) return; + const { scrollbar, $el: $swiperEl } = swiper; + const params = swiper.params.scrollbar; + + let $el = $(params.el); + if (swiper.params.uniqueNavElements && typeof params.el === 'string' && $el.length > 1 && $swiperEl.find(params.el).length === 1) { + $el = $swiperEl.find(params.el); + } + + let $dragEl = $el.find(`.${swiper.params.scrollbar.dragClass}`); + if ($dragEl.length === 0) { + $dragEl = $(`
    `); + $el.append($dragEl); + } + + Utils.extend(scrollbar, { + $el, + el: $el[0], + $dragEl, + dragEl: $dragEl[0], + }); + + if (params.draggable) { + scrollbar.enableDraggable(); + } + }, + destroy() { + const swiper = this; + swiper.scrollbar.disableDraggable(); + }, +}; + +var Scrollbar$1 = { + name: 'scrollbar', + params: { + scrollbar: { + el: null, + dragSize: 'auto', + hide: false, + draggable: false, + snapOnRelease: true, + lockClass: 'swiper-scrollbar-lock', + dragClass: 'swiper-scrollbar-drag', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + scrollbar: { + init: Scrollbar.init.bind(swiper), + destroy: Scrollbar.destroy.bind(swiper), + updateSize: Scrollbar.updateSize.bind(swiper), + setTranslate: Scrollbar.setTranslate.bind(swiper), + setTransition: Scrollbar.setTransition.bind(swiper), + enableDraggable: Scrollbar.enableDraggable.bind(swiper), + disableDraggable: Scrollbar.disableDraggable.bind(swiper), + setDragPosition: Scrollbar.setDragPosition.bind(swiper), + onDragStart: Scrollbar.onDragStart.bind(swiper), + onDragMove: Scrollbar.onDragMove.bind(swiper), + onDragEnd: Scrollbar.onDragEnd.bind(swiper), + isTouched: false, + timeout: null, + dragTimeout: null, + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.scrollbar.init(); + swiper.scrollbar.updateSize(); + swiper.scrollbar.setTranslate(); + }, + update() { + const swiper = this; + swiper.scrollbar.updateSize(); + }, + resize() { + const swiper = this; + swiper.scrollbar.updateSize(); + }, + observerUpdate() { + const swiper = this; + swiper.scrollbar.updateSize(); + }, + setTranslate() { + const swiper = this; + swiper.scrollbar.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + swiper.scrollbar.setTransition(duration); + }, + destroy() { + const swiper = this; + swiper.scrollbar.destroy(); + }, + }, +}; + +const Parallax = { + setTransform(el, progress) { + const swiper = this; + const { rtl } = swiper; + + const $el = $(el); + const rtlFactor = rtl ? -1 : 1; + + const p = $el.attr('data-swiper-parallax') || '0'; + let x = $el.attr('data-swiper-parallax-x'); + let y = $el.attr('data-swiper-parallax-y'); + const scale = $el.attr('data-swiper-parallax-scale'); + const opacity = $el.attr('data-swiper-parallax-opacity'); + + if (x || y) { + x = x || '0'; + y = y || '0'; + } else if (swiper.isHorizontal()) { + x = p; + y = '0'; + } else { + y = p; + x = '0'; + } + + if ((x).indexOf('%') >= 0) { + x = `${parseInt(x, 10) * progress * rtlFactor}%`; + } else { + x = `${x * progress * rtlFactor}px`; + } + if ((y).indexOf('%') >= 0) { + y = `${parseInt(y, 10) * progress}%`; + } else { + y = `${y * progress}px`; + } + + if (typeof opacity !== 'undefined' && opacity !== null) { + const currentOpacity = opacity - ((opacity - 1) * (1 - Math.abs(progress))); + $el[0].style.opacity = currentOpacity; + } + if (typeof scale === 'undefined' || scale === null) { + $el.transform(`translate3d(${x}, ${y}, 0px)`); + } else { + const currentScale = scale - ((scale - 1) * (1 - Math.abs(progress))); + $el.transform(`translate3d(${x}, ${y}, 0px) scale(${currentScale})`); + } + }, + setTranslate() { + const swiper = this; + const { + $el, slides, progress, snapGrid, + } = swiper; + $el.children('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each((index$$1, el) => { + swiper.parallax.setTransform(el, progress); + }); + slides.each((slideIndex, slideEl) => { + let slideProgress = slideEl.progress; + if (swiper.params.slidesPerGroup > 1 && swiper.params.slidesPerView !== 'auto') { + slideProgress += Math.ceil(slideIndex / 2) - (progress * (snapGrid.length - 1)); + } + slideProgress = Math.min(Math.max(slideProgress, -1), 1); + $(slideEl).find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each((index$$1, el) => { + swiper.parallax.setTransform(el, slideProgress); + }); + }); + }, + setTransition(duration = this.params.speed) { + const swiper = this; + const { $el } = swiper; + $el.find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each((index$$1, parallaxEl) => { + const $parallaxEl = $(parallaxEl); + let parallaxDuration = parseInt($parallaxEl.attr('data-swiper-parallax-duration'), 10) || duration; + if (duration === 0) parallaxDuration = 0; + $parallaxEl.transition(parallaxDuration); + }); + }, +}; + +var Parallax$1 = { + name: 'parallax', + params: { + parallax: { + enabled: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + parallax: { + setTransform: Parallax.setTransform.bind(swiper), + setTranslate: Parallax.setTranslate.bind(swiper), + setTransition: Parallax.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (!swiper.params.parallax.enabled) return; + swiper.params.watchSlidesProgress = true; + }, + init() { + const swiper = this; + if (!swiper.params.parallax) return; + swiper.parallax.setTranslate(); + }, + setTranslate() { + const swiper = this; + if (!swiper.params.parallax) return; + swiper.parallax.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (!swiper.params.parallax) return; + swiper.parallax.setTransition(duration); + }, + }, +}; + +const Zoom = { + // Calc Scale From Multi-touches + getDistanceBetweenTouches(e) { + if (e.targetTouches.length < 2) return 1; + const x1 = e.targetTouches[0].pageX; + const y1 = e.targetTouches[0].pageY; + const x2 = e.targetTouches[1].pageX; + const y2 = e.targetTouches[1].pageY; + const distance = Math.sqrt(((x2 - x1) ** 2) + ((y2 - y1) ** 2)); + return distance; + }, + // Events + onGestureStart(e) { + const swiper = this; + const params = swiper.params.zoom; + const zoom = swiper.zoom; + const { gesture } = zoom; + zoom.fakeGestureTouched = false; + zoom.fakeGestureMoved = false; + if (!Support.gestures) { + if (e.type !== 'touchstart' || (e.type === 'touchstart' && e.targetTouches.length < 2)) { + return; + } + zoom.fakeGestureTouched = true; + gesture.scaleStart = Zoom.getDistanceBetweenTouches(e); + } + if (!gesture.$slideEl || !gesture.$slideEl.length) { + gesture.$slideEl = $(e.target).closest('.swiper-slide'); + if (gesture.$slideEl.length === 0) gesture.$slideEl = swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(`.${params.containerClass}`); + gesture.maxRatio = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + if (gesture.$imageWrapEl.length === 0) { + gesture.$imageEl = undefined; + return; + } + } + gesture.$imageEl.transition(0); + swiper.zoom.isScaling = true; + }, + onGestureChange(e) { + const swiper = this; + const params = swiper.params.zoom; + const zoom = swiper.zoom; + const { gesture } = zoom; + if (!Support.gestures) { + if (e.type !== 'touchmove' || (e.type === 'touchmove' && e.targetTouches.length < 2)) { + return; + } + zoom.fakeGestureMoved = true; + gesture.scaleMove = Zoom.getDistanceBetweenTouches(e); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + if (Support.gestures) { + swiper.zoom.scale = e.scale * zoom.currentScale; + } else { + zoom.scale = (gesture.scaleMove / gesture.scaleStart) * zoom.currentScale; + } + if (zoom.scale > gesture.maxRatio) { + zoom.scale = (gesture.maxRatio - 1) + (((zoom.scale - gesture.maxRatio) + 1) ** 0.5); + } + if (zoom.scale < params.minRatio) { + zoom.scale = (params.minRatio + 1) - (((params.minRatio - zoom.scale) + 1) ** 0.5); + } + gesture.$imageEl.transform(`translate3d(0,0,0) scale(${zoom.scale})`); + }, + onGestureEnd(e) { + const swiper = this; + const params = swiper.params.zoom; + const zoom = swiper.zoom; + const { gesture } = zoom; + if (!Support.gestures) { + if (!zoom.fakeGestureTouched || !zoom.fakeGestureMoved) { + return; + } + if (e.type !== 'touchend' || (e.type === 'touchend' && e.changedTouches.length < 2 && !Device.android)) { + return; + } + zoom.fakeGestureTouched = false; + zoom.fakeGestureMoved = false; + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + zoom.scale = Math.max(Math.min(zoom.scale, gesture.maxRatio), params.minRatio); + gesture.$imageEl.transition(swiper.params.speed).transform(`translate3d(0,0,0) scale(${zoom.scale})`); + zoom.currentScale = zoom.scale; + zoom.isScaling = false; + if (zoom.scale === 1) gesture.$slideEl = undefined; + }, + onTouchStart(e) { + const swiper = this; + const zoom = swiper.zoom; + const { gesture, image } = zoom; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + if (image.isTouched) return; + if (Device.android) e.preventDefault(); + image.isTouched = true; + image.touchesStart.x = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX; + image.touchesStart.y = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY; + }, + onTouchMove(e) { + const swiper = this; + const zoom = swiper.zoom; + const { gesture, image, velocity } = zoom; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + swiper.allowClick = false; + if (!image.isTouched || !gesture.$slideEl) return; + + if (!image.isMoved) { + image.width = gesture.$imageEl[0].offsetWidth; + image.height = gesture.$imageEl[0].offsetHeight; + image.startX = Utils.getTranslate(gesture.$imageWrapEl[0], 'x') || 0; + image.startY = Utils.getTranslate(gesture.$imageWrapEl[0], 'y') || 0; + gesture.slideWidth = gesture.$slideEl[0].offsetWidth; + gesture.slideHeight = gesture.$slideEl[0].offsetHeight; + gesture.$imageWrapEl.transition(0); + if (swiper.rtl) { + image.startX = -image.startX; + image.startY = -image.startY; + } + } + // Define if we need image drag + const scaledWidth = image.width * zoom.scale; + const scaledHeight = image.height * zoom.scale; + + if (scaledWidth < gesture.slideWidth && scaledHeight < gesture.slideHeight) return; + + image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0); + image.maxX = -image.minX; + image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0); + image.maxY = -image.minY; + + image.touchesCurrent.x = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX; + image.touchesCurrent.y = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY; + + if (!image.isMoved && !zoom.isScaling) { + if ( + swiper.isHorizontal() && + ( + (Math.floor(image.minX) === Math.floor(image.startX) && image.touchesCurrent.x < image.touchesStart.x) || + (Math.floor(image.maxX) === Math.floor(image.startX) && image.touchesCurrent.x > image.touchesStart.x) + ) + ) { + image.isTouched = false; + return; + } else if ( + !swiper.isHorizontal() && + ( + (Math.floor(image.minY) === Math.floor(image.startY) && image.touchesCurrent.y < image.touchesStart.y) || + (Math.floor(image.maxY) === Math.floor(image.startY) && image.touchesCurrent.y > image.touchesStart.y) + ) + ) { + image.isTouched = false; + return; + } + } + e.preventDefault(); + e.stopPropagation(); + + image.isMoved = true; + image.currentX = (image.touchesCurrent.x - image.touchesStart.x) + image.startX; + image.currentY = (image.touchesCurrent.y - image.touchesStart.y) + image.startY; + + if (image.currentX < image.minX) { + image.currentX = (image.minX + 1) - (((image.minX - image.currentX) + 1) ** 0.8); + } + if (image.currentX > image.maxX) { + image.currentX = (image.maxX - 1) + (((image.currentX - image.maxX) + 1) ** 0.8); + } + + if (image.currentY < image.minY) { + image.currentY = (image.minY + 1) - (((image.minY - image.currentY) + 1) ** 0.8); + } + if (image.currentY > image.maxY) { + image.currentY = (image.maxY - 1) + (((image.currentY - image.maxY) + 1) ** 0.8); + } + + // Velocity + if (!velocity.prevPositionX) velocity.prevPositionX = image.touchesCurrent.x; + if (!velocity.prevPositionY) velocity.prevPositionY = image.touchesCurrent.y; + if (!velocity.prevTime) velocity.prevTime = Date.now(); + velocity.x = (image.touchesCurrent.x - velocity.prevPositionX) / (Date.now() - velocity.prevTime) / 2; + velocity.y = (image.touchesCurrent.y - velocity.prevPositionY) / (Date.now() - velocity.prevTime) / 2; + if (Math.abs(image.touchesCurrent.x - velocity.prevPositionX) < 2) velocity.x = 0; + if (Math.abs(image.touchesCurrent.y - velocity.prevPositionY) < 2) velocity.y = 0; + velocity.prevPositionX = image.touchesCurrent.x; + velocity.prevPositionY = image.touchesCurrent.y; + velocity.prevTime = Date.now(); + + gesture.$imageWrapEl.transform(`translate3d(${image.currentX}px, ${image.currentY}px,0)`); + }, + onTouchEnd() { + const swiper = this; + const zoom = swiper.zoom; + const { gesture, image, velocity } = zoom; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + if (!image.isTouched || !image.isMoved) { + image.isTouched = false; + image.isMoved = false; + return; + } + image.isTouched = false; + image.isMoved = false; + let momentumDurationX = 300; + let momentumDurationY = 300; + const momentumDistanceX = velocity.x * momentumDurationX; + const newPositionX = image.currentX + momentumDistanceX; + const momentumDistanceY = velocity.y * momentumDurationY; + const newPositionY = image.currentY + momentumDistanceY; + + // Fix duration + if (velocity.x !== 0) momentumDurationX = Math.abs((newPositionX - image.currentX) / velocity.x); + if (velocity.y !== 0) momentumDurationY = Math.abs((newPositionY - image.currentY) / velocity.y); + const momentumDuration = Math.max(momentumDurationX, momentumDurationY); + + image.currentX = newPositionX; + image.currentY = newPositionY; + + // Define if we need image drag + const scaledWidth = image.width * zoom.scale; + const scaledHeight = image.height * zoom.scale; + image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0); + image.maxX = -image.minX; + image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0); + image.maxY = -image.minY; + image.currentX = Math.max(Math.min(image.currentX, image.maxX), image.minX); + image.currentY = Math.max(Math.min(image.currentY, image.maxY), image.minY); + + gesture.$imageWrapEl.transition(momentumDuration).transform(`translate3d(${image.currentX}px, ${image.currentY}px,0)`); + }, + onTransitionEnd() { + const swiper = this; + const zoom = swiper.zoom; + const { gesture } = zoom; + if (gesture.$slideEl && swiper.previousIndex !== swiper.activeIndex) { + gesture.$imageEl.transform('translate3d(0,0,0) scale(1)'); + gesture.$imageWrapEl.transform('translate3d(0,0,0)'); + gesture.$slideEl = undefined; + gesture.$imageEl = undefined; + gesture.$imageWrapEl = undefined; + + zoom.scale = 1; + zoom.currentScale = 1; + } + }, + // Toggle Zoom + toggle(e) { + const swiper = this; + const zoom = swiper.zoom; + + if (zoom.scale && zoom.scale !== 1) { + // Zoom Out + zoom.out(); + } else { + // Zoom In + zoom.in(e); + } + }, + in(e) { + const swiper = this; + + const zoom = swiper.zoom; + const params = swiper.params.zoom; + const { gesture, image } = zoom; + + if (!gesture.$slideEl) { + gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(`.${params.containerClass}`); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + + gesture.$slideEl.addClass(`${params.zoomedSlideClass}`); + + let touchX; + let touchY; + let offsetX; + let offsetY; + let diffX; + let diffY; + let translateX; + let translateY; + let imageWidth; + let imageHeight; + let scaledWidth; + let scaledHeight; + let translateMinX; + let translateMinY; + let translateMaxX; + let translateMaxY; + let slideWidth; + let slideHeight; + + if (typeof image.touchesStart.x === 'undefined' && e) { + touchX = e.type === 'touchend' ? e.changedTouches[0].pageX : e.pageX; + touchY = e.type === 'touchend' ? e.changedTouches[0].pageY : e.pageY; + } else { + touchX = image.touchesStart.x; + touchY = image.touchesStart.y; + } + + zoom.scale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + zoom.currentScale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + if (e) { + slideWidth = gesture.$slideEl[0].offsetWidth; + slideHeight = gesture.$slideEl[0].offsetHeight; + offsetX = gesture.$slideEl.offset().left; + offsetY = gesture.$slideEl.offset().top; + diffX = (offsetX + (slideWidth / 2)) - touchX; + diffY = (offsetY + (slideHeight / 2)) - touchY; + + imageWidth = gesture.$imageEl[0].offsetWidth; + imageHeight = gesture.$imageEl[0].offsetHeight; + scaledWidth = imageWidth * zoom.scale; + scaledHeight = imageHeight * zoom.scale; + + translateMinX = Math.min(((slideWidth / 2) - (scaledWidth / 2)), 0); + translateMinY = Math.min(((slideHeight / 2) - (scaledHeight / 2)), 0); + translateMaxX = -translateMinX; + translateMaxY = -translateMinY; + + translateX = diffX * zoom.scale; + translateY = diffY * zoom.scale; + + if (translateX < translateMinX) { + translateX = translateMinX; + } + if (translateX > translateMaxX) { + translateX = translateMaxX; + } + + if (translateY < translateMinY) { + translateY = translateMinY; + } + if (translateY > translateMaxY) { + translateY = translateMaxY; + } + } else { + translateX = 0; + translateY = 0; + } + gesture.$imageWrapEl.transition(300).transform(`translate3d(${translateX}px, ${translateY}px,0)`); + gesture.$imageEl.transition(300).transform(`translate3d(0,0,0) scale(${zoom.scale})`); + }, + out() { + const swiper = this; + + const zoom = swiper.zoom; + const params = swiper.params.zoom; + const { gesture } = zoom; + + if (!gesture.$slideEl) { + gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(`.${params.containerClass}`); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + + zoom.scale = 1; + zoom.currentScale = 1; + gesture.$imageWrapEl.transition(300).transform('translate3d(0,0,0)'); + gesture.$imageEl.transition(300).transform('translate3d(0,0,0) scale(1)'); + gesture.$slideEl.removeClass(`${params.zoomedSlideClass}`); + gesture.$slideEl = undefined; + }, + // Attach/Detach Events + enable() { + const swiper = this; + const zoom = swiper.zoom; + if (zoom.enabled) return; + zoom.enabled = true; + + const passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false; + + // Scale image + if (Support.gestures) { + swiper.$wrapperEl.on('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.on('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.on('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener); + } else if (swiper.touchEvents.start === 'touchstart') { + swiper.$wrapperEl.on(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.on(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.on(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener); + } + + // Move image + swiper.$wrapperEl.on(swiper.touchEvents.move, `.${swiper.params.zoom.containerClass}`, zoom.onTouchMove); + }, + disable() { + const swiper = this; + const zoom = swiper.zoom; + if (!zoom.enabled) return; + + swiper.zoom.enabled = false; + + const passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false; + + // Scale image + if (Support.gestures) { + swiper.$wrapperEl.off('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.off('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.off('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener); + } else if (swiper.touchEvents.start === 'touchstart') { + swiper.$wrapperEl.off(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.off(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.off(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener); + } + + // Move image + swiper.$wrapperEl.off(swiper.touchEvents.move, `.${swiper.params.zoom.containerClass}`, zoom.onTouchMove); + }, +}; + +var Zoom$1 = { + name: 'zoom', + params: { + zoom: { + enabled: false, + maxRatio: 3, + minRatio: 1, + toggle: true, + containerClass: 'swiper-zoom-container', + zoomedSlideClass: 'swiper-slide-zoomed', + }, + }, + create() { + const swiper = this; + const zoom = { + enabled: false, + scale: 1, + currentScale: 1, + isScaling: false, + gesture: { + $slideEl: undefined, + slideWidth: undefined, + slideHeight: undefined, + $imageEl: undefined, + $imageWrapEl: undefined, + maxRatio: 3, + }, + image: { + isTouched: undefined, + isMoved: undefined, + currentX: undefined, + currentY: undefined, + minX: undefined, + minY: undefined, + maxX: undefined, + maxY: undefined, + width: undefined, + height: undefined, + startX: undefined, + startY: undefined, + touchesStart: {}, + touchesCurrent: {}, + }, + velocity: { + x: undefined, + y: undefined, + prevPositionX: undefined, + prevPositionY: undefined, + prevTime: undefined, + }, + }; + ('onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out').split(' ').forEach((methodName) => { + zoom[methodName] = Zoom[methodName].bind(swiper); + }); + Utils.extend(swiper, { + zoom, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.zoom.enabled) { + swiper.zoom.enable(); + } + }, + destroy() { + const swiper = this; + swiper.zoom.disable(); + }, + touchStart(e) { + const swiper = this; + if (!swiper.zoom.enabled) return; + swiper.zoom.onTouchStart(e); + }, + touchEnd(e) { + const swiper = this; + if (!swiper.zoom.enabled) return; + swiper.zoom.onTouchEnd(e); + }, + doubleTap(e) { + const swiper = this; + if (swiper.params.zoom.enabled && swiper.zoom.enabled && swiper.params.zoom.toggle) { + swiper.zoom.toggle(e); + } + }, + transitionEnd() { + const swiper = this; + if (swiper.zoom.enabled && swiper.params.zoom.enabled) { + swiper.zoom.onTransitionEnd(); + } + }, + }, +}; + +const Lazy = { + loadInSlide(index$$1, loadInDuplicate = true) { + const swiper = this; + const params = swiper.params.lazy; + if (typeof index$$1 === 'undefined') return; + if (swiper.slides.length === 0) return; + const isVirtual = swiper.virtual && swiper.params.virtual.enabled; + + const $slideEl = isVirtual + ? swiper.$wrapperEl.children(`.${swiper.params.slideClass}[data-swiper-slide-index="${index$$1}"]`) + : swiper.slides.eq(index$$1); + + let $images = $slideEl.find(`.${params.elementClass}:not(.${params.loadedClass}):not(.${params.loadingClass})`); + if ($slideEl.hasClass(params.elementClass) && !$slideEl.hasClass(params.loadedClass) && !$slideEl.hasClass(params.loadingClass)) { + $images = $images.add($slideEl[0]); + } + if ($images.length === 0) return; + + $images.each((imageIndex, imageEl) => { + const $imageEl = $(imageEl); + $imageEl.addClass(params.loadingClass); + + const background = $imageEl.attr('data-background'); + const src = $imageEl.attr('data-src'); + const srcset = $imageEl.attr('data-srcset'); + const sizes = $imageEl.attr('data-sizes'); + + swiper.loadImage($imageEl[0], (src || background), srcset, sizes, false, () => { + if (typeof swiper === 'undefined' || swiper === null || !swiper || (swiper && !swiper.params) || swiper.destroyed) return; + if (background) { + $imageEl.css('background-image', `url("${background}")`); + $imageEl.removeAttr('data-background'); + } else { + if (srcset) { + $imageEl.attr('srcset', srcset); + $imageEl.removeAttr('data-srcset'); + } + if (sizes) { + $imageEl.attr('sizes', sizes); + $imageEl.removeAttr('data-sizes'); + } + if (src) { + $imageEl.attr('src', src); + $imageEl.removeAttr('data-src'); + } + } + + $imageEl.addClass(params.loadedClass).removeClass(params.loadingClass); + $slideEl.find(`.${params.preloaderClass}`).remove(); + if (swiper.params.loop && loadInDuplicate) { + const slideOriginalIndex = $slideEl.attr('data-swiper-slide-index'); + if ($slideEl.hasClass(swiper.params.slideDuplicateClass)) { + const originalSlide = swiper.$wrapperEl.children(`[data-swiper-slide-index="${slideOriginalIndex}"]:not(.${swiper.params.slideDuplicateClass})`); + swiper.lazy.loadInSlide(originalSlide.index(), false); + } else { + const duplicatedSlide = swiper.$wrapperEl.children(`.${swiper.params.slideDuplicateClass}[data-swiper-slide-index="${slideOriginalIndex}"]`); + swiper.lazy.loadInSlide(duplicatedSlide.index(), false); + } + } + swiper.emit('lazyImageReady', $slideEl[0], $imageEl[0]); + }); + + swiper.emit('lazyImageLoad', $slideEl[0], $imageEl[0]); + }); + }, + load() { + const swiper = this; + const { + $wrapperEl, params: swiperParams, slides, activeIndex, + } = swiper; + const isVirtual = swiper.virtual && swiperParams.virtual.enabled; + const params = swiperParams.lazy; + + let slidesPerView = swiperParams.slidesPerView; + if (slidesPerView === 'auto') { + slidesPerView = 0; + } + + function slideExist(index$$1) { + if (isVirtual) { + if ($wrapperEl.children(`.${swiperParams.slideClass}[data-swiper-slide-index="${index$$1}"]`).length) { + return true; + } + } else if (slides[index$$1]) return true; + return false; + } + function slideIndex(slideEl) { + if (isVirtual) { + return $(slideEl).attr('data-swiper-slide-index'); + } + return $(slideEl).index(); + } + + if (!swiper.lazy.initialImageLoaded) swiper.lazy.initialImageLoaded = true; + if (swiper.params.watchSlidesVisibility) { + $wrapperEl.children(`.${swiperParams.slideVisibleClass}`).each((elIndex, slideEl) => { + const index$$1 = isVirtual ? $(slideEl).attr('data-swiper-slide-index') : $(slideEl).index(); + swiper.lazy.loadInSlide(index$$1); + }); + } else if (slidesPerView > 1) { + for (let i = activeIndex; i < activeIndex + slidesPerView; i += 1) { + if (slideExist(i)) swiper.lazy.loadInSlide(i); + } + } else { + swiper.lazy.loadInSlide(activeIndex); + } + if (params.loadPrevNext) { + if (slidesPerView > 1 || (params.loadPrevNextAmount && params.loadPrevNextAmount > 1)) { + const amount = params.loadPrevNextAmount; + const spv = slidesPerView; + const maxIndex = Math.min(activeIndex + spv + Math.max(amount, spv), slides.length); + const minIndex = Math.max(activeIndex - Math.max(spv, amount), 0); + // Next Slides + for (let i = activeIndex + slidesPerView; i < maxIndex; i += 1) { + if (slideExist(i)) swiper.lazy.loadInSlide(i); + } + // Prev Slides + for (let i = minIndex; i < activeIndex; i += 1) { + if (slideExist(i)) swiper.lazy.loadInSlide(i); + } + } else { + const nextSlide = $wrapperEl.children(`.${swiperParams.slideNextClass}`); + if (nextSlide.length > 0) swiper.lazy.loadInSlide(slideIndex(nextSlide)); + + const prevSlide = $wrapperEl.children(`.${swiperParams.slidePrevClass}`); + if (prevSlide.length > 0) swiper.lazy.loadInSlide(slideIndex(prevSlide)); + } + } + }, +}; + +var Lazy$1 = { + name: 'lazy', + params: { + lazy: { + enabled: false, + loadPrevNext: false, + loadPrevNextAmount: 1, + loadOnTransitionStart: false, + + elementClass: 'swiper-lazy', + loadingClass: 'swiper-lazy-loading', + loadedClass: 'swiper-lazy-loaded', + preloaderClass: 'swiper-lazy-preloader', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + lazy: { + initialImageLoaded: false, + load: Lazy.load.bind(swiper), + loadInSlide: Lazy.loadInSlide.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.lazy.enabled && swiper.params.preloadImages) { + swiper.params.preloadImages = false; + } + }, + init() { + const swiper = this; + if (swiper.params.lazy.enabled && !swiper.params.loop && swiper.params.initialSlide === 0) { + swiper.lazy.load(); + } + }, + scroll() { + const swiper = this; + if (swiper.params.freeMode && !swiper.params.freeModeSticky) { + swiper.lazy.load(); + } + }, + resize() { + const swiper = this; + if (swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + }, + scrollbarDragMove() { + const swiper = this; + if (swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + }, + transitionStart() { + const swiper = this; + if (swiper.params.lazy.enabled) { + if (swiper.params.lazy.loadOnTransitionStart || (!swiper.params.lazy.loadOnTransitionStart && !swiper.lazy.initialImageLoaded)) { + swiper.lazy.load(); + } + } + }, + transitionEnd() { + const swiper = this; + if (swiper.params.lazy.enabled && !swiper.params.lazy.loadOnTransitionStart) { + swiper.lazy.load(); + } + }, + }, +}; + +/* eslint no-bitwise: ["error", { "allow": [">>"] }] */ + +const Controller = { + LinearSpline: function LinearSpline(x, y) { + const binarySearch = (function search() { + let maxIndex; + let minIndex; + let guess; + return (array, val) => { + minIndex = -1; + maxIndex = array.length; + while (maxIndex - minIndex > 1) { + guess = maxIndex + minIndex >> 1; + if (array[guess] <= val) { + minIndex = guess; + } else { + maxIndex = guess; + } + } + return maxIndex; + }; + }()); + this.x = x; + this.y = y; + this.lastIndex = x.length - 1; + // Given an x value (x2), return the expected y2 value: + // (x1,y1) is the known point before given value, + // (x3,y3) is the known point after given value. + let i1; + let i3; + + this.interpolate = function interpolate(x2) { + if (!x2) return 0; + + // Get the indexes of x1 and x3 (the array indexes before and after given x2): + i3 = binarySearch(this.x, x2); + i1 = i3 - 1; + + // We have our indexes i1 & i3, so we can calculate already: + // y2 := ((x2−x1) × (y3−y1)) ÷ (x3−x1) + y1 + return (((x2 - this.x[i1]) * (this.y[i3] - this.y[i1])) / (this.x[i3] - this.x[i1])) + this.y[i1]; + }; + return this; + }, + // xxx: for now i will just save one spline function to to + getInterpolateFunction(c) { + const swiper = this; + if (!swiper.controller.spline) { + swiper.controller.spline = swiper.params.loop ? + new Controller.LinearSpline(swiper.slidesGrid, c.slidesGrid) : + new Controller.LinearSpline(swiper.snapGrid, c.snapGrid); + } + }, + setTranslate(setTranslate, byController) { + const swiper = this; + const controlled = swiper.controller.control; + let multiplier; + let controlledTranslate; + function setControlledTranslate(c) { + // this will create an Interpolate function based on the snapGrids + // x is the Grid of the scrolled scroller and y will be the controlled scroller + // it makes sense to create this only once and recall it for the interpolation + // the function does a lot of value caching for performance + const translate = swiper.rtlTranslate ? -swiper.translate : swiper.translate; + if (swiper.params.controller.by === 'slide') { + swiper.controller.getInterpolateFunction(c); + // i am not sure why the values have to be multiplicated this way, tried to invert the snapGrid + // but it did not work out + controlledTranslate = -swiper.controller.spline.interpolate(-translate); + } + + if (!controlledTranslate || swiper.params.controller.by === 'container') { + multiplier = (c.maxTranslate() - c.minTranslate()) / (swiper.maxTranslate() - swiper.minTranslate()); + controlledTranslate = ((translate - swiper.minTranslate()) * multiplier) + c.minTranslate(); + } + + if (swiper.params.controller.inverse) { + controlledTranslate = c.maxTranslate() - controlledTranslate; + } + c.updateProgress(controlledTranslate); + c.setTranslate(controlledTranslate, swiper); + c.updateActiveIndex(); + c.updateSlidesClasses(); + } + if (Array.isArray(controlled)) { + for (let i = 0; i < controlled.length; i += 1) { + if (controlled[i] !== byController && controlled[i] instanceof Swiper) { + setControlledTranslate(controlled[i]); + } + } + } else if (controlled instanceof Swiper && byController !== controlled) { + setControlledTranslate(controlled); + } + }, + setTransition(duration, byController) { + const swiper = this; + const controlled = swiper.controller.control; + let i; + function setControlledTransition(c) { + c.setTransition(duration, swiper); + if (duration !== 0) { + c.transitionStart(); + c.$wrapperEl.transitionEnd(() => { + if (!controlled) return; + if (c.params.loop && swiper.params.controller.by === 'slide') { + c.loopFix(); + } + c.transitionEnd(); + }); + } + } + if (Array.isArray(controlled)) { + for (i = 0; i < controlled.length; i += 1) { + if (controlled[i] !== byController && controlled[i] instanceof Swiper) { + setControlledTransition(controlled[i]); + } + } + } else if (controlled instanceof Swiper && byController !== controlled) { + setControlledTransition(controlled); + } + }, +}; +var Controller$1 = { + name: 'controller', + params: { + controller: { + control: undefined, + inverse: false, + by: 'slide', // or 'container' + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + controller: { + control: swiper.params.controller.control, + getInterpolateFunction: Controller.getInterpolateFunction.bind(swiper), + setTranslate: Controller.setTranslate.bind(swiper), + setTransition: Controller.setTransition.bind(swiper), + }, + }); + }, + on: { + update() { + const swiper = this; + if (!swiper.controller.control) return; + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + resize() { + const swiper = this; + if (!swiper.controller.control) return; + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + observerUpdate() { + const swiper = this; + if (!swiper.controller.control) return; + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + setTranslate(translate, byController) { + const swiper = this; + if (!swiper.controller.control) return; + swiper.controller.setTranslate(translate, byController); + }, + setTransition(duration, byController) { + const swiper = this; + if (!swiper.controller.control) return; + swiper.controller.setTransition(duration, byController); + }, + }, +}; + +const a11y = { + makeElFocusable($el) { + $el.attr('tabIndex', '0'); + return $el; + }, + addElRole($el, role) { + $el.attr('role', role); + return $el; + }, + addElLabel($el, label) { + $el.attr('aria-label', label); + return $el; + }, + disableEl($el) { + $el.attr('aria-disabled', true); + return $el; + }, + enableEl($el) { + $el.attr('aria-disabled', false); + return $el; + }, + onEnterKey(e) { + const swiper = this; + const params = swiper.params.a11y; + if (e.keyCode !== 13) return; + const $targetEl = $(e.target); + if (swiper.navigation && swiper.navigation.$nextEl && $targetEl.is(swiper.navigation.$nextEl)) { + if (!(swiper.isEnd && !swiper.params.loop)) { + swiper.slideNext(); + } + if (swiper.isEnd) { + swiper.a11y.notify(params.lastSlideMessage); + } else { + swiper.a11y.notify(params.nextSlideMessage); + } + } + if (swiper.navigation && swiper.navigation.$prevEl && $targetEl.is(swiper.navigation.$prevEl)) { + if (!(swiper.isBeginning && !swiper.params.loop)) { + swiper.slidePrev(); + } + if (swiper.isBeginning) { + swiper.a11y.notify(params.firstSlideMessage); + } else { + swiper.a11y.notify(params.prevSlideMessage); + } + } + if (swiper.pagination && $targetEl.is(`.${swiper.params.pagination.bulletClass}`)) { + $targetEl[0].click(); + } + }, + notify(message) { + const swiper = this; + const notification = swiper.a11y.liveRegion; + if (notification.length === 0) return; + notification.html(''); + notification.html(message); + }, + updateNavigation() { + const swiper = this; + + if (swiper.params.loop) return; + const { $nextEl, $prevEl } = swiper.navigation; + + if ($prevEl && $prevEl.length > 0) { + if (swiper.isBeginning) { + swiper.a11y.disableEl($prevEl); + } else { + swiper.a11y.enableEl($prevEl); + } + } + if ($nextEl && $nextEl.length > 0) { + if (swiper.isEnd) { + swiper.a11y.disableEl($nextEl); + } else { + swiper.a11y.enableEl($nextEl); + } + } + }, + updatePagination() { + const swiper = this; + const params = swiper.params.a11y; + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.bullets.each((bulletIndex, bulletEl) => { + const $bulletEl = $(bulletEl); + swiper.a11y.makeElFocusable($bulletEl); + swiper.a11y.addElRole($bulletEl, 'button'); + swiper.a11y.addElLabel($bulletEl, params.paginationBulletMessage.replace(/{{index}}/, $bulletEl.index() + 1)); + }); + } + }, + init() { + const swiper = this; + + swiper.$el.append(swiper.a11y.liveRegion); + + // Navigation + const params = swiper.params.a11y; + let $nextEl; + let $prevEl; + if (swiper.navigation && swiper.navigation.$nextEl) { + $nextEl = swiper.navigation.$nextEl; + } + if (swiper.navigation && swiper.navigation.$prevEl) { + $prevEl = swiper.navigation.$prevEl; + } + if ($nextEl) { + swiper.a11y.makeElFocusable($nextEl); + swiper.a11y.addElRole($nextEl, 'button'); + swiper.a11y.addElLabel($nextEl, params.nextSlideMessage); + $nextEl.on('keydown', swiper.a11y.onEnterKey); + } + if ($prevEl) { + swiper.a11y.makeElFocusable($prevEl); + swiper.a11y.addElRole($prevEl, 'button'); + swiper.a11y.addElLabel($prevEl, params.prevSlideMessage); + $prevEl.on('keydown', swiper.a11y.onEnterKey); + } + + // Pagination + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.$el.on('keydown', `.${swiper.params.pagination.bulletClass}`, swiper.a11y.onEnterKey); + } + }, + destroy() { + const swiper = this; + if (swiper.a11y.liveRegion && swiper.a11y.liveRegion.length > 0) swiper.a11y.liveRegion.remove(); + + let $nextEl; + let $prevEl; + if (swiper.navigation && swiper.navigation.$nextEl) { + $nextEl = swiper.navigation.$nextEl; + } + if (swiper.navigation && swiper.navigation.$prevEl) { + $prevEl = swiper.navigation.$prevEl; + } + if ($nextEl) { + $nextEl.off('keydown', swiper.a11y.onEnterKey); + } + if ($prevEl) { + $prevEl.off('keydown', swiper.a11y.onEnterKey); + } + + // Pagination + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.$el.off('keydown', `.${swiper.params.pagination.bulletClass}`, swiper.a11y.onEnterKey); + } + }, +}; +var A11y = { + name: 'a11y', + params: { + a11y: { + enabled: true, + notificationClass: 'swiper-notification', + prevSlideMessage: 'Previous slide', + nextSlideMessage: 'Next slide', + firstSlideMessage: 'This is the first slide', + lastSlideMessage: 'This is the last slide', + paginationBulletMessage: 'Go to slide {{index}}', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + a11y: { + liveRegion: $(``), + }, + }); + Object.keys(a11y).forEach((methodName) => { + swiper.a11y[methodName] = a11y[methodName].bind(swiper); + }); + }, + on: { + init() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.init(); + swiper.a11y.updateNavigation(); + }, + toEdge() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.updateNavigation(); + }, + fromEdge() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.updateNavigation(); + }, + paginationUpdate() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.updatePagination(); + }, + destroy() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.destroy(); + }, + }, +}; + +const History = { + init() { + const swiper = this; + if (!swiper.params.history) return; + if (!window.history || !window.history.pushState) { + swiper.params.history.enabled = false; + swiper.params.hashNavigation.enabled = true; + return; + } + const history = swiper.history; + history.initialized = true; + history.paths = History.getPathValues(); + if (!history.paths.key && !history.paths.value) return; + history.scrollToSlide(0, history.paths.value, swiper.params.runCallbacksOnInit); + if (!swiper.params.history.replaceState) { + window.addEventListener('popstate', swiper.history.setHistoryPopState); + } + }, + destroy() { + const swiper = this; + if (!swiper.params.history.replaceState) { + window.removeEventListener('popstate', swiper.history.setHistoryPopState); + } + }, + setHistoryPopState() { + const swiper = this; + swiper.history.paths = History.getPathValues(); + swiper.history.scrollToSlide(swiper.params.speed, swiper.history.paths.value, false); + }, + getPathValues() { + const pathArray = window.location.pathname.slice(1).split('/').filter(part => part !== ''); + const total = pathArray.length; + const key = pathArray[total - 2]; + const value = pathArray[total - 1]; + return { key, value }; + }, + setHistory(key, index$$1) { + const swiper = this; + if (!swiper.history.initialized || !swiper.params.history.enabled) return; + const slide = swiper.slides.eq(index$$1); + let value = History.slugify(slide.attr('data-history')); + if (!window.location.pathname.includes(key)) { + value = `${key}/${value}`; + } + const currentState = window.history.state; + if (currentState && currentState.value === value) { + return; + } + if (swiper.params.history.replaceState) { + window.history.replaceState({ value }, null, value); + } else { + window.history.pushState({ value }, null, value); + } + }, + slugify(text$$1) { + return text$$1.toString().toLowerCase() + .replace(/\s+/g, '-') + .replace(/[^\w-]+/g, '') + .replace(/--+/g, '-') + .replace(/^-+/, '') + .replace(/-+$/, ''); + }, + scrollToSlide(speed, value, runCallbacks) { + const swiper = this; + if (value) { + for (let i = 0, length = swiper.slides.length; i < length; i += 1) { + const slide = swiper.slides.eq(i); + const slideHistory = History.slugify(slide.attr('data-history')); + if (slideHistory === value && !slide.hasClass(swiper.params.slideDuplicateClass)) { + const index$$1 = slide.index(); + swiper.slideTo(index$$1, speed, runCallbacks); + } + } + } else { + swiper.slideTo(0, speed, runCallbacks); + } + }, +}; + +var History$1 = { + name: 'history', + params: { + history: { + enabled: false, + replaceState: false, + key: 'slides', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + history: { + init: History.init.bind(swiper), + setHistory: History.setHistory.bind(swiper), + setHistoryPopState: History.setHistoryPopState.bind(swiper), + scrollToSlide: History.scrollToSlide.bind(swiper), + destroy: History.destroy.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.history.enabled) { + swiper.history.init(); + } + }, + destroy() { + const swiper = this; + if (swiper.params.history.enabled) { + swiper.history.destroy(); + } + }, + transitionEnd() { + const swiper = this; + if (swiper.history.initialized) { + swiper.history.setHistory(swiper.params.history.key, swiper.activeIndex); + } + }, + }, +}; + +const HashNavigation = { + onHashCange() { + const swiper = this; + const newHash = document.location.hash.replace('#', ''); + const activeSlideHash = swiper.slides.eq(swiper.activeIndex).attr('data-hash'); + if (newHash !== activeSlideHash) { + swiper.slideTo(swiper.$wrapperEl.children(`.${swiper.params.slideClass}[data-hash="${newHash}"]`).index()); + } + }, + setHash() { + const swiper = this; + if (!swiper.hashNavigation.initialized || !swiper.params.hashNavigation.enabled) return; + if (swiper.params.hashNavigation.replaceState && window.history && window.history.replaceState) { + window.history.replaceState(null, null, (`#${swiper.slides.eq(swiper.activeIndex).attr('data-hash')}` || '')); + } else { + const slide = swiper.slides.eq(swiper.activeIndex); + const hash = slide.attr('data-hash') || slide.attr('data-history'); + document.location.hash = hash || ''; + } + }, + init() { + const swiper = this; + if (!swiper.params.hashNavigation.enabled || (swiper.params.history && swiper.params.history.enabled)) return; + swiper.hashNavigation.initialized = true; + const hash = document.location.hash.replace('#', ''); + if (hash) { + const speed = 0; + for (let i = 0, length = swiper.slides.length; i < length; i += 1) { + const slide = swiper.slides.eq(i); + const slideHash = slide.attr('data-hash') || slide.attr('data-history'); + if (slideHash === hash && !slide.hasClass(swiper.params.slideDuplicateClass)) { + const index$$1 = slide.index(); + swiper.slideTo(index$$1, speed, swiper.params.runCallbacksOnInit, true); + } + } + } + if (swiper.params.hashNavigation.watchState) { + $(window).on('hashchange', swiper.hashNavigation.onHashCange); + } + }, + destroy() { + const swiper = this; + if (swiper.params.hashNavigation.watchState) { + $(window).off('hashchange', swiper.hashNavigation.onHashCange); + } + }, +}; +var HashNavigation$1 = { + name: 'hash-navigation', + params: { + hashNavigation: { + enabled: false, + replaceState: false, + watchState: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + hashNavigation: { + initialized: false, + init: HashNavigation.init.bind(swiper), + destroy: HashNavigation.destroy.bind(swiper), + setHash: HashNavigation.setHash.bind(swiper), + onHashCange: HashNavigation.onHashCange.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.hashNavigation.enabled) { + swiper.hashNavigation.init(); + } + }, + destroy() { + const swiper = this; + if (swiper.params.hashNavigation.enabled) { + swiper.hashNavigation.destroy(); + } + }, + transitionEnd() { + const swiper = this; + if (swiper.hashNavigation.initialized) { + swiper.hashNavigation.setHash(); + } + }, + }, +}; + +/* eslint no-underscore-dangle: "off" */ + +const Autoplay = { + run() { + const swiper = this; + const $activeSlideEl = swiper.slides.eq(swiper.activeIndex); + let delay = swiper.params.autoplay.delay; + if ($activeSlideEl.attr('data-swiper-autoplay')) { + delay = $activeSlideEl.attr('data-swiper-autoplay') || swiper.params.autoplay.delay; + } + swiper.autoplay.timeout = Utils.nextTick(() => { + if (swiper.params.autoplay.reverseDirection) { + if (swiper.params.loop) { + swiper.loopFix(); + swiper.slidePrev(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.isBeginning) { + swiper.slidePrev(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.params.autoplay.stopOnLastSlide) { + swiper.slideTo(swiper.slides.length - 1, swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else { + swiper.autoplay.stop(); + } + } else if (swiper.params.loop) { + swiper.loopFix(); + swiper.slideNext(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.isEnd) { + swiper.slideNext(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.params.autoplay.stopOnLastSlide) { + swiper.slideTo(0, swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else { + swiper.autoplay.stop(); + } + }, delay); + }, + start() { + const swiper = this; + if (typeof swiper.autoplay.timeout !== 'undefined') return false; + if (swiper.autoplay.running) return false; + swiper.autoplay.running = true; + swiper.emit('autoplayStart'); + swiper.autoplay.run(); + return true; + }, + stop() { + const swiper = this; + if (!swiper.autoplay.running) return false; + if (typeof swiper.autoplay.timeout === 'undefined') return false; + + if (swiper.autoplay.timeout) { + clearTimeout(swiper.autoplay.timeout); + swiper.autoplay.timeout = undefined; + } + swiper.autoplay.running = false; + swiper.emit('autoplayStop'); + return true; + }, + pause(speed) { + const swiper = this; + if (!swiper.autoplay.running) return; + if (swiper.autoplay.paused) return; + if (swiper.autoplay.timeout) clearTimeout(swiper.autoplay.timeout); + swiper.autoplay.paused = true; + if (speed === 0 || !swiper.params.autoplay.waitForTransition) { + swiper.autoplay.paused = false; + swiper.autoplay.run(); + } else { + swiper.$wrapperEl[0].addEventListener('transitionend', swiper.autoplay.onTransitionEnd); + swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd); + } + }, +}; + +var Autoplay$1 = { + name: 'autoplay', + params: { + autoplay: { + enabled: false, + delay: 3000, + waitForTransition: true, + disableOnInteraction: true, + stopOnLastSlide: false, + reverseDirection: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + autoplay: { + running: false, + paused: false, + run: Autoplay.run.bind(swiper), + start: Autoplay.start.bind(swiper), + stop: Autoplay.stop.bind(swiper), + pause: Autoplay.pause.bind(swiper), + onTransitionEnd(e) { + if (!swiper || swiper.destroyed || !swiper.$wrapperEl) return; + if (e.target !== this) return; + swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.autoplay.onTransitionEnd); + swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd); + swiper.autoplay.paused = false; + if (!swiper.autoplay.running) { + swiper.autoplay.stop(); + } else { + swiper.autoplay.run(); + } + }, + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.autoplay.enabled) { + swiper.autoplay.start(); + } + }, + beforeTransitionStart(speed, internal) { + const swiper = this; + if (swiper.autoplay.running) { + if (internal || !swiper.params.autoplay.disableOnInteraction) { + swiper.autoplay.pause(speed); + } else { + swiper.autoplay.stop(); + } + } + }, + sliderFirstMove() { + const swiper = this; + if (swiper.autoplay.running) { + if (swiper.params.autoplay.disableOnInteraction) { + swiper.autoplay.stop(); + } else { + swiper.autoplay.pause(); + } + } + }, + destroy() { + const swiper = this; + if (swiper.autoplay.running) { + swiper.autoplay.stop(); + } + }, + }, +}; + +const Fade = { + setTranslate() { + const swiper = this; + const { slides } = swiper; + for (let i = 0; i < slides.length; i += 1) { + const $slideEl = swiper.slides.eq(i); + const offset$$1 = $slideEl[0].swiperSlideOffset; + let tx = -offset$$1; + if (!swiper.params.virtualTranslate) tx -= swiper.translate; + let ty = 0; + if (!swiper.isHorizontal()) { + ty = tx; + tx = 0; + } + const slideOpacity = swiper.params.fadeEffect.crossFade ? + Math.max(1 - Math.abs($slideEl[0].progress), 0) : + 1 + Math.min(Math.max($slideEl[0].progress, -1), 0); + $slideEl + .css({ + opacity: slideOpacity, + }) + .transform(`translate3d(${tx}px, ${ty}px, 0px)`); + } + }, + setTransition(duration) { + const swiper = this; + const { slides, $wrapperEl } = swiper; + slides.transition(duration); + if (swiper.params.virtualTranslate && duration !== 0) { + let eventTriggered = false; + slides.transitionEnd(() => { + if (eventTriggered) return; + if (!swiper || swiper.destroyed) return; + eventTriggered = true; + swiper.animating = false; + const triggerEvents = ['webkitTransitionEnd', 'transitionend']; + for (let i = 0; i < triggerEvents.length; i += 1) { + $wrapperEl.trigger(triggerEvents[i]); + } + }); + } + }, +}; + +var EffectFade = { + name: 'effect-fade', + params: { + fadeEffect: { + crossFade: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + fadeEffect: { + setTranslate: Fade.setTranslate.bind(swiper), + setTransition: Fade.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'fade') return; + swiper.classNames.push(`${swiper.params.containerModifierClass}fade`); + const overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + spaceBetween: 0, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'fade') return; + swiper.fadeEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'fade') return; + swiper.fadeEffect.setTransition(duration); + }, + }, +}; + +const Cube = { + setTranslate() { + const swiper = this; + const { + $el, $wrapperEl, slides, width: swiperWidth, height: swiperHeight, rtlTranslate: rtl, size: swiperSize, + } = swiper; + const params = swiper.params.cubeEffect; + const isHorizontal = swiper.isHorizontal(); + const isVirtual = swiper.virtual && swiper.params.virtual.enabled; + let wrapperRotate = 0; + let $cubeShadowEl; + if (params.shadow) { + if (isHorizontal) { + $cubeShadowEl = $wrapperEl.find('.swiper-cube-shadow'); + if ($cubeShadowEl.length === 0) { + $cubeShadowEl = $('
    '); + $wrapperEl.append($cubeShadowEl); + } + $cubeShadowEl.css({ height: `${swiperWidth}px` }); + } else { + $cubeShadowEl = $el.find('.swiper-cube-shadow'); + if ($cubeShadowEl.length === 0) { + $cubeShadowEl = $('
    '); + $el.append($cubeShadowEl); + } + } + } + for (let i = 0; i < slides.length; i += 1) { + const $slideEl = slides.eq(i); + let slideIndex = i; + if (isVirtual) { + slideIndex = parseInt($slideEl.attr('data-swiper-slide-index'), 10); + } + let slideAngle = slideIndex * 90; + let round = Math.floor(slideAngle / 360); + if (rtl) { + slideAngle = -slideAngle; + round = Math.floor(-slideAngle / 360); + } + const progress = Math.max(Math.min($slideEl[0].progress, 1), -1); + let tx = 0; + let ty = 0; + let tz = 0; + if (slideIndex % 4 === 0) { + tx = -round * 4 * swiperSize; + tz = 0; + } else if ((slideIndex - 1) % 4 === 0) { + tx = 0; + tz = -round * 4 * swiperSize; + } else if ((slideIndex - 2) % 4 === 0) { + tx = swiperSize + (round * 4 * swiperSize); + tz = swiperSize; + } else if ((slideIndex - 3) % 4 === 0) { + tx = -swiperSize; + tz = (3 * swiperSize) + (swiperSize * 4 * round); + } + if (rtl) { + tx = -tx; + } + + if (!isHorizontal) { + ty = tx; + tx = 0; + } + + const transform$$1 = `rotateX(${isHorizontal ? 0 : -slideAngle}deg) rotateY(${isHorizontal ? slideAngle : 0}deg) translate3d(${tx}px, ${ty}px, ${tz}px)`; + if (progress <= 1 && progress > -1) { + wrapperRotate = (slideIndex * 90) + (progress * 90); + if (rtl) wrapperRotate = (-slideIndex * 90) - (progress * 90); + } + $slideEl.transform(transform$$1); + if (params.slideShadows) { + // Set shadows + let shadowBefore = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + let shadowAfter = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if (shadowBefore.length === 0) { + shadowBefore = $(`
    `); + $slideEl.append(shadowBefore); + } + if (shadowAfter.length === 0) { + shadowAfter = $(`
    `); + $slideEl.append(shadowAfter); + } + if (shadowBefore.length) shadowBefore[0].style.opacity = Math.max(-progress, 0); + if (shadowAfter.length) shadowAfter[0].style.opacity = Math.max(progress, 0); + } + } + $wrapperEl.css({ + '-webkit-transform-origin': `50% 50% -${swiperSize / 2}px`, + '-moz-transform-origin': `50% 50% -${swiperSize / 2}px`, + '-ms-transform-origin': `50% 50% -${swiperSize / 2}px`, + 'transform-origin': `50% 50% -${swiperSize / 2}px`, + }); + + if (params.shadow) { + if (isHorizontal) { + $cubeShadowEl.transform(`translate3d(0px, ${(swiperWidth / 2) + params.shadowOffset}px, ${-swiperWidth / 2}px) rotateX(90deg) rotateZ(0deg) scale(${params.shadowScale})`); + } else { + const shadowAngle = Math.abs(wrapperRotate) - (Math.floor(Math.abs(wrapperRotate) / 90) * 90); + const multiplier = 1.5 - ( + (Math.sin((shadowAngle * 2 * Math.PI) / 360) / 2) + + (Math.cos((shadowAngle * 2 * Math.PI) / 360) / 2) + ); + const scale1 = params.shadowScale; + const scale2 = params.shadowScale / multiplier; + const offset$$1 = params.shadowOffset; + $cubeShadowEl.transform(`scale3d(${scale1}, 1, ${scale2}) translate3d(0px, ${(swiperHeight / 2) + offset$$1}px, ${-swiperHeight / 2 / scale2}px) rotateX(-90deg)`); + } + } + const zFactor = (Browser.isSafari || Browser.isUiWebView) ? (-swiperSize / 2) : 0; + $wrapperEl + .transform(`translate3d(0px,0,${zFactor}px) rotateX(${swiper.isHorizontal() ? 0 : wrapperRotate}deg) rotateY(${swiper.isHorizontal() ? -wrapperRotate : 0}deg)`); + }, + setTransition(duration) { + const swiper = this; + const { $el, slides } = swiper; + slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + if (swiper.params.cubeEffect.shadow && !swiper.isHorizontal()) { + $el.find('.swiper-cube-shadow').transition(duration); + } + }, +}; + +var EffectCube = { + name: 'effect-cube', + params: { + cubeEffect: { + slideShadows: true, + shadow: true, + shadowOffset: 20, + shadowScale: 0.94, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + cubeEffect: { + setTranslate: Cube.setTranslate.bind(swiper), + setTransition: Cube.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'cube') return; + swiper.classNames.push(`${swiper.params.containerModifierClass}cube`); + swiper.classNames.push(`${swiper.params.containerModifierClass}3d`); + const overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + resistanceRatio: 0, + spaceBetween: 0, + centeredSlides: false, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'cube') return; + swiper.cubeEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'cube') return; + swiper.cubeEffect.setTransition(duration); + }, + }, +}; + +const Flip = { + setTranslate() { + const swiper = this; + const { slides, rtlTranslate: rtl } = swiper; + for (let i = 0; i < slides.length; i += 1) { + const $slideEl = slides.eq(i); + let progress = $slideEl[0].progress; + if (swiper.params.flipEffect.limitRotation) { + progress = Math.max(Math.min($slideEl[0].progress, 1), -1); + } + const offset$$1 = $slideEl[0].swiperSlideOffset; + const rotate = -180 * progress; + let rotateY = rotate; + let rotateX = 0; + let tx = -offset$$1; + let ty = 0; + if (!swiper.isHorizontal()) { + ty = tx; + tx = 0; + rotateX = -rotateY; + rotateY = 0; + } else if (rtl) { + rotateY = -rotateY; + } + + $slideEl[0].style.zIndex = -Math.abs(Math.round(progress)) + slides.length; + + if (swiper.params.flipEffect.slideShadows) { + // Set shadows + let shadowBefore = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + let shadowAfter = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if (shadowBefore.length === 0) { + shadowBefore = $(`
    `); + $slideEl.append(shadowBefore); + } + if (shadowAfter.length === 0) { + shadowAfter = $(`
    `); + $slideEl.append(shadowAfter); + } + if (shadowBefore.length) shadowBefore[0].style.opacity = Math.max(-progress, 0); + if (shadowAfter.length) shadowAfter[0].style.opacity = Math.max(progress, 0); + } + $slideEl + .transform(`translate3d(${tx}px, ${ty}px, 0px) rotateX(${rotateX}deg) rotateY(${rotateY}deg)`); + } + }, + setTransition(duration) { + const swiper = this; + const { slides, activeIndex, $wrapperEl } = swiper; + slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + if (swiper.params.virtualTranslate && duration !== 0) { + let eventTriggered = false; + // eslint-disable-next-line + slides.eq(activeIndex).transitionEnd(function onTransitionEnd() { + if (eventTriggered) return; + if (!swiper || swiper.destroyed) return; + // if (!$(this).hasClass(swiper.params.slideActiveClass)) return; + eventTriggered = true; + swiper.animating = false; + const triggerEvents = ['webkitTransitionEnd', 'transitionend']; + for (let i = 0; i < triggerEvents.length; i += 1) { + $wrapperEl.trigger(triggerEvents[i]); + } + }); + } + }, +}; + +var EffectFlip = { + name: 'effect-flip', + params: { + flipEffect: { + slideShadows: true, + limitRotation: true, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + flipEffect: { + setTranslate: Flip.setTranslate.bind(swiper), + setTransition: Flip.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'flip') return; + swiper.classNames.push(`${swiper.params.containerModifierClass}flip`); + swiper.classNames.push(`${swiper.params.containerModifierClass}3d`); + const overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + spaceBetween: 0, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'flip') return; + swiper.flipEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'flip') return; + swiper.flipEffect.setTransition(duration); + }, + }, +}; + +const Coverflow = { + setTranslate() { + const swiper = this; + const { + width: swiperWidth, height: swiperHeight, slides, $wrapperEl, slidesSizesGrid, + } = swiper; + const params = swiper.params.coverflowEffect; + const isHorizontal = swiper.isHorizontal(); + const transform$$1 = swiper.translate; + const center = isHorizontal ? -transform$$1 + (swiperWidth / 2) : -transform$$1 + (swiperHeight / 2); + const rotate = isHorizontal ? params.rotate : -params.rotate; + const translate = params.depth; + // Each slide offset from center + for (let i = 0, length = slides.length; i < length; i += 1) { + const $slideEl = slides.eq(i); + const slideSize = slidesSizesGrid[i]; + const slideOffset = $slideEl[0].swiperSlideOffset; + const offsetMultiplier = ((center - slideOffset - (slideSize / 2)) / slideSize) * params.modifier; + + let rotateY = isHorizontal ? rotate * offsetMultiplier : 0; + let rotateX = isHorizontal ? 0 : rotate * offsetMultiplier; + // var rotateZ = 0 + let translateZ = -translate * Math.abs(offsetMultiplier); + + let translateY = isHorizontal ? 0 : params.stretch * (offsetMultiplier); + let translateX = isHorizontal ? params.stretch * (offsetMultiplier) : 0; + + // Fix for ultra small values + if (Math.abs(translateX) < 0.001) translateX = 0; + if (Math.abs(translateY) < 0.001) translateY = 0; + if (Math.abs(translateZ) < 0.001) translateZ = 0; + if (Math.abs(rotateY) < 0.001) rotateY = 0; + if (Math.abs(rotateX) < 0.001) rotateX = 0; + + const slideTransform = `translate3d(${translateX}px,${translateY}px,${translateZ}px) rotateX(${rotateX}deg) rotateY(${rotateY}deg)`; + + $slideEl.transform(slideTransform); + $slideEl[0].style.zIndex = -Math.abs(Math.round(offsetMultiplier)) + 1; + if (params.slideShadows) { + // Set shadows + let $shadowBeforeEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + let $shadowAfterEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if ($shadowBeforeEl.length === 0) { + $shadowBeforeEl = $(`
    `); + $slideEl.append($shadowBeforeEl); + } + if ($shadowAfterEl.length === 0) { + $shadowAfterEl = $(`
    `); + $slideEl.append($shadowAfterEl); + } + if ($shadowBeforeEl.length) $shadowBeforeEl[0].style.opacity = offsetMultiplier > 0 ? offsetMultiplier : 0; + if ($shadowAfterEl.length) $shadowAfterEl[0].style.opacity = (-offsetMultiplier) > 0 ? -offsetMultiplier : 0; + } + } + + // Set correct perspective for IE10 + if (Support.pointerEvents || Support.prefixedPointerEvents) { + const ws = $wrapperEl[0].style; + ws.perspectiveOrigin = `${center}px 50%`; + } + }, + setTransition(duration) { + const swiper = this; + swiper.slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + }, +}; + +var EffectCoverflow = { + name: 'effect-coverflow', + params: { + coverflowEffect: { + rotate: 50, + stretch: 0, + depth: 100, + modifier: 1, + slideShadows: true, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + coverflowEffect: { + setTranslate: Coverflow.setTranslate.bind(swiper), + setTransition: Coverflow.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'coverflow') return; + + swiper.classNames.push(`${swiper.params.containerModifierClass}coverflow`); + swiper.classNames.push(`${swiper.params.containerModifierClass}3d`); + + swiper.params.watchSlidesProgress = true; + swiper.originalParams.watchSlidesProgress = true; + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'coverflow') return; + swiper.coverflowEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'coverflow') return; + swiper.coverflowEffect.setTransition(duration); + }, + }, +}; + +// Swiper Class + +const components = [ + Device$1, + Support$1, + Browser$1, + Resize, + Observer$1, + Virtual$1, + Keyboard$1, + Mousewheel$1, + Navigation$1, + Pagination$1, + Scrollbar$1, + Parallax$1, + Zoom$1, + Lazy$1, + Controller$1, + A11y, + History$1, + HashNavigation$1, + Autoplay$1, + EffectFade, + EffectCube, + EffectFlip, + EffectCoverflow +]; + +if (typeof Swiper.use === 'undefined') { + Swiper.use = Swiper.Class.use; + Swiper.installModule = Swiper.Class.installModule; +} + +Swiper.use(components); + +export default Swiper; diff --git a/static/swiper/js/swiper.esm.js b/static/swiper/js/swiper.esm.js new file mode 100644 index 0000000..a172da1 --- /dev/null +++ b/static/swiper/js/swiper.esm.js @@ -0,0 +1,6605 @@ +/** + * Swiper 4.2.6 + * Most modern mobile touch slider and framework with hardware accelerated transitions + * http://www.idangero.us/swiper/ + * + * Copyright 2014-2018 Vladimir Kharlampidi + * + * Released under the MIT License + * + * Released on: May 1, 2018 + */ + +import { $, addClass, removeClass, hasClass, toggleClass, attr, removeAttr, data, transform, transition, on, off, trigger, transitionEnd, outerWidth, outerHeight, offset, css, each, html, text, is, index, eq, append, prepend, next, nextAll, prev, prevAll, parent, parents, closest, find, children, remove, add, styles } from 'dom7/dist/dom7.modular'; +import { window, document } from 'ssr-window'; + +const Methods = { + addClass, + removeClass, + hasClass, + toggleClass, + attr, + removeAttr, + data, + transform, + transition, + on, + off, + trigger, + transitionEnd, + outerWidth, + outerHeight, + offset, + css, + each, + html, + text, + is, + index, + eq, + append, + prepend, + next, + nextAll, + prev, + prevAll, + parent, + parents, + closest, + find, + children, + remove, + add, + styles, +}; + +Object.keys(Methods).forEach((methodName) => { + $.fn[methodName] = Methods[methodName]; +}); + +const Utils = { + deleteProps(obj) { + const object = obj; + Object.keys(object).forEach((key) => { + try { + object[key] = null; + } catch (e) { + // no getter for object + } + try { + delete object[key]; + } catch (e) { + // something got wrong + } + }); + }, + nextTick(callback, delay = 0) { + return setTimeout(callback, delay); + }, + now() { + return Date.now(); + }, + getTranslate(el, axis = 'x') { + let matrix; + let curTransform; + let transformMatrix; + + const curStyle = window.getComputedStyle(el, null); + + if (window.WebKitCSSMatrix) { + curTransform = curStyle.transform || curStyle.webkitTransform; + if (curTransform.split(',').length > 6) { + curTransform = curTransform.split(', ').map(a => a.replace(',', '.')).join(', '); + } + // Some old versions of Webkit choke when 'none' is passed; pass + // empty string instead in this case + transformMatrix = new window.WebKitCSSMatrix(curTransform === 'none' ? '' : curTransform); + } else { + transformMatrix = curStyle.MozTransform || curStyle.OTransform || curStyle.MsTransform || curStyle.msTransform || curStyle.transform || curStyle.getPropertyValue('transform').replace('translate(', 'matrix(1, 0, 0, 1,'); + matrix = transformMatrix.toString().split(','); + } + + if (axis === 'x') { + // Latest Chrome and webkits Fix + if (window.WebKitCSSMatrix) curTransform = transformMatrix.m41; + // Crazy IE10 Matrix + else if (matrix.length === 16) curTransform = parseFloat(matrix[12]); + // Normal Browsers + else curTransform = parseFloat(matrix[4]); + } + if (axis === 'y') { + // Latest Chrome and webkits Fix + if (window.WebKitCSSMatrix) curTransform = transformMatrix.m42; + // Crazy IE10 Matrix + else if (matrix.length === 16) curTransform = parseFloat(matrix[13]); + // Normal Browsers + else curTransform = parseFloat(matrix[5]); + } + return curTransform || 0; + }, + parseUrlQuery(url) { + const query = {}; + let urlToParse = url || window.location.href; + let i; + let params; + let param; + let length; + if (typeof urlToParse === 'string' && urlToParse.length) { + urlToParse = urlToParse.indexOf('?') > -1 ? urlToParse.replace(/\S*\?/, '') : ''; + params = urlToParse.split('&').filter(paramsPart => paramsPart !== ''); + length = params.length; + + for (i = 0; i < length; i += 1) { + param = params[i].replace(/#\S+/g, '').split('='); + query[decodeURIComponent(param[0])] = typeof param[1] === 'undefined' ? undefined : decodeURIComponent(param[1]) || ''; + } + } + return query; + }, + isObject(o) { + return typeof o === 'object' && o !== null && o.constructor && o.constructor === Object; + }, + extend(...args) { + const to = Object(args[0]); + for (let i = 1; i < args.length; i += 1) { + const nextSource = args[i]; + if (nextSource !== undefined && nextSource !== null) { + const keysArray = Object.keys(Object(nextSource)); + for (let nextIndex = 0, len = keysArray.length; nextIndex < len; nextIndex += 1) { + const nextKey = keysArray[nextIndex]; + const desc = Object.getOwnPropertyDescriptor(nextSource, nextKey); + if (desc !== undefined && desc.enumerable) { + if (Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) { + Utils.extend(to[nextKey], nextSource[nextKey]); + } else if (!Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) { + to[nextKey] = {}; + Utils.extend(to[nextKey], nextSource[nextKey]); + } else { + to[nextKey] = nextSource[nextKey]; + } + } + } + } + } + return to; + }, +}; + +const Support = (function Support() { + const testDiv = document.createElement('div'); + return { + touch: (window.Modernizr && window.Modernizr.touch === true) || (function checkTouch() { + return !!(('ontouchstart' in window) || (window.DocumentTouch && document instanceof window.DocumentTouch)); + }()), + + pointerEvents: !!(window.navigator.pointerEnabled || window.PointerEvent), + prefixedPointerEvents: !!window.navigator.msPointerEnabled, + + transition: (function checkTransition() { + const style = testDiv.style; + return ('transition' in style || 'webkitTransition' in style || 'MozTransition' in style); + }()), + transforms3d: (window.Modernizr && window.Modernizr.csstransforms3d === true) || (function checkTransforms3d() { + const style = testDiv.style; + return ('webkitPerspective' in style || 'MozPerspective' in style || 'OPerspective' in style || 'MsPerspective' in style || 'perspective' in style); + }()), + + flexbox: (function checkFlexbox() { + const style = testDiv.style; + const styles$$1 = ('alignItems webkitAlignItems webkitBoxAlign msFlexAlign mozBoxAlign webkitFlexDirection msFlexDirection mozBoxDirection mozBoxOrient webkitBoxDirection webkitBoxOrient').split(' '); + for (let i = 0; i < styles$$1.length; i += 1) { + if (styles$$1[i] in style) return true; + } + return false; + }()), + + observer: (function checkObserver() { + return ('MutationObserver' in window || 'WebkitMutationObserver' in window); + }()), + + passiveListener: (function checkPassiveListener() { + let supportsPassive = false; + try { + const opts = Object.defineProperty({}, 'passive', { + // eslint-disable-next-line + get() { + supportsPassive = true; + }, + }); + window.addEventListener('testPassiveListener', null, opts); + } catch (e) { + // No support + } + return supportsPassive; + }()), + + gestures: (function checkGestures() { + return 'ongesturestart' in window; + }()), + }; +}()); + +class SwiperClass { + constructor(params = {}) { + const self = this; + self.params = params; + + // Events + self.eventsListeners = {}; + + if (self.params && self.params.on) { + Object.keys(self.params.on).forEach((eventName) => { + self.on(eventName, self.params.on[eventName]); + }); + } + } + on(events, handler, priority) { + const self = this; + if (typeof handler !== 'function') return self; + const method = priority ? 'unshift' : 'push'; + events.split(' ').forEach((event) => { + if (!self.eventsListeners[event]) self.eventsListeners[event] = []; + self.eventsListeners[event][method](handler); + }); + return self; + } + once(events, handler, priority) { + const self = this; + if (typeof handler !== 'function') return self; + function onceHandler(...args) { + handler.apply(self, args); + self.off(events, onceHandler); + } + return self.on(events, onceHandler, priority); + } + off(events, handler) { + const self = this; + if (!self.eventsListeners) return self; + events.split(' ').forEach((event) => { + if (typeof handler === 'undefined') { + self.eventsListeners[event] = []; + } else { + self.eventsListeners[event].forEach((eventHandler, index$$1) => { + if (eventHandler === handler) { + self.eventsListeners[event].splice(index$$1, 1); + } + }); + } + }); + return self; + } + emit(...args) { + const self = this; + if (!self.eventsListeners) return self; + let events; + let data$$1; + let context; + if (typeof args[0] === 'string' || Array.isArray(args[0])) { + events = args[0]; + data$$1 = args.slice(1, args.length); + context = self; + } else { + events = args[0].events; + data$$1 = args[0].data; + context = args[0].context || self; + } + const eventsArray = Array.isArray(events) ? events : events.split(' '); + eventsArray.forEach((event) => { + if (self.eventsListeners && self.eventsListeners[event]) { + const handlers = []; + self.eventsListeners[event].forEach((eventHandler) => { + handlers.push(eventHandler); + }); + handlers.forEach((eventHandler) => { + eventHandler.apply(context, data$$1); + }); + } + }); + return self; + } + useModulesParams(instanceParams) { + const instance = this; + if (!instance.modules) return; + Object.keys(instance.modules).forEach((moduleName) => { + const module = instance.modules[moduleName]; + // Extend params + if (module.params) { + Utils.extend(instanceParams, module.params); + } + }); + } + useModules(modulesParams = {}) { + const instance = this; + if (!instance.modules) return; + Object.keys(instance.modules).forEach((moduleName) => { + const module = instance.modules[moduleName]; + const moduleParams = modulesParams[moduleName] || {}; + // Extend instance methods and props + if (module.instance) { + Object.keys(module.instance).forEach((modulePropName) => { + const moduleProp = module.instance[modulePropName]; + if (typeof moduleProp === 'function') { + instance[modulePropName] = moduleProp.bind(instance); + } else { + instance[modulePropName] = moduleProp; + } + }); + } + // Add event listeners + if (module.on && instance.on) { + Object.keys(module.on).forEach((moduleEventName) => { + instance.on(moduleEventName, module.on[moduleEventName]); + }); + } + + // Module create callback + if (module.create) { + module.create.bind(instance)(moduleParams); + } + }); + } + static set components(components) { + const Class = this; + if (!Class.use) return; + Class.use(components); + } + static installModule(module, ...params) { + const Class = this; + if (!Class.prototype.modules) Class.prototype.modules = {}; + const name = module.name || (`${Object.keys(Class.prototype.modules).length}_${Utils.now()}`); + Class.prototype.modules[name] = module; + // Prototype + if (module.proto) { + Object.keys(module.proto).forEach((key) => { + Class.prototype[key] = module.proto[key]; + }); + } + // Class + if (module.static) { + Object.keys(module.static).forEach((key) => { + Class[key] = module.static[key]; + }); + } + // Callback + if (module.install) { + module.install.apply(Class, params); + } + return Class; + } + static use(module, ...params) { + const Class = this; + if (Array.isArray(module)) { + module.forEach(m => Class.installModule(m)); + return Class; + } + return Class.installModule(module, ...params); + } +} + +function updateSize () { + const swiper = this; + let width; + let height; + const $el = swiper.$el; + if (typeof swiper.params.width !== 'undefined') { + width = swiper.params.width; + } else { + width = $el[0].clientWidth; + } + if (typeof swiper.params.height !== 'undefined') { + height = swiper.params.height; + } else { + height = $el[0].clientHeight; + } + if ((width === 0 && swiper.isHorizontal()) || (height === 0 && swiper.isVertical())) { + return; + } + + // Subtract paddings + width = width - parseInt($el.css('padding-left'), 10) - parseInt($el.css('padding-right'), 10); + height = height - parseInt($el.css('padding-top'), 10) - parseInt($el.css('padding-bottom'), 10); + + Utils.extend(swiper, { + width, + height, + size: swiper.isHorizontal() ? width : height, + }); +} + +function updateSlides () { + const swiper = this; + const params = swiper.params; + + const { + $wrapperEl, size: swiperSize, rtlTranslate: rtl, wrongRTL, + } = swiper; + const slides = $wrapperEl.children(`.${swiper.params.slideClass}`); + const isVirtual = swiper.virtual && params.virtual.enabled; + const slidesLength = isVirtual ? swiper.virtual.slides.length : slides.length; + let snapGrid = []; + const slidesGrid = []; + const slidesSizesGrid = []; + + let offsetBefore = params.slidesOffsetBefore; + if (typeof offsetBefore === 'function') { + offsetBefore = params.slidesOffsetBefore.call(swiper); + } + + let offsetAfter = params.slidesOffsetAfter; + if (typeof offsetAfter === 'function') { + offsetAfter = params.slidesOffsetAfter.call(swiper); + } + + const previousSlidesLength = slidesLength; + const previousSnapGridLength = swiper.snapGrid.length; + const previousSlidesGridLength = swiper.snapGrid.length; + + let spaceBetween = params.spaceBetween; + let slidePosition = -offsetBefore; + let prevSlideSize = 0; + let index$$1 = 0; + if (typeof swiperSize === 'undefined') { + return; + } + if (typeof spaceBetween === 'string' && spaceBetween.indexOf('%') >= 0) { + spaceBetween = (parseFloat(spaceBetween.replace('%', '')) / 100) * swiperSize; + } + + swiper.virtualSize = -spaceBetween; + + // reset margins + if (rtl) slides.css({ marginLeft: '', marginTop: '' }); + else slides.css({ marginRight: '', marginBottom: '' }); + + let slidesNumberEvenToRows; + if (params.slidesPerColumn > 1) { + if (Math.floor(slidesLength / params.slidesPerColumn) === slidesLength / swiper.params.slidesPerColumn) { + slidesNumberEvenToRows = slidesLength; + } else { + slidesNumberEvenToRows = Math.ceil(slidesLength / params.slidesPerColumn) * params.slidesPerColumn; + } + if (params.slidesPerView !== 'auto' && params.slidesPerColumnFill === 'row') { + slidesNumberEvenToRows = Math.max(slidesNumberEvenToRows, params.slidesPerView * params.slidesPerColumn); + } + } + + // Calc slides + let slideSize; + const slidesPerColumn = params.slidesPerColumn; + const slidesPerRow = slidesNumberEvenToRows / slidesPerColumn; + const numFullColumns = slidesPerRow - ((params.slidesPerColumn * slidesPerRow) - slidesLength); + for (let i = 0; i < slidesLength; i += 1) { + slideSize = 0; + const slide = slides.eq(i); + if (params.slidesPerColumn > 1) { + // Set slides order + let newSlideOrderIndex; + let column; + let row; + if (params.slidesPerColumnFill === 'column') { + column = Math.floor(i / slidesPerColumn); + row = i - (column * slidesPerColumn); + if (column > numFullColumns || (column === numFullColumns && row === slidesPerColumn - 1)) { + row += 1; + if (row >= slidesPerColumn) { + row = 0; + column += 1; + } + } + newSlideOrderIndex = column + ((row * slidesNumberEvenToRows) / slidesPerColumn); + slide + .css({ + '-webkit-box-ordinal-group': newSlideOrderIndex, + '-moz-box-ordinal-group': newSlideOrderIndex, + '-ms-flex-order': newSlideOrderIndex, + '-webkit-order': newSlideOrderIndex, + order: newSlideOrderIndex, + }); + } else { + row = Math.floor(i / slidesPerRow); + column = i - (row * slidesPerRow); + } + slide + .css( + `margin-${swiper.isHorizontal() ? 'top' : 'left'}`, + (row !== 0 && params.spaceBetween) && (`${params.spaceBetween}px`) + ) + .attr('data-swiper-column', column) + .attr('data-swiper-row', row); + } + if (slide.css('display') === 'none') continue; // eslint-disable-line + + if (params.slidesPerView === 'auto') { + const slideStyles = window.getComputedStyle(slide[0], null); + const currentTransform = slide[0].style.transform; + if (currentTransform) { + slide[0].style.transform = 'none'; + } + if (swiper.isHorizontal()) { + slideSize = slide[0].getBoundingClientRect().width + + parseFloat(slideStyles.getPropertyValue('margin-left')) + + parseFloat(slideStyles.getPropertyValue('margin-right')); + } else { + slideSize = slide[0].getBoundingClientRect().height + + parseFloat(slideStyles.getPropertyValue('margin-top')) + + parseFloat(slideStyles.getPropertyValue('margin-bottom')); + } + if (currentTransform) { + slide[0].style.transform = currentTransform; + } + if (params.roundLengths) slideSize = Math.floor(slideSize); + } else { + slideSize = (swiperSize - ((params.slidesPerView - 1) * spaceBetween)) / params.slidesPerView; + if (params.roundLengths) slideSize = Math.floor(slideSize); + + if (slides[i]) { + if (swiper.isHorizontal()) { + slides[i].style.width = `${slideSize}px`; + } else { + slides[i].style.height = `${slideSize}px`; + } + } + } + if (slides[i]) { + slides[i].swiperSlideSize = slideSize; + } + slidesSizesGrid.push(slideSize); + + + if (params.centeredSlides) { + slidePosition = slidePosition + (slideSize / 2) + (prevSlideSize / 2) + spaceBetween; + if (prevSlideSize === 0 && i !== 0) slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; + if (i === 0) slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; + if (Math.abs(slidePosition) < 1 / 1000) slidePosition = 0; + if ((index$$1) % params.slidesPerGroup === 0) snapGrid.push(slidePosition); + slidesGrid.push(slidePosition); + } else { + if ((index$$1) % params.slidesPerGroup === 0) snapGrid.push(slidePosition); + slidesGrid.push(slidePosition); + slidePosition = slidePosition + slideSize + spaceBetween; + } + + swiper.virtualSize += slideSize + spaceBetween; + + prevSlideSize = slideSize; + + index$$1 += 1; + } + swiper.virtualSize = Math.max(swiper.virtualSize, swiperSize) + offsetAfter; + let newSlidesGrid; + + if ( + rtl && wrongRTL && (params.effect === 'slide' || params.effect === 'coverflow')) { + $wrapperEl.css({ width: `${swiper.virtualSize + params.spaceBetween}px` }); + } + if (!Support.flexbox || params.setWrapperSize) { + if (swiper.isHorizontal()) $wrapperEl.css({ width: `${swiper.virtualSize + params.spaceBetween}px` }); + else $wrapperEl.css({ height: `${swiper.virtualSize + params.spaceBetween}px` }); + } + + if (params.slidesPerColumn > 1) { + swiper.virtualSize = (slideSize + params.spaceBetween) * slidesNumberEvenToRows; + swiper.virtualSize = Math.ceil(swiper.virtualSize / params.slidesPerColumn) - params.spaceBetween; + if (swiper.isHorizontal()) $wrapperEl.css({ width: `${swiper.virtualSize + params.spaceBetween}px` }); + else $wrapperEl.css({ height: `${swiper.virtualSize + params.spaceBetween}px` }); + if (params.centeredSlides) { + newSlidesGrid = []; + for (let i = 0; i < snapGrid.length; i += 1) { + if (snapGrid[i] < swiper.virtualSize + snapGrid[0]) newSlidesGrid.push(snapGrid[i]); + } + snapGrid = newSlidesGrid; + } + } + + // Remove last grid elements depending on width + if (!params.centeredSlides) { + newSlidesGrid = []; + for (let i = 0; i < snapGrid.length; i += 1) { + if (snapGrid[i] <= swiper.virtualSize - swiperSize) { + newSlidesGrid.push(snapGrid[i]); + } + } + snapGrid = newSlidesGrid; + if (Math.floor(swiper.virtualSize - swiperSize) - Math.floor(snapGrid[snapGrid.length - 1]) > 1) { + snapGrid.push(swiper.virtualSize - swiperSize); + } + } + if (snapGrid.length === 0) snapGrid = [0]; + + if (params.spaceBetween !== 0) { + if (swiper.isHorizontal()) { + if (rtl) slides.css({ marginLeft: `${spaceBetween}px` }); + else slides.css({ marginRight: `${spaceBetween}px` }); + } else slides.css({ marginBottom: `${spaceBetween}px` }); + } + + Utils.extend(swiper, { + slides, + snapGrid, + slidesGrid, + slidesSizesGrid, + }); + + if (slidesLength !== previousSlidesLength) { + swiper.emit('slidesLengthChange'); + } + if (snapGrid.length !== previousSnapGridLength) { + if (swiper.params.watchOverflow) swiper.checkOverflow(); + swiper.emit('snapGridLengthChange'); + } + if (slidesGrid.length !== previousSlidesGridLength) { + swiper.emit('slidesGridLengthChange'); + } + + if (params.watchSlidesProgress || params.watchSlidesVisibility) { + swiper.updateSlidesOffset(); + } +} + +function updateAutoHeight (speed) { + const swiper = this; + const activeSlides = []; + let newHeight = 0; + let i; + if (typeof speed === 'number') { + swiper.setTransition(speed); + } else if (speed === true) { + swiper.setTransition(swiper.params.speed); + } + // Find slides currently in view + if (swiper.params.slidesPerView !== 'auto' && swiper.params.slidesPerView > 1) { + for (i = 0; i < Math.ceil(swiper.params.slidesPerView); i += 1) { + const index$$1 = swiper.activeIndex + i; + if (index$$1 > swiper.slides.length) break; + activeSlides.push(swiper.slides.eq(index$$1)[0]); + } + } else { + activeSlides.push(swiper.slides.eq(swiper.activeIndex)[0]); + } + + // Find new height from highest slide in view + for (i = 0; i < activeSlides.length; i += 1) { + if (typeof activeSlides[i] !== 'undefined') { + const height = activeSlides[i].offsetHeight; + newHeight = height > newHeight ? height : newHeight; + } + } + + // Update Height + if (newHeight) swiper.$wrapperEl.css('height', `${newHeight}px`); +} + +function updateSlidesOffset () { + const swiper = this; + const slides = swiper.slides; + for (let i = 0; i < slides.length; i += 1) { + slides[i].swiperSlideOffset = swiper.isHorizontal() ? slides[i].offsetLeft : slides[i].offsetTop; + } +} + +function updateSlidesProgress (translate = (this && this.translate) || 0) { + const swiper = this; + const params = swiper.params; + + const { slides, rtlTranslate: rtl } = swiper; + + if (slides.length === 0) return; + if (typeof slides[0].swiperSlideOffset === 'undefined') swiper.updateSlidesOffset(); + + let offsetCenter = -translate; + if (rtl) offsetCenter = translate; + + // Visible Slides + slides.removeClass(params.slideVisibleClass); + + for (let i = 0; i < slides.length; i += 1) { + const slide = slides[i]; + const slideProgress = + ( + (offsetCenter + (params.centeredSlides ? swiper.minTranslate() : 0)) - slide.swiperSlideOffset + ) / (slide.swiperSlideSize + params.spaceBetween); + if (params.watchSlidesVisibility) { + const slideBefore = -(offsetCenter - slide.swiperSlideOffset); + const slideAfter = slideBefore + swiper.slidesSizesGrid[i]; + const isVisible = + (slideBefore >= 0 && slideBefore < swiper.size) || + (slideAfter > 0 && slideAfter <= swiper.size) || + (slideBefore <= 0 && slideAfter >= swiper.size); + if (isVisible) { + slides.eq(i).addClass(params.slideVisibleClass); + } + } + slide.progress = rtl ? -slideProgress : slideProgress; + } +} + +function updateProgress (translate = (this && this.translate) || 0) { + const swiper = this; + const params = swiper.params; + + const translatesDiff = swiper.maxTranslate() - swiper.minTranslate(); + let { progress, isBeginning, isEnd } = swiper; + const wasBeginning = isBeginning; + const wasEnd = isEnd; + if (translatesDiff === 0) { + progress = 0; + isBeginning = true; + isEnd = true; + } else { + progress = (translate - swiper.minTranslate()) / (translatesDiff); + isBeginning = progress <= 0; + isEnd = progress >= 1; + } + Utils.extend(swiper, { + progress, + isBeginning, + isEnd, + }); + + if (params.watchSlidesProgress || params.watchSlidesVisibility) swiper.updateSlidesProgress(translate); + + if (isBeginning && !wasBeginning) { + swiper.emit('reachBeginning toEdge'); + } + if (isEnd && !wasEnd) { + swiper.emit('reachEnd toEdge'); + } + if ((wasBeginning && !isBeginning) || (wasEnd && !isEnd)) { + swiper.emit('fromEdge'); + } + + swiper.emit('progress', progress); +} + +function updateSlidesClasses () { + const swiper = this; + + const { + slides, params, $wrapperEl, activeIndex, realIndex, + } = swiper; + const isVirtual = swiper.virtual && params.virtual.enabled; + + slides.removeClass(`${params.slideActiveClass} ${params.slideNextClass} ${params.slidePrevClass} ${params.slideDuplicateActiveClass} ${params.slideDuplicateNextClass} ${params.slideDuplicatePrevClass}`); + + let activeSlide; + if (isVirtual) { + activeSlide = swiper.$wrapperEl.find(`.${params.slideClass}[data-swiper-slide-index="${activeIndex}"]`); + } else { + activeSlide = slides.eq(activeIndex); + } + + // Active classes + activeSlide.addClass(params.slideActiveClass); + + if (params.loop) { + // Duplicate to all looped slides + if (activeSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(`.${params.slideClass}:not(.${params.slideDuplicateClass})[data-swiper-slide-index="${realIndex}"]`) + .addClass(params.slideDuplicateActiveClass); + } else { + $wrapperEl + .children(`.${params.slideClass}.${params.slideDuplicateClass}[data-swiper-slide-index="${realIndex}"]`) + .addClass(params.slideDuplicateActiveClass); + } + } + // Next Slide + let nextSlide = activeSlide.nextAll(`.${params.slideClass}`).eq(0).addClass(params.slideNextClass); + if (params.loop && nextSlide.length === 0) { + nextSlide = slides.eq(0); + nextSlide.addClass(params.slideNextClass); + } + // Prev Slide + let prevSlide = activeSlide.prevAll(`.${params.slideClass}`).eq(0).addClass(params.slidePrevClass); + if (params.loop && prevSlide.length === 0) { + prevSlide = slides.eq(-1); + prevSlide.addClass(params.slidePrevClass); + } + if (params.loop) { + // Duplicate to all looped slides + if (nextSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(`.${params.slideClass}:not(.${params.slideDuplicateClass})[data-swiper-slide-index="${nextSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicateNextClass); + } else { + $wrapperEl + .children(`.${params.slideClass}.${params.slideDuplicateClass}[data-swiper-slide-index="${nextSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicateNextClass); + } + if (prevSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(`.${params.slideClass}:not(.${params.slideDuplicateClass})[data-swiper-slide-index="${prevSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicatePrevClass); + } else { + $wrapperEl + .children(`.${params.slideClass}.${params.slideDuplicateClass}[data-swiper-slide-index="${prevSlide.attr('data-swiper-slide-index')}"]`) + .addClass(params.slideDuplicatePrevClass); + } + } +} + +function updateActiveIndex (newActiveIndex) { + const swiper = this; + const translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate; + const { + slidesGrid, snapGrid, params, activeIndex: previousIndex, realIndex: previousRealIndex, snapIndex: previousSnapIndex, + } = swiper; + let activeIndex = newActiveIndex; + let snapIndex; + if (typeof activeIndex === 'undefined') { + for (let i = 0; i < slidesGrid.length; i += 1) { + if (typeof slidesGrid[i + 1] !== 'undefined') { + if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1] - ((slidesGrid[i + 1] - slidesGrid[i]) / 2)) { + activeIndex = i; + } else if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1]) { + activeIndex = i + 1; + } + } else if (translate >= slidesGrid[i]) { + activeIndex = i; + } + } + // Normalize slideIndex + if (params.normalizeSlideIndex) { + if (activeIndex < 0 || typeof activeIndex === 'undefined') activeIndex = 0; + } + } + if (snapGrid.indexOf(translate) >= 0) { + snapIndex = snapGrid.indexOf(translate); + } else { + snapIndex = Math.floor(activeIndex / params.slidesPerGroup); + } + if (snapIndex >= snapGrid.length) snapIndex = snapGrid.length - 1; + if (activeIndex === previousIndex) { + if (snapIndex !== previousSnapIndex) { + swiper.snapIndex = snapIndex; + swiper.emit('snapIndexChange'); + } + return; + } + + // Get real index + const realIndex = parseInt(swiper.slides.eq(activeIndex).attr('data-swiper-slide-index') || activeIndex, 10); + + Utils.extend(swiper, { + snapIndex, + realIndex, + previousIndex, + activeIndex, + }); + swiper.emit('activeIndexChange'); + swiper.emit('snapIndexChange'); + if (previousRealIndex !== realIndex) { + swiper.emit('realIndexChange'); + } + swiper.emit('slideChange'); +} + +function updateClickedSlide (e) { + const swiper = this; + const params = swiper.params; + const slide = $(e.target).closest(`.${params.slideClass}`)[0]; + let slideFound = false; + if (slide) { + for (let i = 0; i < swiper.slides.length; i += 1) { + if (swiper.slides[i] === slide) slideFound = true; + } + } + + if (slide && slideFound) { + swiper.clickedSlide = slide; + if (swiper.virtual && swiper.params.virtual.enabled) { + swiper.clickedIndex = parseInt($(slide).attr('data-swiper-slide-index'), 10); + } else { + swiper.clickedIndex = $(slide).index(); + } + } else { + swiper.clickedSlide = undefined; + swiper.clickedIndex = undefined; + return; + } + if (params.slideToClickedSlide && swiper.clickedIndex !== undefined && swiper.clickedIndex !== swiper.activeIndex) { + swiper.slideToClickedSlide(); + } +} + +var update = { + updateSize, + updateSlides, + updateAutoHeight, + updateSlidesOffset, + updateSlidesProgress, + updateProgress, + updateSlidesClasses, + updateActiveIndex, + updateClickedSlide, +}; + +function getTranslate (axis = this.isHorizontal() ? 'x' : 'y') { + const swiper = this; + + const { + params, rtlTranslate: rtl, translate, $wrapperEl, + } = swiper; + + if (params.virtualTranslate) { + return rtl ? -translate : translate; + } + + let currentTranslate = Utils.getTranslate($wrapperEl[0], axis); + if (rtl) currentTranslate = -currentTranslate; + + return currentTranslate || 0; +} + +function setTranslate (translate, byController) { + const swiper = this; + const { + rtlTranslate: rtl, params, $wrapperEl, progress, + } = swiper; + let x = 0; + let y = 0; + const z = 0; + + if (swiper.isHorizontal()) { + x = rtl ? -translate : translate; + } else { + y = translate; + } + + if (params.roundLengths) { + x = Math.floor(x); + y = Math.floor(y); + } + + if (!params.virtualTranslate) { + if (Support.transforms3d) $wrapperEl.transform(`translate3d(${x}px, ${y}px, ${z}px)`); + else $wrapperEl.transform(`translate(${x}px, ${y}px)`); + } + + swiper.translate = swiper.isHorizontal() ? x : y; + + // Check if we need to update progress + let newProgress; + const translatesDiff = swiper.maxTranslate() - swiper.minTranslate(); + if (translatesDiff === 0) { + newProgress = 0; + } else { + newProgress = (translate - swiper.minTranslate()) / (translatesDiff); + } + if (newProgress !== progress) { + swiper.updateProgress(translate); + } + + swiper.emit('setTranslate', swiper.translate, byController); +} + +function minTranslate () { + return (-this.snapGrid[0]); +} + +function maxTranslate () { + return (-this.snapGrid[this.snapGrid.length - 1]); +} + +var translate = { + getTranslate, + setTranslate, + minTranslate, + maxTranslate, +}; + +function setTransition (duration, byController) { + const swiper = this; + + swiper.$wrapperEl.transition(duration); + + swiper.emit('setTransition', duration, byController); +} + +function transitionStart (runCallbacks = true, direction) { + const swiper = this; + const { activeIndex, params, previousIndex } = swiper; + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + + let dir = direction; + if (!dir) { + if (activeIndex > previousIndex) dir = 'next'; + else if (activeIndex < previousIndex) dir = 'prev'; + else dir = 'reset'; + } + + swiper.emit('transitionStart'); + + if (runCallbacks && activeIndex !== previousIndex) { + if (dir === 'reset') { + swiper.emit('slideResetTransitionStart'); + return; + } + swiper.emit('slideChangeTransitionStart'); + if (dir === 'next') { + swiper.emit('slideNextTransitionStart'); + } else { + swiper.emit('slidePrevTransitionStart'); + } + } +} + +function transitionEnd$1 (runCallbacks = true, direction) { + const swiper = this; + const { activeIndex, previousIndex } = swiper; + swiper.animating = false; + swiper.setTransition(0); + + let dir = direction; + if (!dir) { + if (activeIndex > previousIndex) dir = 'next'; + else if (activeIndex < previousIndex) dir = 'prev'; + else dir = 'reset'; + } + + swiper.emit('transitionEnd'); + + if (runCallbacks && activeIndex !== previousIndex) { + if (dir === 'reset') { + swiper.emit('slideResetTransitionEnd'); + return; + } + swiper.emit('slideChangeTransitionEnd'); + if (dir === 'next') { + swiper.emit('slideNextTransitionEnd'); + } else { + swiper.emit('slidePrevTransitionEnd'); + } + } +} + +var transition$1 = { + setTransition, + transitionStart, + transitionEnd: transitionEnd$1, +}; + +function slideTo (index$$1 = 0, speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + let slideIndex = index$$1; + if (slideIndex < 0) slideIndex = 0; + + const { + params, snapGrid, slidesGrid, previousIndex, activeIndex, rtlTranslate: rtl, + } = swiper; + if (swiper.animating && params.preventIntercationOnTransition) { + return false; + } + + let snapIndex = Math.floor(slideIndex / params.slidesPerGroup); + if (snapIndex >= snapGrid.length) snapIndex = snapGrid.length - 1; + + if ((activeIndex || params.initialSlide || 0) === (previousIndex || 0) && runCallbacks) { + swiper.emit('beforeSlideChangeStart'); + } + + const translate = -snapGrid[snapIndex]; + + // Update progress + swiper.updateProgress(translate); + + // Normalize slideIndex + if (params.normalizeSlideIndex) { + for (let i = 0; i < slidesGrid.length; i += 1) { + if (-Math.floor(translate * 100) >= Math.floor(slidesGrid[i] * 100)) { + slideIndex = i; + } + } + } + // Directions locks + if (swiper.initialized && slideIndex !== activeIndex) { + if (!swiper.allowSlideNext && translate < swiper.translate && translate < swiper.minTranslate()) { + return false; + } + if (!swiper.allowSlidePrev && translate > swiper.translate && translate > swiper.maxTranslate()) { + if ((activeIndex || 0) !== slideIndex) return false; + } + } + + let direction; + if (slideIndex > activeIndex) direction = 'next'; + else if (slideIndex < activeIndex) direction = 'prev'; + else direction = 'reset'; + + + // Update Index + if ((rtl && -translate === swiper.translate) || (!rtl && translate === swiper.translate)) { + swiper.updateActiveIndex(slideIndex); + // Update Height + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + swiper.updateSlidesClasses(); + if (params.effect !== 'slide') { + swiper.setTranslate(translate); + } + if (direction !== 'reset') { + swiper.transitionStart(runCallbacks, direction); + swiper.transitionEnd(runCallbacks, direction); + } + return false; + } + + if (speed === 0 || !Support.transition) { + swiper.setTransition(0); + swiper.setTranslate(translate); + swiper.updateActiveIndex(slideIndex); + swiper.updateSlidesClasses(); + swiper.emit('beforeTransitionStart', speed, internal); + swiper.transitionStart(runCallbacks, direction); + swiper.transitionEnd(runCallbacks, direction); + } else { + swiper.setTransition(speed); + swiper.setTranslate(translate); + swiper.updateActiveIndex(slideIndex); + swiper.updateSlidesClasses(); + swiper.emit('beforeTransitionStart', speed, internal); + swiper.transitionStart(runCallbacks, direction); + if (!swiper.animating) { + swiper.animating = true; + if (!swiper.onSlideToWrapperTransitionEnd) { + swiper.onSlideToWrapperTransitionEnd = function transitionEnd$$1(e) { + if (!swiper || swiper.destroyed) return; + if (e.target !== this) return; + swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd); + swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd); + swiper.transitionEnd(runCallbacks, direction); + }; + } + swiper.$wrapperEl[0].addEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd); + swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd); + } + } + + return true; +} + +function slideToLoop (index$$1 = 0, speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + let newIndex = index$$1; + if (swiper.params.loop) { + newIndex += swiper.loopedSlides; + } + + return swiper.slideTo(newIndex, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slideNext (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + const { params, animating } = swiper; + if (params.loop) { + if (animating) return false; + swiper.loopFix(); + // eslint-disable-next-line + swiper._clientLeft = swiper.$wrapperEl[0].clientLeft; + return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal); + } + return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slidePrev (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + const { + params, animating, snapGrid, slidesGrid, rtlTranslate, + } = swiper; + + if (params.loop) { + if (animating) return false; + swiper.loopFix(); + // eslint-disable-next-line + swiper._clientLeft = swiper.$wrapperEl[0].clientLeft; + } + const translate = rtlTranslate ? swiper.translate : -swiper.translate; + const currentSnap = snapGrid[snapGrid.indexOf(translate)]; + const prevSnap = snapGrid[snapGrid.indexOf(translate) - 1]; + let prevIndex; + + if (prevSnap) { + prevIndex = slidesGrid.indexOf(prevSnap); + if (prevIndex < 0) prevIndex = swiper.activeIndex - 1; + } + return swiper.slideTo(prevIndex, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slideReset (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + return swiper.slideTo(swiper.activeIndex, speed, runCallbacks, internal); +} + +/* eslint no-unused-vars: "off" */ +function slideToClosest (speed = this.params.speed, runCallbacks = true, internal) { + const swiper = this; + let index$$1 = swiper.activeIndex; + const snapIndex = Math.floor(index$$1 / swiper.params.slidesPerGroup); + + if (snapIndex < swiper.snapGrid.length - 1) { + const translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate; + + const currentSnap = swiper.snapGrid[snapIndex]; + const nextSnap = swiper.snapGrid[snapIndex + 1]; + + if ((translate - currentSnap) > (nextSnap - currentSnap) / 2) { + index$$1 = swiper.params.slidesPerGroup; + } + } + + return swiper.slideTo(index$$1, speed, runCallbacks, internal); +} + +function slideToClickedSlide () { + const swiper = this; + const { params, $wrapperEl } = swiper; + + const slidesPerView = params.slidesPerView === 'auto' ? swiper.slidesPerViewDynamic() : params.slidesPerView; + let slideToIndex = swiper.clickedIndex; + let realIndex; + if (params.loop) { + if (swiper.animating) return; + realIndex = parseInt($(swiper.clickedSlide).attr('data-swiper-slide-index'), 10); + if (params.centeredSlides) { + if ( + (slideToIndex < swiper.loopedSlides - (slidesPerView / 2)) || + (slideToIndex > (swiper.slides.length - swiper.loopedSlides) + (slidesPerView / 2)) + ) { + swiper.loopFix(); + slideToIndex = $wrapperEl + .children(`.${params.slideClass}[data-swiper-slide-index="${realIndex}"]:not(.${params.slideDuplicateClass})`) + .eq(0) + .index(); + + Utils.nextTick(() => { + swiper.slideTo(slideToIndex); + }); + } else { + swiper.slideTo(slideToIndex); + } + } else if (slideToIndex > swiper.slides.length - slidesPerView) { + swiper.loopFix(); + slideToIndex = $wrapperEl + .children(`.${params.slideClass}[data-swiper-slide-index="${realIndex}"]:not(.${params.slideDuplicateClass})`) + .eq(0) + .index(); + + Utils.nextTick(() => { + swiper.slideTo(slideToIndex); + }); + } else { + swiper.slideTo(slideToIndex); + } + } else { + swiper.slideTo(slideToIndex); + } +} + +var slide = { + slideTo, + slideToLoop, + slideNext, + slidePrev, + slideReset, + slideToClosest, + slideToClickedSlide, +}; + +function loopCreate () { + const swiper = this; + const { params, $wrapperEl } = swiper; + // Remove duplicated slides + $wrapperEl.children(`.${params.slideClass}.${params.slideDuplicateClass}`).remove(); + + let slides = $wrapperEl.children(`.${params.slideClass}`); + + if (params.loopFillGroupWithBlank) { + const blankSlidesNum = params.slidesPerGroup - (slides.length % params.slidesPerGroup); + if (blankSlidesNum !== params.slidesPerGroup) { + for (let i = 0; i < blankSlidesNum; i += 1) { + const blankNode = $(document.createElement('div')).addClass(`${params.slideClass} ${params.slideBlankClass}`); + $wrapperEl.append(blankNode); + } + slides = $wrapperEl.children(`.${params.slideClass}`); + } + } + + if (params.slidesPerView === 'auto' && !params.loopedSlides) params.loopedSlides = slides.length; + + swiper.loopedSlides = parseInt(params.loopedSlides || params.slidesPerView, 10); + swiper.loopedSlides += params.loopAdditionalSlides; + if (swiper.loopedSlides > slides.length) { + swiper.loopedSlides = slides.length; + } + + const prependSlides = []; + const appendSlides = []; + slides.each((index$$1, el) => { + const slide = $(el); + if (index$$1 < swiper.loopedSlides) appendSlides.push(el); + if (index$$1 < slides.length && index$$1 >= slides.length - swiper.loopedSlides) prependSlides.push(el); + slide.attr('data-swiper-slide-index', index$$1); + }); + for (let i = 0; i < appendSlides.length; i += 1) { + $wrapperEl.append($(appendSlides[i].cloneNode(true)).addClass(params.slideDuplicateClass)); + } + for (let i = prependSlides.length - 1; i >= 0; i -= 1) { + $wrapperEl.prepend($(prependSlides[i].cloneNode(true)).addClass(params.slideDuplicateClass)); + } +} + +function loopFix () { + const swiper = this; + const { + params, activeIndex, slides, loopedSlides, allowSlidePrev, allowSlideNext, snapGrid, rtlTranslate: rtl, + } = swiper; + let newIndex; + swiper.allowSlidePrev = true; + swiper.allowSlideNext = true; + + const snapTranslate = -snapGrid[activeIndex]; + const diff = snapTranslate - swiper.getTranslate(); + + + // Fix For Negative Oversliding + if (activeIndex < loopedSlides) { + newIndex = (slides.length - (loopedSlides * 3)) + activeIndex; + newIndex += loopedSlides; + const slideChanged = swiper.slideTo(newIndex, 0, false, true); + if (slideChanged && diff !== 0) { + swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff); + } + } else if ((params.slidesPerView === 'auto' && activeIndex >= loopedSlides * 2) || (activeIndex > slides.length - (params.slidesPerView * 2))) { + // Fix For Positive Oversliding + newIndex = -slides.length + activeIndex + loopedSlides; + newIndex += loopedSlides; + const slideChanged = swiper.slideTo(newIndex, 0, false, true); + if (slideChanged && diff !== 0) { + swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff); + } + } + swiper.allowSlidePrev = allowSlidePrev; + swiper.allowSlideNext = allowSlideNext; +} + +function loopDestroy () { + const swiper = this; + const { $wrapperEl, params, slides } = swiper; + $wrapperEl.children(`.${params.slideClass}.${params.slideDuplicateClass}`).remove(); + slides.removeAttr('data-swiper-slide-index'); +} + +var loop = { + loopCreate, + loopFix, + loopDestroy, +}; + +function setGrabCursor (moving) { + const swiper = this; + if (Support.touch || !swiper.params.simulateTouch || (swiper.params.watchOverflow && swiper.isLocked)) return; + const el = swiper.el; + el.style.cursor = 'move'; + el.style.cursor = moving ? '-webkit-grabbing' : '-webkit-grab'; + el.style.cursor = moving ? '-moz-grabbin' : '-moz-grab'; + el.style.cursor = moving ? 'grabbing' : 'grab'; +} + +function unsetGrabCursor () { + const swiper = this; + if (Support.touch || (swiper.params.watchOverflow && swiper.isLocked)) return; + swiper.el.style.cursor = ''; +} + +var grabCursor = { + setGrabCursor, + unsetGrabCursor, +}; + +function appendSlide (slides) { + const swiper = this; + const { $wrapperEl, params } = swiper; + if (params.loop) { + swiper.loopDestroy(); + } + if (typeof slides === 'object' && 'length' in slides) { + for (let i = 0; i < slides.length; i += 1) { + if (slides[i]) $wrapperEl.append(slides[i]); + } + } else { + $wrapperEl.append(slides); + } + if (params.loop) { + swiper.loopCreate(); + } + if (!(params.observer && Support.observer)) { + swiper.update(); + } +} + +function prependSlide (slides) { + const swiper = this; + const { params, $wrapperEl, activeIndex } = swiper; + + if (params.loop) { + swiper.loopDestroy(); + } + let newActiveIndex = activeIndex + 1; + if (typeof slides === 'object' && 'length' in slides) { + for (let i = 0; i < slides.length; i += 1) { + if (slides[i]) $wrapperEl.prepend(slides[i]); + } + newActiveIndex = activeIndex + slides.length; + } else { + $wrapperEl.prepend(slides); + } + if (params.loop) { + swiper.loopCreate(); + } + if (!(params.observer && Support.observer)) { + swiper.update(); + } + swiper.slideTo(newActiveIndex, 0, false); +} + +function removeSlide (slidesIndexes) { + const swiper = this; + const { params, $wrapperEl, activeIndex } = swiper; + + if (params.loop) { + swiper.loopDestroy(); + swiper.slides = $wrapperEl.children(`.${params.slideClass}`); + } + let newActiveIndex = activeIndex; + let indexToRemove; + + if (typeof slidesIndexes === 'object' && 'length' in slidesIndexes) { + for (let i = 0; i < slidesIndexes.length; i += 1) { + indexToRemove = slidesIndexes[i]; + if (swiper.slides[indexToRemove]) swiper.slides.eq(indexToRemove).remove(); + if (indexToRemove < newActiveIndex) newActiveIndex -= 1; + } + newActiveIndex = Math.max(newActiveIndex, 0); + } else { + indexToRemove = slidesIndexes; + if (swiper.slides[indexToRemove]) swiper.slides.eq(indexToRemove).remove(); + if (indexToRemove < newActiveIndex) newActiveIndex -= 1; + newActiveIndex = Math.max(newActiveIndex, 0); + } + + if (params.loop) { + swiper.loopCreate(); + } + + if (!(params.observer && Support.observer)) { + swiper.update(); + } + if (params.loop) { + swiper.slideTo(newActiveIndex + swiper.loopedSlides, 0, false); + } else { + swiper.slideTo(newActiveIndex, 0, false); + } +} + +function removeAllSlides () { + const swiper = this; + + const slidesIndexes = []; + for (let i = 0; i < swiper.slides.length; i += 1) { + slidesIndexes.push(i); + } + swiper.removeSlide(slidesIndexes); +} + +var manipulation = { + appendSlide, + prependSlide, + removeSlide, + removeAllSlides, +}; + +const Device = (function Device() { + const ua = window.navigator.userAgent; + + const device = { + ios: false, + android: false, + androidChrome: false, + desktop: false, + windows: false, + iphone: false, + ipod: false, + ipad: false, + cordova: window.cordova || window.phonegap, + phonegap: window.cordova || window.phonegap, + }; + + const windows = ua.match(/(Windows Phone);?[\s\/]+([\d.]+)?/); // eslint-disable-line + const android = ua.match(/(Android);?[\s\/]+([\d.]+)?/); // eslint-disable-line + const ipad = ua.match(/(iPad).*OS\s([\d_]+)/); + const ipod = ua.match(/(iPod)(.*OS\s([\d_]+))?/); + const iphone = !ipad && ua.match(/(iPhone\sOS|iOS)\s([\d_]+)/); + + + // Windows + if (windows) { + device.os = 'windows'; + device.osVersion = windows[2]; + device.windows = true; + } + // Android + if (android && !windows) { + device.os = 'android'; + device.osVersion = android[2]; + device.android = true; + device.androidChrome = ua.toLowerCase().indexOf('chrome') >= 0; + } + if (ipad || iphone || ipod) { + device.os = 'ios'; + device.ios = true; + } + // iOS + if (iphone && !ipod) { + device.osVersion = iphone[2].replace(/_/g, '.'); + device.iphone = true; + } + if (ipad) { + device.osVersion = ipad[2].replace(/_/g, '.'); + device.ipad = true; + } + if (ipod) { + device.osVersion = ipod[3] ? ipod[3].replace(/_/g, '.') : null; + device.iphone = true; + } + // iOS 8+ changed UA + if (device.ios && device.osVersion && ua.indexOf('Version/') >= 0) { + if (device.osVersion.split('.')[0] === '10') { + device.osVersion = ua.toLowerCase().split('version/')[1].split(' ')[0]; + } + } + + // Desktop + device.desktop = !(device.os || device.android || device.webView); + + // Webview + device.webView = (iphone || ipad || ipod) && ua.match(/.*AppleWebKit(?!.*Safari)/i); + + // Minimal UI + if (device.os && device.os === 'ios') { + const osVersionArr = device.osVersion.split('.'); + const metaViewport = document.querySelector('meta[name="viewport"]'); + device.minimalUi = + !device.webView && + (ipod || iphone) && + (osVersionArr[0] * 1 === 7 ? osVersionArr[1] * 1 >= 1 : osVersionArr[0] * 1 > 7) && + metaViewport && metaViewport.getAttribute('content').indexOf('minimal-ui') >= 0; + } + + // Pixel Ratio + device.pixelRatio = window.devicePixelRatio || 1; + + // Export object + return device; +}()); + +function onTouchStart (event) { + const swiper = this; + const data$$1 = swiper.touchEventsData; + const { params, touches } = swiper; + if (swiper.animating && params.preventIntercationOnTransition) { + return; + } + let e = event; + if (e.originalEvent) e = e.originalEvent; + data$$1.isTouchEvent = e.type === 'touchstart'; + if (!data$$1.isTouchEvent && 'which' in e && e.which === 3) return; + if (data$$1.isTouched && data$$1.isMoved) return; + if (params.noSwiping && $(e.target).closest(params.noSwipingSelector ? params.noSwipingSelector : `.${params.noSwipingClass}`)[0]) { + swiper.allowClick = true; + return; + } + if (params.swipeHandler) { + if (!$(e).closest(params.swipeHandler)[0]) return; + } + + touches.currentX = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX; + touches.currentY = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY; + const startX = touches.currentX; + const startY = touches.currentY; + + // Do NOT start if iOS edge swipe is detected. Otherwise iOS app (UIWebView) cannot swipe-to-go-back anymore + + if ( + Device.ios && + !Device.cordova && + params.iOSEdgeSwipeDetection && + (startX <= params.iOSEdgeSwipeThreshold) && + (startX >= window.screen.width - params.iOSEdgeSwipeThreshold) + ) { + return; + } + + Utils.extend(data$$1, { + isTouched: true, + isMoved: false, + allowTouchCallbacks: true, + isScrolling: undefined, + startMoving: undefined, + }); + + touches.startX = startX; + touches.startY = startY; + data$$1.touchStartTime = Utils.now(); + swiper.allowClick = true; + swiper.updateSize(); + swiper.swipeDirection = undefined; + if (params.threshold > 0) data$$1.allowThresholdMove = false; + if (e.type !== 'touchstart') { + let preventDefault = true; + if ($(e.target).is(data$$1.formElements)) preventDefault = false; + if ( + document.activeElement && + $(document.activeElement).is(data$$1.formElements) && + document.activeElement !== e.target + ) { + document.activeElement.blur(); + } + if (preventDefault && swiper.allowTouchMove) { + e.preventDefault(); + } + } + swiper.emit('touchStart', e); +} + +function onTouchMove (event) { + const swiper = this; + const data$$1 = swiper.touchEventsData; + const { params, touches, rtlTranslate: rtl } = swiper; + let e = event; + if (e.originalEvent) e = e.originalEvent; + if (!data$$1.isTouched) { + if (data$$1.startMoving && data$$1.isScrolling) { + swiper.emit('touchMoveOpposite', e); + } + return; + } + if (data$$1.isTouchEvent && e.type === 'mousemove') return; + const pageX = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX; + const pageY = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY; + if (e.preventedByNestedSwiper) { + touches.startX = pageX; + touches.startY = pageY; + return; + } + if (!swiper.allowTouchMove) { + // isMoved = true; + swiper.allowClick = false; + if (data$$1.isTouched) { + Utils.extend(touches, { + startX: pageX, + startY: pageY, + currentX: pageX, + currentY: pageY, + }); + data$$1.touchStartTime = Utils.now(); + } + return; + } + if (data$$1.isTouchEvent && params.touchReleaseOnEdges && !params.loop) { + if (swiper.isVertical()) { + // Vertical + if ( + (pageY < touches.startY && swiper.translate <= swiper.maxTranslate()) || + (pageY > touches.startY && swiper.translate >= swiper.minTranslate()) + ) { + data$$1.isTouched = false; + data$$1.isMoved = false; + return; + } + } else if ( + (pageX < touches.startX && swiper.translate <= swiper.maxTranslate()) || + (pageX > touches.startX && swiper.translate >= swiper.minTranslate()) + ) { + return; + } + } + if (data$$1.isTouchEvent && document.activeElement) { + if (e.target === document.activeElement && $(e.target).is(data$$1.formElements)) { + data$$1.isMoved = true; + swiper.allowClick = false; + return; + } + } + if (data$$1.allowTouchCallbacks) { + swiper.emit('touchMove', e); + } + if (e.targetTouches && e.targetTouches.length > 1) return; + + touches.currentX = pageX; + touches.currentY = pageY; + + const diffX = touches.currentX - touches.startX; + const diffY = touches.currentY - touches.startY; + + if (typeof data$$1.isScrolling === 'undefined') { + let touchAngle; + if ((swiper.isHorizontal() && touches.currentY === touches.startY) || (swiper.isVertical() && touches.currentX === touches.startX)) { + data$$1.isScrolling = false; + } else { + // eslint-disable-next-line + if ((diffX * diffX) + (diffY * diffY) >= 25) { + touchAngle = (Math.atan2(Math.abs(diffY), Math.abs(diffX)) * 180) / Math.PI; + data$$1.isScrolling = swiper.isHorizontal() ? touchAngle > params.touchAngle : (90 - touchAngle > params.touchAngle); + } + } + } + if (data$$1.isScrolling) { + swiper.emit('touchMoveOpposite', e); + } + if (typeof startMoving === 'undefined') { + if (touches.currentX !== touches.startX || touches.currentY !== touches.startY) { + data$$1.startMoving = true; + } + } + if (data$$1.isScrolling) { + data$$1.isTouched = false; + return; + } + if (!data$$1.startMoving) { + return; + } + swiper.allowClick = false; + e.preventDefault(); + if (params.touchMoveStopPropagation && !params.nested) { + e.stopPropagation(); + } + + if (!data$$1.isMoved) { + if (params.loop) { + swiper.loopFix(); + } + data$$1.startTranslate = swiper.getTranslate(); + swiper.setTransition(0); + if (swiper.animating) { + swiper.$wrapperEl.trigger('webkitTransitionEnd transitionend'); + } + data$$1.allowMomentumBounce = false; + // Grab Cursor + if (params.grabCursor && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) { + swiper.setGrabCursor(true); + } + swiper.emit('sliderFirstMove', e); + } + swiper.emit('sliderMove', e); + data$$1.isMoved = true; + + let diff = swiper.isHorizontal() ? diffX : diffY; + touches.diff = diff; + + diff *= params.touchRatio; + if (rtl) diff = -diff; + + swiper.swipeDirection = diff > 0 ? 'prev' : 'next'; + data$$1.currentTranslate = diff + data$$1.startTranslate; + + let disableParentSwiper = true; + let resistanceRatio = params.resistanceRatio; + if (params.touchReleaseOnEdges) { + resistanceRatio = 0; + } + if ((diff > 0 && data$$1.currentTranslate > swiper.minTranslate())) { + disableParentSwiper = false; + if (params.resistance) data$$1.currentTranslate = (swiper.minTranslate() - 1) + ((-swiper.minTranslate() + data$$1.startTranslate + diff) ** resistanceRatio); + } else if (diff < 0 && data$$1.currentTranslate < swiper.maxTranslate()) { + disableParentSwiper = false; + if (params.resistance) data$$1.currentTranslate = (swiper.maxTranslate() + 1) - ((swiper.maxTranslate() - data$$1.startTranslate - diff) ** resistanceRatio); + } + + if (disableParentSwiper) { + e.preventedByNestedSwiper = true; + } + + // Directions locks + if (!swiper.allowSlideNext && swiper.swipeDirection === 'next' && data$$1.currentTranslate < data$$1.startTranslate) { + data$$1.currentTranslate = data$$1.startTranslate; + } + if (!swiper.allowSlidePrev && swiper.swipeDirection === 'prev' && data$$1.currentTranslate > data$$1.startTranslate) { + data$$1.currentTranslate = data$$1.startTranslate; + } + + + // Threshold + if (params.threshold > 0) { + if (Math.abs(diff) > params.threshold || data$$1.allowThresholdMove) { + if (!data$$1.allowThresholdMove) { + data$$1.allowThresholdMove = true; + touches.startX = touches.currentX; + touches.startY = touches.currentY; + data$$1.currentTranslate = data$$1.startTranslate; + touches.diff = swiper.isHorizontal() ? touches.currentX - touches.startX : touches.currentY - touches.startY; + return; + } + } else { + data$$1.currentTranslate = data$$1.startTranslate; + return; + } + } + + if (!params.followFinger) return; + + // Update active index in free mode + if (params.freeMode || params.watchSlidesProgress || params.watchSlidesVisibility) { + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + if (params.freeMode) { + // Velocity + if (data$$1.velocities.length === 0) { + data$$1.velocities.push({ + position: touches[swiper.isHorizontal() ? 'startX' : 'startY'], + time: data$$1.touchStartTime, + }); + } + data$$1.velocities.push({ + position: touches[swiper.isHorizontal() ? 'currentX' : 'currentY'], + time: Utils.now(), + }); + } + // Update progress + swiper.updateProgress(data$$1.currentTranslate); + // Update translate + swiper.setTranslate(data$$1.currentTranslate); +} + +function onTouchEnd (event) { + const swiper = this; + const data$$1 = swiper.touchEventsData; + + const { + params, touches, rtlTranslate: rtl, $wrapperEl, slidesGrid, snapGrid, + } = swiper; + let e = event; + if (e.originalEvent) e = e.originalEvent; + if (data$$1.allowTouchCallbacks) { + swiper.emit('touchEnd', e); + } + data$$1.allowTouchCallbacks = false; + if (!data$$1.isTouched) { + if (data$$1.isMoved && params.grabCursor) { + swiper.setGrabCursor(false); + } + data$$1.isMoved = false; + data$$1.startMoving = false; + return; + } + // Return Grab Cursor + if (params.grabCursor && data$$1.isMoved && data$$1.isTouched && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) { + swiper.setGrabCursor(false); + } + + // Time diff + const touchEndTime = Utils.now(); + const timeDiff = touchEndTime - data$$1.touchStartTime; + + // Tap, doubleTap, Click + if (swiper.allowClick) { + swiper.updateClickedSlide(e); + swiper.emit('tap', e); + if (timeDiff < 300 && (touchEndTime - data$$1.lastClickTime) > 300) { + if (data$$1.clickTimeout) clearTimeout(data$$1.clickTimeout); + data$$1.clickTimeout = Utils.nextTick(() => { + if (!swiper || swiper.destroyed) return; + swiper.emit('click', e); + }, 300); + } + if (timeDiff < 300 && (touchEndTime - data$$1.lastClickTime) < 300) { + if (data$$1.clickTimeout) clearTimeout(data$$1.clickTimeout); + swiper.emit('doubleTap', e); + } + } + + data$$1.lastClickTime = Utils.now(); + Utils.nextTick(() => { + if (!swiper.destroyed) swiper.allowClick = true; + }); + + if (!data$$1.isTouched || !data$$1.isMoved || !swiper.swipeDirection || touches.diff === 0 || data$$1.currentTranslate === data$$1.startTranslate) { + data$$1.isTouched = false; + data$$1.isMoved = false; + data$$1.startMoving = false; + return; + } + data$$1.isTouched = false; + data$$1.isMoved = false; + data$$1.startMoving = false; + + let currentPos; + if (params.followFinger) { + currentPos = rtl ? swiper.translate : -swiper.translate; + } else { + currentPos = -data$$1.currentTranslate; + } + + if (params.freeMode) { + if (currentPos < -swiper.minTranslate()) { + swiper.slideTo(swiper.activeIndex); + return; + } else if (currentPos > -swiper.maxTranslate()) { + if (swiper.slides.length < snapGrid.length) { + swiper.slideTo(snapGrid.length - 1); + } else { + swiper.slideTo(swiper.slides.length - 1); + } + return; + } + + if (params.freeModeMomentum) { + if (data$$1.velocities.length > 1) { + const lastMoveEvent = data$$1.velocities.pop(); + const velocityEvent = data$$1.velocities.pop(); + + const distance = lastMoveEvent.position - velocityEvent.position; + const time = lastMoveEvent.time - velocityEvent.time; + swiper.velocity = distance / time; + swiper.velocity /= 2; + if (Math.abs(swiper.velocity) < params.freeModeMinimumVelocity) { + swiper.velocity = 0; + } + // this implies that the user stopped moving a finger then released. + // There would be no events with distance zero, so the last event is stale. + if (time > 150 || (Utils.now() - lastMoveEvent.time) > 300) { + swiper.velocity = 0; + } + } else { + swiper.velocity = 0; + } + swiper.velocity *= params.freeModeMomentumVelocityRatio; + + data$$1.velocities.length = 0; + let momentumDuration = 1000 * params.freeModeMomentumRatio; + const momentumDistance = swiper.velocity * momentumDuration; + + let newPosition = swiper.translate + momentumDistance; + if (rtl) newPosition = -newPosition; + + let doBounce = false; + let afterBouncePosition; + const bounceAmount = Math.abs(swiper.velocity) * 20 * params.freeModeMomentumBounceRatio; + let needsLoopFix; + if (newPosition < swiper.maxTranslate()) { + if (params.freeModeMomentumBounce) { + if (newPosition + swiper.maxTranslate() < -bounceAmount) { + newPosition = swiper.maxTranslate() - bounceAmount; + } + afterBouncePosition = swiper.maxTranslate(); + doBounce = true; + data$$1.allowMomentumBounce = true; + } else { + newPosition = swiper.maxTranslate(); + } + if (params.loop && params.centeredSlides) needsLoopFix = true; + } else if (newPosition > swiper.minTranslate()) { + if (params.freeModeMomentumBounce) { + if (newPosition - swiper.minTranslate() > bounceAmount) { + newPosition = swiper.minTranslate() + bounceAmount; + } + afterBouncePosition = swiper.minTranslate(); + doBounce = true; + data$$1.allowMomentumBounce = true; + } else { + newPosition = swiper.minTranslate(); + } + if (params.loop && params.centeredSlides) needsLoopFix = true; + } else if (params.freeModeSticky) { + let nextSlide; + for (let j = 0; j < snapGrid.length; j += 1) { + if (snapGrid[j] > -newPosition) { + nextSlide = j; + break; + } + } + + if (Math.abs(snapGrid[nextSlide] - newPosition) < Math.abs(snapGrid[nextSlide - 1] - newPosition) || swiper.swipeDirection === 'next') { + newPosition = snapGrid[nextSlide]; + } else { + newPosition = snapGrid[nextSlide - 1]; + } + newPosition = -newPosition; + } + if (needsLoopFix) { + swiper.once('transitionEnd', () => { + swiper.loopFix(); + }); + } + // Fix duration + if (swiper.velocity !== 0) { + if (rtl) { + momentumDuration = Math.abs((-newPosition - swiper.translate) / swiper.velocity); + } else { + momentumDuration = Math.abs((newPosition - swiper.translate) / swiper.velocity); + } + } else if (params.freeModeSticky) { + swiper.slideToClosest(); + return; + } + + if (params.freeModeMomentumBounce && doBounce) { + swiper.updateProgress(afterBouncePosition); + swiper.setTransition(momentumDuration); + swiper.setTranslate(newPosition); + swiper.transitionStart(true, swiper.swipeDirection); + swiper.animating = true; + $wrapperEl.transitionEnd(() => { + if (!swiper || swiper.destroyed || !data$$1.allowMomentumBounce) return; + swiper.emit('momentumBounce'); + + swiper.setTransition(params.speed); + swiper.setTranslate(afterBouncePosition); + $wrapperEl.transitionEnd(() => { + if (!swiper || swiper.destroyed) return; + swiper.transitionEnd(); + }); + }); + } else if (swiper.velocity) { + swiper.updateProgress(newPosition); + swiper.setTransition(momentumDuration); + swiper.setTranslate(newPosition); + swiper.transitionStart(true, swiper.swipeDirection); + if (!swiper.animating) { + swiper.animating = true; + $wrapperEl.transitionEnd(() => { + if (!swiper || swiper.destroyed) return; + swiper.transitionEnd(); + }); + } + } else { + swiper.updateProgress(newPosition); + } + + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } else if (params.freeModeSticky) { + swiper.slideToClosest(); + return; + } + + if (!params.freeModeMomentum || timeDiff >= params.longSwipesMs) { + swiper.updateProgress(); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + return; + } + + // Find current slide + let stopIndex = 0; + let groupSize = swiper.slidesSizesGrid[0]; + for (let i = 0; i < slidesGrid.length; i += params.slidesPerGroup) { + if (typeof slidesGrid[i + params.slidesPerGroup] !== 'undefined') { + if (currentPos >= slidesGrid[i] && currentPos < slidesGrid[i + params.slidesPerGroup]) { + stopIndex = i; + groupSize = slidesGrid[i + params.slidesPerGroup] - slidesGrid[i]; + } + } else if (currentPos >= slidesGrid[i]) { + stopIndex = i; + groupSize = slidesGrid[slidesGrid.length - 1] - slidesGrid[slidesGrid.length - 2]; + } + } + + // Find current slide size + const ratio = (currentPos - slidesGrid[stopIndex]) / groupSize; + + if (timeDiff > params.longSwipesMs) { + // Long touches + if (!params.longSwipes) { + swiper.slideTo(swiper.activeIndex); + return; + } + if (swiper.swipeDirection === 'next') { + if (ratio >= params.longSwipesRatio) swiper.slideTo(stopIndex + params.slidesPerGroup); + else swiper.slideTo(stopIndex); + } + if (swiper.swipeDirection === 'prev') { + if (ratio > (1 - params.longSwipesRatio)) swiper.slideTo(stopIndex + params.slidesPerGroup); + else swiper.slideTo(stopIndex); + } + } else { + // Short swipes + if (!params.shortSwipes) { + swiper.slideTo(swiper.activeIndex); + return; + } + if (swiper.swipeDirection === 'next') { + swiper.slideTo(stopIndex + params.slidesPerGroup); + } + if (swiper.swipeDirection === 'prev') { + swiper.slideTo(stopIndex); + } + } +} + +function onResize () { + const swiper = this; + + const { params, el } = swiper; + + if (el && el.offsetWidth === 0) return; + + // Breakpoints + if (params.breakpoints) { + swiper.setBreakpoint(); + } + + // Save locks + const { allowSlideNext, allowSlidePrev, snapGrid } = swiper; + + // Disable locks on resize + swiper.allowSlideNext = true; + swiper.allowSlidePrev = true; + + swiper.updateSize(); + swiper.updateSlides(); + + if (params.freeMode) { + const newTranslate = Math.min(Math.max(swiper.translate, swiper.maxTranslate()), swiper.minTranslate()); + swiper.setTranslate(newTranslate); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + } else { + swiper.updateSlidesClasses(); + if ((params.slidesPerView === 'auto' || params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) { + swiper.slideTo(swiper.slides.length - 1, 0, false, true); + } else { + swiper.slideTo(swiper.activeIndex, 0, false, true); + } + } + // Return locks after resize + swiper.allowSlidePrev = allowSlidePrev; + swiper.allowSlideNext = allowSlideNext; + + if (swiper.params.watchOverflow && snapGrid !== swiper.snapGrid) { + swiper.checkOverflow(); + } +} + +function onClick (e) { + const swiper = this; + if (!swiper.allowClick) { + if (swiper.params.preventClicks) e.preventDefault(); + if (swiper.params.preventClicksPropagation && swiper.animating) { + e.stopPropagation(); + e.stopImmediatePropagation(); + } + } +} + +function attachEvents() { + const swiper = this; + const { + params, touchEvents, el, wrapperEl, + } = swiper; + + { + swiper.onTouchStart = onTouchStart.bind(swiper); + swiper.onTouchMove = onTouchMove.bind(swiper); + swiper.onTouchEnd = onTouchEnd.bind(swiper); + } + + swiper.onClick = onClick.bind(swiper); + + const target = params.touchEventsTarget === 'container' ? el : wrapperEl; + const capture = !!params.nested; + + // Touch Events + { + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.addEventListener(touchEvents.start, swiper.onTouchStart, false); + document.addEventListener(touchEvents.move, swiper.onTouchMove, capture); + document.addEventListener(touchEvents.end, swiper.onTouchEnd, false); + } else { + if (Support.touch) { + const passiveListener = touchEvents.start === 'touchstart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false; + target.addEventListener(touchEvents.start, swiper.onTouchStart, passiveListener); + target.addEventListener(touchEvents.move, swiper.onTouchMove, Support.passiveListener ? { passive: false, capture } : capture); + target.addEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.addEventListener('mousedown', swiper.onTouchStart, false); + document.addEventListener('mousemove', swiper.onTouchMove, capture); + document.addEventListener('mouseup', swiper.onTouchEnd, false); + } + } + // Prevent Links Clicks + if (params.preventClicks || params.preventClicksPropagation) { + target.addEventListener('click', swiper.onClick, true); + } + } + + // Resize handler + swiper.on('resize observerUpdate', onResize, true); +} + +function detachEvents() { + const swiper = this; + + const { + params, touchEvents, el, wrapperEl, + } = swiper; + + const target = params.touchEventsTarget === 'container' ? el : wrapperEl; + const capture = !!params.nested; + + // Touch Events + { + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.removeEventListener(touchEvents.start, swiper.onTouchStart, false); + document.removeEventListener(touchEvents.move, swiper.onTouchMove, capture); + document.removeEventListener(touchEvents.end, swiper.onTouchEnd, false); + } else { + if (Support.touch) { + const passiveListener = touchEvents.start === 'onTouchStart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false; + target.removeEventListener(touchEvents.start, swiper.onTouchStart, passiveListener); + target.removeEventListener(touchEvents.move, swiper.onTouchMove, capture); + target.removeEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.removeEventListener('mousedown', swiper.onTouchStart, false); + document.removeEventListener('mousemove', swiper.onTouchMove, capture); + document.removeEventListener('mouseup', swiper.onTouchEnd, false); + } + } + // Prevent Links Clicks + if (params.preventClicks || params.preventClicksPropagation) { + target.removeEventListener('click', swiper.onClick, true); + } + } + + // Resize handler + swiper.off('resize observerUpdate', onResize); +} + +var events = { + attachEvents, + detachEvents, +}; + +function setBreakpoint () { + const swiper = this; + const { + activeIndex, initialized, loopedSlides = 0, params, + } = swiper; + const breakpoints = params.breakpoints; + if (!breakpoints || (breakpoints && Object.keys(breakpoints).length === 0)) return; + // Set breakpoint for window width and update parameters + const breakpoint = swiper.getBreakpoint(breakpoints); + if (breakpoint && swiper.currentBreakpoint !== breakpoint) { + const breakPointsParams = breakpoint in breakpoints ? breakpoints[breakpoint] : swiper.originalParams; + const needsReLoop = params.loop && (breakPointsParams.slidesPerView !== params.slidesPerView); + + Utils.extend(swiper.params, breakPointsParams); + + Utils.extend(swiper, { + allowTouchMove: swiper.params.allowTouchMove, + allowSlideNext: swiper.params.allowSlideNext, + allowSlidePrev: swiper.params.allowSlidePrev, + }); + + swiper.currentBreakpoint = breakpoint; + + if (needsReLoop && initialized) { + swiper.loopDestroy(); + swiper.loopCreate(); + swiper.updateSlides(); + swiper.slideTo((activeIndex - loopedSlides) + swiper.loopedSlides, 0, false); + } + swiper.emit('breakpoint', breakPointsParams); + } +} + +function getBreakpoint (breakpoints) { + // Get breakpoint for window width + if (!breakpoints) return undefined; + let breakpoint = false; + const points = []; + Object.keys(breakpoints).forEach((point) => { + points.push(point); + }); + points.sort((a, b) => parseInt(a, 10) - parseInt(b, 10)); + for (let i = 0; i < points.length; i += 1) { + const point = points[i]; + if (point >= window.innerWidth && !breakpoint) { + breakpoint = point; + } + } + return breakpoint || 'max'; +} + +var breakpoints = { setBreakpoint, getBreakpoint }; + +const Browser = (function Browser() { + function isSafari() { + const ua = window.navigator.userAgent.toLowerCase(); + return (ua.indexOf('safari') >= 0 && ua.indexOf('chrome') < 0 && ua.indexOf('android') < 0); + } + return { + isIE: !!window.navigator.userAgent.match(/Trident/g) || !!window.navigator.userAgent.match(/MSIE/g), + isSafari: isSafari(), + isUiWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(window.navigator.userAgent), + }; +}()); + +function addClasses () { + const swiper = this; + const { + classNames, params, rtl, $el, + } = swiper; + const suffixes = []; + + suffixes.push(params.direction); + + if (params.freeMode) { + suffixes.push('free-mode'); + } + if (!Support.flexbox) { + suffixes.push('no-flexbox'); + } + if (params.autoHeight) { + suffixes.push('autoheight'); + } + if (rtl) { + suffixes.push('rtl'); + } + if (params.slidesPerColumn > 1) { + suffixes.push('multirow'); + } + if (Device.android) { + suffixes.push('android'); + } + if (Device.ios) { + suffixes.push('ios'); + } + // WP8 Touch Events Fix + if (Browser.isIE && (Support.pointerEvents || Support.prefixedPointerEvents)) { + suffixes.push(`wp8-${params.direction}`); + } + + suffixes.forEach((suffix) => { + classNames.push(params.containerModifierClass + suffix); + }); + + $el.addClass(classNames.join(' ')); +} + +function removeClasses () { + const swiper = this; + const { $el, classNames } = swiper; + + $el.removeClass(classNames.join(' ')); +} + +var classes = { addClasses, removeClasses }; + +function loadImage (imageEl, src, srcset, sizes, checkForComplete, callback) { + let image; + function onReady() { + if (callback) callback(); + } + if (!imageEl.complete || !checkForComplete) { + if (src) { + image = new window.Image(); + image.onload = onReady; + image.onerror = onReady; + if (sizes) { + image.sizes = sizes; + } + if (srcset) { + image.srcset = srcset; + } + if (src) { + image.src = src; + } + } else { + onReady(); + } + } else { + // image already loaded... + onReady(); + } +} + +function preloadImages () { + const swiper = this; + swiper.imagesToLoad = swiper.$el.find('img'); + function onReady() { + if (typeof swiper === 'undefined' || swiper === null || !swiper || swiper.destroyed) return; + if (swiper.imagesLoaded !== undefined) swiper.imagesLoaded += 1; + if (swiper.imagesLoaded === swiper.imagesToLoad.length) { + if (swiper.params.updateOnImagesReady) swiper.update(); + swiper.emit('imagesReady'); + } + } + for (let i = 0; i < swiper.imagesToLoad.length; i += 1) { + const imageEl = swiper.imagesToLoad[i]; + swiper.loadImage( + imageEl, + imageEl.currentSrc || imageEl.getAttribute('src'), + imageEl.srcset || imageEl.getAttribute('srcset'), + imageEl.sizes || imageEl.getAttribute('sizes'), + true, + onReady + ); + } +} + +var images = { + loadImage, + preloadImages, +}; + +function checkOverflow() { + const swiper = this; + const wasLocked = swiper.isLocked; + + swiper.isLocked = swiper.snapGrid.length === 1; + swiper.allowSlideNext = !swiper.isLocked; + swiper.allowSlidePrev = !swiper.isLocked; + + // events + if (wasLocked !== swiper.isLocked) swiper.emit(swiper.isLocked ? 'lock' : 'unlock'); + + if (wasLocked && wasLocked !== swiper.isLocked) { + swiper.isEnd = false; + swiper.navigation.update(); + } +} + +var checkOverflow$1 = { checkOverflow }; + +var defaults = { + init: true, + direction: 'horizontal', + touchEventsTarget: 'container', + initialSlide: 0, + speed: 300, + // + preventIntercationOnTransition: false, + + // To support iOS's swipe-to-go-back gesture (when being used in-app, with UIWebView). + iOSEdgeSwipeDetection: false, + iOSEdgeSwipeThreshold: 20, + + // Free mode + freeMode: false, + freeModeMomentum: true, + freeModeMomentumRatio: 1, + freeModeMomentumBounce: true, + freeModeMomentumBounceRatio: 1, + freeModeMomentumVelocityRatio: 1, + freeModeSticky: false, + freeModeMinimumVelocity: 0.02, + + // Autoheight + autoHeight: false, + + // Set wrapper width + setWrapperSize: false, + + // Virtual Translate + virtualTranslate: false, + + // Effects + effect: 'slide', // 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip' + + // Breakpoints + breakpoints: undefined, + + // Slides grid + spaceBetween: 0, + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerColumnFill: 'column', + slidesPerGroup: 1, + centeredSlides: false, + slidesOffsetBefore: 0, // in px + slidesOffsetAfter: 0, // in px + normalizeSlideIndex: true, + + // Disable swiper and hide navigation when container not overflow + watchOverflow: false, + + // Round length + roundLengths: false, + + // Touches + touchRatio: 1, + touchAngle: 45, + simulateTouch: true, + shortSwipes: true, + longSwipes: true, + longSwipesRatio: 0.5, + longSwipesMs: 300, + followFinger: true, + allowTouchMove: true, + threshold: 0, + touchMoveStopPropagation: true, + touchReleaseOnEdges: false, + + // Unique Navigation Elements + uniqueNavElements: true, + + // Resistance + resistance: true, + resistanceRatio: 0.85, + + // Progress + watchSlidesProgress: false, + watchSlidesVisibility: false, + + // Cursor + grabCursor: false, + + // Clicks + preventClicks: true, + preventClicksPropagation: true, + slideToClickedSlide: false, + + // Images + preloadImages: true, + updateOnImagesReady: true, + + // loop + loop: false, + loopAdditionalSlides: 0, + loopedSlides: null, + loopFillGroupWithBlank: false, + + // Swiping/no swiping + allowSlidePrev: true, + allowSlideNext: true, + swipeHandler: null, // '.swipe-handler', + noSwiping: true, + noSwipingClass: 'swiper-no-swiping', + noSwipingSelector: null, + + // Passive Listeners + passiveListeners: true, + + // NS + containerModifierClass: 'swiper-container-', // NEW + slideClass: 'swiper-slide', + slideBlankClass: 'swiper-slide-invisible-blank', + slideActiveClass: 'swiper-slide-active', + slideDuplicateActiveClass: 'swiper-slide-duplicate-active', + slideVisibleClass: 'swiper-slide-visible', + slideDuplicateClass: 'swiper-slide-duplicate', + slideNextClass: 'swiper-slide-next', + slideDuplicateNextClass: 'swiper-slide-duplicate-next', + slidePrevClass: 'swiper-slide-prev', + slideDuplicatePrevClass: 'swiper-slide-duplicate-prev', + wrapperClass: 'swiper-wrapper', + + // Callbacks + runCallbacksOnInit: true, +}; + +const prototypes = { + update, + translate, + transition: transition$1, + slide, + loop, + grabCursor, + manipulation, + events, + breakpoints, + checkOverflow: checkOverflow$1, + classes, + images, +}; + +const extendedDefaults = {}; + +class Swiper extends SwiperClass { + constructor(...args) { + let el; + let params; + if (args.length === 1 && args[0].constructor && args[0].constructor === Object) { + params = args[0]; + } else { + [el, params] = args; + } + if (!params) params = {}; + + params = Utils.extend({}, params); + if (el && !params.el) params.el = el; + + super(params); + + Object.keys(prototypes).forEach((prototypeGroup) => { + Object.keys(prototypes[prototypeGroup]).forEach((protoMethod) => { + if (!Swiper.prototype[protoMethod]) { + Swiper.prototype[protoMethod] = prototypes[prototypeGroup][protoMethod]; + } + }); + }); + + // Swiper Instance + const swiper = this; + if (typeof swiper.modules === 'undefined') { + swiper.modules = {}; + } + Object.keys(swiper.modules).forEach((moduleName) => { + const module = swiper.modules[moduleName]; + if (module.params) { + const moduleParamName = Object.keys(module.params)[0]; + const moduleParams = module.params[moduleParamName]; + if (typeof moduleParams !== 'object') return; + if (!(moduleParamName in params && 'enabled' in moduleParams)) return; + if (params[moduleParamName] === true) { + params[moduleParamName] = { enabled: true }; + } + if ( + typeof params[moduleParamName] === 'object' && + !('enabled' in params[moduleParamName]) + ) { + params[moduleParamName].enabled = true; + } + if (!params[moduleParamName]) params[moduleParamName] = { enabled: false }; + } + }); + + // Extend defaults with modules params + const swiperParams = Utils.extend({}, defaults); + swiper.useModulesParams(swiperParams); + + // Extend defaults with passed params + swiper.params = Utils.extend({}, swiperParams, extendedDefaults, params); + swiper.originalParams = Utils.extend({}, swiper.params); + swiper.passedParams = Utils.extend({}, params); + + // Save Dom lib + swiper.$ = $; + + // Find el + const $el = $(swiper.params.el); + el = $el[0]; + + if (!el) { + return undefined; + } + + if ($el.length > 1) { + const swipers = []; + $el.each((index$$1, containerEl) => { + const newParams = Utils.extend({}, params, { el: containerEl }); + swipers.push(new Swiper(newParams)); + }); + return swipers; + } + + el.swiper = swiper; + $el.data('swiper', swiper); + + // Find Wrapper + const $wrapperEl = $el.children(`.${swiper.params.wrapperClass}`); + + // Extend Swiper + Utils.extend(swiper, { + $el, + el, + $wrapperEl, + wrapperEl: $wrapperEl[0], + + // Classes + classNames: [], + + // Slides + slides: $(), + slidesGrid: [], + snapGrid: [], + slidesSizesGrid: [], + + // isDirection + isHorizontal() { + return swiper.params.direction === 'horizontal'; + }, + isVertical() { + return swiper.params.direction === 'vertical'; + }, + // RTL + rtl: (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'), + rtlTranslate: swiper.params.direction === 'horizontal' && (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'), + wrongRTL: $wrapperEl.css('display') === '-webkit-box', + + // Indexes + activeIndex: 0, + realIndex: 0, + + // + isBeginning: true, + isEnd: false, + + // Props + translate: 0, + progress: 0, + velocity: 0, + animating: false, + + // Locks + allowSlideNext: swiper.params.allowSlideNext, + allowSlidePrev: swiper.params.allowSlidePrev, + + // Touch Events + touchEvents: (function touchEvents() { + const touch = ['touchstart', 'touchmove', 'touchend']; + let desktop = ['mousedown', 'mousemove', 'mouseup']; + if (Support.pointerEvents) { + desktop = ['pointerdown', 'pointermove', 'pointerup']; + } else if (Support.prefixedPointerEvents) { + desktop = ['MSPointerDown', 'MSPointerMove', 'MSPointerUp']; + } + swiper.touchEventsTouch = { + start: touch[0], + move: touch[1], + end: touch[2], + }; + swiper.touchEventsDesktop = { + start: desktop[0], + move: desktop[1], + end: desktop[2], + }; + return Support.touch || !swiper.params.simulateTouch ? swiper.touchEventsTouch : swiper.touchEventsDesktop; + }()), + touchEventsData: { + isTouched: undefined, + isMoved: undefined, + allowTouchCallbacks: undefined, + touchStartTime: undefined, + isScrolling: undefined, + currentTranslate: undefined, + startTranslate: undefined, + allowThresholdMove: undefined, + // Form elements to match + formElements: 'input, select, option, textarea, button, video', + // Last click time + lastClickTime: Utils.now(), + clickTimeout: undefined, + // Velocities + velocities: [], + allowMomentumBounce: undefined, + isTouchEvent: undefined, + startMoving: undefined, + }, + + // Clicks + allowClick: true, + + // Touches + allowTouchMove: swiper.params.allowTouchMove, + + touches: { + startX: 0, + startY: 0, + currentX: 0, + currentY: 0, + diff: 0, + }, + + // Images + imagesToLoad: [], + imagesLoaded: 0, + + }); + + // Install Modules + swiper.useModules(); + + // Init + if (swiper.params.init) { + swiper.init(); + } + + // Return app instance + return swiper; + } + slidesPerViewDynamic() { + const swiper = this; + const { + params, slides, slidesGrid, size: swiperSize, activeIndex, + } = swiper; + let spv = 1; + if (params.centeredSlides) { + let slideSize = slides[activeIndex].swiperSlideSize; + let breakLoop; + for (let i = activeIndex + 1; i < slides.length; i += 1) { + if (slides[i] && !breakLoop) { + slideSize += slides[i].swiperSlideSize; + spv += 1; + if (slideSize > swiperSize) breakLoop = true; + } + } + for (let i = activeIndex - 1; i >= 0; i -= 1) { + if (slides[i] && !breakLoop) { + slideSize += slides[i].swiperSlideSize; + spv += 1; + if (slideSize > swiperSize) breakLoop = true; + } + } + } else { + for (let i = activeIndex + 1; i < slides.length; i += 1) { + if (slidesGrid[i] - slidesGrid[activeIndex] < swiperSize) { + spv += 1; + } + } + } + return spv; + } + update() { + const swiper = this; + if (!swiper || swiper.destroyed) return; + const { snapGrid, params } = swiper; + // Breakpoints + if (params.breakpoints) { + swiper.setBreakpoint(); + } + swiper.updateSize(); + swiper.updateSlides(); + swiper.updateProgress(); + swiper.updateSlidesClasses(); + + function setTranslate() { + const translateValue = swiper.rtlTranslate ? swiper.translate * -1 : swiper.translate; + const newTranslate = Math.min(Math.max(translateValue, swiper.maxTranslate()), swiper.minTranslate()); + swiper.setTranslate(newTranslate); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + let translated; + if (swiper.params.freeMode) { + setTranslate(); + if (swiper.params.autoHeight) { + swiper.updateAutoHeight(); + } + } else { + if ((swiper.params.slidesPerView === 'auto' || swiper.params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) { + translated = swiper.slideTo(swiper.slides.length - 1, 0, false, true); + } else { + translated = swiper.slideTo(swiper.activeIndex, 0, false, true); + } + if (!translated) { + setTranslate(); + } + } + if (params.watchOverflow && snapGrid !== swiper.snapGrid) { + swiper.checkOverflow(); + } + swiper.emit('update'); + } + init() { + const swiper = this; + if (swiper.initialized) return; + + swiper.emit('beforeInit'); + + // Set breakpoint + if (swiper.params.breakpoints) { + swiper.setBreakpoint(); + } + + // Add Classes + swiper.addClasses(); + + // Create loop + if (swiper.params.loop) { + swiper.loopCreate(); + } + + // Update size + swiper.updateSize(); + + // Update slides + swiper.updateSlides(); + + if (swiper.params.watchOverflow) { + swiper.checkOverflow(); + } + + // Set Grab Cursor + if (swiper.params.grabCursor) { + swiper.setGrabCursor(); + } + + if (swiper.params.preloadImages) { + swiper.preloadImages(); + } + + // Slide To Initial Slide + if (swiper.params.loop) { + swiper.slideTo(swiper.params.initialSlide + swiper.loopedSlides, 0, swiper.params.runCallbacksOnInit); + } else { + swiper.slideTo(swiper.params.initialSlide, 0, swiper.params.runCallbacksOnInit); + } + + // Attach events + swiper.attachEvents(); + + // Init Flag + swiper.initialized = true; + + // Emit + swiper.emit('init'); + } + destroy(deleteInstance = true, cleanStyles = true) { + const swiper = this; + const { + params, $el, $wrapperEl, slides, + } = swiper; + + if (typeof swiper.params === 'undefined' || swiper.destroyed) { + return null; + } + + swiper.emit('beforeDestroy'); + + // Init Flag + swiper.initialized = false; + + // Detach events + swiper.detachEvents(); + + // Destroy loop + if (params.loop) { + swiper.loopDestroy(); + } + + // Cleanup styles + if (cleanStyles) { + swiper.removeClasses(); + $el.removeAttr('style'); + $wrapperEl.removeAttr('style'); + if (slides && slides.length) { + slides + .removeClass([ + params.slideVisibleClass, + params.slideActiveClass, + params.slideNextClass, + params.slidePrevClass, + ].join(' ')) + .removeAttr('style') + .removeAttr('data-swiper-slide-index') + .removeAttr('data-swiper-column') + .removeAttr('data-swiper-row'); + } + } + + swiper.emit('destroy'); + + // Detach emitter events + Object.keys(swiper.eventsListeners).forEach((eventName) => { + swiper.off(eventName); + }); + + if (deleteInstance !== false) { + swiper.$el[0].swiper = null; + swiper.$el.data('swiper', null); + Utils.deleteProps(swiper); + } + swiper.destroyed = true; + + return null; + } + static extendDefaults(newDefaults) { + Utils.extend(extendedDefaults, newDefaults); + } + static get extendedDefaults() { + return extendedDefaults; + } + static get defaults() { + return defaults; + } + static get Class() { + return SwiperClass; + } + static get $() { + return $; + } +} + +var Device$1 = { + name: 'device', + proto: { + device: Device, + }, + static: { + device: Device, + }, +}; + +var Support$1 = { + name: 'support', + proto: { + support: Support, + }, + static: { + support: Support, + }, +}; + +var Browser$1 = { + name: 'browser', + proto: { + browser: Browser, + }, + static: { + browser: Browser, + }, +}; + +var Resize = { + name: 'resize', + create() { + const swiper = this; + Utils.extend(swiper, { + resize: { + resizeHandler() { + if (!swiper || swiper.destroyed || !swiper.initialized) return; + swiper.emit('beforeResize'); + swiper.emit('resize'); + }, + orientationChangeHandler() { + if (!swiper || swiper.destroyed || !swiper.initialized) return; + swiper.emit('orientationchange'); + }, + }, + }); + }, + on: { + init() { + const swiper = this; + // Emit resize + window.addEventListener('resize', swiper.resize.resizeHandler); + + // Emit orientationchange + window.addEventListener('orientationchange', swiper.resize.orientationChangeHandler); + }, + destroy() { + const swiper = this; + window.removeEventListener('resize', swiper.resize.resizeHandler); + window.removeEventListener('orientationchange', swiper.resize.orientationChangeHandler); + }, + }, +}; + +const Observer = { + func: window.MutationObserver || window.WebkitMutationObserver, + attach(target, options = {}) { + const swiper = this; + + const ObserverFunc = Observer.func; + const observer = new ObserverFunc((mutations) => { + mutations.forEach((mutation) => { + swiper.emit('observerUpdate', mutation); + }); + }); + + observer.observe(target, { + attributes: typeof options.attributes === 'undefined' ? true : options.attributes, + childList: typeof options.childList === 'undefined' ? true : options.childList, + characterData: typeof options.characterData === 'undefined' ? true : options.characterData, + }); + + swiper.observer.observers.push(observer); + }, + init() { + const swiper = this; + if (!Support.observer || !swiper.params.observer) return; + if (swiper.params.observeParents) { + const containerParents = swiper.$el.parents(); + for (let i = 0; i < containerParents.length; i += 1) { + swiper.observer.attach(containerParents[i]); + } + } + // Observe container + swiper.observer.attach(swiper.$el[0], { childList: false }); + + // Observe wrapper + swiper.observer.attach(swiper.$wrapperEl[0], { attributes: false }); + }, + destroy() { + const swiper = this; + swiper.observer.observers.forEach((observer) => { + observer.disconnect(); + }); + swiper.observer.observers = []; + }, +}; + +var Observer$1 = { + name: 'observer', + params: { + observer: false, + observeParents: false, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + observer: { + init: Observer.init.bind(swiper), + attach: Observer.attach.bind(swiper), + destroy: Observer.destroy.bind(swiper), + observers: [], + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.observer.init(); + }, + destroy() { + const swiper = this; + swiper.observer.destroy(); + }, + }, +}; + +const Virtual = { + update(force) { + const swiper = this; + const { slidesPerView, slidesPerGroup, centeredSlides } = swiper.params; + const { + from: previousFrom, + to: previousTo, + slides, + slidesGrid: previousSlidesGrid, + renderSlide, + offset: previousOffset, + } = swiper.virtual; + swiper.updateActiveIndex(); + const activeIndex = swiper.activeIndex || 0; + + let offsetProp; + if (swiper.rtlTranslate) offsetProp = 'right'; + else offsetProp = swiper.isHorizontal() ? 'left' : 'top'; + + let slidesAfter; + let slidesBefore; + if (centeredSlides) { + slidesAfter = Math.floor(slidesPerView / 2) + slidesPerGroup; + slidesBefore = Math.floor(slidesPerView / 2) + slidesPerGroup; + } else { + slidesAfter = slidesPerView + (slidesPerGroup - 1); + slidesBefore = slidesPerGroup; + } + const from = Math.max((activeIndex || 0) - slidesBefore, 0); + const to = Math.min((activeIndex || 0) + slidesAfter, slides.length - 1); + const offset$$1 = (swiper.slidesGrid[from] || 0) - (swiper.slidesGrid[0] || 0); + + Utils.extend(swiper.virtual, { + from, + to, + offset: offset$$1, + slidesGrid: swiper.slidesGrid, + }); + + function onRendered() { + swiper.updateSlides(); + swiper.updateProgress(); + swiper.updateSlidesClasses(); + if (swiper.lazy && swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + } + + if (previousFrom === from && previousTo === to && !force) { + if (swiper.slidesGrid !== previousSlidesGrid && offset$$1 !== previousOffset) { + swiper.slides.css(offsetProp, `${offset$$1}px`); + } + swiper.updateProgress(); + return; + } + if (swiper.params.virtual.renderExternal) { + swiper.params.virtual.renderExternal.call(swiper, { + offset: offset$$1, + from, + to, + slides: (function getSlides() { + const slidesToRender = []; + for (let i = from; i <= to; i += 1) { + slidesToRender.push(slides[i]); + } + return slidesToRender; + }()), + }); + onRendered(); + return; + } + const prependIndexes = []; + const appendIndexes = []; + if (force) { + swiper.$wrapperEl.find(`.${swiper.params.slideClass}`).remove(); + } else { + for (let i = previousFrom; i <= previousTo; i += 1) { + if (i < from || i > to) { + swiper.$wrapperEl.find(`.${swiper.params.slideClass}[data-swiper-slide-index="${i}"]`).remove(); + } + } + } + for (let i = 0; i < slides.length; i += 1) { + if (i >= from && i <= to) { + if (typeof previousTo === 'undefined' || force) { + appendIndexes.push(i); + } else { + if (i > previousTo) appendIndexes.push(i); + if (i < previousFrom) prependIndexes.push(i); + } + } + } + appendIndexes.forEach((index$$1) => { + swiper.$wrapperEl.append(renderSlide(slides[index$$1], index$$1)); + }); + prependIndexes.sort((a, b) => a < b).forEach((index$$1) => { + swiper.$wrapperEl.prepend(renderSlide(slides[index$$1], index$$1)); + }); + swiper.$wrapperEl.children('.swiper-slide').css(offsetProp, `${offset$$1}px`); + onRendered(); + }, + renderSlide(slide, index$$1) { + const swiper = this; + const params = swiper.params.virtual; + if (params.cache && swiper.virtual.cache[index$$1]) { + return swiper.virtual.cache[index$$1]; + } + const $slideEl = params.renderSlide + ? $(params.renderSlide.call(swiper, slide, index$$1)) + : $(`
    ${slide}
    `); + if (!$slideEl.attr('data-swiper-slide-index')) $slideEl.attr('data-swiper-slide-index', index$$1); + if (params.cache) swiper.virtual.cache[index$$1] = $slideEl; + return $slideEl; + }, + appendSlide(slide) { + const swiper = this; + swiper.virtual.slides.push(slide); + swiper.virtual.update(true); + }, + prependSlide(slide) { + const swiper = this; + swiper.virtual.slides.unshift(slide); + if (swiper.params.virtual.cache) { + const cache = swiper.virtual.cache; + const newCache = {}; + Object.keys(cache).forEach((cachedIndex) => { + newCache[cachedIndex + 1] = cache[cachedIndex]; + }); + swiper.virtual.cache = newCache; + } + swiper.virtual.update(true); + swiper.slideNext(0); + }, +}; + +var virtual = { + name: 'virtual', + params: { + virtual: { + enabled: false, + slides: [], + cache: true, + renderSlide: null, + renderExternal: null, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + virtual: { + update: Virtual.update.bind(swiper), + appendSlide: Virtual.appendSlide.bind(swiper), + prependSlide: Virtual.prependSlide.bind(swiper), + renderSlide: Virtual.renderSlide.bind(swiper), + slides: swiper.params.virtual.slides, + cache: {}, + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (!swiper.params.virtual.enabled) return; + swiper.classNames.push(`${swiper.params.containerModifierClass}virtual`); + const overwriteParams = { + watchSlidesProgress: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + + swiper.virtual.update(); + }, + setTranslate() { + const swiper = this; + if (!swiper.params.virtual.enabled) return; + swiper.virtual.update(); + }, + }, +}; + +const Keyboard = { + handle(event) { + const swiper = this; + const { rtlTranslate: rtl } = swiper; + let e = event; + if (e.originalEvent) e = e.originalEvent; // jquery fix + const kc = e.keyCode || e.charCode; + // Directions locks + if (!swiper.allowSlideNext && ((swiper.isHorizontal() && kc === 39) || (swiper.isVertical() && kc === 40))) { + return false; + } + if (!swiper.allowSlidePrev && ((swiper.isHorizontal() && kc === 37) || (swiper.isVertical() && kc === 38))) { + return false; + } + if (e.shiftKey || e.altKey || e.ctrlKey || e.metaKey) { + return undefined; + } + if (document.activeElement && document.activeElement.nodeName && (document.activeElement.nodeName.toLowerCase() === 'input' || document.activeElement.nodeName.toLowerCase() === 'textarea')) { + return undefined; + } + if (swiper.params.keyboard.onlyInViewport && (kc === 37 || kc === 39 || kc === 38 || kc === 40)) { + let inView = false; + // Check that swiper should be inside of visible area of window + if (swiper.$el.parents(`.${swiper.params.slideClass}`).length > 0 && swiper.$el.parents(`.${swiper.params.slideActiveClass}`).length === 0) { + return undefined; + } + const windowWidth = window.innerWidth; + const windowHeight = window.innerHeight; + const swiperOffset = swiper.$el.offset(); + if (rtl) swiperOffset.left -= swiper.$el[0].scrollLeft; + const swiperCoord = [ + [swiperOffset.left, swiperOffset.top], + [swiperOffset.left + swiper.width, swiperOffset.top], + [swiperOffset.left, swiperOffset.top + swiper.height], + [swiperOffset.left + swiper.width, swiperOffset.top + swiper.height], + ]; + for (let i = 0; i < swiperCoord.length; i += 1) { + const point = swiperCoord[i]; + if ( + point[0] >= 0 && point[0] <= windowWidth && + point[1] >= 0 && point[1] <= windowHeight + ) { + inView = true; + } + } + if (!inView) return undefined; + } + if (swiper.isHorizontal()) { + if (kc === 37 || kc === 39) { + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + } + if ((kc === 39 && !rtl) || (kc === 37 && rtl)) swiper.slideNext(); + if ((kc === 37 && !rtl) || (kc === 39 && rtl)) swiper.slidePrev(); + } else { + if (kc === 38 || kc === 40) { + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + } + if (kc === 40) swiper.slideNext(); + if (kc === 38) swiper.slidePrev(); + } + swiper.emit('keyPress', kc); + return undefined; + }, + enable() { + const swiper = this; + if (swiper.keyboard.enabled) return; + $(document).on('keydown', swiper.keyboard.handle); + swiper.keyboard.enabled = true; + }, + disable() { + const swiper = this; + if (!swiper.keyboard.enabled) return; + $(document).off('keydown', swiper.keyboard.handle); + swiper.keyboard.enabled = false; + }, +}; + +var keyboard = { + name: 'keyboard', + params: { + keyboard: { + enabled: false, + onlyInViewport: true, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + keyboard: { + enabled: false, + enable: Keyboard.enable.bind(swiper), + disable: Keyboard.disable.bind(swiper), + handle: Keyboard.handle.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.keyboard.enabled) { + swiper.keyboard.enable(); + } + }, + destroy() { + const swiper = this; + if (swiper.keyboard.enabled) { + swiper.keyboard.disable(); + } + }, + }, +}; + +function isEventSupported() { + const eventName = 'onwheel'; + let isSupported = eventName in document; + + if (!isSupported) { + const element = document.createElement('div'); + element.setAttribute(eventName, 'return;'); + isSupported = typeof element[eventName] === 'function'; + } + + if (!isSupported && + document.implementation && + document.implementation.hasFeature && + // always returns true in newer browsers as per the standard. + // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature + document.implementation.hasFeature('', '') !== true + ) { + // This is the only way to test support for the `wheel` event in IE9+. + isSupported = document.implementation.hasFeature('Events.wheel', '3.0'); + } + + return isSupported; +} +const Mousewheel = { + lastScrollTime: Utils.now(), + event: (function getEvent() { + if (window.navigator.userAgent.indexOf('firefox') > -1) return 'DOMMouseScroll'; + return isEventSupported() ? 'wheel' : 'mousewheel'; + }()), + normalize(e) { + // Reasonable defaults + const PIXEL_STEP = 10; + const LINE_HEIGHT = 40; + const PAGE_HEIGHT = 800; + + let sX = 0; + let sY = 0; // spinX, spinY + let pX = 0; + let pY = 0; // pixelX, pixelY + + // Legacy + if ('detail' in e) { + sY = e.detail; + } + if ('wheelDelta' in e) { + sY = -e.wheelDelta / 120; + } + if ('wheelDeltaY' in e) { + sY = -e.wheelDeltaY / 120; + } + if ('wheelDeltaX' in e) { + sX = -e.wheelDeltaX / 120; + } + + // side scrolling on FF with DOMMouseScroll + if ('axis' in e && e.axis === e.HORIZONTAL_AXIS) { + sX = sY; + sY = 0; + } + + pX = sX * PIXEL_STEP; + pY = sY * PIXEL_STEP; + + if ('deltaY' in e) { + pY = e.deltaY; + } + if ('deltaX' in e) { + pX = e.deltaX; + } + + if ((pX || pY) && e.deltaMode) { + if (e.deltaMode === 1) { // delta in LINE units + pX *= LINE_HEIGHT; + pY *= LINE_HEIGHT; + } else { // delta in PAGE units + pX *= PAGE_HEIGHT; + pY *= PAGE_HEIGHT; + } + } + + // Fall-back if spin cannot be determined + if (pX && !sX) { + sX = (pX < 1) ? -1 : 1; + } + if (pY && !sY) { + sY = (pY < 1) ? -1 : 1; + } + + return { + spinX: sX, + spinY: sY, + pixelX: pX, + pixelY: pY, + }; + }, + handleMouseEnter() { + const swiper = this; + swiper.mouseEntered = true; + }, + handleMouseLeave() { + const swiper = this; + swiper.mouseEntered = false; + }, + handle(event) { + let e = event; + const swiper = this; + const params = swiper.params.mousewheel; + + if (!swiper.mouseEntered && !params.releaseOnEdges) return true; + + if (e.originalEvent) e = e.originalEvent; // jquery fix + let delta = 0; + const rtlFactor = swiper.rtlTranslate ? -1 : 1; + + const data$$1 = Mousewheel.normalize(e); + + if (params.forceToAxis) { + if (swiper.isHorizontal()) { + if (Math.abs(data$$1.pixelX) > Math.abs(data$$1.pixelY)) delta = data$$1.pixelX * rtlFactor; + else return true; + } else if (Math.abs(data$$1.pixelY) > Math.abs(data$$1.pixelX)) delta = data$$1.pixelY; + else return true; + } else { + delta = Math.abs(data$$1.pixelX) > Math.abs(data$$1.pixelY) ? -data$$1.pixelX * rtlFactor : -data$$1.pixelY; + } + + if (delta === 0) return true; + + if (params.invert) delta = -delta; + + if (!swiper.params.freeMode) { + if (Utils.now() - swiper.mousewheel.lastScrollTime > 60) { + if (delta < 0) { + if ((!swiper.isEnd || swiper.params.loop) && !swiper.animating) { + swiper.slideNext(); + swiper.emit('scroll', e); + } else if (params.releaseOnEdges) return true; + } else if ((!swiper.isBeginning || swiper.params.loop) && !swiper.animating) { + swiper.slidePrev(); + swiper.emit('scroll', e); + } else if (params.releaseOnEdges) return true; + } + swiper.mousewheel.lastScrollTime = (new window.Date()).getTime(); + } else { + // Freemode or scrollContainer: + if (swiper.params.loop) { + swiper.loopFix(); + } + let position = swiper.getTranslate() + (delta * params.sensitivity); + const wasBeginning = swiper.isBeginning; + const wasEnd = swiper.isEnd; + + if (position >= swiper.minTranslate()) position = swiper.minTranslate(); + if (position <= swiper.maxTranslate()) position = swiper.maxTranslate(); + + swiper.setTransition(0); + swiper.setTranslate(position); + swiper.updateProgress(); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + + if ((!wasBeginning && swiper.isBeginning) || (!wasEnd && swiper.isEnd)) { + swiper.updateSlidesClasses(); + } + + if (swiper.params.freeModeSticky) { + clearTimeout(swiper.mousewheel.timeout); + swiper.mousewheel.timeout = Utils.nextTick(() => { + swiper.slideToClosest(); + }, 300); + } + // Emit event + swiper.emit('scroll', e); + + // Stop autoplay + if (swiper.params.autoplay && swiper.params.autoplayDisableOnInteraction) swiper.stopAutoplay(); + // Return page scroll on edge positions + if (position === swiper.minTranslate() || position === swiper.maxTranslate()) return true; + } + + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + return false; + }, + enable() { + const swiper = this; + if (!Mousewheel.event) return false; + if (swiper.mousewheel.enabled) return false; + let target = swiper.$el; + if (swiper.params.mousewheel.eventsTarged !== 'container') { + target = $(swiper.params.mousewheel.eventsTarged); + } + target.on('mouseenter', swiper.mousewheel.handleMouseEnter); + target.on('mouseleave', swiper.mousewheel.handleMouseLeave); + target.on(Mousewheel.event, swiper.mousewheel.handle); + swiper.mousewheel.enabled = true; + return true; + }, + disable() { + const swiper = this; + if (!Mousewheel.event) return false; + if (!swiper.mousewheel.enabled) return false; + let target = swiper.$el; + if (swiper.params.mousewheel.eventsTarged !== 'container') { + target = $(swiper.params.mousewheel.eventsTarged); + } + target.off(Mousewheel.event, swiper.mousewheel.handle); + swiper.mousewheel.enabled = false; + return true; + }, +}; + +var mousewheel = { + name: 'mousewheel', + params: { + mousewheel: { + enabled: false, + releaseOnEdges: false, + invert: false, + forceToAxis: false, + sensitivity: 1, + eventsTarged: 'container', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + mousewheel: { + enabled: false, + enable: Mousewheel.enable.bind(swiper), + disable: Mousewheel.disable.bind(swiper), + handle: Mousewheel.handle.bind(swiper), + handleMouseEnter: Mousewheel.handleMouseEnter.bind(swiper), + handleMouseLeave: Mousewheel.handleMouseLeave.bind(swiper), + lastScrollTime: Utils.now(), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.mousewheel.enabled) swiper.mousewheel.enable(); + }, + destroy() { + const swiper = this; + if (swiper.mousewheel.enabled) swiper.mousewheel.disable(); + }, + }, +}; + +const Navigation = { + update() { + // Update Navigation Buttons + const swiper = this; + const params = swiper.params.navigation; + + if (swiper.params.loop) return; + const { $nextEl, $prevEl } = swiper.navigation; + + if ($prevEl && $prevEl.length > 0) { + if (swiper.isBeginning) { + $prevEl.addClass(params.disabledClass); + } else { + $prevEl.removeClass(params.disabledClass); + } + $prevEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + } + if ($nextEl && $nextEl.length > 0) { + if (swiper.isEnd) { + $nextEl.addClass(params.disabledClass); + } else { + $nextEl.removeClass(params.disabledClass); + } + $nextEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + } + }, + init() { + const swiper = this; + const params = swiper.params.navigation; + if (!(params.nextEl || params.prevEl)) return; + + let $nextEl; + let $prevEl; + if (params.nextEl) { + $nextEl = $(params.nextEl); + if ( + swiper.params.uniqueNavElements && + typeof params.nextEl === 'string' && + $nextEl.length > 1 && + swiper.$el.find(params.nextEl).length === 1 + ) { + $nextEl = swiper.$el.find(params.nextEl); + } + } + if (params.prevEl) { + $prevEl = $(params.prevEl); + if ( + swiper.params.uniqueNavElements && + typeof params.prevEl === 'string' && + $prevEl.length > 1 && + swiper.$el.find(params.prevEl).length === 1 + ) { + $prevEl = swiper.$el.find(params.prevEl); + } + } + + if ($nextEl && $nextEl.length > 0) { + $nextEl.on('click', (e) => { + e.preventDefault(); + if (swiper.isEnd && !swiper.params.loop) return; + swiper.slideNext(); + }); + } + if ($prevEl && $prevEl.length > 0) { + $prevEl.on('click', (e) => { + e.preventDefault(); + if (swiper.isBeginning && !swiper.params.loop) return; + swiper.slidePrev(); + }); + } + + Utils.extend(swiper.navigation, { + $nextEl, + nextEl: $nextEl && $nextEl[0], + $prevEl, + prevEl: $prevEl && $prevEl[0], + }); + }, + destroy() { + const swiper = this; + const { $nextEl, $prevEl } = swiper.navigation; + if ($nextEl && $nextEl.length) { + $nextEl.off('click'); + $nextEl.removeClass(swiper.params.navigation.disabledClass); + } + if ($prevEl && $prevEl.length) { + $prevEl.off('click'); + $prevEl.removeClass(swiper.params.navigation.disabledClass); + } + }, +}; + +var navigation = { + name: 'navigation', + params: { + navigation: { + nextEl: null, + prevEl: null, + + hideOnClick: false, + disabledClass: 'swiper-button-disabled', + hiddenClass: 'swiper-button-hidden', + lockClass: 'swiper-button-lock', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + navigation: { + init: Navigation.init.bind(swiper), + update: Navigation.update.bind(swiper), + destroy: Navigation.destroy.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.navigation.init(); + swiper.navigation.update(); + }, + toEdge() { + const swiper = this; + swiper.navigation.update(); + }, + fromEdge() { + const swiper = this; + swiper.navigation.update(); + }, + destroy() { + const swiper = this; + swiper.navigation.destroy(); + }, + click(e) { + const swiper = this; + const { $nextEl, $prevEl } = swiper.navigation; + if ( + swiper.params.navigation.hideOnClick && + !$(e.target).is($prevEl) && + !$(e.target).is($nextEl) + ) { + if ($nextEl) $nextEl.toggleClass(swiper.params.navigation.hiddenClass); + if ($prevEl) $prevEl.toggleClass(swiper.params.navigation.hiddenClass); + } + }, + }, +}; + +const Pagination = { + update() { + // Render || Update Pagination bullets/items + const swiper = this; + const rtl = swiper.rtl; + const params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) return; + const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length; + const $el = swiper.pagination.$el; + // Current/Total + let current; + const total = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length; + if (swiper.params.loop) { + current = Math.ceil((swiper.activeIndex - swiper.loopedSlides) / swiper.params.slidesPerGroup); + if (current > slidesLength - 1 - (swiper.loopedSlides * 2)) { + current -= (slidesLength - (swiper.loopedSlides * 2)); + } + if (current > total - 1) current -= total; + if (current < 0 && swiper.params.paginationType !== 'bullets') current = total + current; + } else if (typeof swiper.snapIndex !== 'undefined') { + current = swiper.snapIndex; + } else { + current = swiper.activeIndex || 0; + } + // Types + if (params.type === 'bullets' && swiper.pagination.bullets && swiper.pagination.bullets.length > 0) { + const bullets = swiper.pagination.bullets; + let firstIndex; + let lastIndex; + let midIndex; + if (params.dynamicBullets) { + swiper.pagination.bulletSize = bullets.eq(0)[swiper.isHorizontal() ? 'outerWidth' : 'outerHeight'](true); + $el.css(swiper.isHorizontal() ? 'width' : 'height', `${swiper.pagination.bulletSize * (params.dynamicMainBullets + 4)}px`); + if (params.dynamicMainBullets > 1 && swiper.previousIndex !== undefined) { + swiper.pagination.dynamicBulletIndex += (current - swiper.previousIndex); + if (swiper.pagination.dynamicBulletIndex > (params.dynamicMainBullets - 1)) { + swiper.pagination.dynamicBulletIndex = params.dynamicMainBullets - 1; + } else if (swiper.pagination.dynamicBulletIndex < 0) { + swiper.pagination.dynamicBulletIndex = 0; + } + } + firstIndex = current - swiper.pagination.dynamicBulletIndex; + lastIndex = firstIndex + (Math.min(bullets.length, params.dynamicMainBullets) - 1); + midIndex = (lastIndex + firstIndex) / 2; + } + bullets.removeClass(`${params.bulletActiveClass} ${params.bulletActiveClass}-next ${params.bulletActiveClass}-next-next ${params.bulletActiveClass}-prev ${params.bulletActiveClass}-prev-prev ${params.bulletActiveClass}-main`); + if ($el.length > 1) { + bullets.each((index$$1, bullet) => { + const $bullet = $(bullet); + const bulletIndex = $bullet.index(); + if (bulletIndex === current) { + $bullet.addClass(params.bulletActiveClass); + } + if (params.dynamicBullets) { + if (bulletIndex >= firstIndex && bulletIndex <= lastIndex) { + $bullet.addClass(`${params.bulletActiveClass}-main`); + } + if (bulletIndex === firstIndex) { + $bullet + .prev() + .addClass(`${params.bulletActiveClass}-prev`) + .prev() + .addClass(`${params.bulletActiveClass}-prev-prev`); + } + if (bulletIndex === lastIndex) { + $bullet + .next() + .addClass(`${params.bulletActiveClass}-next`) + .next() + .addClass(`${params.bulletActiveClass}-next-next`); + } + } + }); + } else { + const $bullet = bullets.eq(current); + $bullet.addClass(params.bulletActiveClass); + if (params.dynamicBullets) { + const $firstDisplayedBullet = bullets.eq(firstIndex); + const $lastDisplayedBullet = bullets.eq(lastIndex); + for (let i = firstIndex; i <= lastIndex; i += 1) { + bullets.eq(i).addClass(`${params.bulletActiveClass}-main`); + } + $firstDisplayedBullet + .prev() + .addClass(`${params.bulletActiveClass}-prev`) + .prev() + .addClass(`${params.bulletActiveClass}-prev-prev`); + $lastDisplayedBullet + .next() + .addClass(`${params.bulletActiveClass}-next`) + .next() + .addClass(`${params.bulletActiveClass}-next-next`); + } + } + if (params.dynamicBullets) { + const dynamicBulletsLength = Math.min(bullets.length, params.dynamicMainBullets + 4); + const bulletsOffset = (((swiper.pagination.bulletSize * dynamicBulletsLength) - (swiper.pagination.bulletSize)) / 2) - (midIndex * swiper.pagination.bulletSize); + const offsetProp = rtl ? 'right' : 'left'; + bullets.css(swiper.isHorizontal() ? offsetProp : 'top', `${bulletsOffset}px`); + } + } + if (params.type === 'fraction') { + $el.find(`.${params.currentClass}`).text(current + 1); + $el.find(`.${params.totalClass}`).text(total); + } + if (params.type === 'progressbar') { + let progressbarDirection; + if (params.progressbarOpposite) { + progressbarDirection = swiper.isHorizontal() ? 'vertical' : 'horizontal'; + } else { + progressbarDirection = swiper.isHorizontal() ? 'horizontal' : 'vertical'; + } + const scale = (current + 1) / total; + let scaleX = 1; + let scaleY = 1; + if (progressbarDirection === 'horizontal') { + scaleX = scale; + } else { + scaleY = scale; + } + $el.find(`.${params.progressbarFillClass}`).transform(`translate3d(0,0,0) scaleX(${scaleX}) scaleY(${scaleY})`).transition(swiper.params.speed); + } + if (params.type === 'custom' && params.renderCustom) { + $el.html(params.renderCustom(swiper, current + 1, total)); + swiper.emit('paginationRender', swiper, $el[0]); + } else { + swiper.emit('paginationUpdate', swiper, $el[0]); + } + $el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + }, + render() { + // Render Container + const swiper = this; + const params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) return; + const slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length; + + const $el = swiper.pagination.$el; + let paginationHTML = ''; + if (params.type === 'bullets') { + const numberOfBullets = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length; + for (let i = 0; i < numberOfBullets; i += 1) { + if (params.renderBullet) { + paginationHTML += params.renderBullet.call(swiper, i, params.bulletClass); + } else { + paginationHTML += `<${params.bulletElement} class="${params.bulletClass}">`; + } + } + $el.html(paginationHTML); + swiper.pagination.bullets = $el.find(`.${params.bulletClass}`); + } + if (params.type === 'fraction') { + if (params.renderFraction) { + paginationHTML = params.renderFraction.call(swiper, params.currentClass, params.totalClass); + } else { + paginationHTML = + `` + + ' / ' + + ``; + } + $el.html(paginationHTML); + } + if (params.type === 'progressbar') { + if (params.renderProgressbar) { + paginationHTML = params.renderProgressbar.call(swiper, params.progressbarFillClass); + } else { + paginationHTML = ``; + } + $el.html(paginationHTML); + } + if (params.type !== 'custom') { + swiper.emit('paginationRender', swiper.pagination.$el[0]); + } + }, + init() { + const swiper = this; + const params = swiper.params.pagination; + if (!params.el) return; + + let $el = $(params.el); + if ($el.length === 0) return; + + if ( + swiper.params.uniqueNavElements && + typeof params.el === 'string' && + $el.length > 1 && + swiper.$el.find(params.el).length === 1 + ) { + $el = swiper.$el.find(params.el); + } + + if (params.type === 'bullets' && params.clickable) { + $el.addClass(params.clickableClass); + } + + $el.addClass(params.modifierClass + params.type); + + if (params.type === 'bullets' && params.dynamicBullets) { + $el.addClass(`${params.modifierClass}${params.type}-dynamic`); + swiper.pagination.dynamicBulletIndex = 0; + if (params.dynamicMainBullets < 1) { + params.dynamicMainBullets = 1; + } + } + if (params.type === 'progressbar' && params.progressbarOpposite) { + $el.addClass(params.progressbarOppositeClass); + } + + if (params.clickable) { + $el.on('click', `.${params.bulletClass}`, function onClick(e) { + e.preventDefault(); + let index$$1 = $(this).index() * swiper.params.slidesPerGroup; + if (swiper.params.loop) index$$1 += swiper.loopedSlides; + swiper.slideTo(index$$1); + }); + } + + Utils.extend(swiper.pagination, { + $el, + el: $el[0], + }); + }, + destroy() { + const swiper = this; + const params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) return; + const $el = swiper.pagination.$el; + + $el.removeClass(params.hiddenClass); + $el.removeClass(params.modifierClass + params.type); + if (swiper.pagination.bullets) swiper.pagination.bullets.removeClass(params.bulletActiveClass); + if (params.clickable) { + $el.off('click', `.${params.bulletClass}`); + } + }, +}; + +var pagination = { + name: 'pagination', + params: { + pagination: { + el: null, + bulletElement: 'span', + clickable: false, + hideOnClick: false, + renderBullet: null, + renderProgressbar: null, + renderFraction: null, + renderCustom: null, + progressbarOpposite: false, + type: 'bullets', // 'bullets' or 'progressbar' or 'fraction' or 'custom' + dynamicBullets: false, + dynamicMainBullets: 1, + bulletClass: 'swiper-pagination-bullet', + bulletActiveClass: 'swiper-pagination-bullet-active', + modifierClass: 'swiper-pagination-', // NEW + currentClass: 'swiper-pagination-current', + totalClass: 'swiper-pagination-total', + hiddenClass: 'swiper-pagination-hidden', + progressbarFillClass: 'swiper-pagination-progressbar-fill', + progressbarOppositeClass: 'swiper-pagination-progressbar-opposite', + clickableClass: 'swiper-pagination-clickable', // NEW + lockClass: 'swiper-pagination-lock', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + pagination: { + init: Pagination.init.bind(swiper), + render: Pagination.render.bind(swiper), + update: Pagination.update.bind(swiper), + destroy: Pagination.destroy.bind(swiper), + dynamicBulletIndex: 0, + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.pagination.init(); + swiper.pagination.render(); + swiper.pagination.update(); + }, + activeIndexChange() { + const swiper = this; + if (swiper.params.loop) { + swiper.pagination.update(); + } else if (typeof swiper.snapIndex === 'undefined') { + swiper.pagination.update(); + } + }, + snapIndexChange() { + const swiper = this; + if (!swiper.params.loop) { + swiper.pagination.update(); + } + }, + slidesLengthChange() { + const swiper = this; + if (swiper.params.loop) { + swiper.pagination.render(); + swiper.pagination.update(); + } + }, + snapGridLengthChange() { + const swiper = this; + if (!swiper.params.loop) { + swiper.pagination.render(); + swiper.pagination.update(); + } + }, + destroy() { + const swiper = this; + swiper.pagination.destroy(); + }, + click(e) { + const swiper = this; + if ( + swiper.params.pagination.el && + swiper.params.pagination.hideOnClick && + swiper.pagination.$el.length > 0 && + !$(e.target).hasClass(swiper.params.pagination.bulletClass) + ) { + swiper.pagination.$el.toggleClass(swiper.params.pagination.hiddenClass); + } + }, + }, +}; + +const Scrollbar = { + setTranslate() { + const swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return; + const { scrollbar, rtlTranslate: rtl, progress } = swiper; + const { + dragSize, trackSize, $dragEl, $el, + } = scrollbar; + const params = swiper.params.scrollbar; + + let newSize = dragSize; + let newPos = (trackSize - dragSize) * progress; + if (rtl) { + newPos = -newPos; + if (newPos > 0) { + newSize = dragSize - newPos; + newPos = 0; + } else if (-newPos + dragSize > trackSize) { + newSize = trackSize + newPos; + } + } else if (newPos < 0) { + newSize = dragSize + newPos; + newPos = 0; + } else if (newPos + dragSize > trackSize) { + newSize = trackSize - newPos; + } + if (swiper.isHorizontal()) { + if (Support.transforms3d) { + $dragEl.transform(`translate3d(${newPos}px, 0, 0)`); + } else { + $dragEl.transform(`translateX(${newPos}px)`); + } + $dragEl[0].style.width = `${newSize}px`; + } else { + if (Support.transforms3d) { + $dragEl.transform(`translate3d(0px, ${newPos}px, 0)`); + } else { + $dragEl.transform(`translateY(${newPos}px)`); + } + $dragEl[0].style.height = `${newSize}px`; + } + if (params.hide) { + clearTimeout(swiper.scrollbar.timeout); + $el[0].style.opacity = 1; + swiper.scrollbar.timeout = setTimeout(() => { + $el[0].style.opacity = 0; + $el.transition(400); + }, 1000); + } + }, + setTransition(duration) { + const swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return; + swiper.scrollbar.$dragEl.transition(duration); + }, + updateSize() { + const swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) return; + + const { scrollbar } = swiper; + const { $dragEl, $el } = scrollbar; + + $dragEl[0].style.width = ''; + $dragEl[0].style.height = ''; + const trackSize = swiper.isHorizontal() ? $el[0].offsetWidth : $el[0].offsetHeight; + + const divider = swiper.size / swiper.virtualSize; + const moveDivider = divider * (trackSize / swiper.size); + let dragSize; + if (swiper.params.scrollbar.dragSize === 'auto') { + dragSize = trackSize * divider; + } else { + dragSize = parseInt(swiper.params.scrollbar.dragSize, 10); + } + + if (swiper.isHorizontal()) { + $dragEl[0].style.width = `${dragSize}px`; + } else { + $dragEl[0].style.height = `${dragSize}px`; + } + + if (divider >= 1) { + $el[0].style.display = 'none'; + } else { + $el[0].style.display = ''; + } + if (swiper.params.scrollbarHide) { + $el[0].style.opacity = 0; + } + Utils.extend(scrollbar, { + trackSize, + divider, + moveDivider, + dragSize, + }); + scrollbar.$el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](swiper.params.scrollbar.lockClass); + }, + setDragPosition(e) { + const swiper = this; + const { scrollbar, rtlTranslate: rtl } = swiper; + const { $el, dragSize, trackSize } = scrollbar; + + let pointerPosition; + if (swiper.isHorizontal()) { + pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageX : e.pageX || e.clientX); + } else { + pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageY : e.pageY || e.clientY); + } + let positionRatio; + positionRatio = ((pointerPosition) - $el.offset()[swiper.isHorizontal() ? 'left' : 'top'] - (dragSize / 2)) / (trackSize - dragSize); + positionRatio = Math.max(Math.min(positionRatio, 1), 0); + if (rtl) { + positionRatio = 1 - positionRatio; + } + + const position = swiper.minTranslate() + ((swiper.maxTranslate() - swiper.minTranslate()) * positionRatio); + + swiper.updateProgress(position); + swiper.setTranslate(position); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + }, + onDragStart(e) { + const swiper = this; + const params = swiper.params.scrollbar; + const { scrollbar, $wrapperEl } = swiper; + const { $el, $dragEl } = scrollbar; + swiper.scrollbar.isTouched = true; + e.preventDefault(); + e.stopPropagation(); + + $wrapperEl.transition(100); + $dragEl.transition(100); + scrollbar.setDragPosition(e); + + clearTimeout(swiper.scrollbar.dragTimeout); + + $el.transition(0); + if (params.hide) { + $el.css('opacity', 1); + } + swiper.emit('scrollbarDragStart', e); + }, + onDragMove(e) { + const swiper = this; + const { scrollbar, $wrapperEl } = swiper; + const { $el, $dragEl } = scrollbar; + + if (!swiper.scrollbar.isTouched) return; + if (e.preventDefault) e.preventDefault(); + else e.returnValue = false; + scrollbar.setDragPosition(e); + $wrapperEl.transition(0); + $el.transition(0); + $dragEl.transition(0); + swiper.emit('scrollbarDragMove', e); + }, + onDragEnd(e) { + const swiper = this; + + const params = swiper.params.scrollbar; + const { scrollbar } = swiper; + const { $el } = scrollbar; + + if (!swiper.scrollbar.isTouched) return; + swiper.scrollbar.isTouched = false; + if (params.hide) { + clearTimeout(swiper.scrollbar.dragTimeout); + swiper.scrollbar.dragTimeout = Utils.nextTick(() => { + $el.css('opacity', 0); + $el.transition(400); + }, 1000); + } + swiper.emit('scrollbarDragEnd', e); + if (params.snapOnRelease) { + swiper.slideToClosest(); + } + }, + enableDraggable() { + const swiper = this; + if (!swiper.params.scrollbar.el) return; + const { + scrollbar, touchEvents, touchEventsDesktop, params, + } = swiper; + const $el = scrollbar.$el; + const target = $el[0]; + const activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false; + const passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false; + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.addEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener); + document.addEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener); + document.addEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener); + } else { + if (Support.touch) { + target.addEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener); + target.addEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener); + target.addEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.addEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener); + document.addEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener); + document.addEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener); + } + } + }, + disableDraggable() { + const swiper = this; + if (!swiper.params.scrollbar.el) return; + const { + scrollbar, touchEvents, touchEventsDesktop, params, + } = swiper; + const $el = scrollbar.$el; + const target = $el[0]; + const activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false; + const passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false; + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.removeEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener); + document.removeEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener); + document.removeEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener); + } else { + if (Support.touch) { + target.removeEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener); + target.removeEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener); + target.removeEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.removeEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener); + document.removeEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener); + document.removeEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener); + } + } + }, + init() { + const swiper = this; + if (!swiper.params.scrollbar.el) return; + const { scrollbar, $el: $swiperEl } = swiper; + const params = swiper.params.scrollbar; + + let $el = $(params.el); + if (swiper.params.uniqueNavElements && typeof params.el === 'string' && $el.length > 1 && $swiperEl.find(params.el).length === 1) { + $el = $swiperEl.find(params.el); + } + + let $dragEl = $el.find(`.${swiper.params.scrollbar.dragClass}`); + if ($dragEl.length === 0) { + $dragEl = $(`
    `); + $el.append($dragEl); + } + + Utils.extend(scrollbar, { + $el, + el: $el[0], + $dragEl, + dragEl: $dragEl[0], + }); + + if (params.draggable) { + scrollbar.enableDraggable(); + } + }, + destroy() { + const swiper = this; + swiper.scrollbar.disableDraggable(); + }, +}; + +var scrollbar = { + name: 'scrollbar', + params: { + scrollbar: { + el: null, + dragSize: 'auto', + hide: false, + draggable: false, + snapOnRelease: true, + lockClass: 'swiper-scrollbar-lock', + dragClass: 'swiper-scrollbar-drag', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + scrollbar: { + init: Scrollbar.init.bind(swiper), + destroy: Scrollbar.destroy.bind(swiper), + updateSize: Scrollbar.updateSize.bind(swiper), + setTranslate: Scrollbar.setTranslate.bind(swiper), + setTransition: Scrollbar.setTransition.bind(swiper), + enableDraggable: Scrollbar.enableDraggable.bind(swiper), + disableDraggable: Scrollbar.disableDraggable.bind(swiper), + setDragPosition: Scrollbar.setDragPosition.bind(swiper), + onDragStart: Scrollbar.onDragStart.bind(swiper), + onDragMove: Scrollbar.onDragMove.bind(swiper), + onDragEnd: Scrollbar.onDragEnd.bind(swiper), + isTouched: false, + timeout: null, + dragTimeout: null, + }, + }); + }, + on: { + init() { + const swiper = this; + swiper.scrollbar.init(); + swiper.scrollbar.updateSize(); + swiper.scrollbar.setTranslate(); + }, + update() { + const swiper = this; + swiper.scrollbar.updateSize(); + }, + resize() { + const swiper = this; + swiper.scrollbar.updateSize(); + }, + observerUpdate() { + const swiper = this; + swiper.scrollbar.updateSize(); + }, + setTranslate() { + const swiper = this; + swiper.scrollbar.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + swiper.scrollbar.setTransition(duration); + }, + destroy() { + const swiper = this; + swiper.scrollbar.destroy(); + }, + }, +}; + +const Parallax = { + setTransform(el, progress) { + const swiper = this; + const { rtl } = swiper; + + const $el = $(el); + const rtlFactor = rtl ? -1 : 1; + + const p = $el.attr('data-swiper-parallax') || '0'; + let x = $el.attr('data-swiper-parallax-x'); + let y = $el.attr('data-swiper-parallax-y'); + const scale = $el.attr('data-swiper-parallax-scale'); + const opacity = $el.attr('data-swiper-parallax-opacity'); + + if (x || y) { + x = x || '0'; + y = y || '0'; + } else if (swiper.isHorizontal()) { + x = p; + y = '0'; + } else { + y = p; + x = '0'; + } + + if ((x).indexOf('%') >= 0) { + x = `${parseInt(x, 10) * progress * rtlFactor}%`; + } else { + x = `${x * progress * rtlFactor}px`; + } + if ((y).indexOf('%') >= 0) { + y = `${parseInt(y, 10) * progress}%`; + } else { + y = `${y * progress}px`; + } + + if (typeof opacity !== 'undefined' && opacity !== null) { + const currentOpacity = opacity - ((opacity - 1) * (1 - Math.abs(progress))); + $el[0].style.opacity = currentOpacity; + } + if (typeof scale === 'undefined' || scale === null) { + $el.transform(`translate3d(${x}, ${y}, 0px)`); + } else { + const currentScale = scale - ((scale - 1) * (1 - Math.abs(progress))); + $el.transform(`translate3d(${x}, ${y}, 0px) scale(${currentScale})`); + } + }, + setTranslate() { + const swiper = this; + const { + $el, slides, progress, snapGrid, + } = swiper; + $el.children('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each((index$$1, el) => { + swiper.parallax.setTransform(el, progress); + }); + slides.each((slideIndex, slideEl) => { + let slideProgress = slideEl.progress; + if (swiper.params.slidesPerGroup > 1 && swiper.params.slidesPerView !== 'auto') { + slideProgress += Math.ceil(slideIndex / 2) - (progress * (snapGrid.length - 1)); + } + slideProgress = Math.min(Math.max(slideProgress, -1), 1); + $(slideEl).find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each((index$$1, el) => { + swiper.parallax.setTransform(el, slideProgress); + }); + }); + }, + setTransition(duration = this.params.speed) { + const swiper = this; + const { $el } = swiper; + $el.find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each((index$$1, parallaxEl) => { + const $parallaxEl = $(parallaxEl); + let parallaxDuration = parseInt($parallaxEl.attr('data-swiper-parallax-duration'), 10) || duration; + if (duration === 0) parallaxDuration = 0; + $parallaxEl.transition(parallaxDuration); + }); + }, +}; + +var parallax = { + name: 'parallax', + params: { + parallax: { + enabled: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + parallax: { + setTransform: Parallax.setTransform.bind(swiper), + setTranslate: Parallax.setTranslate.bind(swiper), + setTransition: Parallax.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (!swiper.params.parallax.enabled) return; + swiper.params.watchSlidesProgress = true; + }, + init() { + const swiper = this; + if (!swiper.params.parallax) return; + swiper.parallax.setTranslate(); + }, + setTranslate() { + const swiper = this; + if (!swiper.params.parallax) return; + swiper.parallax.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (!swiper.params.parallax) return; + swiper.parallax.setTransition(duration); + }, + }, +}; + +const Zoom = { + // Calc Scale From Multi-touches + getDistanceBetweenTouches(e) { + if (e.targetTouches.length < 2) return 1; + const x1 = e.targetTouches[0].pageX; + const y1 = e.targetTouches[0].pageY; + const x2 = e.targetTouches[1].pageX; + const y2 = e.targetTouches[1].pageY; + const distance = Math.sqrt(((x2 - x1) ** 2) + ((y2 - y1) ** 2)); + return distance; + }, + // Events + onGestureStart(e) { + const swiper = this; + const params = swiper.params.zoom; + const zoom = swiper.zoom; + const { gesture } = zoom; + zoom.fakeGestureTouched = false; + zoom.fakeGestureMoved = false; + if (!Support.gestures) { + if (e.type !== 'touchstart' || (e.type === 'touchstart' && e.targetTouches.length < 2)) { + return; + } + zoom.fakeGestureTouched = true; + gesture.scaleStart = Zoom.getDistanceBetweenTouches(e); + } + if (!gesture.$slideEl || !gesture.$slideEl.length) { + gesture.$slideEl = $(e.target).closest('.swiper-slide'); + if (gesture.$slideEl.length === 0) gesture.$slideEl = swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(`.${params.containerClass}`); + gesture.maxRatio = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + if (gesture.$imageWrapEl.length === 0) { + gesture.$imageEl = undefined; + return; + } + } + gesture.$imageEl.transition(0); + swiper.zoom.isScaling = true; + }, + onGestureChange(e) { + const swiper = this; + const params = swiper.params.zoom; + const zoom = swiper.zoom; + const { gesture } = zoom; + if (!Support.gestures) { + if (e.type !== 'touchmove' || (e.type === 'touchmove' && e.targetTouches.length < 2)) { + return; + } + zoom.fakeGestureMoved = true; + gesture.scaleMove = Zoom.getDistanceBetweenTouches(e); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + if (Support.gestures) { + swiper.zoom.scale = e.scale * zoom.currentScale; + } else { + zoom.scale = (gesture.scaleMove / gesture.scaleStart) * zoom.currentScale; + } + if (zoom.scale > gesture.maxRatio) { + zoom.scale = (gesture.maxRatio - 1) + (((zoom.scale - gesture.maxRatio) + 1) ** 0.5); + } + if (zoom.scale < params.minRatio) { + zoom.scale = (params.minRatio + 1) - (((params.minRatio - zoom.scale) + 1) ** 0.5); + } + gesture.$imageEl.transform(`translate3d(0,0,0) scale(${zoom.scale})`); + }, + onGestureEnd(e) { + const swiper = this; + const params = swiper.params.zoom; + const zoom = swiper.zoom; + const { gesture } = zoom; + if (!Support.gestures) { + if (!zoom.fakeGestureTouched || !zoom.fakeGestureMoved) { + return; + } + if (e.type !== 'touchend' || (e.type === 'touchend' && e.changedTouches.length < 2 && !Device.android)) { + return; + } + zoom.fakeGestureTouched = false; + zoom.fakeGestureMoved = false; + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + zoom.scale = Math.max(Math.min(zoom.scale, gesture.maxRatio), params.minRatio); + gesture.$imageEl.transition(swiper.params.speed).transform(`translate3d(0,0,0) scale(${zoom.scale})`); + zoom.currentScale = zoom.scale; + zoom.isScaling = false; + if (zoom.scale === 1) gesture.$slideEl = undefined; + }, + onTouchStart(e) { + const swiper = this; + const zoom = swiper.zoom; + const { gesture, image } = zoom; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + if (image.isTouched) return; + if (Device.android) e.preventDefault(); + image.isTouched = true; + image.touchesStart.x = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX; + image.touchesStart.y = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY; + }, + onTouchMove(e) { + const swiper = this; + const zoom = swiper.zoom; + const { gesture, image, velocity } = zoom; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + swiper.allowClick = false; + if (!image.isTouched || !gesture.$slideEl) return; + + if (!image.isMoved) { + image.width = gesture.$imageEl[0].offsetWidth; + image.height = gesture.$imageEl[0].offsetHeight; + image.startX = Utils.getTranslate(gesture.$imageWrapEl[0], 'x') || 0; + image.startY = Utils.getTranslate(gesture.$imageWrapEl[0], 'y') || 0; + gesture.slideWidth = gesture.$slideEl[0].offsetWidth; + gesture.slideHeight = gesture.$slideEl[0].offsetHeight; + gesture.$imageWrapEl.transition(0); + if (swiper.rtl) { + image.startX = -image.startX; + image.startY = -image.startY; + } + } + // Define if we need image drag + const scaledWidth = image.width * zoom.scale; + const scaledHeight = image.height * zoom.scale; + + if (scaledWidth < gesture.slideWidth && scaledHeight < gesture.slideHeight) return; + + image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0); + image.maxX = -image.minX; + image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0); + image.maxY = -image.minY; + + image.touchesCurrent.x = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX; + image.touchesCurrent.y = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY; + + if (!image.isMoved && !zoom.isScaling) { + if ( + swiper.isHorizontal() && + ( + (Math.floor(image.minX) === Math.floor(image.startX) && image.touchesCurrent.x < image.touchesStart.x) || + (Math.floor(image.maxX) === Math.floor(image.startX) && image.touchesCurrent.x > image.touchesStart.x) + ) + ) { + image.isTouched = false; + return; + } else if ( + !swiper.isHorizontal() && + ( + (Math.floor(image.minY) === Math.floor(image.startY) && image.touchesCurrent.y < image.touchesStart.y) || + (Math.floor(image.maxY) === Math.floor(image.startY) && image.touchesCurrent.y > image.touchesStart.y) + ) + ) { + image.isTouched = false; + return; + } + } + e.preventDefault(); + e.stopPropagation(); + + image.isMoved = true; + image.currentX = (image.touchesCurrent.x - image.touchesStart.x) + image.startX; + image.currentY = (image.touchesCurrent.y - image.touchesStart.y) + image.startY; + + if (image.currentX < image.minX) { + image.currentX = (image.minX + 1) - (((image.minX - image.currentX) + 1) ** 0.8); + } + if (image.currentX > image.maxX) { + image.currentX = (image.maxX - 1) + (((image.currentX - image.maxX) + 1) ** 0.8); + } + + if (image.currentY < image.minY) { + image.currentY = (image.minY + 1) - (((image.minY - image.currentY) + 1) ** 0.8); + } + if (image.currentY > image.maxY) { + image.currentY = (image.maxY - 1) + (((image.currentY - image.maxY) + 1) ** 0.8); + } + + // Velocity + if (!velocity.prevPositionX) velocity.prevPositionX = image.touchesCurrent.x; + if (!velocity.prevPositionY) velocity.prevPositionY = image.touchesCurrent.y; + if (!velocity.prevTime) velocity.prevTime = Date.now(); + velocity.x = (image.touchesCurrent.x - velocity.prevPositionX) / (Date.now() - velocity.prevTime) / 2; + velocity.y = (image.touchesCurrent.y - velocity.prevPositionY) / (Date.now() - velocity.prevTime) / 2; + if (Math.abs(image.touchesCurrent.x - velocity.prevPositionX) < 2) velocity.x = 0; + if (Math.abs(image.touchesCurrent.y - velocity.prevPositionY) < 2) velocity.y = 0; + velocity.prevPositionX = image.touchesCurrent.x; + velocity.prevPositionY = image.touchesCurrent.y; + velocity.prevTime = Date.now(); + + gesture.$imageWrapEl.transform(`translate3d(${image.currentX}px, ${image.currentY}px,0)`); + }, + onTouchEnd() { + const swiper = this; + const zoom = swiper.zoom; + const { gesture, image, velocity } = zoom; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + if (!image.isTouched || !image.isMoved) { + image.isTouched = false; + image.isMoved = false; + return; + } + image.isTouched = false; + image.isMoved = false; + let momentumDurationX = 300; + let momentumDurationY = 300; + const momentumDistanceX = velocity.x * momentumDurationX; + const newPositionX = image.currentX + momentumDistanceX; + const momentumDistanceY = velocity.y * momentumDurationY; + const newPositionY = image.currentY + momentumDistanceY; + + // Fix duration + if (velocity.x !== 0) momentumDurationX = Math.abs((newPositionX - image.currentX) / velocity.x); + if (velocity.y !== 0) momentumDurationY = Math.abs((newPositionY - image.currentY) / velocity.y); + const momentumDuration = Math.max(momentumDurationX, momentumDurationY); + + image.currentX = newPositionX; + image.currentY = newPositionY; + + // Define if we need image drag + const scaledWidth = image.width * zoom.scale; + const scaledHeight = image.height * zoom.scale; + image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0); + image.maxX = -image.minX; + image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0); + image.maxY = -image.minY; + image.currentX = Math.max(Math.min(image.currentX, image.maxX), image.minX); + image.currentY = Math.max(Math.min(image.currentY, image.maxY), image.minY); + + gesture.$imageWrapEl.transition(momentumDuration).transform(`translate3d(${image.currentX}px, ${image.currentY}px,0)`); + }, + onTransitionEnd() { + const swiper = this; + const zoom = swiper.zoom; + const { gesture } = zoom; + if (gesture.$slideEl && swiper.previousIndex !== swiper.activeIndex) { + gesture.$imageEl.transform('translate3d(0,0,0) scale(1)'); + gesture.$imageWrapEl.transform('translate3d(0,0,0)'); + gesture.$slideEl = undefined; + gesture.$imageEl = undefined; + gesture.$imageWrapEl = undefined; + + zoom.scale = 1; + zoom.currentScale = 1; + } + }, + // Toggle Zoom + toggle(e) { + const swiper = this; + const zoom = swiper.zoom; + + if (zoom.scale && zoom.scale !== 1) { + // Zoom Out + zoom.out(); + } else { + // Zoom In + zoom.in(e); + } + }, + in(e) { + const swiper = this; + + const zoom = swiper.zoom; + const params = swiper.params.zoom; + const { gesture, image } = zoom; + + if (!gesture.$slideEl) { + gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(`.${params.containerClass}`); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + + gesture.$slideEl.addClass(`${params.zoomedSlideClass}`); + + let touchX; + let touchY; + let offsetX; + let offsetY; + let diffX; + let diffY; + let translateX; + let translateY; + let imageWidth; + let imageHeight; + let scaledWidth; + let scaledHeight; + let translateMinX; + let translateMinY; + let translateMaxX; + let translateMaxY; + let slideWidth; + let slideHeight; + + if (typeof image.touchesStart.x === 'undefined' && e) { + touchX = e.type === 'touchend' ? e.changedTouches[0].pageX : e.pageX; + touchY = e.type === 'touchend' ? e.changedTouches[0].pageY : e.pageY; + } else { + touchX = image.touchesStart.x; + touchY = image.touchesStart.y; + } + + zoom.scale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + zoom.currentScale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + if (e) { + slideWidth = gesture.$slideEl[0].offsetWidth; + slideHeight = gesture.$slideEl[0].offsetHeight; + offsetX = gesture.$slideEl.offset().left; + offsetY = gesture.$slideEl.offset().top; + diffX = (offsetX + (slideWidth / 2)) - touchX; + diffY = (offsetY + (slideHeight / 2)) - touchY; + + imageWidth = gesture.$imageEl[0].offsetWidth; + imageHeight = gesture.$imageEl[0].offsetHeight; + scaledWidth = imageWidth * zoom.scale; + scaledHeight = imageHeight * zoom.scale; + + translateMinX = Math.min(((slideWidth / 2) - (scaledWidth / 2)), 0); + translateMinY = Math.min(((slideHeight / 2) - (scaledHeight / 2)), 0); + translateMaxX = -translateMinX; + translateMaxY = -translateMinY; + + translateX = diffX * zoom.scale; + translateY = diffY * zoom.scale; + + if (translateX < translateMinX) { + translateX = translateMinX; + } + if (translateX > translateMaxX) { + translateX = translateMaxX; + } + + if (translateY < translateMinY) { + translateY = translateMinY; + } + if (translateY > translateMaxY) { + translateY = translateMaxY; + } + } else { + translateX = 0; + translateY = 0; + } + gesture.$imageWrapEl.transition(300).transform(`translate3d(${translateX}px, ${translateY}px,0)`); + gesture.$imageEl.transition(300).transform(`translate3d(0,0,0) scale(${zoom.scale})`); + }, + out() { + const swiper = this; + + const zoom = swiper.zoom; + const params = swiper.params.zoom; + const { gesture } = zoom; + + if (!gesture.$slideEl) { + gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(`.${params.containerClass}`); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) return; + + zoom.scale = 1; + zoom.currentScale = 1; + gesture.$imageWrapEl.transition(300).transform('translate3d(0,0,0)'); + gesture.$imageEl.transition(300).transform('translate3d(0,0,0) scale(1)'); + gesture.$slideEl.removeClass(`${params.zoomedSlideClass}`); + gesture.$slideEl = undefined; + }, + // Attach/Detach Events + enable() { + const swiper = this; + const zoom = swiper.zoom; + if (zoom.enabled) return; + zoom.enabled = true; + + const passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false; + + // Scale image + if (Support.gestures) { + swiper.$wrapperEl.on('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.on('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.on('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener); + } else if (swiper.touchEvents.start === 'touchstart') { + swiper.$wrapperEl.on(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.on(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.on(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener); + } + + // Move image + swiper.$wrapperEl.on(swiper.touchEvents.move, `.${swiper.params.zoom.containerClass}`, zoom.onTouchMove); + }, + disable() { + const swiper = this; + const zoom = swiper.zoom; + if (!zoom.enabled) return; + + swiper.zoom.enabled = false; + + const passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false; + + // Scale image + if (Support.gestures) { + swiper.$wrapperEl.off('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.off('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.off('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener); + } else if (swiper.touchEvents.start === 'touchstart') { + swiper.$wrapperEl.off(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.off(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.off(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener); + } + + // Move image + swiper.$wrapperEl.off(swiper.touchEvents.move, `.${swiper.params.zoom.containerClass}`, zoom.onTouchMove); + }, +}; + +var zoom = { + name: 'zoom', + params: { + zoom: { + enabled: false, + maxRatio: 3, + minRatio: 1, + toggle: true, + containerClass: 'swiper-zoom-container', + zoomedSlideClass: 'swiper-slide-zoomed', + }, + }, + create() { + const swiper = this; + const zoom = { + enabled: false, + scale: 1, + currentScale: 1, + isScaling: false, + gesture: { + $slideEl: undefined, + slideWidth: undefined, + slideHeight: undefined, + $imageEl: undefined, + $imageWrapEl: undefined, + maxRatio: 3, + }, + image: { + isTouched: undefined, + isMoved: undefined, + currentX: undefined, + currentY: undefined, + minX: undefined, + minY: undefined, + maxX: undefined, + maxY: undefined, + width: undefined, + height: undefined, + startX: undefined, + startY: undefined, + touchesStart: {}, + touchesCurrent: {}, + }, + velocity: { + x: undefined, + y: undefined, + prevPositionX: undefined, + prevPositionY: undefined, + prevTime: undefined, + }, + }; + ('onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out').split(' ').forEach((methodName) => { + zoom[methodName] = Zoom[methodName].bind(swiper); + }); + Utils.extend(swiper, { + zoom, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.zoom.enabled) { + swiper.zoom.enable(); + } + }, + destroy() { + const swiper = this; + swiper.zoom.disable(); + }, + touchStart(e) { + const swiper = this; + if (!swiper.zoom.enabled) return; + swiper.zoom.onTouchStart(e); + }, + touchEnd(e) { + const swiper = this; + if (!swiper.zoom.enabled) return; + swiper.zoom.onTouchEnd(e); + }, + doubleTap(e) { + const swiper = this; + if (swiper.params.zoom.enabled && swiper.zoom.enabled && swiper.params.zoom.toggle) { + swiper.zoom.toggle(e); + } + }, + transitionEnd() { + const swiper = this; + if (swiper.zoom.enabled && swiper.params.zoom.enabled) { + swiper.zoom.onTransitionEnd(); + } + }, + }, +}; + +const Lazy = { + loadInSlide(index$$1, loadInDuplicate = true) { + const swiper = this; + const params = swiper.params.lazy; + if (typeof index$$1 === 'undefined') return; + if (swiper.slides.length === 0) return; + const isVirtual = swiper.virtual && swiper.params.virtual.enabled; + + const $slideEl = isVirtual + ? swiper.$wrapperEl.children(`.${swiper.params.slideClass}[data-swiper-slide-index="${index$$1}"]`) + : swiper.slides.eq(index$$1); + + let $images = $slideEl.find(`.${params.elementClass}:not(.${params.loadedClass}):not(.${params.loadingClass})`); + if ($slideEl.hasClass(params.elementClass) && !$slideEl.hasClass(params.loadedClass) && !$slideEl.hasClass(params.loadingClass)) { + $images = $images.add($slideEl[0]); + } + if ($images.length === 0) return; + + $images.each((imageIndex, imageEl) => { + const $imageEl = $(imageEl); + $imageEl.addClass(params.loadingClass); + + const background = $imageEl.attr('data-background'); + const src = $imageEl.attr('data-src'); + const srcset = $imageEl.attr('data-srcset'); + const sizes = $imageEl.attr('data-sizes'); + + swiper.loadImage($imageEl[0], (src || background), srcset, sizes, false, () => { + if (typeof swiper === 'undefined' || swiper === null || !swiper || (swiper && !swiper.params) || swiper.destroyed) return; + if (background) { + $imageEl.css('background-image', `url("${background}")`); + $imageEl.removeAttr('data-background'); + } else { + if (srcset) { + $imageEl.attr('srcset', srcset); + $imageEl.removeAttr('data-srcset'); + } + if (sizes) { + $imageEl.attr('sizes', sizes); + $imageEl.removeAttr('data-sizes'); + } + if (src) { + $imageEl.attr('src', src); + $imageEl.removeAttr('data-src'); + } + } + + $imageEl.addClass(params.loadedClass).removeClass(params.loadingClass); + $slideEl.find(`.${params.preloaderClass}`).remove(); + if (swiper.params.loop && loadInDuplicate) { + const slideOriginalIndex = $slideEl.attr('data-swiper-slide-index'); + if ($slideEl.hasClass(swiper.params.slideDuplicateClass)) { + const originalSlide = swiper.$wrapperEl.children(`[data-swiper-slide-index="${slideOriginalIndex}"]:not(.${swiper.params.slideDuplicateClass})`); + swiper.lazy.loadInSlide(originalSlide.index(), false); + } else { + const duplicatedSlide = swiper.$wrapperEl.children(`.${swiper.params.slideDuplicateClass}[data-swiper-slide-index="${slideOriginalIndex}"]`); + swiper.lazy.loadInSlide(duplicatedSlide.index(), false); + } + } + swiper.emit('lazyImageReady', $slideEl[0], $imageEl[0]); + }); + + swiper.emit('lazyImageLoad', $slideEl[0], $imageEl[0]); + }); + }, + load() { + const swiper = this; + const { + $wrapperEl, params: swiperParams, slides, activeIndex, + } = swiper; + const isVirtual = swiper.virtual && swiperParams.virtual.enabled; + const params = swiperParams.lazy; + + let slidesPerView = swiperParams.slidesPerView; + if (slidesPerView === 'auto') { + slidesPerView = 0; + } + + function slideExist(index$$1) { + if (isVirtual) { + if ($wrapperEl.children(`.${swiperParams.slideClass}[data-swiper-slide-index="${index$$1}"]`).length) { + return true; + } + } else if (slides[index$$1]) return true; + return false; + } + function slideIndex(slideEl) { + if (isVirtual) { + return $(slideEl).attr('data-swiper-slide-index'); + } + return $(slideEl).index(); + } + + if (!swiper.lazy.initialImageLoaded) swiper.lazy.initialImageLoaded = true; + if (swiper.params.watchSlidesVisibility) { + $wrapperEl.children(`.${swiperParams.slideVisibleClass}`).each((elIndex, slideEl) => { + const index$$1 = isVirtual ? $(slideEl).attr('data-swiper-slide-index') : $(slideEl).index(); + swiper.lazy.loadInSlide(index$$1); + }); + } else if (slidesPerView > 1) { + for (let i = activeIndex; i < activeIndex + slidesPerView; i += 1) { + if (slideExist(i)) swiper.lazy.loadInSlide(i); + } + } else { + swiper.lazy.loadInSlide(activeIndex); + } + if (params.loadPrevNext) { + if (slidesPerView > 1 || (params.loadPrevNextAmount && params.loadPrevNextAmount > 1)) { + const amount = params.loadPrevNextAmount; + const spv = slidesPerView; + const maxIndex = Math.min(activeIndex + spv + Math.max(amount, spv), slides.length); + const minIndex = Math.max(activeIndex - Math.max(spv, amount), 0); + // Next Slides + for (let i = activeIndex + slidesPerView; i < maxIndex; i += 1) { + if (slideExist(i)) swiper.lazy.loadInSlide(i); + } + // Prev Slides + for (let i = minIndex; i < activeIndex; i += 1) { + if (slideExist(i)) swiper.lazy.loadInSlide(i); + } + } else { + const nextSlide = $wrapperEl.children(`.${swiperParams.slideNextClass}`); + if (nextSlide.length > 0) swiper.lazy.loadInSlide(slideIndex(nextSlide)); + + const prevSlide = $wrapperEl.children(`.${swiperParams.slidePrevClass}`); + if (prevSlide.length > 0) swiper.lazy.loadInSlide(slideIndex(prevSlide)); + } + } + }, +}; + +var lazy = { + name: 'lazy', + params: { + lazy: { + enabled: false, + loadPrevNext: false, + loadPrevNextAmount: 1, + loadOnTransitionStart: false, + + elementClass: 'swiper-lazy', + loadingClass: 'swiper-lazy-loading', + loadedClass: 'swiper-lazy-loaded', + preloaderClass: 'swiper-lazy-preloader', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + lazy: { + initialImageLoaded: false, + load: Lazy.load.bind(swiper), + loadInSlide: Lazy.loadInSlide.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.lazy.enabled && swiper.params.preloadImages) { + swiper.params.preloadImages = false; + } + }, + init() { + const swiper = this; + if (swiper.params.lazy.enabled && !swiper.params.loop && swiper.params.initialSlide === 0) { + swiper.lazy.load(); + } + }, + scroll() { + const swiper = this; + if (swiper.params.freeMode && !swiper.params.freeModeSticky) { + swiper.lazy.load(); + } + }, + resize() { + const swiper = this; + if (swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + }, + scrollbarDragMove() { + const swiper = this; + if (swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + }, + transitionStart() { + const swiper = this; + if (swiper.params.lazy.enabled) { + if (swiper.params.lazy.loadOnTransitionStart || (!swiper.params.lazy.loadOnTransitionStart && !swiper.lazy.initialImageLoaded)) { + swiper.lazy.load(); + } + } + }, + transitionEnd() { + const swiper = this; + if (swiper.params.lazy.enabled && !swiper.params.lazy.loadOnTransitionStart) { + swiper.lazy.load(); + } + }, + }, +}; + +/* eslint no-bitwise: ["error", { "allow": [">>"] }] */ + +const Controller = { + LinearSpline: function LinearSpline(x, y) { + const binarySearch = (function search() { + let maxIndex; + let minIndex; + let guess; + return (array, val) => { + minIndex = -1; + maxIndex = array.length; + while (maxIndex - minIndex > 1) { + guess = maxIndex + minIndex >> 1; + if (array[guess] <= val) { + minIndex = guess; + } else { + maxIndex = guess; + } + } + return maxIndex; + }; + }()); + this.x = x; + this.y = y; + this.lastIndex = x.length - 1; + // Given an x value (x2), return the expected y2 value: + // (x1,y1) is the known point before given value, + // (x3,y3) is the known point after given value. + let i1; + let i3; + + this.interpolate = function interpolate(x2) { + if (!x2) return 0; + + // Get the indexes of x1 and x3 (the array indexes before and after given x2): + i3 = binarySearch(this.x, x2); + i1 = i3 - 1; + + // We have our indexes i1 & i3, so we can calculate already: + // y2 := ((x2−x1) × (y3−y1)) ÷ (x3−x1) + y1 + return (((x2 - this.x[i1]) * (this.y[i3] - this.y[i1])) / (this.x[i3] - this.x[i1])) + this.y[i1]; + }; + return this; + }, + // xxx: for now i will just save one spline function to to + getInterpolateFunction(c) { + const swiper = this; + if (!swiper.controller.spline) { + swiper.controller.spline = swiper.params.loop ? + new Controller.LinearSpline(swiper.slidesGrid, c.slidesGrid) : + new Controller.LinearSpline(swiper.snapGrid, c.snapGrid); + } + }, + setTranslate(setTranslate, byController) { + const swiper = this; + const controlled = swiper.controller.control; + let multiplier; + let controlledTranslate; + function setControlledTranslate(c) { + // this will create an Interpolate function based on the snapGrids + // x is the Grid of the scrolled scroller and y will be the controlled scroller + // it makes sense to create this only once and recall it for the interpolation + // the function does a lot of value caching for performance + const translate = swiper.rtlTranslate ? -swiper.translate : swiper.translate; + if (swiper.params.controller.by === 'slide') { + swiper.controller.getInterpolateFunction(c); + // i am not sure why the values have to be multiplicated this way, tried to invert the snapGrid + // but it did not work out + controlledTranslate = -swiper.controller.spline.interpolate(-translate); + } + + if (!controlledTranslate || swiper.params.controller.by === 'container') { + multiplier = (c.maxTranslate() - c.minTranslate()) / (swiper.maxTranslate() - swiper.minTranslate()); + controlledTranslate = ((translate - swiper.minTranslate()) * multiplier) + c.minTranslate(); + } + + if (swiper.params.controller.inverse) { + controlledTranslate = c.maxTranslate() - controlledTranslate; + } + c.updateProgress(controlledTranslate); + c.setTranslate(controlledTranslate, swiper); + c.updateActiveIndex(); + c.updateSlidesClasses(); + } + if (Array.isArray(controlled)) { + for (let i = 0; i < controlled.length; i += 1) { + if (controlled[i] !== byController && controlled[i] instanceof Swiper) { + setControlledTranslate(controlled[i]); + } + } + } else if (controlled instanceof Swiper && byController !== controlled) { + setControlledTranslate(controlled); + } + }, + setTransition(duration, byController) { + const swiper = this; + const controlled = swiper.controller.control; + let i; + function setControlledTransition(c) { + c.setTransition(duration, swiper); + if (duration !== 0) { + c.transitionStart(); + c.$wrapperEl.transitionEnd(() => { + if (!controlled) return; + if (c.params.loop && swiper.params.controller.by === 'slide') { + c.loopFix(); + } + c.transitionEnd(); + }); + } + } + if (Array.isArray(controlled)) { + for (i = 0; i < controlled.length; i += 1) { + if (controlled[i] !== byController && controlled[i] instanceof Swiper) { + setControlledTransition(controlled[i]); + } + } + } else if (controlled instanceof Swiper && byController !== controlled) { + setControlledTransition(controlled); + } + }, +}; +var controller = { + name: 'controller', + params: { + controller: { + control: undefined, + inverse: false, + by: 'slide', // or 'container' + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + controller: { + control: swiper.params.controller.control, + getInterpolateFunction: Controller.getInterpolateFunction.bind(swiper), + setTranslate: Controller.setTranslate.bind(swiper), + setTransition: Controller.setTransition.bind(swiper), + }, + }); + }, + on: { + update() { + const swiper = this; + if (!swiper.controller.control) return; + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + resize() { + const swiper = this; + if (!swiper.controller.control) return; + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + observerUpdate() { + const swiper = this; + if (!swiper.controller.control) return; + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + setTranslate(translate, byController) { + const swiper = this; + if (!swiper.controller.control) return; + swiper.controller.setTranslate(translate, byController); + }, + setTransition(duration, byController) { + const swiper = this; + if (!swiper.controller.control) return; + swiper.controller.setTransition(duration, byController); + }, + }, +}; + +const a11y = { + makeElFocusable($el) { + $el.attr('tabIndex', '0'); + return $el; + }, + addElRole($el, role) { + $el.attr('role', role); + return $el; + }, + addElLabel($el, label) { + $el.attr('aria-label', label); + return $el; + }, + disableEl($el) { + $el.attr('aria-disabled', true); + return $el; + }, + enableEl($el) { + $el.attr('aria-disabled', false); + return $el; + }, + onEnterKey(e) { + const swiper = this; + const params = swiper.params.a11y; + if (e.keyCode !== 13) return; + const $targetEl = $(e.target); + if (swiper.navigation && swiper.navigation.$nextEl && $targetEl.is(swiper.navigation.$nextEl)) { + if (!(swiper.isEnd && !swiper.params.loop)) { + swiper.slideNext(); + } + if (swiper.isEnd) { + swiper.a11y.notify(params.lastSlideMessage); + } else { + swiper.a11y.notify(params.nextSlideMessage); + } + } + if (swiper.navigation && swiper.navigation.$prevEl && $targetEl.is(swiper.navigation.$prevEl)) { + if (!(swiper.isBeginning && !swiper.params.loop)) { + swiper.slidePrev(); + } + if (swiper.isBeginning) { + swiper.a11y.notify(params.firstSlideMessage); + } else { + swiper.a11y.notify(params.prevSlideMessage); + } + } + if (swiper.pagination && $targetEl.is(`.${swiper.params.pagination.bulletClass}`)) { + $targetEl[0].click(); + } + }, + notify(message) { + const swiper = this; + const notification = swiper.a11y.liveRegion; + if (notification.length === 0) return; + notification.html(''); + notification.html(message); + }, + updateNavigation() { + const swiper = this; + + if (swiper.params.loop) return; + const { $nextEl, $prevEl } = swiper.navigation; + + if ($prevEl && $prevEl.length > 0) { + if (swiper.isBeginning) { + swiper.a11y.disableEl($prevEl); + } else { + swiper.a11y.enableEl($prevEl); + } + } + if ($nextEl && $nextEl.length > 0) { + if (swiper.isEnd) { + swiper.a11y.disableEl($nextEl); + } else { + swiper.a11y.enableEl($nextEl); + } + } + }, + updatePagination() { + const swiper = this; + const params = swiper.params.a11y; + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.bullets.each((bulletIndex, bulletEl) => { + const $bulletEl = $(bulletEl); + swiper.a11y.makeElFocusable($bulletEl); + swiper.a11y.addElRole($bulletEl, 'button'); + swiper.a11y.addElLabel($bulletEl, params.paginationBulletMessage.replace(/{{index}}/, $bulletEl.index() + 1)); + }); + } + }, + init() { + const swiper = this; + + swiper.$el.append(swiper.a11y.liveRegion); + + // Navigation + const params = swiper.params.a11y; + let $nextEl; + let $prevEl; + if (swiper.navigation && swiper.navigation.$nextEl) { + $nextEl = swiper.navigation.$nextEl; + } + if (swiper.navigation && swiper.navigation.$prevEl) { + $prevEl = swiper.navigation.$prevEl; + } + if ($nextEl) { + swiper.a11y.makeElFocusable($nextEl); + swiper.a11y.addElRole($nextEl, 'button'); + swiper.a11y.addElLabel($nextEl, params.nextSlideMessage); + $nextEl.on('keydown', swiper.a11y.onEnterKey); + } + if ($prevEl) { + swiper.a11y.makeElFocusable($prevEl); + swiper.a11y.addElRole($prevEl, 'button'); + swiper.a11y.addElLabel($prevEl, params.prevSlideMessage); + $prevEl.on('keydown', swiper.a11y.onEnterKey); + } + + // Pagination + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.$el.on('keydown', `.${swiper.params.pagination.bulletClass}`, swiper.a11y.onEnterKey); + } + }, + destroy() { + const swiper = this; + if (swiper.a11y.liveRegion && swiper.a11y.liveRegion.length > 0) swiper.a11y.liveRegion.remove(); + + let $nextEl; + let $prevEl; + if (swiper.navigation && swiper.navigation.$nextEl) { + $nextEl = swiper.navigation.$nextEl; + } + if (swiper.navigation && swiper.navigation.$prevEl) { + $prevEl = swiper.navigation.$prevEl; + } + if ($nextEl) { + $nextEl.off('keydown', swiper.a11y.onEnterKey); + } + if ($prevEl) { + $prevEl.off('keydown', swiper.a11y.onEnterKey); + } + + // Pagination + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.$el.off('keydown', `.${swiper.params.pagination.bulletClass}`, swiper.a11y.onEnterKey); + } + }, +}; +var a11y$1 = { + name: 'a11y', + params: { + a11y: { + enabled: true, + notificationClass: 'swiper-notification', + prevSlideMessage: 'Previous slide', + nextSlideMessage: 'Next slide', + firstSlideMessage: 'This is the first slide', + lastSlideMessage: 'This is the last slide', + paginationBulletMessage: 'Go to slide {{index}}', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + a11y: { + liveRegion: $(``), + }, + }); + Object.keys(a11y).forEach((methodName) => { + swiper.a11y[methodName] = a11y[methodName].bind(swiper); + }); + }, + on: { + init() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.init(); + swiper.a11y.updateNavigation(); + }, + toEdge() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.updateNavigation(); + }, + fromEdge() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.updateNavigation(); + }, + paginationUpdate() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.updatePagination(); + }, + destroy() { + const swiper = this; + if (!swiper.params.a11y.enabled) return; + swiper.a11y.destroy(); + }, + }, +}; + +const History = { + init() { + const swiper = this; + if (!swiper.params.history) return; + if (!window.history || !window.history.pushState) { + swiper.params.history.enabled = false; + swiper.params.hashNavigation.enabled = true; + return; + } + const history = swiper.history; + history.initialized = true; + history.paths = History.getPathValues(); + if (!history.paths.key && !history.paths.value) return; + history.scrollToSlide(0, history.paths.value, swiper.params.runCallbacksOnInit); + if (!swiper.params.history.replaceState) { + window.addEventListener('popstate', swiper.history.setHistoryPopState); + } + }, + destroy() { + const swiper = this; + if (!swiper.params.history.replaceState) { + window.removeEventListener('popstate', swiper.history.setHistoryPopState); + } + }, + setHistoryPopState() { + const swiper = this; + swiper.history.paths = History.getPathValues(); + swiper.history.scrollToSlide(swiper.params.speed, swiper.history.paths.value, false); + }, + getPathValues() { + const pathArray = window.location.pathname.slice(1).split('/').filter(part => part !== ''); + const total = pathArray.length; + const key = pathArray[total - 2]; + const value = pathArray[total - 1]; + return { key, value }; + }, + setHistory(key, index$$1) { + const swiper = this; + if (!swiper.history.initialized || !swiper.params.history.enabled) return; + const slide = swiper.slides.eq(index$$1); + let value = History.slugify(slide.attr('data-history')); + if (!window.location.pathname.includes(key)) { + value = `${key}/${value}`; + } + const currentState = window.history.state; + if (currentState && currentState.value === value) { + return; + } + if (swiper.params.history.replaceState) { + window.history.replaceState({ value }, null, value); + } else { + window.history.pushState({ value }, null, value); + } + }, + slugify(text$$1) { + return text$$1.toString().toLowerCase() + .replace(/\s+/g, '-') + .replace(/[^\w-]+/g, '') + .replace(/--+/g, '-') + .replace(/^-+/, '') + .replace(/-+$/, ''); + }, + scrollToSlide(speed, value, runCallbacks) { + const swiper = this; + if (value) { + for (let i = 0, length = swiper.slides.length; i < length; i += 1) { + const slide = swiper.slides.eq(i); + const slideHistory = History.slugify(slide.attr('data-history')); + if (slideHistory === value && !slide.hasClass(swiper.params.slideDuplicateClass)) { + const index$$1 = slide.index(); + swiper.slideTo(index$$1, speed, runCallbacks); + } + } + } else { + swiper.slideTo(0, speed, runCallbacks); + } + }, +}; + +var history = { + name: 'history', + params: { + history: { + enabled: false, + replaceState: false, + key: 'slides', + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + history: { + init: History.init.bind(swiper), + setHistory: History.setHistory.bind(swiper), + setHistoryPopState: History.setHistoryPopState.bind(swiper), + scrollToSlide: History.scrollToSlide.bind(swiper), + destroy: History.destroy.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.history.enabled) { + swiper.history.init(); + } + }, + destroy() { + const swiper = this; + if (swiper.params.history.enabled) { + swiper.history.destroy(); + } + }, + transitionEnd() { + const swiper = this; + if (swiper.history.initialized) { + swiper.history.setHistory(swiper.params.history.key, swiper.activeIndex); + } + }, + }, +}; + +const HashNavigation = { + onHashCange() { + const swiper = this; + const newHash = document.location.hash.replace('#', ''); + const activeSlideHash = swiper.slides.eq(swiper.activeIndex).attr('data-hash'); + if (newHash !== activeSlideHash) { + swiper.slideTo(swiper.$wrapperEl.children(`.${swiper.params.slideClass}[data-hash="${newHash}"]`).index()); + } + }, + setHash() { + const swiper = this; + if (!swiper.hashNavigation.initialized || !swiper.params.hashNavigation.enabled) return; + if (swiper.params.hashNavigation.replaceState && window.history && window.history.replaceState) { + window.history.replaceState(null, null, (`#${swiper.slides.eq(swiper.activeIndex).attr('data-hash')}` || '')); + } else { + const slide = swiper.slides.eq(swiper.activeIndex); + const hash = slide.attr('data-hash') || slide.attr('data-history'); + document.location.hash = hash || ''; + } + }, + init() { + const swiper = this; + if (!swiper.params.hashNavigation.enabled || (swiper.params.history && swiper.params.history.enabled)) return; + swiper.hashNavigation.initialized = true; + const hash = document.location.hash.replace('#', ''); + if (hash) { + const speed = 0; + for (let i = 0, length = swiper.slides.length; i < length; i += 1) { + const slide = swiper.slides.eq(i); + const slideHash = slide.attr('data-hash') || slide.attr('data-history'); + if (slideHash === hash && !slide.hasClass(swiper.params.slideDuplicateClass)) { + const index$$1 = slide.index(); + swiper.slideTo(index$$1, speed, swiper.params.runCallbacksOnInit, true); + } + } + } + if (swiper.params.hashNavigation.watchState) { + $(window).on('hashchange', swiper.hashNavigation.onHashCange); + } + }, + destroy() { + const swiper = this; + if (swiper.params.hashNavigation.watchState) { + $(window).off('hashchange', swiper.hashNavigation.onHashCange); + } + }, +}; +var hashNavigation = { + name: 'hash-navigation', + params: { + hashNavigation: { + enabled: false, + replaceState: false, + watchState: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + hashNavigation: { + initialized: false, + init: HashNavigation.init.bind(swiper), + destroy: HashNavigation.destroy.bind(swiper), + setHash: HashNavigation.setHash.bind(swiper), + onHashCange: HashNavigation.onHashCange.bind(swiper), + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.hashNavigation.enabled) { + swiper.hashNavigation.init(); + } + }, + destroy() { + const swiper = this; + if (swiper.params.hashNavigation.enabled) { + swiper.hashNavigation.destroy(); + } + }, + transitionEnd() { + const swiper = this; + if (swiper.hashNavigation.initialized) { + swiper.hashNavigation.setHash(); + } + }, + }, +}; + +/* eslint no-underscore-dangle: "off" */ + +const Autoplay = { + run() { + const swiper = this; + const $activeSlideEl = swiper.slides.eq(swiper.activeIndex); + let delay = swiper.params.autoplay.delay; + if ($activeSlideEl.attr('data-swiper-autoplay')) { + delay = $activeSlideEl.attr('data-swiper-autoplay') || swiper.params.autoplay.delay; + } + swiper.autoplay.timeout = Utils.nextTick(() => { + if (swiper.params.autoplay.reverseDirection) { + if (swiper.params.loop) { + swiper.loopFix(); + swiper.slidePrev(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.isBeginning) { + swiper.slidePrev(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.params.autoplay.stopOnLastSlide) { + swiper.slideTo(swiper.slides.length - 1, swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else { + swiper.autoplay.stop(); + } + } else if (swiper.params.loop) { + swiper.loopFix(); + swiper.slideNext(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.isEnd) { + swiper.slideNext(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.params.autoplay.stopOnLastSlide) { + swiper.slideTo(0, swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else { + swiper.autoplay.stop(); + } + }, delay); + }, + start() { + const swiper = this; + if (typeof swiper.autoplay.timeout !== 'undefined') return false; + if (swiper.autoplay.running) return false; + swiper.autoplay.running = true; + swiper.emit('autoplayStart'); + swiper.autoplay.run(); + return true; + }, + stop() { + const swiper = this; + if (!swiper.autoplay.running) return false; + if (typeof swiper.autoplay.timeout === 'undefined') return false; + + if (swiper.autoplay.timeout) { + clearTimeout(swiper.autoplay.timeout); + swiper.autoplay.timeout = undefined; + } + swiper.autoplay.running = false; + swiper.emit('autoplayStop'); + return true; + }, + pause(speed) { + const swiper = this; + if (!swiper.autoplay.running) return; + if (swiper.autoplay.paused) return; + if (swiper.autoplay.timeout) clearTimeout(swiper.autoplay.timeout); + swiper.autoplay.paused = true; + if (speed === 0 || !swiper.params.autoplay.waitForTransition) { + swiper.autoplay.paused = false; + swiper.autoplay.run(); + } else { + swiper.$wrapperEl[0].addEventListener('transitionend', swiper.autoplay.onTransitionEnd); + swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd); + } + }, +}; + +var autoplay = { + name: 'autoplay', + params: { + autoplay: { + enabled: false, + delay: 3000, + waitForTransition: true, + disableOnInteraction: true, + stopOnLastSlide: false, + reverseDirection: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + autoplay: { + running: false, + paused: false, + run: Autoplay.run.bind(swiper), + start: Autoplay.start.bind(swiper), + stop: Autoplay.stop.bind(swiper), + pause: Autoplay.pause.bind(swiper), + onTransitionEnd(e) { + if (!swiper || swiper.destroyed || !swiper.$wrapperEl) return; + if (e.target !== this) return; + swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.autoplay.onTransitionEnd); + swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd); + swiper.autoplay.paused = false; + if (!swiper.autoplay.running) { + swiper.autoplay.stop(); + } else { + swiper.autoplay.run(); + } + }, + }, + }); + }, + on: { + init() { + const swiper = this; + if (swiper.params.autoplay.enabled) { + swiper.autoplay.start(); + } + }, + beforeTransitionStart(speed, internal) { + const swiper = this; + if (swiper.autoplay.running) { + if (internal || !swiper.params.autoplay.disableOnInteraction) { + swiper.autoplay.pause(speed); + } else { + swiper.autoplay.stop(); + } + } + }, + sliderFirstMove() { + const swiper = this; + if (swiper.autoplay.running) { + if (swiper.params.autoplay.disableOnInteraction) { + swiper.autoplay.stop(); + } else { + swiper.autoplay.pause(); + } + } + }, + destroy() { + const swiper = this; + if (swiper.autoplay.running) { + swiper.autoplay.stop(); + } + }, + }, +}; + +const Fade = { + setTranslate() { + const swiper = this; + const { slides } = swiper; + for (let i = 0; i < slides.length; i += 1) { + const $slideEl = swiper.slides.eq(i); + const offset$$1 = $slideEl[0].swiperSlideOffset; + let tx = -offset$$1; + if (!swiper.params.virtualTranslate) tx -= swiper.translate; + let ty = 0; + if (!swiper.isHorizontal()) { + ty = tx; + tx = 0; + } + const slideOpacity = swiper.params.fadeEffect.crossFade ? + Math.max(1 - Math.abs($slideEl[0].progress), 0) : + 1 + Math.min(Math.max($slideEl[0].progress, -1), 0); + $slideEl + .css({ + opacity: slideOpacity, + }) + .transform(`translate3d(${tx}px, ${ty}px, 0px)`); + } + }, + setTransition(duration) { + const swiper = this; + const { slides, $wrapperEl } = swiper; + slides.transition(duration); + if (swiper.params.virtualTranslate && duration !== 0) { + let eventTriggered = false; + slides.transitionEnd(() => { + if (eventTriggered) return; + if (!swiper || swiper.destroyed) return; + eventTriggered = true; + swiper.animating = false; + const triggerEvents = ['webkitTransitionEnd', 'transitionend']; + for (let i = 0; i < triggerEvents.length; i += 1) { + $wrapperEl.trigger(triggerEvents[i]); + } + }); + } + }, +}; + +var effectFade = { + name: 'effect-fade', + params: { + fadeEffect: { + crossFade: false, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + fadeEffect: { + setTranslate: Fade.setTranslate.bind(swiper), + setTransition: Fade.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'fade') return; + swiper.classNames.push(`${swiper.params.containerModifierClass}fade`); + const overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + spaceBetween: 0, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'fade') return; + swiper.fadeEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'fade') return; + swiper.fadeEffect.setTransition(duration); + }, + }, +}; + +const Cube = { + setTranslate() { + const swiper = this; + const { + $el, $wrapperEl, slides, width: swiperWidth, height: swiperHeight, rtlTranslate: rtl, size: swiperSize, + } = swiper; + const params = swiper.params.cubeEffect; + const isHorizontal = swiper.isHorizontal(); + const isVirtual = swiper.virtual && swiper.params.virtual.enabled; + let wrapperRotate = 0; + let $cubeShadowEl; + if (params.shadow) { + if (isHorizontal) { + $cubeShadowEl = $wrapperEl.find('.swiper-cube-shadow'); + if ($cubeShadowEl.length === 0) { + $cubeShadowEl = $('
    '); + $wrapperEl.append($cubeShadowEl); + } + $cubeShadowEl.css({ height: `${swiperWidth}px` }); + } else { + $cubeShadowEl = $el.find('.swiper-cube-shadow'); + if ($cubeShadowEl.length === 0) { + $cubeShadowEl = $('
    '); + $el.append($cubeShadowEl); + } + } + } + for (let i = 0; i < slides.length; i += 1) { + const $slideEl = slides.eq(i); + let slideIndex = i; + if (isVirtual) { + slideIndex = parseInt($slideEl.attr('data-swiper-slide-index'), 10); + } + let slideAngle = slideIndex * 90; + let round = Math.floor(slideAngle / 360); + if (rtl) { + slideAngle = -slideAngle; + round = Math.floor(-slideAngle / 360); + } + const progress = Math.max(Math.min($slideEl[0].progress, 1), -1); + let tx = 0; + let ty = 0; + let tz = 0; + if (slideIndex % 4 === 0) { + tx = -round * 4 * swiperSize; + tz = 0; + } else if ((slideIndex - 1) % 4 === 0) { + tx = 0; + tz = -round * 4 * swiperSize; + } else if ((slideIndex - 2) % 4 === 0) { + tx = swiperSize + (round * 4 * swiperSize); + tz = swiperSize; + } else if ((slideIndex - 3) % 4 === 0) { + tx = -swiperSize; + tz = (3 * swiperSize) + (swiperSize * 4 * round); + } + if (rtl) { + tx = -tx; + } + + if (!isHorizontal) { + ty = tx; + tx = 0; + } + + const transform$$1 = `rotateX(${isHorizontal ? 0 : -slideAngle}deg) rotateY(${isHorizontal ? slideAngle : 0}deg) translate3d(${tx}px, ${ty}px, ${tz}px)`; + if (progress <= 1 && progress > -1) { + wrapperRotate = (slideIndex * 90) + (progress * 90); + if (rtl) wrapperRotate = (-slideIndex * 90) - (progress * 90); + } + $slideEl.transform(transform$$1); + if (params.slideShadows) { + // Set shadows + let shadowBefore = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + let shadowAfter = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if (shadowBefore.length === 0) { + shadowBefore = $(`
    `); + $slideEl.append(shadowBefore); + } + if (shadowAfter.length === 0) { + shadowAfter = $(`
    `); + $slideEl.append(shadowAfter); + } + if (shadowBefore.length) shadowBefore[0].style.opacity = Math.max(-progress, 0); + if (shadowAfter.length) shadowAfter[0].style.opacity = Math.max(progress, 0); + } + } + $wrapperEl.css({ + '-webkit-transform-origin': `50% 50% -${swiperSize / 2}px`, + '-moz-transform-origin': `50% 50% -${swiperSize / 2}px`, + '-ms-transform-origin': `50% 50% -${swiperSize / 2}px`, + 'transform-origin': `50% 50% -${swiperSize / 2}px`, + }); + + if (params.shadow) { + if (isHorizontal) { + $cubeShadowEl.transform(`translate3d(0px, ${(swiperWidth / 2) + params.shadowOffset}px, ${-swiperWidth / 2}px) rotateX(90deg) rotateZ(0deg) scale(${params.shadowScale})`); + } else { + const shadowAngle = Math.abs(wrapperRotate) - (Math.floor(Math.abs(wrapperRotate) / 90) * 90); + const multiplier = 1.5 - ( + (Math.sin((shadowAngle * 2 * Math.PI) / 360) / 2) + + (Math.cos((shadowAngle * 2 * Math.PI) / 360) / 2) + ); + const scale1 = params.shadowScale; + const scale2 = params.shadowScale / multiplier; + const offset$$1 = params.shadowOffset; + $cubeShadowEl.transform(`scale3d(${scale1}, 1, ${scale2}) translate3d(0px, ${(swiperHeight / 2) + offset$$1}px, ${-swiperHeight / 2 / scale2}px) rotateX(-90deg)`); + } + } + const zFactor = (Browser.isSafari || Browser.isUiWebView) ? (-swiperSize / 2) : 0; + $wrapperEl + .transform(`translate3d(0px,0,${zFactor}px) rotateX(${swiper.isHorizontal() ? 0 : wrapperRotate}deg) rotateY(${swiper.isHorizontal() ? -wrapperRotate : 0}deg)`); + }, + setTransition(duration) { + const swiper = this; + const { $el, slides } = swiper; + slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + if (swiper.params.cubeEffect.shadow && !swiper.isHorizontal()) { + $el.find('.swiper-cube-shadow').transition(duration); + } + }, +}; + +var effectCube = { + name: 'effect-cube', + params: { + cubeEffect: { + slideShadows: true, + shadow: true, + shadowOffset: 20, + shadowScale: 0.94, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + cubeEffect: { + setTranslate: Cube.setTranslate.bind(swiper), + setTransition: Cube.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'cube') return; + swiper.classNames.push(`${swiper.params.containerModifierClass}cube`); + swiper.classNames.push(`${swiper.params.containerModifierClass}3d`); + const overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + resistanceRatio: 0, + spaceBetween: 0, + centeredSlides: false, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'cube') return; + swiper.cubeEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'cube') return; + swiper.cubeEffect.setTransition(duration); + }, + }, +}; + +const Flip = { + setTranslate() { + const swiper = this; + const { slides, rtlTranslate: rtl } = swiper; + for (let i = 0; i < slides.length; i += 1) { + const $slideEl = slides.eq(i); + let progress = $slideEl[0].progress; + if (swiper.params.flipEffect.limitRotation) { + progress = Math.max(Math.min($slideEl[0].progress, 1), -1); + } + const offset$$1 = $slideEl[0].swiperSlideOffset; + const rotate = -180 * progress; + let rotateY = rotate; + let rotateX = 0; + let tx = -offset$$1; + let ty = 0; + if (!swiper.isHorizontal()) { + ty = tx; + tx = 0; + rotateX = -rotateY; + rotateY = 0; + } else if (rtl) { + rotateY = -rotateY; + } + + $slideEl[0].style.zIndex = -Math.abs(Math.round(progress)) + slides.length; + + if (swiper.params.flipEffect.slideShadows) { + // Set shadows + let shadowBefore = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + let shadowAfter = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if (shadowBefore.length === 0) { + shadowBefore = $(`
    `); + $slideEl.append(shadowBefore); + } + if (shadowAfter.length === 0) { + shadowAfter = $(`
    `); + $slideEl.append(shadowAfter); + } + if (shadowBefore.length) shadowBefore[0].style.opacity = Math.max(-progress, 0); + if (shadowAfter.length) shadowAfter[0].style.opacity = Math.max(progress, 0); + } + $slideEl + .transform(`translate3d(${tx}px, ${ty}px, 0px) rotateX(${rotateX}deg) rotateY(${rotateY}deg)`); + } + }, + setTransition(duration) { + const swiper = this; + const { slides, activeIndex, $wrapperEl } = swiper; + slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + if (swiper.params.virtualTranslate && duration !== 0) { + let eventTriggered = false; + // eslint-disable-next-line + slides.eq(activeIndex).transitionEnd(function onTransitionEnd() { + if (eventTriggered) return; + if (!swiper || swiper.destroyed) return; + // if (!$(this).hasClass(swiper.params.slideActiveClass)) return; + eventTriggered = true; + swiper.animating = false; + const triggerEvents = ['webkitTransitionEnd', 'transitionend']; + for (let i = 0; i < triggerEvents.length; i += 1) { + $wrapperEl.trigger(triggerEvents[i]); + } + }); + } + }, +}; + +var effectFlip = { + name: 'effect-flip', + params: { + flipEffect: { + slideShadows: true, + limitRotation: true, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + flipEffect: { + setTranslate: Flip.setTranslate.bind(swiper), + setTransition: Flip.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'flip') return; + swiper.classNames.push(`${swiper.params.containerModifierClass}flip`); + swiper.classNames.push(`${swiper.params.containerModifierClass}3d`); + const overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + spaceBetween: 0, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'flip') return; + swiper.flipEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'flip') return; + swiper.flipEffect.setTransition(duration); + }, + }, +}; + +const Coverflow = { + setTranslate() { + const swiper = this; + const { + width: swiperWidth, height: swiperHeight, slides, $wrapperEl, slidesSizesGrid, + } = swiper; + const params = swiper.params.coverflowEffect; + const isHorizontal = swiper.isHorizontal(); + const transform$$1 = swiper.translate; + const center = isHorizontal ? -transform$$1 + (swiperWidth / 2) : -transform$$1 + (swiperHeight / 2); + const rotate = isHorizontal ? params.rotate : -params.rotate; + const translate = params.depth; + // Each slide offset from center + for (let i = 0, length = slides.length; i < length; i += 1) { + const $slideEl = slides.eq(i); + const slideSize = slidesSizesGrid[i]; + const slideOffset = $slideEl[0].swiperSlideOffset; + const offsetMultiplier = ((center - slideOffset - (slideSize / 2)) / slideSize) * params.modifier; + + let rotateY = isHorizontal ? rotate * offsetMultiplier : 0; + let rotateX = isHorizontal ? 0 : rotate * offsetMultiplier; + // var rotateZ = 0 + let translateZ = -translate * Math.abs(offsetMultiplier); + + let translateY = isHorizontal ? 0 : params.stretch * (offsetMultiplier); + let translateX = isHorizontal ? params.stretch * (offsetMultiplier) : 0; + + // Fix for ultra small values + if (Math.abs(translateX) < 0.001) translateX = 0; + if (Math.abs(translateY) < 0.001) translateY = 0; + if (Math.abs(translateZ) < 0.001) translateZ = 0; + if (Math.abs(rotateY) < 0.001) rotateY = 0; + if (Math.abs(rotateX) < 0.001) rotateX = 0; + + const slideTransform = `translate3d(${translateX}px,${translateY}px,${translateZ}px) rotateX(${rotateX}deg) rotateY(${rotateY}deg)`; + + $slideEl.transform(slideTransform); + $slideEl[0].style.zIndex = -Math.abs(Math.round(offsetMultiplier)) + 1; + if (params.slideShadows) { + // Set shadows + let $shadowBeforeEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + let $shadowAfterEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if ($shadowBeforeEl.length === 0) { + $shadowBeforeEl = $(`
    `); + $slideEl.append($shadowBeforeEl); + } + if ($shadowAfterEl.length === 0) { + $shadowAfterEl = $(`
    `); + $slideEl.append($shadowAfterEl); + } + if ($shadowBeforeEl.length) $shadowBeforeEl[0].style.opacity = offsetMultiplier > 0 ? offsetMultiplier : 0; + if ($shadowAfterEl.length) $shadowAfterEl[0].style.opacity = (-offsetMultiplier) > 0 ? -offsetMultiplier : 0; + } + } + + // Set correct perspective for IE10 + if (Support.pointerEvents || Support.prefixedPointerEvents) { + const ws = $wrapperEl[0].style; + ws.perspectiveOrigin = `${center}px 50%`; + } + }, + setTransition(duration) { + const swiper = this; + swiper.slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + }, +}; + +var effectCoverflow = { + name: 'effect-coverflow', + params: { + coverflowEffect: { + rotate: 50, + stretch: 0, + depth: 100, + modifier: 1, + slideShadows: true, + }, + }, + create() { + const swiper = this; + Utils.extend(swiper, { + coverflowEffect: { + setTranslate: Coverflow.setTranslate.bind(swiper), + setTransition: Coverflow.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit() { + const swiper = this; + if (swiper.params.effect !== 'coverflow') return; + + swiper.classNames.push(`${swiper.params.containerModifierClass}coverflow`); + swiper.classNames.push(`${swiper.params.containerModifierClass}3d`); + + swiper.params.watchSlidesProgress = true; + swiper.originalParams.watchSlidesProgress = true; + }, + setTranslate() { + const swiper = this; + if (swiper.params.effect !== 'coverflow') return; + swiper.coverflowEffect.setTranslate(); + }, + setTransition(duration) { + const swiper = this; + if (swiper.params.effect !== 'coverflow') return; + swiper.coverflowEffect.setTransition(duration); + }, + }, +}; + +// Swiper Class + +const components = [ + Device$1, + Support$1, + Browser$1, + Resize, + Observer$1, + +]; + +if (typeof Swiper.use === 'undefined') { + Swiper.use = Swiper.Class.use; + Swiper.installModule = Swiper.Class.installModule; +} + +Swiper.use(components); + +export { Swiper, virtual as Virtual, keyboard as Keyboard, mousewheel as Mousewheel, navigation as Navigation, pagination as Pagination, scrollbar as Scrollbar, parallax as Parallax, zoom as Zoom, lazy as Lazy, controller as Controller, a11y$1 as A11y, history as History, hashNavigation as HashNavigation, autoplay as Autoplay, effectFade as EffectFade, effectCube as EffectCube, effectFlip as EffectFlip, effectCoverflow as EffectCoverflow }; diff --git a/static/swiper/js/swiper.js b/static/swiper/js/swiper.js new file mode 100644 index 0000000..ec4ff20 --- /dev/null +++ b/static/swiper/js/swiper.js @@ -0,0 +1,7637 @@ +/** + * Swiper 4.2.6 + * Most modern mobile touch slider and framework with hardware accelerated transitions + * http://www.idangero.us/swiper/ + * + * Copyright 2014-2018 Vladimir Kharlampidi + * + * Released under the MIT License + * + * Released on: May 1, 2018 + */ + +(function (global, factory) { + typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : + typeof define === 'function' && define.amd ? define(factory) : + (global.Swiper = factory()); +}(this, (function () { 'use strict'; + + /** + * SSR Window 1.0.0 + * Better handling for window object in SSR environment + * https://github.com/nolimits4web/ssr-window + * + * Copyright 2018, Vladimir Kharlampidi + * + * Licensed under MIT + * + * Released on: February 10, 2018 + */ + var d; + if (typeof document === 'undefined') { + d = { + body: {}, + addEventListener: function addEventListener() {}, + removeEventListener: function removeEventListener() {}, + activeElement: { + blur: function blur() {}, + nodeName: '', + }, + querySelector: function querySelector() { + return null; + }, + querySelectorAll: function querySelectorAll() { + return []; + }, + getElementById: function getElementById() { + return null; + }, + createEvent: function createEvent() { + return { + initEvent: function initEvent() {}, + }; + }, + createElement: function createElement() { + return { + children: [], + childNodes: [], + style: {}, + setAttribute: function setAttribute() {}, + getElementsByTagName: function getElementsByTagName() { + return []; + }, + }; + }, + location: { hash: '' }, + }; + } else { + // eslint-disable-next-line + d = document; + } + + var doc = d; + + var w; + if (typeof window === 'undefined') { + w = { + document: doc, + navigator: { + userAgent: '', + }, + location: {}, + history: {}, + CustomEvent: function CustomEvent() { + return this; + }, + addEventListener: function addEventListener() {}, + removeEventListener: function removeEventListener() {}, + getComputedStyle: function getComputedStyle() { + return { + getPropertyValue: function getPropertyValue() { + return ''; + }, + }; + }, + Image: function Image() {}, + Date: function Date() {}, + screen: {}, + setTimeout: function setTimeout() {}, + clearTimeout: function clearTimeout() {}, + }; + } else { + // eslint-disable-next-line + w = window; + } + + var win = w; + + /** + * Dom7 2.0.5 + * Minimalistic JavaScript library for DOM manipulation, with a jQuery-compatible API + * http://framework7.io/docs/dom.html + * + * Copyright 2018, Vladimir Kharlampidi + * The iDangero.us + * http://www.idangero.us/ + * + * Licensed under MIT + * + * Released on: April 20, 2018 + */ + + var Dom7 = function Dom7(arr) { + var self = this; + // Create array-like object + for (var i = 0; i < arr.length; i += 1) { + self[i] = arr[i]; + } + self.length = arr.length; + // Return collection with methods + return this; + }; + + function $(selector, context) { + var arr = []; + var i = 0; + if (selector && !context) { + if (selector instanceof Dom7) { + return selector; + } + } + if (selector) { + // String + if (typeof selector === 'string') { + var els; + var tempParent; + var html = selector.trim(); + if (html.indexOf('<') >= 0 && html.indexOf('>') >= 0) { + var toCreate = 'div'; + if (html.indexOf(':~]/)) { + // Pure ID selector + els = [doc.getElementById(selector.trim().split('#')[1])]; + } else { + // Other selectors + els = (context || doc).querySelectorAll(selector.trim()); + } + for (i = 0; i < els.length; i += 1) { + if (els[i]) { arr.push(els[i]); } + } + } + } else if (selector.nodeType || selector === win || selector === doc) { + // Node/element + arr.push(selector); + } else if (selector.length > 0 && selector[0].nodeType) { + // Array of elements or instance of Dom + for (i = 0; i < selector.length; i += 1) { + arr.push(selector[i]); + } + } + } + return new Dom7(arr); + } + + $.fn = Dom7.prototype; + $.Class = Dom7; + $.Dom7 = Dom7; + + function unique(arr) { + var uniqueArray = []; + for (var i = 0; i < arr.length; i += 1) { + if (uniqueArray.indexOf(arr[i]) === -1) { uniqueArray.push(arr[i]); } + } + return uniqueArray; + } + + // Classes and attributes + function addClass(className) { + var this$1 = this; + + if (typeof className === 'undefined') { + return this; + } + var classes = className.split(' '); + for (var i = 0; i < classes.length; i += 1) { + for (var j = 0; j < this.length; j += 1) { + if (typeof this$1[j].classList !== 'undefined') { this$1[j].classList.add(classes[i]); } + } + } + return this; + } + function removeClass(className) { + var this$1 = this; + + var classes = className.split(' '); + for (var i = 0; i < classes.length; i += 1) { + for (var j = 0; j < this.length; j += 1) { + if (typeof this$1[j].classList !== 'undefined') { this$1[j].classList.remove(classes[i]); } + } + } + return this; + } + function hasClass(className) { + if (!this[0]) { return false; } + return this[0].classList.contains(className); + } + function toggleClass(className) { + var this$1 = this; + + var classes = className.split(' '); + for (var i = 0; i < classes.length; i += 1) { + for (var j = 0; j < this.length; j += 1) { + if (typeof this$1[j].classList !== 'undefined') { this$1[j].classList.toggle(classes[i]); } + } + } + return this; + } + function attr(attrs, value) { + var arguments$1 = arguments; + var this$1 = this; + + if (arguments.length === 1 && typeof attrs === 'string') { + // Get attr + if (this[0]) { return this[0].getAttribute(attrs); } + return undefined; + } + + // Set attrs + for (var i = 0; i < this.length; i += 1) { + if (arguments$1.length === 2) { + // String + this$1[i].setAttribute(attrs, value); + } else { + // Object + // eslint-disable-next-line + for (var attrName in attrs) { + this$1[i][attrName] = attrs[attrName]; + this$1[i].setAttribute(attrName, attrs[attrName]); + } + } + } + return this; + } + // eslint-disable-next-line + function removeAttr(attr) { + var this$1 = this; + + for (var i = 0; i < this.length; i += 1) { + this$1[i].removeAttribute(attr); + } + return this; + } + function data(key, value) { + var this$1 = this; + + var el; + if (typeof value === 'undefined') { + el = this[0]; + // Get value + if (el) { + if (el.dom7ElementDataStorage && (key in el.dom7ElementDataStorage)) { + return el.dom7ElementDataStorage[key]; + } + + var dataKey = el.getAttribute(("data-" + key)); + if (dataKey) { + return dataKey; + } + return undefined; + } + return undefined; + } + + // Set value + for (var i = 0; i < this.length; i += 1) { + el = this$1[i]; + if (!el.dom7ElementDataStorage) { el.dom7ElementDataStorage = {}; } + el.dom7ElementDataStorage[key] = value; + } + return this; + } + // Transforms + // eslint-disable-next-line + function transform(transform) { + var this$1 = this; + + for (var i = 0; i < this.length; i += 1) { + var elStyle = this$1[i].style; + elStyle.webkitTransform = transform; + elStyle.transform = transform; + } + return this; + } + function transition(duration) { + var this$1 = this; + + if (typeof duration !== 'string') { + duration = duration + "ms"; // eslint-disable-line + } + for (var i = 0; i < this.length; i += 1) { + var elStyle = this$1[i].style; + elStyle.webkitTransitionDuration = duration; + elStyle.transitionDuration = duration; + } + return this; + } + // Events + function on() { + var this$1 = this; + var assign; + + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + var eventType = args[0]; + var targetSelector = args[1]; + var listener = args[2]; + var capture = args[3]; + if (typeof args[1] === 'function') { + (assign = args, eventType = assign[0], listener = assign[1], capture = assign[2]); + targetSelector = undefined; + } + if (!capture) { capture = false; } + + function handleLiveEvent(e) { + var target = e.target; + if (!target) { return; } + var eventData = e.target.dom7EventData || []; + if (eventData.indexOf(e) < 0) { + eventData.unshift(e); + } + if ($(target).is(targetSelector)) { listener.apply(target, eventData); } + else { + var parents = $(target).parents(); // eslint-disable-line + for (var k = 0; k < parents.length; k += 1) { + if ($(parents[k]).is(targetSelector)) { listener.apply(parents[k], eventData); } + } + } + } + function handleEvent(e) { + var eventData = e && e.target ? e.target.dom7EventData || [] : []; + if (eventData.indexOf(e) < 0) { + eventData.unshift(e); + } + listener.apply(this, eventData); + } + var events = eventType.split(' '); + var j; + for (var i = 0; i < this.length; i += 1) { + var el = this$1[i]; + if (!targetSelector) { + for (j = 0; j < events.length; j += 1) { + var event = events[j]; + if (!el.dom7Listeners) { el.dom7Listeners = {}; } + if (!el.dom7Listeners[event]) { el.dom7Listeners[event] = []; } + el.dom7Listeners[event].push({ + listener: listener, + proxyListener: handleEvent, + }); + el.addEventListener(event, handleEvent, capture); + } + } else { + // Live events + for (j = 0; j < events.length; j += 1) { + var event$1 = events[j]; + if (!el.dom7LiveListeners) { el.dom7LiveListeners = {}; } + if (!el.dom7LiveListeners[event$1]) { el.dom7LiveListeners[event$1] = []; } + el.dom7LiveListeners[event$1].push({ + listener: listener, + proxyListener: handleLiveEvent, + }); + el.addEventListener(event$1, handleLiveEvent, capture); + } + } + } + return this; + } + function off() { + var this$1 = this; + var assign; + + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + var eventType = args[0]; + var targetSelector = args[1]; + var listener = args[2]; + var capture = args[3]; + if (typeof args[1] === 'function') { + (assign = args, eventType = assign[0], listener = assign[1], capture = assign[2]); + targetSelector = undefined; + } + if (!capture) { capture = false; } + + var events = eventType.split(' '); + for (var i = 0; i < events.length; i += 1) { + var event = events[i]; + for (var j = 0; j < this.length; j += 1) { + var el = this$1[j]; + var handlers = (void 0); + if (!targetSelector && el.dom7Listeners) { + handlers = el.dom7Listeners[event]; + } else if (targetSelector && el.dom7LiveListeners) { + handlers = el.dom7LiveListeners[event]; + } + for (var k = handlers.length - 1; k >= 0; k -= 1) { + var handler = handlers[k]; + if (listener && handler.listener === listener) { + el.removeEventListener(event, handler.proxyListener, capture); + handlers.splice(k, 1); + } else if (!listener) { + el.removeEventListener(event, handler.proxyListener, capture); + handlers.splice(k, 1); + } + } + } + } + return this; + } + function trigger() { + var this$1 = this; + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + + var events = args[0].split(' '); + var eventData = args[1]; + for (var i = 0; i < events.length; i += 1) { + var event = events[i]; + for (var j = 0; j < this.length; j += 1) { + var el = this$1[j]; + var evt = (void 0); + try { + evt = new win.CustomEvent(event, { + detail: eventData, + bubbles: true, + cancelable: true, + }); + } catch (e) { + evt = doc.createEvent('Event'); + evt.initEvent(event, true, true); + evt.detail = eventData; + } + // eslint-disable-next-line + el.dom7EventData = args.filter(function (data, dataIndex) { return dataIndex > 0; }); + el.dispatchEvent(evt); + el.dom7EventData = []; + delete el.dom7EventData; + } + } + return this; + } + function transitionEnd(callback) { + var events = ['webkitTransitionEnd', 'transitionend']; + var dom = this; + var i; + function fireCallBack(e) { + /* jshint validthis:true */ + if (e.target !== this) { return; } + callback.call(this, e); + for (i = 0; i < events.length; i += 1) { + dom.off(events[i], fireCallBack); + } + } + if (callback) { + for (i = 0; i < events.length; i += 1) { + dom.on(events[i], fireCallBack); + } + } + return this; + } + function outerWidth(includeMargins) { + if (this.length > 0) { + if (includeMargins) { + // eslint-disable-next-line + var styles = this.styles(); + return this[0].offsetWidth + parseFloat(styles.getPropertyValue('margin-right')) + parseFloat(styles.getPropertyValue('margin-left')); + } + return this[0].offsetWidth; + } + return null; + } + function outerHeight(includeMargins) { + if (this.length > 0) { + if (includeMargins) { + // eslint-disable-next-line + var styles = this.styles(); + return this[0].offsetHeight + parseFloat(styles.getPropertyValue('margin-top')) + parseFloat(styles.getPropertyValue('margin-bottom')); + } + return this[0].offsetHeight; + } + return null; + } + function offset() { + if (this.length > 0) { + var el = this[0]; + var box = el.getBoundingClientRect(); + var body = doc.body; + var clientTop = el.clientTop || body.clientTop || 0; + var clientLeft = el.clientLeft || body.clientLeft || 0; + var scrollTop = el === win ? win.scrollY : el.scrollTop; + var scrollLeft = el === win ? win.scrollX : el.scrollLeft; + return { + top: (box.top + scrollTop) - clientTop, + left: (box.left + scrollLeft) - clientLeft, + }; + } + + return null; + } + function styles() { + if (this[0]) { return win.getComputedStyle(this[0], null); } + return {}; + } + function css(props, value) { + var this$1 = this; + + var i; + if (arguments.length === 1) { + if (typeof props === 'string') { + if (this[0]) { return win.getComputedStyle(this[0], null).getPropertyValue(props); } + } else { + for (i = 0; i < this.length; i += 1) { + // eslint-disable-next-line + for (var prop in props) { + this$1[i].style[prop] = props[prop]; + } + } + return this; + } + } + if (arguments.length === 2 && typeof props === 'string') { + for (i = 0; i < this.length; i += 1) { + this$1[i].style[props] = value; + } + return this; + } + return this; + } + // Iterate over the collection passing elements to `callback` + function each(callback) { + var this$1 = this; + + // Don't bother continuing without a callback + if (!callback) { return this; } + // Iterate over the current collection + for (var i = 0; i < this.length; i += 1) { + // If the callback returns false + if (callback.call(this$1[i], i, this$1[i]) === false) { + // End the loop early + return this$1; + } + } + // Return `this` to allow chained DOM operations + return this; + } + // eslint-disable-next-line + function html(html) { + var this$1 = this; + + if (typeof html === 'undefined') { + return this[0] ? this[0].innerHTML : undefined; + } + + for (var i = 0; i < this.length; i += 1) { + this$1[i].innerHTML = html; + } + return this; + } + // eslint-disable-next-line + function text(text) { + var this$1 = this; + + if (typeof text === 'undefined') { + if (this[0]) { + return this[0].textContent.trim(); + } + return null; + } + + for (var i = 0; i < this.length; i += 1) { + this$1[i].textContent = text; + } + return this; + } + function is(selector) { + var el = this[0]; + var compareWith; + var i; + if (!el || typeof selector === 'undefined') { return false; } + if (typeof selector === 'string') { + if (el.matches) { return el.matches(selector); } + else if (el.webkitMatchesSelector) { return el.webkitMatchesSelector(selector); } + else if (el.msMatchesSelector) { return el.msMatchesSelector(selector); } + + compareWith = $(selector); + for (i = 0; i < compareWith.length; i += 1) { + if (compareWith[i] === el) { return true; } + } + return false; + } else if (selector === doc) { return el === doc; } + else if (selector === win) { return el === win; } + + if (selector.nodeType || selector instanceof Dom7) { + compareWith = selector.nodeType ? [selector] : selector; + for (i = 0; i < compareWith.length; i += 1) { + if (compareWith[i] === el) { return true; } + } + return false; + } + return false; + } + function index() { + var child = this[0]; + var i; + if (child) { + i = 0; + // eslint-disable-next-line + while ((child = child.previousSibling) !== null) { + if (child.nodeType === 1) { i += 1; } + } + return i; + } + return undefined; + } + // eslint-disable-next-line + function eq(index) { + if (typeof index === 'undefined') { return this; } + var length = this.length; + var returnIndex; + if (index > length - 1) { + return new Dom7([]); + } + if (index < 0) { + returnIndex = length + index; + if (returnIndex < 0) { return new Dom7([]); } + return new Dom7([this[returnIndex]]); + } + return new Dom7([this[index]]); + } + function append() { + var this$1 = this; + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + + var newChild; + + for (var k = 0; k < args.length; k += 1) { + newChild = args[k]; + for (var i = 0; i < this.length; i += 1) { + if (typeof newChild === 'string') { + var tempDiv = doc.createElement('div'); + tempDiv.innerHTML = newChild; + while (tempDiv.firstChild) { + this$1[i].appendChild(tempDiv.firstChild); + } + } else if (newChild instanceof Dom7) { + for (var j = 0; j < newChild.length; j += 1) { + this$1[i].appendChild(newChild[j]); + } + } else { + this$1[i].appendChild(newChild); + } + } + } + + return this; + } + function prepend(newChild) { + var this$1 = this; + + var i; + var j; + for (i = 0; i < this.length; i += 1) { + if (typeof newChild === 'string') { + var tempDiv = doc.createElement('div'); + tempDiv.innerHTML = newChild; + for (j = tempDiv.childNodes.length - 1; j >= 0; j -= 1) { + this$1[i].insertBefore(tempDiv.childNodes[j], this$1[i].childNodes[0]); + } + } else if (newChild instanceof Dom7) { + for (j = 0; j < newChild.length; j += 1) { + this$1[i].insertBefore(newChild[j], this$1[i].childNodes[0]); + } + } else { + this$1[i].insertBefore(newChild, this$1[i].childNodes[0]); + } + } + return this; + } + function next(selector) { + if (this.length > 0) { + if (selector) { + if (this[0].nextElementSibling && $(this[0].nextElementSibling).is(selector)) { + return new Dom7([this[0].nextElementSibling]); + } + return new Dom7([]); + } + + if (this[0].nextElementSibling) { return new Dom7([this[0].nextElementSibling]); } + return new Dom7([]); + } + return new Dom7([]); + } + function nextAll(selector) { + var nextEls = []; + var el = this[0]; + if (!el) { return new Dom7([]); } + while (el.nextElementSibling) { + var next = el.nextElementSibling; // eslint-disable-line + if (selector) { + if ($(next).is(selector)) { nextEls.push(next); } + } else { nextEls.push(next); } + el = next; + } + return new Dom7(nextEls); + } + function prev(selector) { + if (this.length > 0) { + var el = this[0]; + if (selector) { + if (el.previousElementSibling && $(el.previousElementSibling).is(selector)) { + return new Dom7([el.previousElementSibling]); + } + return new Dom7([]); + } + + if (el.previousElementSibling) { return new Dom7([el.previousElementSibling]); } + return new Dom7([]); + } + return new Dom7([]); + } + function prevAll(selector) { + var prevEls = []; + var el = this[0]; + if (!el) { return new Dom7([]); } + while (el.previousElementSibling) { + var prev = el.previousElementSibling; // eslint-disable-line + if (selector) { + if ($(prev).is(selector)) { prevEls.push(prev); } + } else { prevEls.push(prev); } + el = prev; + } + return new Dom7(prevEls); + } + function parent(selector) { + var this$1 = this; + + var parents = []; // eslint-disable-line + for (var i = 0; i < this.length; i += 1) { + if (this$1[i].parentNode !== null) { + if (selector) { + if ($(this$1[i].parentNode).is(selector)) { parents.push(this$1[i].parentNode); } + } else { + parents.push(this$1[i].parentNode); + } + } + } + return $(unique(parents)); + } + function parents(selector) { + var this$1 = this; + + var parents = []; // eslint-disable-line + for (var i = 0; i < this.length; i += 1) { + var parent = this$1[i].parentNode; // eslint-disable-line + while (parent) { + if (selector) { + if ($(parent).is(selector)) { parents.push(parent); } + } else { + parents.push(parent); + } + parent = parent.parentNode; + } + } + return $(unique(parents)); + } + function closest(selector) { + var closest = this; // eslint-disable-line + if (typeof selector === 'undefined') { + return new Dom7([]); + } + if (!closest.is(selector)) { + closest = closest.parents(selector).eq(0); + } + return closest; + } + function find(selector) { + var this$1 = this; + + var foundElements = []; + for (var i = 0; i < this.length; i += 1) { + var found = this$1[i].querySelectorAll(selector); + for (var j = 0; j < found.length; j += 1) { + foundElements.push(found[j]); + } + } + return new Dom7(foundElements); + } + function children(selector) { + var this$1 = this; + + var children = []; // eslint-disable-line + for (var i = 0; i < this.length; i += 1) { + var childNodes = this$1[i].childNodes; + + for (var j = 0; j < childNodes.length; j += 1) { + if (!selector) { + if (childNodes[j].nodeType === 1) { children.push(childNodes[j]); } + } else if (childNodes[j].nodeType === 1 && $(childNodes[j]).is(selector)) { + children.push(childNodes[j]); + } + } + } + return new Dom7(unique(children)); + } + function remove() { + var this$1 = this; + + for (var i = 0; i < this.length; i += 1) { + if (this$1[i].parentNode) { this$1[i].parentNode.removeChild(this$1[i]); } + } + return this; + } + function add() { + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + + var dom = this; + var i; + var j; + for (i = 0; i < args.length; i += 1) { + var toAdd = $(args[i]); + for (j = 0; j < toAdd.length; j += 1) { + dom[dom.length] = toAdd[j]; + dom.length += 1; + } + } + return dom; + } + + var Methods = { + addClass: addClass, + removeClass: removeClass, + hasClass: hasClass, + toggleClass: toggleClass, + attr: attr, + removeAttr: removeAttr, + data: data, + transform: transform, + transition: transition, + on: on, + off: off, + trigger: trigger, + transitionEnd: transitionEnd, + outerWidth: outerWidth, + outerHeight: outerHeight, + offset: offset, + css: css, + each: each, + html: html, + text: text, + is: is, + index: index, + eq: eq, + append: append, + prepend: prepend, + next: next, + nextAll: nextAll, + prev: prev, + prevAll: prevAll, + parent: parent, + parents: parents, + closest: closest, + find: find, + children: children, + remove: remove, + add: add, + styles: styles, + }; + + Object.keys(Methods).forEach(function (methodName) { + $.fn[methodName] = Methods[methodName]; + }); + + var Utils = { + deleteProps: function deleteProps(obj) { + var object = obj; + Object.keys(object).forEach(function (key) { + try { + object[key] = null; + } catch (e) { + // no getter for object + } + try { + delete object[key]; + } catch (e) { + // something got wrong + } + }); + }, + nextTick: function nextTick(callback, delay) { + if ( delay === void 0 ) delay = 0; + + return setTimeout(callback, delay); + }, + now: function now() { + return Date.now(); + }, + getTranslate: function getTranslate(el, axis) { + if ( axis === void 0 ) axis = 'x'; + + var matrix; + var curTransform; + var transformMatrix; + + var curStyle = win.getComputedStyle(el, null); + + if (win.WebKitCSSMatrix) { + curTransform = curStyle.transform || curStyle.webkitTransform; + if (curTransform.split(',').length > 6) { + curTransform = curTransform.split(', ').map(function (a) { return a.replace(',', '.'); }).join(', '); + } + // Some old versions of Webkit choke when 'none' is passed; pass + // empty string instead in this case + transformMatrix = new win.WebKitCSSMatrix(curTransform === 'none' ? '' : curTransform); + } else { + transformMatrix = curStyle.MozTransform || curStyle.OTransform || curStyle.MsTransform || curStyle.msTransform || curStyle.transform || curStyle.getPropertyValue('transform').replace('translate(', 'matrix(1, 0, 0, 1,'); + matrix = transformMatrix.toString().split(','); + } + + if (axis === 'x') { + // Latest Chrome and webkits Fix + if (win.WebKitCSSMatrix) { curTransform = transformMatrix.m41; } + // Crazy IE10 Matrix + else if (matrix.length === 16) { curTransform = parseFloat(matrix[12]); } + // Normal Browsers + else { curTransform = parseFloat(matrix[4]); } + } + if (axis === 'y') { + // Latest Chrome and webkits Fix + if (win.WebKitCSSMatrix) { curTransform = transformMatrix.m42; } + // Crazy IE10 Matrix + else if (matrix.length === 16) { curTransform = parseFloat(matrix[13]); } + // Normal Browsers + else { curTransform = parseFloat(matrix[5]); } + } + return curTransform || 0; + }, + parseUrlQuery: function parseUrlQuery(url) { + var query = {}; + var urlToParse = url || win.location.href; + var i; + var params; + var param; + var length; + if (typeof urlToParse === 'string' && urlToParse.length) { + urlToParse = urlToParse.indexOf('?') > -1 ? urlToParse.replace(/\S*\?/, '') : ''; + params = urlToParse.split('&').filter(function (paramsPart) { return paramsPart !== ''; }); + length = params.length; + + for (i = 0; i < length; i += 1) { + param = params[i].replace(/#\S+/g, '').split('='); + query[decodeURIComponent(param[0])] = typeof param[1] === 'undefined' ? undefined : decodeURIComponent(param[1]) || ''; + } + } + return query; + }, + isObject: function isObject(o) { + return typeof o === 'object' && o !== null && o.constructor && o.constructor === Object; + }, + extend: function extend() { + var args = [], len$1 = arguments.length; + while ( len$1-- ) args[ len$1 ] = arguments[ len$1 ]; + + var to = Object(args[0]); + for (var i = 1; i < args.length; i += 1) { + var nextSource = args[i]; + if (nextSource !== undefined && nextSource !== null) { + var keysArray = Object.keys(Object(nextSource)); + for (var nextIndex = 0, len = keysArray.length; nextIndex < len; nextIndex += 1) { + var nextKey = keysArray[nextIndex]; + var desc = Object.getOwnPropertyDescriptor(nextSource, nextKey); + if (desc !== undefined && desc.enumerable) { + if (Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) { + Utils.extend(to[nextKey], nextSource[nextKey]); + } else if (!Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) { + to[nextKey] = {}; + Utils.extend(to[nextKey], nextSource[nextKey]); + } else { + to[nextKey] = nextSource[nextKey]; + } + } + } + } + } + return to; + }, + }; + + var Support = (function Support() { + var testDiv = doc.createElement('div'); + return { + touch: (win.Modernizr && win.Modernizr.touch === true) || (function checkTouch() { + return !!(('ontouchstart' in win) || (win.DocumentTouch && doc instanceof win.DocumentTouch)); + }()), + + pointerEvents: !!(win.navigator.pointerEnabled || win.PointerEvent), + prefixedPointerEvents: !!win.navigator.msPointerEnabled, + + transition: (function checkTransition() { + var style = testDiv.style; + return ('transition' in style || 'webkitTransition' in style || 'MozTransition' in style); + }()), + transforms3d: (win.Modernizr && win.Modernizr.csstransforms3d === true) || (function checkTransforms3d() { + var style = testDiv.style; + return ('webkitPerspective' in style || 'MozPerspective' in style || 'OPerspective' in style || 'MsPerspective' in style || 'perspective' in style); + }()), + + flexbox: (function checkFlexbox() { + var style = testDiv.style; + var styles = ('alignItems webkitAlignItems webkitBoxAlign msFlexAlign mozBoxAlign webkitFlexDirection msFlexDirection mozBoxDirection mozBoxOrient webkitBoxDirection webkitBoxOrient').split(' '); + for (var i = 0; i < styles.length; i += 1) { + if (styles[i] in style) { return true; } + } + return false; + }()), + + observer: (function checkObserver() { + return ('MutationObserver' in win || 'WebkitMutationObserver' in win); + }()), + + passiveListener: (function checkPassiveListener() { + var supportsPassive = false; + try { + var opts = Object.defineProperty({}, 'passive', { + // eslint-disable-next-line + get: function get() { + supportsPassive = true; + }, + }); + win.addEventListener('testPassiveListener', null, opts); + } catch (e) { + // No support + } + return supportsPassive; + }()), + + gestures: (function checkGestures() { + return 'ongesturestart' in win; + }()), + }; + }()); + + var SwiperClass = function SwiperClass(params) { + if ( params === void 0 ) params = {}; + + var self = this; + self.params = params; + + // Events + self.eventsListeners = {}; + + if (self.params && self.params.on) { + Object.keys(self.params.on).forEach(function (eventName) { + self.on(eventName, self.params.on[eventName]); + }); + } + }; + + var staticAccessors = { components: { configurable: true } }; + SwiperClass.prototype.on = function on (events, handler, priority) { + var self = this; + if (typeof handler !== 'function') { return self; } + var method = priority ? 'unshift' : 'push'; + events.split(' ').forEach(function (event) { + if (!self.eventsListeners[event]) { self.eventsListeners[event] = []; } + self.eventsListeners[event][method](handler); + }); + return self; + }; + SwiperClass.prototype.once = function once (events, handler, priority) { + var self = this; + if (typeof handler !== 'function') { return self; } + function onceHandler() { + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + + handler.apply(self, args); + self.off(events, onceHandler); + } + return self.on(events, onceHandler, priority); + }; + SwiperClass.prototype.off = function off (events, handler) { + var self = this; + if (!self.eventsListeners) { return self; } + events.split(' ').forEach(function (event) { + if (typeof handler === 'undefined') { + self.eventsListeners[event] = []; + } else { + self.eventsListeners[event].forEach(function (eventHandler, index) { + if (eventHandler === handler) { + self.eventsListeners[event].splice(index, 1); + } + }); + } + }); + return self; + }; + SwiperClass.prototype.emit = function emit () { + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + + var self = this; + if (!self.eventsListeners) { return self; } + var events; + var data; + var context; + if (typeof args[0] === 'string' || Array.isArray(args[0])) { + events = args[0]; + data = args.slice(1, args.length); + context = self; + } else { + events = args[0].events; + data = args[0].data; + context = args[0].context || self; + } + var eventsArray = Array.isArray(events) ? events : events.split(' '); + eventsArray.forEach(function (event) { + if (self.eventsListeners && self.eventsListeners[event]) { + var handlers = []; + self.eventsListeners[event].forEach(function (eventHandler) { + handlers.push(eventHandler); + }); + handlers.forEach(function (eventHandler) { + eventHandler.apply(context, data); + }); + } + }); + return self; + }; + SwiperClass.prototype.useModulesParams = function useModulesParams (instanceParams) { + var instance = this; + if (!instance.modules) { return; } + Object.keys(instance.modules).forEach(function (moduleName) { + var module = instance.modules[moduleName]; + // Extend params + if (module.params) { + Utils.extend(instanceParams, module.params); + } + }); + }; + SwiperClass.prototype.useModules = function useModules (modulesParams) { + if ( modulesParams === void 0 ) modulesParams = {}; + + var instance = this; + if (!instance.modules) { return; } + Object.keys(instance.modules).forEach(function (moduleName) { + var module = instance.modules[moduleName]; + var moduleParams = modulesParams[moduleName] || {}; + // Extend instance methods and props + if (module.instance) { + Object.keys(module.instance).forEach(function (modulePropName) { + var moduleProp = module.instance[modulePropName]; + if (typeof moduleProp === 'function') { + instance[modulePropName] = moduleProp.bind(instance); + } else { + instance[modulePropName] = moduleProp; + } + }); + } + // Add event listeners + if (module.on && instance.on) { + Object.keys(module.on).forEach(function (moduleEventName) { + instance.on(moduleEventName, module.on[moduleEventName]); + }); + } + + // Module create callback + if (module.create) { + module.create.bind(instance)(moduleParams); + } + }); + }; + staticAccessors.components.set = function (components) { + var Class = this; + if (!Class.use) { return; } + Class.use(components); + }; + SwiperClass.installModule = function installModule (module) { + var params = [], len = arguments.length - 1; + while ( len-- > 0 ) params[ len ] = arguments[ len + 1 ]; + + var Class = this; + if (!Class.prototype.modules) { Class.prototype.modules = {}; } + var name = module.name || (((Object.keys(Class.prototype.modules).length) + "_" + (Utils.now()))); + Class.prototype.modules[name] = module; + // Prototype + if (module.proto) { + Object.keys(module.proto).forEach(function (key) { + Class.prototype[key] = module.proto[key]; + }); + } + // Class + if (module.static) { + Object.keys(module.static).forEach(function (key) { + Class[key] = module.static[key]; + }); + } + // Callback + if (module.install) { + module.install.apply(Class, params); + } + return Class; + }; + SwiperClass.use = function use (module) { + var params = [], len = arguments.length - 1; + while ( len-- > 0 ) params[ len ] = arguments[ len + 1 ]; + + var Class = this; + if (Array.isArray(module)) { + module.forEach(function (m) { return Class.installModule(m); }); + return Class; + } + return Class.installModule.apply(Class, [ module ].concat( params )); + }; + + Object.defineProperties( SwiperClass, staticAccessors ); + + function updateSize () { + var swiper = this; + var width; + var height; + var $el = swiper.$el; + if (typeof swiper.params.width !== 'undefined') { + width = swiper.params.width; + } else { + width = $el[0].clientWidth; + } + if (typeof swiper.params.height !== 'undefined') { + height = swiper.params.height; + } else { + height = $el[0].clientHeight; + } + if ((width === 0 && swiper.isHorizontal()) || (height === 0 && swiper.isVertical())) { + return; + } + + // Subtract paddings + width = width - parseInt($el.css('padding-left'), 10) - parseInt($el.css('padding-right'), 10); + height = height - parseInt($el.css('padding-top'), 10) - parseInt($el.css('padding-bottom'), 10); + + Utils.extend(swiper, { + width: width, + height: height, + size: swiper.isHorizontal() ? width : height, + }); + } + + function updateSlides () { + var swiper = this; + var params = swiper.params; + + var $wrapperEl = swiper.$wrapperEl; + var swiperSize = swiper.size; + var rtl = swiper.rtlTranslate; + var wrongRTL = swiper.wrongRTL; + var slides = $wrapperEl.children(("." + (swiper.params.slideClass))); + var isVirtual = swiper.virtual && params.virtual.enabled; + var slidesLength = isVirtual ? swiper.virtual.slides.length : slides.length; + var snapGrid = []; + var slidesGrid = []; + var slidesSizesGrid = []; + + var offsetBefore = params.slidesOffsetBefore; + if (typeof offsetBefore === 'function') { + offsetBefore = params.slidesOffsetBefore.call(swiper); + } + + var offsetAfter = params.slidesOffsetAfter; + if (typeof offsetAfter === 'function') { + offsetAfter = params.slidesOffsetAfter.call(swiper); + } + + var previousSlidesLength = slidesLength; + var previousSnapGridLength = swiper.snapGrid.length; + var previousSlidesGridLength = swiper.snapGrid.length; + + var spaceBetween = params.spaceBetween; + var slidePosition = -offsetBefore; + var prevSlideSize = 0; + var index = 0; + if (typeof swiperSize === 'undefined') { + return; + } + if (typeof spaceBetween === 'string' && spaceBetween.indexOf('%') >= 0) { + spaceBetween = (parseFloat(spaceBetween.replace('%', '')) / 100) * swiperSize; + } + + swiper.virtualSize = -spaceBetween; + + // reset margins + if (rtl) { slides.css({ marginLeft: '', marginTop: '' }); } + else { slides.css({ marginRight: '', marginBottom: '' }); } + + var slidesNumberEvenToRows; + if (params.slidesPerColumn > 1) { + if (Math.floor(slidesLength / params.slidesPerColumn) === slidesLength / swiper.params.slidesPerColumn) { + slidesNumberEvenToRows = slidesLength; + } else { + slidesNumberEvenToRows = Math.ceil(slidesLength / params.slidesPerColumn) * params.slidesPerColumn; + } + if (params.slidesPerView !== 'auto' && params.slidesPerColumnFill === 'row') { + slidesNumberEvenToRows = Math.max(slidesNumberEvenToRows, params.slidesPerView * params.slidesPerColumn); + } + } + + // Calc slides + var slideSize; + var slidesPerColumn = params.slidesPerColumn; + var slidesPerRow = slidesNumberEvenToRows / slidesPerColumn; + var numFullColumns = slidesPerRow - ((params.slidesPerColumn * slidesPerRow) - slidesLength); + for (var i = 0; i < slidesLength; i += 1) { + slideSize = 0; + var slide = slides.eq(i); + if (params.slidesPerColumn > 1) { + // Set slides order + var newSlideOrderIndex = (void 0); + var column = (void 0); + var row = (void 0); + if (params.slidesPerColumnFill === 'column') { + column = Math.floor(i / slidesPerColumn); + row = i - (column * slidesPerColumn); + if (column > numFullColumns || (column === numFullColumns && row === slidesPerColumn - 1)) { + row += 1; + if (row >= slidesPerColumn) { + row = 0; + column += 1; + } + } + newSlideOrderIndex = column + ((row * slidesNumberEvenToRows) / slidesPerColumn); + slide + .css({ + '-webkit-box-ordinal-group': newSlideOrderIndex, + '-moz-box-ordinal-group': newSlideOrderIndex, + '-ms-flex-order': newSlideOrderIndex, + '-webkit-order': newSlideOrderIndex, + order: newSlideOrderIndex, + }); + } else { + row = Math.floor(i / slidesPerRow); + column = i - (row * slidesPerRow); + } + slide + .css( + ("margin-" + (swiper.isHorizontal() ? 'top' : 'left')), + (row !== 0 && params.spaceBetween) && (((params.spaceBetween) + "px")) + ) + .attr('data-swiper-column', column) + .attr('data-swiper-row', row); + } + if (slide.css('display') === 'none') { continue; } // eslint-disable-line + + if (params.slidesPerView === 'auto') { + var slideStyles = win.getComputedStyle(slide[0], null); + var currentTransform = slide[0].style.transform; + if (currentTransform) { + slide[0].style.transform = 'none'; + } + if (swiper.isHorizontal()) { + slideSize = slide[0].getBoundingClientRect().width + + parseFloat(slideStyles.getPropertyValue('margin-left')) + + parseFloat(slideStyles.getPropertyValue('margin-right')); + } else { + slideSize = slide[0].getBoundingClientRect().height + + parseFloat(slideStyles.getPropertyValue('margin-top')) + + parseFloat(slideStyles.getPropertyValue('margin-bottom')); + } + if (currentTransform) { + slide[0].style.transform = currentTransform; + } + if (params.roundLengths) { slideSize = Math.floor(slideSize); } + } else { + slideSize = (swiperSize - ((params.slidesPerView - 1) * spaceBetween)) / params.slidesPerView; + if (params.roundLengths) { slideSize = Math.floor(slideSize); } + + if (slides[i]) { + if (swiper.isHorizontal()) { + slides[i].style.width = slideSize + "px"; + } else { + slides[i].style.height = slideSize + "px"; + } + } + } + if (slides[i]) { + slides[i].swiperSlideSize = slideSize; + } + slidesSizesGrid.push(slideSize); + + + if (params.centeredSlides) { + slidePosition = slidePosition + (slideSize / 2) + (prevSlideSize / 2) + spaceBetween; + if (prevSlideSize === 0 && i !== 0) { slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; } + if (i === 0) { slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; } + if (Math.abs(slidePosition) < 1 / 1000) { slidePosition = 0; } + if ((index) % params.slidesPerGroup === 0) { snapGrid.push(slidePosition); } + slidesGrid.push(slidePosition); + } else { + if ((index) % params.slidesPerGroup === 0) { snapGrid.push(slidePosition); } + slidesGrid.push(slidePosition); + slidePosition = slidePosition + slideSize + spaceBetween; + } + + swiper.virtualSize += slideSize + spaceBetween; + + prevSlideSize = slideSize; + + index += 1; + } + swiper.virtualSize = Math.max(swiper.virtualSize, swiperSize) + offsetAfter; + var newSlidesGrid; + + if ( + rtl && wrongRTL && (params.effect === 'slide' || params.effect === 'coverflow')) { + $wrapperEl.css({ width: ((swiper.virtualSize + params.spaceBetween) + "px") }); + } + if (!Support.flexbox || params.setWrapperSize) { + if (swiper.isHorizontal()) { $wrapperEl.css({ width: ((swiper.virtualSize + params.spaceBetween) + "px") }); } + else { $wrapperEl.css({ height: ((swiper.virtualSize + params.spaceBetween) + "px") }); } + } + + if (params.slidesPerColumn > 1) { + swiper.virtualSize = (slideSize + params.spaceBetween) * slidesNumberEvenToRows; + swiper.virtualSize = Math.ceil(swiper.virtualSize / params.slidesPerColumn) - params.spaceBetween; + if (swiper.isHorizontal()) { $wrapperEl.css({ width: ((swiper.virtualSize + params.spaceBetween) + "px") }); } + else { $wrapperEl.css({ height: ((swiper.virtualSize + params.spaceBetween) + "px") }); } + if (params.centeredSlides) { + newSlidesGrid = []; + for (var i$1 = 0; i$1 < snapGrid.length; i$1 += 1) { + if (snapGrid[i$1] < swiper.virtualSize + snapGrid[0]) { newSlidesGrid.push(snapGrid[i$1]); } + } + snapGrid = newSlidesGrid; + } + } + + // Remove last grid elements depending on width + if (!params.centeredSlides) { + newSlidesGrid = []; + for (var i$2 = 0; i$2 < snapGrid.length; i$2 += 1) { + if (snapGrid[i$2] <= swiper.virtualSize - swiperSize) { + newSlidesGrid.push(snapGrid[i$2]); + } + } + snapGrid = newSlidesGrid; + if (Math.floor(swiper.virtualSize - swiperSize) - Math.floor(snapGrid[snapGrid.length - 1]) > 1) { + snapGrid.push(swiper.virtualSize - swiperSize); + } + } + if (snapGrid.length === 0) { snapGrid = [0]; } + + if (params.spaceBetween !== 0) { + if (swiper.isHorizontal()) { + if (rtl) { slides.css({ marginLeft: (spaceBetween + "px") }); } + else { slides.css({ marginRight: (spaceBetween + "px") }); } + } else { slides.css({ marginBottom: (spaceBetween + "px") }); } + } + + Utils.extend(swiper, { + slides: slides, + snapGrid: snapGrid, + slidesGrid: slidesGrid, + slidesSizesGrid: slidesSizesGrid, + }); + + if (slidesLength !== previousSlidesLength) { + swiper.emit('slidesLengthChange'); + } + if (snapGrid.length !== previousSnapGridLength) { + if (swiper.params.watchOverflow) { swiper.checkOverflow(); } + swiper.emit('snapGridLengthChange'); + } + if (slidesGrid.length !== previousSlidesGridLength) { + swiper.emit('slidesGridLengthChange'); + } + + if (params.watchSlidesProgress || params.watchSlidesVisibility) { + swiper.updateSlidesOffset(); + } + } + + function updateAutoHeight (speed) { + var swiper = this; + var activeSlides = []; + var newHeight = 0; + var i; + if (typeof speed === 'number') { + swiper.setTransition(speed); + } else if (speed === true) { + swiper.setTransition(swiper.params.speed); + } + // Find slides currently in view + if (swiper.params.slidesPerView !== 'auto' && swiper.params.slidesPerView > 1) { + for (i = 0; i < Math.ceil(swiper.params.slidesPerView); i += 1) { + var index = swiper.activeIndex + i; + if (index > swiper.slides.length) { break; } + activeSlides.push(swiper.slides.eq(index)[0]); + } + } else { + activeSlides.push(swiper.slides.eq(swiper.activeIndex)[0]); + } + + // Find new height from highest slide in view + for (i = 0; i < activeSlides.length; i += 1) { + if (typeof activeSlides[i] !== 'undefined') { + var height = activeSlides[i].offsetHeight; + newHeight = height > newHeight ? height : newHeight; + } + } + + // Update Height + if (newHeight) { swiper.$wrapperEl.css('height', (newHeight + "px")); } + } + + function updateSlidesOffset () { + var swiper = this; + var slides = swiper.slides; + for (var i = 0; i < slides.length; i += 1) { + slides[i].swiperSlideOffset = swiper.isHorizontal() ? slides[i].offsetLeft : slides[i].offsetTop; + } + } + + function updateSlidesProgress (translate) { + if ( translate === void 0 ) translate = (this && this.translate) || 0; + + var swiper = this; + var params = swiper.params; + + var slides = swiper.slides; + var rtl = swiper.rtlTranslate; + + if (slides.length === 0) { return; } + if (typeof slides[0].swiperSlideOffset === 'undefined') { swiper.updateSlidesOffset(); } + + var offsetCenter = -translate; + if (rtl) { offsetCenter = translate; } + + // Visible Slides + slides.removeClass(params.slideVisibleClass); + + for (var i = 0; i < slides.length; i += 1) { + var slide = slides[i]; + var slideProgress = + ( + (offsetCenter + (params.centeredSlides ? swiper.minTranslate() : 0)) - slide.swiperSlideOffset + ) / (slide.swiperSlideSize + params.spaceBetween); + if (params.watchSlidesVisibility) { + var slideBefore = -(offsetCenter - slide.swiperSlideOffset); + var slideAfter = slideBefore + swiper.slidesSizesGrid[i]; + var isVisible = + (slideBefore >= 0 && slideBefore < swiper.size) || + (slideAfter > 0 && slideAfter <= swiper.size) || + (slideBefore <= 0 && slideAfter >= swiper.size); + if (isVisible) { + slides.eq(i).addClass(params.slideVisibleClass); + } + } + slide.progress = rtl ? -slideProgress : slideProgress; + } + } + + function updateProgress (translate) { + if ( translate === void 0 ) translate = (this && this.translate) || 0; + + var swiper = this; + var params = swiper.params; + + var translatesDiff = swiper.maxTranslate() - swiper.minTranslate(); + var progress = swiper.progress; + var isBeginning = swiper.isBeginning; + var isEnd = swiper.isEnd; + var wasBeginning = isBeginning; + var wasEnd = isEnd; + if (translatesDiff === 0) { + progress = 0; + isBeginning = true; + isEnd = true; + } else { + progress = (translate - swiper.minTranslate()) / (translatesDiff); + isBeginning = progress <= 0; + isEnd = progress >= 1; + } + Utils.extend(swiper, { + progress: progress, + isBeginning: isBeginning, + isEnd: isEnd, + }); + + if (params.watchSlidesProgress || params.watchSlidesVisibility) { swiper.updateSlidesProgress(translate); } + + if (isBeginning && !wasBeginning) { + swiper.emit('reachBeginning toEdge'); + } + if (isEnd && !wasEnd) { + swiper.emit('reachEnd toEdge'); + } + if ((wasBeginning && !isBeginning) || (wasEnd && !isEnd)) { + swiper.emit('fromEdge'); + } + + swiper.emit('progress', progress); + } + + function updateSlidesClasses () { + var swiper = this; + + var slides = swiper.slides; + var params = swiper.params; + var $wrapperEl = swiper.$wrapperEl; + var activeIndex = swiper.activeIndex; + var realIndex = swiper.realIndex; + var isVirtual = swiper.virtual && params.virtual.enabled; + + slides.removeClass(((params.slideActiveClass) + " " + (params.slideNextClass) + " " + (params.slidePrevClass) + " " + (params.slideDuplicateActiveClass) + " " + (params.slideDuplicateNextClass) + " " + (params.slideDuplicatePrevClass))); + + var activeSlide; + if (isVirtual) { + activeSlide = swiper.$wrapperEl.find(("." + (params.slideClass) + "[data-swiper-slide-index=\"" + activeIndex + "\"]")); + } else { + activeSlide = slides.eq(activeIndex); + } + + // Active classes + activeSlide.addClass(params.slideActiveClass); + + if (params.loop) { + // Duplicate to all looped slides + if (activeSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(("." + (params.slideClass) + ":not(." + (params.slideDuplicateClass) + ")[data-swiper-slide-index=\"" + realIndex + "\"]")) + .addClass(params.slideDuplicateActiveClass); + } else { + $wrapperEl + .children(("." + (params.slideClass) + "." + (params.slideDuplicateClass) + "[data-swiper-slide-index=\"" + realIndex + "\"]")) + .addClass(params.slideDuplicateActiveClass); + } + } + // Next Slide + var nextSlide = activeSlide.nextAll(("." + (params.slideClass))).eq(0).addClass(params.slideNextClass); + if (params.loop && nextSlide.length === 0) { + nextSlide = slides.eq(0); + nextSlide.addClass(params.slideNextClass); + } + // Prev Slide + var prevSlide = activeSlide.prevAll(("." + (params.slideClass))).eq(0).addClass(params.slidePrevClass); + if (params.loop && prevSlide.length === 0) { + prevSlide = slides.eq(-1); + prevSlide.addClass(params.slidePrevClass); + } + if (params.loop) { + // Duplicate to all looped slides + if (nextSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(("." + (params.slideClass) + ":not(." + (params.slideDuplicateClass) + ")[data-swiper-slide-index=\"" + (nextSlide.attr('data-swiper-slide-index')) + "\"]")) + .addClass(params.slideDuplicateNextClass); + } else { + $wrapperEl + .children(("." + (params.slideClass) + "." + (params.slideDuplicateClass) + "[data-swiper-slide-index=\"" + (nextSlide.attr('data-swiper-slide-index')) + "\"]")) + .addClass(params.slideDuplicateNextClass); + } + if (prevSlide.hasClass(params.slideDuplicateClass)) { + $wrapperEl + .children(("." + (params.slideClass) + ":not(." + (params.slideDuplicateClass) + ")[data-swiper-slide-index=\"" + (prevSlide.attr('data-swiper-slide-index')) + "\"]")) + .addClass(params.slideDuplicatePrevClass); + } else { + $wrapperEl + .children(("." + (params.slideClass) + "." + (params.slideDuplicateClass) + "[data-swiper-slide-index=\"" + (prevSlide.attr('data-swiper-slide-index')) + "\"]")) + .addClass(params.slideDuplicatePrevClass); + } + } + } + + function updateActiveIndex (newActiveIndex) { + var swiper = this; + var translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate; + var slidesGrid = swiper.slidesGrid; + var snapGrid = swiper.snapGrid; + var params = swiper.params; + var previousIndex = swiper.activeIndex; + var previousRealIndex = swiper.realIndex; + var previousSnapIndex = swiper.snapIndex; + var activeIndex = newActiveIndex; + var snapIndex; + if (typeof activeIndex === 'undefined') { + for (var i = 0; i < slidesGrid.length; i += 1) { + if (typeof slidesGrid[i + 1] !== 'undefined') { + if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1] - ((slidesGrid[i + 1] - slidesGrid[i]) / 2)) { + activeIndex = i; + } else if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1]) { + activeIndex = i + 1; + } + } else if (translate >= slidesGrid[i]) { + activeIndex = i; + } + } + // Normalize slideIndex + if (params.normalizeSlideIndex) { + if (activeIndex < 0 || typeof activeIndex === 'undefined') { activeIndex = 0; } + } + } + if (snapGrid.indexOf(translate) >= 0) { + snapIndex = snapGrid.indexOf(translate); + } else { + snapIndex = Math.floor(activeIndex / params.slidesPerGroup); + } + if (snapIndex >= snapGrid.length) { snapIndex = snapGrid.length - 1; } + if (activeIndex === previousIndex) { + if (snapIndex !== previousSnapIndex) { + swiper.snapIndex = snapIndex; + swiper.emit('snapIndexChange'); + } + return; + } + + // Get real index + var realIndex = parseInt(swiper.slides.eq(activeIndex).attr('data-swiper-slide-index') || activeIndex, 10); + + Utils.extend(swiper, { + snapIndex: snapIndex, + realIndex: realIndex, + previousIndex: previousIndex, + activeIndex: activeIndex, + }); + swiper.emit('activeIndexChange'); + swiper.emit('snapIndexChange'); + if (previousRealIndex !== realIndex) { + swiper.emit('realIndexChange'); + } + swiper.emit('slideChange'); + } + + function updateClickedSlide (e) { + var swiper = this; + var params = swiper.params; + var slide = $(e.target).closest(("." + (params.slideClass)))[0]; + var slideFound = false; + if (slide) { + for (var i = 0; i < swiper.slides.length; i += 1) { + if (swiper.slides[i] === slide) { slideFound = true; } + } + } + + if (slide && slideFound) { + swiper.clickedSlide = slide; + if (swiper.virtual && swiper.params.virtual.enabled) { + swiper.clickedIndex = parseInt($(slide).attr('data-swiper-slide-index'), 10); + } else { + swiper.clickedIndex = $(slide).index(); + } + } else { + swiper.clickedSlide = undefined; + swiper.clickedIndex = undefined; + return; + } + if (params.slideToClickedSlide && swiper.clickedIndex !== undefined && swiper.clickedIndex !== swiper.activeIndex) { + swiper.slideToClickedSlide(); + } + } + + var update = { + updateSize: updateSize, + updateSlides: updateSlides, + updateAutoHeight: updateAutoHeight, + updateSlidesOffset: updateSlidesOffset, + updateSlidesProgress: updateSlidesProgress, + updateProgress: updateProgress, + updateSlidesClasses: updateSlidesClasses, + updateActiveIndex: updateActiveIndex, + updateClickedSlide: updateClickedSlide, + }; + + function getTranslate (axis) { + if ( axis === void 0 ) axis = this.isHorizontal() ? 'x' : 'y'; + + var swiper = this; + + var params = swiper.params; + var rtl = swiper.rtlTranslate; + var translate = swiper.translate; + var $wrapperEl = swiper.$wrapperEl; + + if (params.virtualTranslate) { + return rtl ? -translate : translate; + } + + var currentTranslate = Utils.getTranslate($wrapperEl[0], axis); + if (rtl) { currentTranslate = -currentTranslate; } + + return currentTranslate || 0; + } + + function setTranslate (translate, byController) { + var swiper = this; + var rtl = swiper.rtlTranslate; + var params = swiper.params; + var $wrapperEl = swiper.$wrapperEl; + var progress = swiper.progress; + var x = 0; + var y = 0; + var z = 0; + + if (swiper.isHorizontal()) { + x = rtl ? -translate : translate; + } else { + y = translate; + } + + if (params.roundLengths) { + x = Math.floor(x); + y = Math.floor(y); + } + + if (!params.virtualTranslate) { + if (Support.transforms3d) { $wrapperEl.transform(("translate3d(" + x + "px, " + y + "px, " + z + "px)")); } + else { $wrapperEl.transform(("translate(" + x + "px, " + y + "px)")); } + } + + swiper.translate = swiper.isHorizontal() ? x : y; + + // Check if we need to update progress + var newProgress; + var translatesDiff = swiper.maxTranslate() - swiper.minTranslate(); + if (translatesDiff === 0) { + newProgress = 0; + } else { + newProgress = (translate - swiper.minTranslate()) / (translatesDiff); + } + if (newProgress !== progress) { + swiper.updateProgress(translate); + } + + swiper.emit('setTranslate', swiper.translate, byController); + } + + function minTranslate () { + return (-this.snapGrid[0]); + } + + function maxTranslate () { + return (-this.snapGrid[this.snapGrid.length - 1]); + } + + var translate = { + getTranslate: getTranslate, + setTranslate: setTranslate, + minTranslate: minTranslate, + maxTranslate: maxTranslate, + }; + + function setTransition (duration, byController) { + var swiper = this; + + swiper.$wrapperEl.transition(duration); + + swiper.emit('setTransition', duration, byController); + } + + function transitionStart (runCallbacks, direction) { + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + var activeIndex = swiper.activeIndex; + var params = swiper.params; + var previousIndex = swiper.previousIndex; + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + + var dir = direction; + if (!dir) { + if (activeIndex > previousIndex) { dir = 'next'; } + else if (activeIndex < previousIndex) { dir = 'prev'; } + else { dir = 'reset'; } + } + + swiper.emit('transitionStart'); + + if (runCallbacks && activeIndex !== previousIndex) { + if (dir === 'reset') { + swiper.emit('slideResetTransitionStart'); + return; + } + swiper.emit('slideChangeTransitionStart'); + if (dir === 'next') { + swiper.emit('slideNextTransitionStart'); + } else { + swiper.emit('slidePrevTransitionStart'); + } + } + } + + function transitionEnd$1 (runCallbacks, direction) { + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + var activeIndex = swiper.activeIndex; + var previousIndex = swiper.previousIndex; + swiper.animating = false; + swiper.setTransition(0); + + var dir = direction; + if (!dir) { + if (activeIndex > previousIndex) { dir = 'next'; } + else if (activeIndex < previousIndex) { dir = 'prev'; } + else { dir = 'reset'; } + } + + swiper.emit('transitionEnd'); + + if (runCallbacks && activeIndex !== previousIndex) { + if (dir === 'reset') { + swiper.emit('slideResetTransitionEnd'); + return; + } + swiper.emit('slideChangeTransitionEnd'); + if (dir === 'next') { + swiper.emit('slideNextTransitionEnd'); + } else { + swiper.emit('slidePrevTransitionEnd'); + } + } + } + + var transition$1 = { + setTransition: setTransition, + transitionStart: transitionStart, + transitionEnd: transitionEnd$1, + }; + + function slideTo (index, speed, runCallbacks, internal) { + if ( index === void 0 ) index = 0; + if ( speed === void 0 ) speed = this.params.speed; + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + var slideIndex = index; + if (slideIndex < 0) { slideIndex = 0; } + + var params = swiper.params; + var snapGrid = swiper.snapGrid; + var slidesGrid = swiper.slidesGrid; + var previousIndex = swiper.previousIndex; + var activeIndex = swiper.activeIndex; + var rtl = swiper.rtlTranslate; + if (swiper.animating && params.preventIntercationOnTransition) { + return false; + } + + var snapIndex = Math.floor(slideIndex / params.slidesPerGroup); + if (snapIndex >= snapGrid.length) { snapIndex = snapGrid.length - 1; } + + if ((activeIndex || params.initialSlide || 0) === (previousIndex || 0) && runCallbacks) { + swiper.emit('beforeSlideChangeStart'); + } + + var translate = -snapGrid[snapIndex]; + + // Update progress + swiper.updateProgress(translate); + + // Normalize slideIndex + if (params.normalizeSlideIndex) { + for (var i = 0; i < slidesGrid.length; i += 1) { + if (-Math.floor(translate * 100) >= Math.floor(slidesGrid[i] * 100)) { + slideIndex = i; + } + } + } + // Directions locks + if (swiper.initialized && slideIndex !== activeIndex) { + if (!swiper.allowSlideNext && translate < swiper.translate && translate < swiper.minTranslate()) { + return false; + } + if (!swiper.allowSlidePrev && translate > swiper.translate && translate > swiper.maxTranslate()) { + if ((activeIndex || 0) !== slideIndex) { return false; } + } + } + + var direction; + if (slideIndex > activeIndex) { direction = 'next'; } + else if (slideIndex < activeIndex) { direction = 'prev'; } + else { direction = 'reset'; } + + + // Update Index + if ((rtl && -translate === swiper.translate) || (!rtl && translate === swiper.translate)) { + swiper.updateActiveIndex(slideIndex); + // Update Height + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + swiper.updateSlidesClasses(); + if (params.effect !== 'slide') { + swiper.setTranslate(translate); + } + if (direction !== 'reset') { + swiper.transitionStart(runCallbacks, direction); + swiper.transitionEnd(runCallbacks, direction); + } + return false; + } + + if (speed === 0 || !Support.transition) { + swiper.setTransition(0); + swiper.setTranslate(translate); + swiper.updateActiveIndex(slideIndex); + swiper.updateSlidesClasses(); + swiper.emit('beforeTransitionStart', speed, internal); + swiper.transitionStart(runCallbacks, direction); + swiper.transitionEnd(runCallbacks, direction); + } else { + swiper.setTransition(speed); + swiper.setTranslate(translate); + swiper.updateActiveIndex(slideIndex); + swiper.updateSlidesClasses(); + swiper.emit('beforeTransitionStart', speed, internal); + swiper.transitionStart(runCallbacks, direction); + if (!swiper.animating) { + swiper.animating = true; + if (!swiper.onSlideToWrapperTransitionEnd) { + swiper.onSlideToWrapperTransitionEnd = function transitionEnd(e) { + if (!swiper || swiper.destroyed) { return; } + if (e.target !== this) { return; } + swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd); + swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd); + swiper.transitionEnd(runCallbacks, direction); + }; + } + swiper.$wrapperEl[0].addEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd); + swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd); + } + } + + return true; + } + + function slideToLoop (index, speed, runCallbacks, internal) { + if ( index === void 0 ) index = 0; + if ( speed === void 0 ) speed = this.params.speed; + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + var newIndex = index; + if (swiper.params.loop) { + newIndex += swiper.loopedSlides; + } + + return swiper.slideTo(newIndex, speed, runCallbacks, internal); + } + + /* eslint no-unused-vars: "off" */ + function slideNext (speed, runCallbacks, internal) { + if ( speed === void 0 ) speed = this.params.speed; + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + var params = swiper.params; + var animating = swiper.animating; + if (params.loop) { + if (animating) { return false; } + swiper.loopFix(); + // eslint-disable-next-line + swiper._clientLeft = swiper.$wrapperEl[0].clientLeft; + return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal); + } + return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal); + } + + /* eslint no-unused-vars: "off" */ + function slidePrev (speed, runCallbacks, internal) { + if ( speed === void 0 ) speed = this.params.speed; + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + var params = swiper.params; + var animating = swiper.animating; + var snapGrid = swiper.snapGrid; + var slidesGrid = swiper.slidesGrid; + var rtlTranslate = swiper.rtlTranslate; + + if (params.loop) { + if (animating) { return false; } + swiper.loopFix(); + // eslint-disable-next-line + swiper._clientLeft = swiper.$wrapperEl[0].clientLeft; + } + var translate = rtlTranslate ? swiper.translate : -swiper.translate; + var currentSnap = snapGrid[snapGrid.indexOf(translate)]; + var prevSnap = snapGrid[snapGrid.indexOf(translate) - 1]; + var prevIndex; + + if (prevSnap) { + prevIndex = slidesGrid.indexOf(prevSnap); + if (prevIndex < 0) { prevIndex = swiper.activeIndex - 1; } + } + return swiper.slideTo(prevIndex, speed, runCallbacks, internal); + } + + /* eslint no-unused-vars: "off" */ + function slideReset (speed, runCallbacks, internal) { + if ( speed === void 0 ) speed = this.params.speed; + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + return swiper.slideTo(swiper.activeIndex, speed, runCallbacks, internal); + } + + /* eslint no-unused-vars: "off" */ + function slideToClosest (speed, runCallbacks, internal) { + if ( speed === void 0 ) speed = this.params.speed; + if ( runCallbacks === void 0 ) runCallbacks = true; + + var swiper = this; + var index = swiper.activeIndex; + var snapIndex = Math.floor(index / swiper.params.slidesPerGroup); + + if (snapIndex < swiper.snapGrid.length - 1) { + var translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate; + + var currentSnap = swiper.snapGrid[snapIndex]; + var nextSnap = swiper.snapGrid[snapIndex + 1]; + + if ((translate - currentSnap) > (nextSnap - currentSnap) / 2) { + index = swiper.params.slidesPerGroup; + } + } + + return swiper.slideTo(index, speed, runCallbacks, internal); + } + + function slideToClickedSlide () { + var swiper = this; + var params = swiper.params; + var $wrapperEl = swiper.$wrapperEl; + + var slidesPerView = params.slidesPerView === 'auto' ? swiper.slidesPerViewDynamic() : params.slidesPerView; + var slideToIndex = swiper.clickedIndex; + var realIndex; + if (params.loop) { + if (swiper.animating) { return; } + realIndex = parseInt($(swiper.clickedSlide).attr('data-swiper-slide-index'), 10); + if (params.centeredSlides) { + if ( + (slideToIndex < swiper.loopedSlides - (slidesPerView / 2)) || + (slideToIndex > (swiper.slides.length - swiper.loopedSlides) + (slidesPerView / 2)) + ) { + swiper.loopFix(); + slideToIndex = $wrapperEl + .children(("." + (params.slideClass) + "[data-swiper-slide-index=\"" + realIndex + "\"]:not(." + (params.slideDuplicateClass) + ")")) + .eq(0) + .index(); + + Utils.nextTick(function () { + swiper.slideTo(slideToIndex); + }); + } else { + swiper.slideTo(slideToIndex); + } + } else if (slideToIndex > swiper.slides.length - slidesPerView) { + swiper.loopFix(); + slideToIndex = $wrapperEl + .children(("." + (params.slideClass) + "[data-swiper-slide-index=\"" + realIndex + "\"]:not(." + (params.slideDuplicateClass) + ")")) + .eq(0) + .index(); + + Utils.nextTick(function () { + swiper.slideTo(slideToIndex); + }); + } else { + swiper.slideTo(slideToIndex); + } + } else { + swiper.slideTo(slideToIndex); + } + } + + var slide = { + slideTo: slideTo, + slideToLoop: slideToLoop, + slideNext: slideNext, + slidePrev: slidePrev, + slideReset: slideReset, + slideToClosest: slideToClosest, + slideToClickedSlide: slideToClickedSlide, + }; + + function loopCreate () { + var swiper = this; + var params = swiper.params; + var $wrapperEl = swiper.$wrapperEl; + // Remove duplicated slides + $wrapperEl.children(("." + (params.slideClass) + "." + (params.slideDuplicateClass))).remove(); + + var slides = $wrapperEl.children(("." + (params.slideClass))); + + if (params.loopFillGroupWithBlank) { + var blankSlidesNum = params.slidesPerGroup - (slides.length % params.slidesPerGroup); + if (blankSlidesNum !== params.slidesPerGroup) { + for (var i = 0; i < blankSlidesNum; i += 1) { + var blankNode = $(doc.createElement('div')).addClass(((params.slideClass) + " " + (params.slideBlankClass))); + $wrapperEl.append(blankNode); + } + slides = $wrapperEl.children(("." + (params.slideClass))); + } + } + + if (params.slidesPerView === 'auto' && !params.loopedSlides) { params.loopedSlides = slides.length; } + + swiper.loopedSlides = parseInt(params.loopedSlides || params.slidesPerView, 10); + swiper.loopedSlides += params.loopAdditionalSlides; + if (swiper.loopedSlides > slides.length) { + swiper.loopedSlides = slides.length; + } + + var prependSlides = []; + var appendSlides = []; + slides.each(function (index, el) { + var slide = $(el); + if (index < swiper.loopedSlides) { appendSlides.push(el); } + if (index < slides.length && index >= slides.length - swiper.loopedSlides) { prependSlides.push(el); } + slide.attr('data-swiper-slide-index', index); + }); + for (var i$1 = 0; i$1 < appendSlides.length; i$1 += 1) { + $wrapperEl.append($(appendSlides[i$1].cloneNode(true)).addClass(params.slideDuplicateClass)); + } + for (var i$2 = prependSlides.length - 1; i$2 >= 0; i$2 -= 1) { + $wrapperEl.prepend($(prependSlides[i$2].cloneNode(true)).addClass(params.slideDuplicateClass)); + } + } + + function loopFix () { + var swiper = this; + var params = swiper.params; + var activeIndex = swiper.activeIndex; + var slides = swiper.slides; + var loopedSlides = swiper.loopedSlides; + var allowSlidePrev = swiper.allowSlidePrev; + var allowSlideNext = swiper.allowSlideNext; + var snapGrid = swiper.snapGrid; + var rtl = swiper.rtlTranslate; + var newIndex; + swiper.allowSlidePrev = true; + swiper.allowSlideNext = true; + + var snapTranslate = -snapGrid[activeIndex]; + var diff = snapTranslate - swiper.getTranslate(); + + + // Fix For Negative Oversliding + if (activeIndex < loopedSlides) { + newIndex = (slides.length - (loopedSlides * 3)) + activeIndex; + newIndex += loopedSlides; + var slideChanged = swiper.slideTo(newIndex, 0, false, true); + if (slideChanged && diff !== 0) { + swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff); + } + } else if ((params.slidesPerView === 'auto' && activeIndex >= loopedSlides * 2) || (activeIndex > slides.length - (params.slidesPerView * 2))) { + // Fix For Positive Oversliding + newIndex = -slides.length + activeIndex + loopedSlides; + newIndex += loopedSlides; + var slideChanged$1 = swiper.slideTo(newIndex, 0, false, true); + if (slideChanged$1 && diff !== 0) { + swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff); + } + } + swiper.allowSlidePrev = allowSlidePrev; + swiper.allowSlideNext = allowSlideNext; + } + + function loopDestroy () { + var swiper = this; + var $wrapperEl = swiper.$wrapperEl; + var params = swiper.params; + var slides = swiper.slides; + $wrapperEl.children(("." + (params.slideClass) + "." + (params.slideDuplicateClass))).remove(); + slides.removeAttr('data-swiper-slide-index'); + } + + var loop = { + loopCreate: loopCreate, + loopFix: loopFix, + loopDestroy: loopDestroy, + }; + + function setGrabCursor (moving) { + var swiper = this; + if (Support.touch || !swiper.params.simulateTouch || (swiper.params.watchOverflow && swiper.isLocked)) { return; } + var el = swiper.el; + el.style.cursor = 'move'; + el.style.cursor = moving ? '-webkit-grabbing' : '-webkit-grab'; + el.style.cursor = moving ? '-moz-grabbin' : '-moz-grab'; + el.style.cursor = moving ? 'grabbing' : 'grab'; + } + + function unsetGrabCursor () { + var swiper = this; + if (Support.touch || (swiper.params.watchOverflow && swiper.isLocked)) { return; } + swiper.el.style.cursor = ''; + } + + var grabCursor = { + setGrabCursor: setGrabCursor, + unsetGrabCursor: unsetGrabCursor, + }; + + function appendSlide (slides) { + var swiper = this; + var $wrapperEl = swiper.$wrapperEl; + var params = swiper.params; + if (params.loop) { + swiper.loopDestroy(); + } + if (typeof slides === 'object' && 'length' in slides) { + for (var i = 0; i < slides.length; i += 1) { + if (slides[i]) { $wrapperEl.append(slides[i]); } + } + } else { + $wrapperEl.append(slides); + } + if (params.loop) { + swiper.loopCreate(); + } + if (!(params.observer && Support.observer)) { + swiper.update(); + } + } + + function prependSlide (slides) { + var swiper = this; + var params = swiper.params; + var $wrapperEl = swiper.$wrapperEl; + var activeIndex = swiper.activeIndex; + + if (params.loop) { + swiper.loopDestroy(); + } + var newActiveIndex = activeIndex + 1; + if (typeof slides === 'object' && 'length' in slides) { + for (var i = 0; i < slides.length; i += 1) { + if (slides[i]) { $wrapperEl.prepend(slides[i]); } + } + newActiveIndex = activeIndex + slides.length; + } else { + $wrapperEl.prepend(slides); + } + if (params.loop) { + swiper.loopCreate(); + } + if (!(params.observer && Support.observer)) { + swiper.update(); + } + swiper.slideTo(newActiveIndex, 0, false); + } + + function removeSlide (slidesIndexes) { + var swiper = this; + var params = swiper.params; + var $wrapperEl = swiper.$wrapperEl; + var activeIndex = swiper.activeIndex; + + if (params.loop) { + swiper.loopDestroy(); + swiper.slides = $wrapperEl.children(("." + (params.slideClass))); + } + var newActiveIndex = activeIndex; + var indexToRemove; + + if (typeof slidesIndexes === 'object' && 'length' in slidesIndexes) { + for (var i = 0; i < slidesIndexes.length; i += 1) { + indexToRemove = slidesIndexes[i]; + if (swiper.slides[indexToRemove]) { swiper.slides.eq(indexToRemove).remove(); } + if (indexToRemove < newActiveIndex) { newActiveIndex -= 1; } + } + newActiveIndex = Math.max(newActiveIndex, 0); + } else { + indexToRemove = slidesIndexes; + if (swiper.slides[indexToRemove]) { swiper.slides.eq(indexToRemove).remove(); } + if (indexToRemove < newActiveIndex) { newActiveIndex -= 1; } + newActiveIndex = Math.max(newActiveIndex, 0); + } + + if (params.loop) { + swiper.loopCreate(); + } + + if (!(params.observer && Support.observer)) { + swiper.update(); + } + if (params.loop) { + swiper.slideTo(newActiveIndex + swiper.loopedSlides, 0, false); + } else { + swiper.slideTo(newActiveIndex, 0, false); + } + } + + function removeAllSlides () { + var swiper = this; + + var slidesIndexes = []; + for (var i = 0; i < swiper.slides.length; i += 1) { + slidesIndexes.push(i); + } + swiper.removeSlide(slidesIndexes); + } + + var manipulation = { + appendSlide: appendSlide, + prependSlide: prependSlide, + removeSlide: removeSlide, + removeAllSlides: removeAllSlides, + }; + + var Device = (function Device() { + var ua = win.navigator.userAgent; + + var device = { + ios: false, + android: false, + androidChrome: false, + desktop: false, + windows: false, + iphone: false, + ipod: false, + ipad: false, + cordova: win.cordova || win.phonegap, + phonegap: win.cordova || win.phonegap, + }; + + var windows = ua.match(/(Windows Phone);?[\s\/]+([\d.]+)?/); // eslint-disable-line + var android = ua.match(/(Android);?[\s\/]+([\d.]+)?/); // eslint-disable-line + var ipad = ua.match(/(iPad).*OS\s([\d_]+)/); + var ipod = ua.match(/(iPod)(.*OS\s([\d_]+))?/); + var iphone = !ipad && ua.match(/(iPhone\sOS|iOS)\s([\d_]+)/); + + + // Windows + if (windows) { + device.os = 'windows'; + device.osVersion = windows[2]; + device.windows = true; + } + // Android + if (android && !windows) { + device.os = 'android'; + device.osVersion = android[2]; + device.android = true; + device.androidChrome = ua.toLowerCase().indexOf('chrome') >= 0; + } + if (ipad || iphone || ipod) { + device.os = 'ios'; + device.ios = true; + } + // iOS + if (iphone && !ipod) { + device.osVersion = iphone[2].replace(/_/g, '.'); + device.iphone = true; + } + if (ipad) { + device.osVersion = ipad[2].replace(/_/g, '.'); + device.ipad = true; + } + if (ipod) { + device.osVersion = ipod[3] ? ipod[3].replace(/_/g, '.') : null; + device.iphone = true; + } + // iOS 8+ changed UA + if (device.ios && device.osVersion && ua.indexOf('Version/') >= 0) { + if (device.osVersion.split('.')[0] === '10') { + device.osVersion = ua.toLowerCase().split('version/')[1].split(' ')[0]; + } + } + + // Desktop + device.desktop = !(device.os || device.android || device.webView); + + // Webview + device.webView = (iphone || ipad || ipod) && ua.match(/.*AppleWebKit(?!.*Safari)/i); + + // Minimal UI + if (device.os && device.os === 'ios') { + var osVersionArr = device.osVersion.split('.'); + var metaViewport = doc.querySelector('meta[name="viewport"]'); + device.minimalUi = + !device.webView && + (ipod || iphone) && + (osVersionArr[0] * 1 === 7 ? osVersionArr[1] * 1 >= 1 : osVersionArr[0] * 1 > 7) && + metaViewport && metaViewport.getAttribute('content').indexOf('minimal-ui') >= 0; + } + + // Pixel Ratio + device.pixelRatio = win.devicePixelRatio || 1; + + // Export object + return device; + }()); + + function onTouchStart (event) { + var swiper = this; + var data = swiper.touchEventsData; + var params = swiper.params; + var touches = swiper.touches; + if (swiper.animating && params.preventIntercationOnTransition) { + return; + } + var e = event; + if (e.originalEvent) { e = e.originalEvent; } + data.isTouchEvent = e.type === 'touchstart'; + if (!data.isTouchEvent && 'which' in e && e.which === 3) { return; } + if (data.isTouched && data.isMoved) { return; } + if (params.noSwiping && $(e.target).closest(params.noSwipingSelector ? params.noSwipingSelector : ("." + (params.noSwipingClass)))[0]) { + swiper.allowClick = true; + return; + } + if (params.swipeHandler) { + if (!$(e).closest(params.swipeHandler)[0]) { return; } + } + + touches.currentX = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX; + touches.currentY = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY; + var startX = touches.currentX; + var startY = touches.currentY; + + // Do NOT start if iOS edge swipe is detected. Otherwise iOS app (UIWebView) cannot swipe-to-go-back anymore + + if ( + Device.ios && + !Device.cordova && + params.iOSEdgeSwipeDetection && + (startX <= params.iOSEdgeSwipeThreshold) && + (startX >= win.screen.width - params.iOSEdgeSwipeThreshold) + ) { + return; + } + + Utils.extend(data, { + isTouched: true, + isMoved: false, + allowTouchCallbacks: true, + isScrolling: undefined, + startMoving: undefined, + }); + + touches.startX = startX; + touches.startY = startY; + data.touchStartTime = Utils.now(); + swiper.allowClick = true; + swiper.updateSize(); + swiper.swipeDirection = undefined; + if (params.threshold > 0) { data.allowThresholdMove = false; } + if (e.type !== 'touchstart') { + var preventDefault = true; + if ($(e.target).is(data.formElements)) { preventDefault = false; } + if ( + doc.activeElement && + $(doc.activeElement).is(data.formElements) && + doc.activeElement !== e.target + ) { + doc.activeElement.blur(); + } + if (preventDefault && swiper.allowTouchMove) { + e.preventDefault(); + } + } + swiper.emit('touchStart', e); + } + + function onTouchMove (event) { + var swiper = this; + var data = swiper.touchEventsData; + var params = swiper.params; + var touches = swiper.touches; + var rtl = swiper.rtlTranslate; + var e = event; + if (e.originalEvent) { e = e.originalEvent; } + if (!data.isTouched) { + if (data.startMoving && data.isScrolling) { + swiper.emit('touchMoveOpposite', e); + } + return; + } + if (data.isTouchEvent && e.type === 'mousemove') { return; } + var pageX = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX; + var pageY = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY; + if (e.preventedByNestedSwiper) { + touches.startX = pageX; + touches.startY = pageY; + return; + } + if (!swiper.allowTouchMove) { + // isMoved = true; + swiper.allowClick = false; + if (data.isTouched) { + Utils.extend(touches, { + startX: pageX, + startY: pageY, + currentX: pageX, + currentY: pageY, + }); + data.touchStartTime = Utils.now(); + } + return; + } + if (data.isTouchEvent && params.touchReleaseOnEdges && !params.loop) { + if (swiper.isVertical()) { + // Vertical + if ( + (pageY < touches.startY && swiper.translate <= swiper.maxTranslate()) || + (pageY > touches.startY && swiper.translate >= swiper.minTranslate()) + ) { + data.isTouched = false; + data.isMoved = false; + return; + } + } else if ( + (pageX < touches.startX && swiper.translate <= swiper.maxTranslate()) || + (pageX > touches.startX && swiper.translate >= swiper.minTranslate()) + ) { + return; + } + } + if (data.isTouchEvent && doc.activeElement) { + if (e.target === doc.activeElement && $(e.target).is(data.formElements)) { + data.isMoved = true; + swiper.allowClick = false; + return; + } + } + if (data.allowTouchCallbacks) { + swiper.emit('touchMove', e); + } + if (e.targetTouches && e.targetTouches.length > 1) { return; } + + touches.currentX = pageX; + touches.currentY = pageY; + + var diffX = touches.currentX - touches.startX; + var diffY = touches.currentY - touches.startY; + + if (typeof data.isScrolling === 'undefined') { + var touchAngle; + if ((swiper.isHorizontal() && touches.currentY === touches.startY) || (swiper.isVertical() && touches.currentX === touches.startX)) { + data.isScrolling = false; + } else { + // eslint-disable-next-line + if ((diffX * diffX) + (diffY * diffY) >= 25) { + touchAngle = (Math.atan2(Math.abs(diffY), Math.abs(diffX)) * 180) / Math.PI; + data.isScrolling = swiper.isHorizontal() ? touchAngle > params.touchAngle : (90 - touchAngle > params.touchAngle); + } + } + } + if (data.isScrolling) { + swiper.emit('touchMoveOpposite', e); + } + if (typeof startMoving === 'undefined') { + if (touches.currentX !== touches.startX || touches.currentY !== touches.startY) { + data.startMoving = true; + } + } + if (data.isScrolling) { + data.isTouched = false; + return; + } + if (!data.startMoving) { + return; + } + swiper.allowClick = false; + e.preventDefault(); + if (params.touchMoveStopPropagation && !params.nested) { + e.stopPropagation(); + } + + if (!data.isMoved) { + if (params.loop) { + swiper.loopFix(); + } + data.startTranslate = swiper.getTranslate(); + swiper.setTransition(0); + if (swiper.animating) { + swiper.$wrapperEl.trigger('webkitTransitionEnd transitionend'); + } + data.allowMomentumBounce = false; + // Grab Cursor + if (params.grabCursor && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) { + swiper.setGrabCursor(true); + } + swiper.emit('sliderFirstMove', e); + } + swiper.emit('sliderMove', e); + data.isMoved = true; + + var diff = swiper.isHorizontal() ? diffX : diffY; + touches.diff = diff; + + diff *= params.touchRatio; + if (rtl) { diff = -diff; } + + swiper.swipeDirection = diff > 0 ? 'prev' : 'next'; + data.currentTranslate = diff + data.startTranslate; + + var disableParentSwiper = true; + var resistanceRatio = params.resistanceRatio; + if (params.touchReleaseOnEdges) { + resistanceRatio = 0; + } + if ((diff > 0 && data.currentTranslate > swiper.minTranslate())) { + disableParentSwiper = false; + if (params.resistance) { data.currentTranslate = (swiper.minTranslate() - 1) + (Math.pow( (-swiper.minTranslate() + data.startTranslate + diff), resistanceRatio )); } + } else if (diff < 0 && data.currentTranslate < swiper.maxTranslate()) { + disableParentSwiper = false; + if (params.resistance) { data.currentTranslate = (swiper.maxTranslate() + 1) - (Math.pow( (swiper.maxTranslate() - data.startTranslate - diff), resistanceRatio )); } + } + + if (disableParentSwiper) { + e.preventedByNestedSwiper = true; + } + + // Directions locks + if (!swiper.allowSlideNext && swiper.swipeDirection === 'next' && data.currentTranslate < data.startTranslate) { + data.currentTranslate = data.startTranslate; + } + if (!swiper.allowSlidePrev && swiper.swipeDirection === 'prev' && data.currentTranslate > data.startTranslate) { + data.currentTranslate = data.startTranslate; + } + + + // Threshold + if (params.threshold > 0) { + if (Math.abs(diff) > params.threshold || data.allowThresholdMove) { + if (!data.allowThresholdMove) { + data.allowThresholdMove = true; + touches.startX = touches.currentX; + touches.startY = touches.currentY; + data.currentTranslate = data.startTranslate; + touches.diff = swiper.isHorizontal() ? touches.currentX - touches.startX : touches.currentY - touches.startY; + return; + } + } else { + data.currentTranslate = data.startTranslate; + return; + } + } + + if (!params.followFinger) { return; } + + // Update active index in free mode + if (params.freeMode || params.watchSlidesProgress || params.watchSlidesVisibility) { + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + if (params.freeMode) { + // Velocity + if (data.velocities.length === 0) { + data.velocities.push({ + position: touches[swiper.isHorizontal() ? 'startX' : 'startY'], + time: data.touchStartTime, + }); + } + data.velocities.push({ + position: touches[swiper.isHorizontal() ? 'currentX' : 'currentY'], + time: Utils.now(), + }); + } + // Update progress + swiper.updateProgress(data.currentTranslate); + // Update translate + swiper.setTranslate(data.currentTranslate); + } + + function onTouchEnd (event) { + var swiper = this; + var data = swiper.touchEventsData; + + var params = swiper.params; + var touches = swiper.touches; + var rtl = swiper.rtlTranslate; + var $wrapperEl = swiper.$wrapperEl; + var slidesGrid = swiper.slidesGrid; + var snapGrid = swiper.snapGrid; + var e = event; + if (e.originalEvent) { e = e.originalEvent; } + if (data.allowTouchCallbacks) { + swiper.emit('touchEnd', e); + } + data.allowTouchCallbacks = false; + if (!data.isTouched) { + if (data.isMoved && params.grabCursor) { + swiper.setGrabCursor(false); + } + data.isMoved = false; + data.startMoving = false; + return; + } + // Return Grab Cursor + if (params.grabCursor && data.isMoved && data.isTouched && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) { + swiper.setGrabCursor(false); + } + + // Time diff + var touchEndTime = Utils.now(); + var timeDiff = touchEndTime - data.touchStartTime; + + // Tap, doubleTap, Click + if (swiper.allowClick) { + swiper.updateClickedSlide(e); + swiper.emit('tap', e); + if (timeDiff < 300 && (touchEndTime - data.lastClickTime) > 300) { + if (data.clickTimeout) { clearTimeout(data.clickTimeout); } + data.clickTimeout = Utils.nextTick(function () { + if (!swiper || swiper.destroyed) { return; } + swiper.emit('click', e); + }, 300); + } + if (timeDiff < 300 && (touchEndTime - data.lastClickTime) < 300) { + if (data.clickTimeout) { clearTimeout(data.clickTimeout); } + swiper.emit('doubleTap', e); + } + } + + data.lastClickTime = Utils.now(); + Utils.nextTick(function () { + if (!swiper.destroyed) { swiper.allowClick = true; } + }); + + if (!data.isTouched || !data.isMoved || !swiper.swipeDirection || touches.diff === 0 || data.currentTranslate === data.startTranslate) { + data.isTouched = false; + data.isMoved = false; + data.startMoving = false; + return; + } + data.isTouched = false; + data.isMoved = false; + data.startMoving = false; + + var currentPos; + if (params.followFinger) { + currentPos = rtl ? swiper.translate : -swiper.translate; + } else { + currentPos = -data.currentTranslate; + } + + if (params.freeMode) { + if (currentPos < -swiper.minTranslate()) { + swiper.slideTo(swiper.activeIndex); + return; + } else if (currentPos > -swiper.maxTranslate()) { + if (swiper.slides.length < snapGrid.length) { + swiper.slideTo(snapGrid.length - 1); + } else { + swiper.slideTo(swiper.slides.length - 1); + } + return; + } + + if (params.freeModeMomentum) { + if (data.velocities.length > 1) { + var lastMoveEvent = data.velocities.pop(); + var velocityEvent = data.velocities.pop(); + + var distance = lastMoveEvent.position - velocityEvent.position; + var time = lastMoveEvent.time - velocityEvent.time; + swiper.velocity = distance / time; + swiper.velocity /= 2; + if (Math.abs(swiper.velocity) < params.freeModeMinimumVelocity) { + swiper.velocity = 0; + } + // this implies that the user stopped moving a finger then released. + // There would be no events with distance zero, so the last event is stale. + if (time > 150 || (Utils.now() - lastMoveEvent.time) > 300) { + swiper.velocity = 0; + } + } else { + swiper.velocity = 0; + } + swiper.velocity *= params.freeModeMomentumVelocityRatio; + + data.velocities.length = 0; + var momentumDuration = 1000 * params.freeModeMomentumRatio; + var momentumDistance = swiper.velocity * momentumDuration; + + var newPosition = swiper.translate + momentumDistance; + if (rtl) { newPosition = -newPosition; } + + var doBounce = false; + var afterBouncePosition; + var bounceAmount = Math.abs(swiper.velocity) * 20 * params.freeModeMomentumBounceRatio; + var needsLoopFix; + if (newPosition < swiper.maxTranslate()) { + if (params.freeModeMomentumBounce) { + if (newPosition + swiper.maxTranslate() < -bounceAmount) { + newPosition = swiper.maxTranslate() - bounceAmount; + } + afterBouncePosition = swiper.maxTranslate(); + doBounce = true; + data.allowMomentumBounce = true; + } else { + newPosition = swiper.maxTranslate(); + } + if (params.loop && params.centeredSlides) { needsLoopFix = true; } + } else if (newPosition > swiper.minTranslate()) { + if (params.freeModeMomentumBounce) { + if (newPosition - swiper.minTranslate() > bounceAmount) { + newPosition = swiper.minTranslate() + bounceAmount; + } + afterBouncePosition = swiper.minTranslate(); + doBounce = true; + data.allowMomentumBounce = true; + } else { + newPosition = swiper.minTranslate(); + } + if (params.loop && params.centeredSlides) { needsLoopFix = true; } + } else if (params.freeModeSticky) { + var nextSlide; + for (var j = 0; j < snapGrid.length; j += 1) { + if (snapGrid[j] > -newPosition) { + nextSlide = j; + break; + } + } + + if (Math.abs(snapGrid[nextSlide] - newPosition) < Math.abs(snapGrid[nextSlide - 1] - newPosition) || swiper.swipeDirection === 'next') { + newPosition = snapGrid[nextSlide]; + } else { + newPosition = snapGrid[nextSlide - 1]; + } + newPosition = -newPosition; + } + if (needsLoopFix) { + swiper.once('transitionEnd', function () { + swiper.loopFix(); + }); + } + // Fix duration + if (swiper.velocity !== 0) { + if (rtl) { + momentumDuration = Math.abs((-newPosition - swiper.translate) / swiper.velocity); + } else { + momentumDuration = Math.abs((newPosition - swiper.translate) / swiper.velocity); + } + } else if (params.freeModeSticky) { + swiper.slideToClosest(); + return; + } + + if (params.freeModeMomentumBounce && doBounce) { + swiper.updateProgress(afterBouncePosition); + swiper.setTransition(momentumDuration); + swiper.setTranslate(newPosition); + swiper.transitionStart(true, swiper.swipeDirection); + swiper.animating = true; + $wrapperEl.transitionEnd(function () { + if (!swiper || swiper.destroyed || !data.allowMomentumBounce) { return; } + swiper.emit('momentumBounce'); + + swiper.setTransition(params.speed); + swiper.setTranslate(afterBouncePosition); + $wrapperEl.transitionEnd(function () { + if (!swiper || swiper.destroyed) { return; } + swiper.transitionEnd(); + }); + }); + } else if (swiper.velocity) { + swiper.updateProgress(newPosition); + swiper.setTransition(momentumDuration); + swiper.setTranslate(newPosition); + swiper.transitionStart(true, swiper.swipeDirection); + if (!swiper.animating) { + swiper.animating = true; + $wrapperEl.transitionEnd(function () { + if (!swiper || swiper.destroyed) { return; } + swiper.transitionEnd(); + }); + } + } else { + swiper.updateProgress(newPosition); + } + + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } else if (params.freeModeSticky) { + swiper.slideToClosest(); + return; + } + + if (!params.freeModeMomentum || timeDiff >= params.longSwipesMs) { + swiper.updateProgress(); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + return; + } + + // Find current slide + var stopIndex = 0; + var groupSize = swiper.slidesSizesGrid[0]; + for (var i = 0; i < slidesGrid.length; i += params.slidesPerGroup) { + if (typeof slidesGrid[i + params.slidesPerGroup] !== 'undefined') { + if (currentPos >= slidesGrid[i] && currentPos < slidesGrid[i + params.slidesPerGroup]) { + stopIndex = i; + groupSize = slidesGrid[i + params.slidesPerGroup] - slidesGrid[i]; + } + } else if (currentPos >= slidesGrid[i]) { + stopIndex = i; + groupSize = slidesGrid[slidesGrid.length - 1] - slidesGrid[slidesGrid.length - 2]; + } + } + + // Find current slide size + var ratio = (currentPos - slidesGrid[stopIndex]) / groupSize; + + if (timeDiff > params.longSwipesMs) { + // Long touches + if (!params.longSwipes) { + swiper.slideTo(swiper.activeIndex); + return; + } + if (swiper.swipeDirection === 'next') { + if (ratio >= params.longSwipesRatio) { swiper.slideTo(stopIndex + params.slidesPerGroup); } + else { swiper.slideTo(stopIndex); } + } + if (swiper.swipeDirection === 'prev') { + if (ratio > (1 - params.longSwipesRatio)) { swiper.slideTo(stopIndex + params.slidesPerGroup); } + else { swiper.slideTo(stopIndex); } + } + } else { + // Short swipes + if (!params.shortSwipes) { + swiper.slideTo(swiper.activeIndex); + return; + } + if (swiper.swipeDirection === 'next') { + swiper.slideTo(stopIndex + params.slidesPerGroup); + } + if (swiper.swipeDirection === 'prev') { + swiper.slideTo(stopIndex); + } + } + } + + function onResize () { + var swiper = this; + + var params = swiper.params; + var el = swiper.el; + + if (el && el.offsetWidth === 0) { return; } + + // Breakpoints + if (params.breakpoints) { + swiper.setBreakpoint(); + } + + // Save locks + var allowSlideNext = swiper.allowSlideNext; + var allowSlidePrev = swiper.allowSlidePrev; + var snapGrid = swiper.snapGrid; + + // Disable locks on resize + swiper.allowSlideNext = true; + swiper.allowSlidePrev = true; + + swiper.updateSize(); + swiper.updateSlides(); + + if (params.freeMode) { + var newTranslate = Math.min(Math.max(swiper.translate, swiper.maxTranslate()), swiper.minTranslate()); + swiper.setTranslate(newTranslate); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + + if (params.autoHeight) { + swiper.updateAutoHeight(); + } + } else { + swiper.updateSlidesClasses(); + if ((params.slidesPerView === 'auto' || params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) { + swiper.slideTo(swiper.slides.length - 1, 0, false, true); + } else { + swiper.slideTo(swiper.activeIndex, 0, false, true); + } + } + // Return locks after resize + swiper.allowSlidePrev = allowSlidePrev; + swiper.allowSlideNext = allowSlideNext; + + if (swiper.params.watchOverflow && snapGrid !== swiper.snapGrid) { + swiper.checkOverflow(); + } + } + + function onClick (e) { + var swiper = this; + if (!swiper.allowClick) { + if (swiper.params.preventClicks) { e.preventDefault(); } + if (swiper.params.preventClicksPropagation && swiper.animating) { + e.stopPropagation(); + e.stopImmediatePropagation(); + } + } + } + + function attachEvents() { + var swiper = this; + var params = swiper.params; + var touchEvents = swiper.touchEvents; + var el = swiper.el; + var wrapperEl = swiper.wrapperEl; + + { + swiper.onTouchStart = onTouchStart.bind(swiper); + swiper.onTouchMove = onTouchMove.bind(swiper); + swiper.onTouchEnd = onTouchEnd.bind(swiper); + } + + swiper.onClick = onClick.bind(swiper); + + var target = params.touchEventsTarget === 'container' ? el : wrapperEl; + var capture = !!params.nested; + + // Touch Events + { + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.addEventListener(touchEvents.start, swiper.onTouchStart, false); + doc.addEventListener(touchEvents.move, swiper.onTouchMove, capture); + doc.addEventListener(touchEvents.end, swiper.onTouchEnd, false); + } else { + if (Support.touch) { + var passiveListener = touchEvents.start === 'touchstart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false; + target.addEventListener(touchEvents.start, swiper.onTouchStart, passiveListener); + target.addEventListener(touchEvents.move, swiper.onTouchMove, Support.passiveListener ? { passive: false, capture: capture } : capture); + target.addEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.addEventListener('mousedown', swiper.onTouchStart, false); + doc.addEventListener('mousemove', swiper.onTouchMove, capture); + doc.addEventListener('mouseup', swiper.onTouchEnd, false); + } + } + // Prevent Links Clicks + if (params.preventClicks || params.preventClicksPropagation) { + target.addEventListener('click', swiper.onClick, true); + } + } + + // Resize handler + swiper.on('resize observerUpdate', onResize, true); + } + + function detachEvents() { + var swiper = this; + + var params = swiper.params; + var touchEvents = swiper.touchEvents; + var el = swiper.el; + var wrapperEl = swiper.wrapperEl; + + var target = params.touchEventsTarget === 'container' ? el : wrapperEl; + var capture = !!params.nested; + + // Touch Events + { + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.removeEventListener(touchEvents.start, swiper.onTouchStart, false); + doc.removeEventListener(touchEvents.move, swiper.onTouchMove, capture); + doc.removeEventListener(touchEvents.end, swiper.onTouchEnd, false); + } else { + if (Support.touch) { + var passiveListener = touchEvents.start === 'onTouchStart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false; + target.removeEventListener(touchEvents.start, swiper.onTouchStart, passiveListener); + target.removeEventListener(touchEvents.move, swiper.onTouchMove, capture); + target.removeEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.removeEventListener('mousedown', swiper.onTouchStart, false); + doc.removeEventListener('mousemove', swiper.onTouchMove, capture); + doc.removeEventListener('mouseup', swiper.onTouchEnd, false); + } + } + // Prevent Links Clicks + if (params.preventClicks || params.preventClicksPropagation) { + target.removeEventListener('click', swiper.onClick, true); + } + } + + // Resize handler + swiper.off('resize observerUpdate', onResize); + } + + var events = { + attachEvents: attachEvents, + detachEvents: detachEvents, + }; + + function setBreakpoint () { + var swiper = this; + var activeIndex = swiper.activeIndex; + var initialized = swiper.initialized; + var loopedSlides = swiper.loopedSlides; if ( loopedSlides === void 0 ) loopedSlides = 0; + var params = swiper.params; + var breakpoints = params.breakpoints; + if (!breakpoints || (breakpoints && Object.keys(breakpoints).length === 0)) { return; } + // Set breakpoint for window width and update parameters + var breakpoint = swiper.getBreakpoint(breakpoints); + if (breakpoint && swiper.currentBreakpoint !== breakpoint) { + var breakPointsParams = breakpoint in breakpoints ? breakpoints[breakpoint] : swiper.originalParams; + var needsReLoop = params.loop && (breakPointsParams.slidesPerView !== params.slidesPerView); + + Utils.extend(swiper.params, breakPointsParams); + + Utils.extend(swiper, { + allowTouchMove: swiper.params.allowTouchMove, + allowSlideNext: swiper.params.allowSlideNext, + allowSlidePrev: swiper.params.allowSlidePrev, + }); + + swiper.currentBreakpoint = breakpoint; + + if (needsReLoop && initialized) { + swiper.loopDestroy(); + swiper.loopCreate(); + swiper.updateSlides(); + swiper.slideTo((activeIndex - loopedSlides) + swiper.loopedSlides, 0, false); + } + swiper.emit('breakpoint', breakPointsParams); + } + } + + function getBreakpoint (breakpoints) { + // Get breakpoint for window width + if (!breakpoints) { return undefined; } + var breakpoint = false; + var points = []; + Object.keys(breakpoints).forEach(function (point) { + points.push(point); + }); + points.sort(function (a, b) { return parseInt(a, 10) - parseInt(b, 10); }); + for (var i = 0; i < points.length; i += 1) { + var point = points[i]; + if (point >= win.innerWidth && !breakpoint) { + breakpoint = point; + } + } + return breakpoint || 'max'; + } + + var breakpoints = { setBreakpoint: setBreakpoint, getBreakpoint: getBreakpoint }; + + var Browser = (function Browser() { + function isSafari() { + var ua = win.navigator.userAgent.toLowerCase(); + return (ua.indexOf('safari') >= 0 && ua.indexOf('chrome') < 0 && ua.indexOf('android') < 0); + } + return { + isIE: !!win.navigator.userAgent.match(/Trident/g) || !!win.navigator.userAgent.match(/MSIE/g), + isSafari: isSafari(), + isUiWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(win.navigator.userAgent), + }; + }()); + + function addClasses () { + var swiper = this; + var classNames = swiper.classNames; + var params = swiper.params; + var rtl = swiper.rtl; + var $el = swiper.$el; + var suffixes = []; + + suffixes.push(params.direction); + + if (params.freeMode) { + suffixes.push('free-mode'); + } + if (!Support.flexbox) { + suffixes.push('no-flexbox'); + } + if (params.autoHeight) { + suffixes.push('autoheight'); + } + if (rtl) { + suffixes.push('rtl'); + } + if (params.slidesPerColumn > 1) { + suffixes.push('multirow'); + } + if (Device.android) { + suffixes.push('android'); + } + if (Device.ios) { + suffixes.push('ios'); + } + // WP8 Touch Events Fix + if (Browser.isIE && (Support.pointerEvents || Support.prefixedPointerEvents)) { + suffixes.push(("wp8-" + (params.direction))); + } + + suffixes.forEach(function (suffix) { + classNames.push(params.containerModifierClass + suffix); + }); + + $el.addClass(classNames.join(' ')); + } + + function removeClasses () { + var swiper = this; + var $el = swiper.$el; + var classNames = swiper.classNames; + + $el.removeClass(classNames.join(' ')); + } + + var classes = { addClasses: addClasses, removeClasses: removeClasses }; + + function loadImage (imageEl, src, srcset, sizes, checkForComplete, callback) { + var image; + function onReady() { + if (callback) { callback(); } + } + if (!imageEl.complete || !checkForComplete) { + if (src) { + image = new win.Image(); + image.onload = onReady; + image.onerror = onReady; + if (sizes) { + image.sizes = sizes; + } + if (srcset) { + image.srcset = srcset; + } + if (src) { + image.src = src; + } + } else { + onReady(); + } + } else { + // image already loaded... + onReady(); + } + } + + function preloadImages () { + var swiper = this; + swiper.imagesToLoad = swiper.$el.find('img'); + function onReady() { + if (typeof swiper === 'undefined' || swiper === null || !swiper || swiper.destroyed) { return; } + if (swiper.imagesLoaded !== undefined) { swiper.imagesLoaded += 1; } + if (swiper.imagesLoaded === swiper.imagesToLoad.length) { + if (swiper.params.updateOnImagesReady) { swiper.update(); } + swiper.emit('imagesReady'); + } + } + for (var i = 0; i < swiper.imagesToLoad.length; i += 1) { + var imageEl = swiper.imagesToLoad[i]; + swiper.loadImage( + imageEl, + imageEl.currentSrc || imageEl.getAttribute('src'), + imageEl.srcset || imageEl.getAttribute('srcset'), + imageEl.sizes || imageEl.getAttribute('sizes'), + true, + onReady + ); + } + } + + var images = { + loadImage: loadImage, + preloadImages: preloadImages, + }; + + function checkOverflow() { + var swiper = this; + var wasLocked = swiper.isLocked; + + swiper.isLocked = swiper.snapGrid.length === 1; + swiper.allowSlideNext = !swiper.isLocked; + swiper.allowSlidePrev = !swiper.isLocked; + + // events + if (wasLocked !== swiper.isLocked) { swiper.emit(swiper.isLocked ? 'lock' : 'unlock'); } + + if (wasLocked && wasLocked !== swiper.isLocked) { + swiper.isEnd = false; + swiper.navigation.update(); + } + } + + var checkOverflow$1 = { checkOverflow: checkOverflow }; + + var defaults = { + init: true, + direction: 'horizontal', + touchEventsTarget: 'container', + initialSlide: 0, + speed: 300, + // + preventIntercationOnTransition: false, + + // To support iOS's swipe-to-go-back gesture (when being used in-app, with UIWebView). + iOSEdgeSwipeDetection: false, + iOSEdgeSwipeThreshold: 20, + + // Free mode + freeMode: false, + freeModeMomentum: true, + freeModeMomentumRatio: 1, + freeModeMomentumBounce: true, + freeModeMomentumBounceRatio: 1, + freeModeMomentumVelocityRatio: 1, + freeModeSticky: false, + freeModeMinimumVelocity: 0.02, + + // Autoheight + autoHeight: false, + + // Set wrapper width + setWrapperSize: false, + + // Virtual Translate + virtualTranslate: false, + + // Effects + effect: 'slide', // 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip' + + // Breakpoints + breakpoints: undefined, + + // Slides grid + spaceBetween: 0, + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerColumnFill: 'column', + slidesPerGroup: 1, + centeredSlides: false, + slidesOffsetBefore: 0, // in px + slidesOffsetAfter: 0, // in px + normalizeSlideIndex: true, + + // Disable swiper and hide navigation when container not overflow + watchOverflow: false, + + // Round length + roundLengths: false, + + // Touches + touchRatio: 1, + touchAngle: 45, + simulateTouch: true, + shortSwipes: true, + longSwipes: true, + longSwipesRatio: 0.5, + longSwipesMs: 300, + followFinger: true, + allowTouchMove: true, + threshold: 0, + touchMoveStopPropagation: true, + touchReleaseOnEdges: false, + + // Unique Navigation Elements + uniqueNavElements: true, + + // Resistance + resistance: true, + resistanceRatio: 0.85, + + // Progress + watchSlidesProgress: false, + watchSlidesVisibility: false, + + // Cursor + grabCursor: false, + + // Clicks + preventClicks: true, + preventClicksPropagation: true, + slideToClickedSlide: false, + + // Images + preloadImages: true, + updateOnImagesReady: true, + + // loop + loop: false, + loopAdditionalSlides: 0, + loopedSlides: null, + loopFillGroupWithBlank: false, + + // Swiping/no swiping + allowSlidePrev: true, + allowSlideNext: true, + swipeHandler: null, // '.swipe-handler', + noSwiping: true, + noSwipingClass: 'swiper-no-swiping', + noSwipingSelector: null, + + // Passive Listeners + passiveListeners: true, + + // NS + containerModifierClass: 'swiper-container-', // NEW + slideClass: 'swiper-slide', + slideBlankClass: 'swiper-slide-invisible-blank', + slideActiveClass: 'swiper-slide-active', + slideDuplicateActiveClass: 'swiper-slide-duplicate-active', + slideVisibleClass: 'swiper-slide-visible', + slideDuplicateClass: 'swiper-slide-duplicate', + slideNextClass: 'swiper-slide-next', + slideDuplicateNextClass: 'swiper-slide-duplicate-next', + slidePrevClass: 'swiper-slide-prev', + slideDuplicatePrevClass: 'swiper-slide-duplicate-prev', + wrapperClass: 'swiper-wrapper', + + // Callbacks + runCallbacksOnInit: true, + }; + + var prototypes = { + update: update, + translate: translate, + transition: transition$1, + slide: slide, + loop: loop, + grabCursor: grabCursor, + manipulation: manipulation, + events: events, + breakpoints: breakpoints, + checkOverflow: checkOverflow$1, + classes: classes, + images: images, + }; + + var extendedDefaults = {}; + + var Swiper = (function (SwiperClass$$1) { + function Swiper() { + var assign; + + var args = [], len = arguments.length; + while ( len-- ) args[ len ] = arguments[ len ]; + var el; + var params; + if (args.length === 1 && args[0].constructor && args[0].constructor === Object) { + params = args[0]; + } else { + (assign = args, el = assign[0], params = assign[1]); + } + if (!params) { params = {}; } + + params = Utils.extend({}, params); + if (el && !params.el) { params.el = el; } + + SwiperClass$$1.call(this, params); + + Object.keys(prototypes).forEach(function (prototypeGroup) { + Object.keys(prototypes[prototypeGroup]).forEach(function (protoMethod) { + if (!Swiper.prototype[protoMethod]) { + Swiper.prototype[protoMethod] = prototypes[prototypeGroup][protoMethod]; + } + }); + }); + + // Swiper Instance + var swiper = this; + if (typeof swiper.modules === 'undefined') { + swiper.modules = {}; + } + Object.keys(swiper.modules).forEach(function (moduleName) { + var module = swiper.modules[moduleName]; + if (module.params) { + var moduleParamName = Object.keys(module.params)[0]; + var moduleParams = module.params[moduleParamName]; + if (typeof moduleParams !== 'object') { return; } + if (!(moduleParamName in params && 'enabled' in moduleParams)) { return; } + if (params[moduleParamName] === true) { + params[moduleParamName] = { enabled: true }; + } + if ( + typeof params[moduleParamName] === 'object' && + !('enabled' in params[moduleParamName]) + ) { + params[moduleParamName].enabled = true; + } + if (!params[moduleParamName]) { params[moduleParamName] = { enabled: false }; } + } + }); + + // Extend defaults with modules params + var swiperParams = Utils.extend({}, defaults); + swiper.useModulesParams(swiperParams); + + // Extend defaults with passed params + swiper.params = Utils.extend({}, swiperParams, extendedDefaults, params); + swiper.originalParams = Utils.extend({}, swiper.params); + swiper.passedParams = Utils.extend({}, params); + + // Save Dom lib + swiper.$ = $; + + // Find el + var $el = $(swiper.params.el); + el = $el[0]; + + if (!el) { + return undefined; + } + + if ($el.length > 1) { + var swipers = []; + $el.each(function (index, containerEl) { + var newParams = Utils.extend({}, params, { el: containerEl }); + swipers.push(new Swiper(newParams)); + }); + return swipers; + } + + el.swiper = swiper; + $el.data('swiper', swiper); + + // Find Wrapper + var $wrapperEl = $el.children(("." + (swiper.params.wrapperClass))); + + // Extend Swiper + Utils.extend(swiper, { + $el: $el, + el: el, + $wrapperEl: $wrapperEl, + wrapperEl: $wrapperEl[0], + + // Classes + classNames: [], + + // Slides + slides: $(), + slidesGrid: [], + snapGrid: [], + slidesSizesGrid: [], + + // isDirection + isHorizontal: function isHorizontal() { + return swiper.params.direction === 'horizontal'; + }, + isVertical: function isVertical() { + return swiper.params.direction === 'vertical'; + }, + // RTL + rtl: (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'), + rtlTranslate: swiper.params.direction === 'horizontal' && (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'), + wrongRTL: $wrapperEl.css('display') === '-webkit-box', + + // Indexes + activeIndex: 0, + realIndex: 0, + + // + isBeginning: true, + isEnd: false, + + // Props + translate: 0, + progress: 0, + velocity: 0, + animating: false, + + // Locks + allowSlideNext: swiper.params.allowSlideNext, + allowSlidePrev: swiper.params.allowSlidePrev, + + // Touch Events + touchEvents: (function touchEvents() { + var touch = ['touchstart', 'touchmove', 'touchend']; + var desktop = ['mousedown', 'mousemove', 'mouseup']; + if (Support.pointerEvents) { + desktop = ['pointerdown', 'pointermove', 'pointerup']; + } else if (Support.prefixedPointerEvents) { + desktop = ['MSPointerDown', 'MSPointerMove', 'MSPointerUp']; + } + swiper.touchEventsTouch = { + start: touch[0], + move: touch[1], + end: touch[2], + }; + swiper.touchEventsDesktop = { + start: desktop[0], + move: desktop[1], + end: desktop[2], + }; + return Support.touch || !swiper.params.simulateTouch ? swiper.touchEventsTouch : swiper.touchEventsDesktop; + }()), + touchEventsData: { + isTouched: undefined, + isMoved: undefined, + allowTouchCallbacks: undefined, + touchStartTime: undefined, + isScrolling: undefined, + currentTranslate: undefined, + startTranslate: undefined, + allowThresholdMove: undefined, + // Form elements to match + formElements: 'input, select, option, textarea, button, video', + // Last click time + lastClickTime: Utils.now(), + clickTimeout: undefined, + // Velocities + velocities: [], + allowMomentumBounce: undefined, + isTouchEvent: undefined, + startMoving: undefined, + }, + + // Clicks + allowClick: true, + + // Touches + allowTouchMove: swiper.params.allowTouchMove, + + touches: { + startX: 0, + startY: 0, + currentX: 0, + currentY: 0, + diff: 0, + }, + + // Images + imagesToLoad: [], + imagesLoaded: 0, + + }); + + // Install Modules + swiper.useModules(); + + // Init + if (swiper.params.init) { + swiper.init(); + } + + // Return app instance + return swiper; + } + + if ( SwiperClass$$1 ) Swiper.__proto__ = SwiperClass$$1; + Swiper.prototype = Object.create( SwiperClass$$1 && SwiperClass$$1.prototype ); + Swiper.prototype.constructor = Swiper; + + var staticAccessors = { extendedDefaults: { configurable: true },defaults: { configurable: true },Class: { configurable: true },$: { configurable: true } }; + Swiper.prototype.slidesPerViewDynamic = function slidesPerViewDynamic () { + var swiper = this; + var params = swiper.params; + var slides = swiper.slides; + var slidesGrid = swiper.slidesGrid; + var swiperSize = swiper.size; + var activeIndex = swiper.activeIndex; + var spv = 1; + if (params.centeredSlides) { + var slideSize = slides[activeIndex].swiperSlideSize; + var breakLoop; + for (var i = activeIndex + 1; i < slides.length; i += 1) { + if (slides[i] && !breakLoop) { + slideSize += slides[i].swiperSlideSize; + spv += 1; + if (slideSize > swiperSize) { breakLoop = true; } + } + } + for (var i$1 = activeIndex - 1; i$1 >= 0; i$1 -= 1) { + if (slides[i$1] && !breakLoop) { + slideSize += slides[i$1].swiperSlideSize; + spv += 1; + if (slideSize > swiperSize) { breakLoop = true; } + } + } + } else { + for (var i$2 = activeIndex + 1; i$2 < slides.length; i$2 += 1) { + if (slidesGrid[i$2] - slidesGrid[activeIndex] < swiperSize) { + spv += 1; + } + } + } + return spv; + }; + Swiper.prototype.update = function update$$1 () { + var swiper = this; + if (!swiper || swiper.destroyed) { return; } + var snapGrid = swiper.snapGrid; + var params = swiper.params; + // Breakpoints + if (params.breakpoints) { + swiper.setBreakpoint(); + } + swiper.updateSize(); + swiper.updateSlides(); + swiper.updateProgress(); + swiper.updateSlidesClasses(); + + function setTranslate() { + var translateValue = swiper.rtlTranslate ? swiper.translate * -1 : swiper.translate; + var newTranslate = Math.min(Math.max(translateValue, swiper.maxTranslate()), swiper.minTranslate()); + swiper.setTranslate(newTranslate); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + } + var translated; + if (swiper.params.freeMode) { + setTranslate(); + if (swiper.params.autoHeight) { + swiper.updateAutoHeight(); + } + } else { + if ((swiper.params.slidesPerView === 'auto' || swiper.params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) { + translated = swiper.slideTo(swiper.slides.length - 1, 0, false, true); + } else { + translated = swiper.slideTo(swiper.activeIndex, 0, false, true); + } + if (!translated) { + setTranslate(); + } + } + if (params.watchOverflow && snapGrid !== swiper.snapGrid) { + swiper.checkOverflow(); + } + swiper.emit('update'); + }; + Swiper.prototype.init = function init () { + var swiper = this; + if (swiper.initialized) { return; } + + swiper.emit('beforeInit'); + + // Set breakpoint + if (swiper.params.breakpoints) { + swiper.setBreakpoint(); + } + + // Add Classes + swiper.addClasses(); + + // Create loop + if (swiper.params.loop) { + swiper.loopCreate(); + } + + // Update size + swiper.updateSize(); + + // Update slides + swiper.updateSlides(); + + if (swiper.params.watchOverflow) { + swiper.checkOverflow(); + } + + // Set Grab Cursor + if (swiper.params.grabCursor) { + swiper.setGrabCursor(); + } + + if (swiper.params.preloadImages) { + swiper.preloadImages(); + } + + // Slide To Initial Slide + if (swiper.params.loop) { + swiper.slideTo(swiper.params.initialSlide + swiper.loopedSlides, 0, swiper.params.runCallbacksOnInit); + } else { + swiper.slideTo(swiper.params.initialSlide, 0, swiper.params.runCallbacksOnInit); + } + + // Attach events + swiper.attachEvents(); + + // Init Flag + swiper.initialized = true; + + // Emit + swiper.emit('init'); + }; + Swiper.prototype.destroy = function destroy (deleteInstance, cleanStyles) { + if ( deleteInstance === void 0 ) deleteInstance = true; + if ( cleanStyles === void 0 ) cleanStyles = true; + + var swiper = this; + var params = swiper.params; + var $el = swiper.$el; + var $wrapperEl = swiper.$wrapperEl; + var slides = swiper.slides; + + if (typeof swiper.params === 'undefined' || swiper.destroyed) { + return null; + } + + swiper.emit('beforeDestroy'); + + // Init Flag + swiper.initialized = false; + + // Detach events + swiper.detachEvents(); + + // Destroy loop + if (params.loop) { + swiper.loopDestroy(); + } + + // Cleanup styles + if (cleanStyles) { + swiper.removeClasses(); + $el.removeAttr('style'); + $wrapperEl.removeAttr('style'); + if (slides && slides.length) { + slides + .removeClass([ + params.slideVisibleClass, + params.slideActiveClass, + params.slideNextClass, + params.slidePrevClass ].join(' ')) + .removeAttr('style') + .removeAttr('data-swiper-slide-index') + .removeAttr('data-swiper-column') + .removeAttr('data-swiper-row'); + } + } + + swiper.emit('destroy'); + + // Detach emitter events + Object.keys(swiper.eventsListeners).forEach(function (eventName) { + swiper.off(eventName); + }); + + if (deleteInstance !== false) { + swiper.$el[0].swiper = null; + swiper.$el.data('swiper', null); + Utils.deleteProps(swiper); + } + swiper.destroyed = true; + + return null; + }; + Swiper.extendDefaults = function extendDefaults (newDefaults) { + Utils.extend(extendedDefaults, newDefaults); + }; + staticAccessors.extendedDefaults.get = function () { + return extendedDefaults; + }; + staticAccessors.defaults.get = function () { + return defaults; + }; + staticAccessors.Class.get = function () { + return SwiperClass$$1; + }; + staticAccessors.$.get = function () { + return $; + }; + + Object.defineProperties( Swiper, staticAccessors ); + + return Swiper; + }(SwiperClass)); + + var Device$1 = { + name: 'device', + proto: { + device: Device, + }, + static: { + device: Device, + }, + }; + + var Support$1 = { + name: 'support', + proto: { + support: Support, + }, + static: { + support: Support, + }, + }; + + var Browser$1 = { + name: 'browser', + proto: { + browser: Browser, + }, + static: { + browser: Browser, + }, + }; + + var Resize = { + name: 'resize', + create: function create() { + var swiper = this; + Utils.extend(swiper, { + resize: { + resizeHandler: function resizeHandler() { + if (!swiper || swiper.destroyed || !swiper.initialized) { return; } + swiper.emit('beforeResize'); + swiper.emit('resize'); + }, + orientationChangeHandler: function orientationChangeHandler() { + if (!swiper || swiper.destroyed || !swiper.initialized) { return; } + swiper.emit('orientationchange'); + }, + }, + }); + }, + on: { + init: function init() { + var swiper = this; + // Emit resize + win.addEventListener('resize', swiper.resize.resizeHandler); + + // Emit orientationchange + win.addEventListener('orientationchange', swiper.resize.orientationChangeHandler); + }, + destroy: function destroy() { + var swiper = this; + win.removeEventListener('resize', swiper.resize.resizeHandler); + win.removeEventListener('orientationchange', swiper.resize.orientationChangeHandler); + }, + }, + }; + + var Observer = { + func: win.MutationObserver || win.WebkitMutationObserver, + attach: function attach(target, options) { + if ( options === void 0 ) options = {}; + + var swiper = this; + + var ObserverFunc = Observer.func; + var observer = new ObserverFunc(function (mutations) { + mutations.forEach(function (mutation) { + swiper.emit('observerUpdate', mutation); + }); + }); + + observer.observe(target, { + attributes: typeof options.attributes === 'undefined' ? true : options.attributes, + childList: typeof options.childList === 'undefined' ? true : options.childList, + characterData: typeof options.characterData === 'undefined' ? true : options.characterData, + }); + + swiper.observer.observers.push(observer); + }, + init: function init() { + var swiper = this; + if (!Support.observer || !swiper.params.observer) { return; } + if (swiper.params.observeParents) { + var containerParents = swiper.$el.parents(); + for (var i = 0; i < containerParents.length; i += 1) { + swiper.observer.attach(containerParents[i]); + } + } + // Observe container + swiper.observer.attach(swiper.$el[0], { childList: false }); + + // Observe wrapper + swiper.observer.attach(swiper.$wrapperEl[0], { attributes: false }); + }, + destroy: function destroy() { + var swiper = this; + swiper.observer.observers.forEach(function (observer) { + observer.disconnect(); + }); + swiper.observer.observers = []; + }, + }; + + var Observer$1 = { + name: 'observer', + params: { + observer: false, + observeParents: false, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + observer: { + init: Observer.init.bind(swiper), + attach: Observer.attach.bind(swiper), + destroy: Observer.destroy.bind(swiper), + observers: [], + }, + }); + }, + on: { + init: function init() { + var swiper = this; + swiper.observer.init(); + }, + destroy: function destroy() { + var swiper = this; + swiper.observer.destroy(); + }, + }, + }; + + var Virtual = { + update: function update(force) { + var swiper = this; + var ref = swiper.params; + var slidesPerView = ref.slidesPerView; + var slidesPerGroup = ref.slidesPerGroup; + var centeredSlides = ref.centeredSlides; + var ref$1 = swiper.virtual; + var previousFrom = ref$1.from; + var previousTo = ref$1.to; + var slides = ref$1.slides; + var previousSlidesGrid = ref$1.slidesGrid; + var renderSlide = ref$1.renderSlide; + var previousOffset = ref$1.offset; + swiper.updateActiveIndex(); + var activeIndex = swiper.activeIndex || 0; + + var offsetProp; + if (swiper.rtlTranslate) { offsetProp = 'right'; } + else { offsetProp = swiper.isHorizontal() ? 'left' : 'top'; } + + var slidesAfter; + var slidesBefore; + if (centeredSlides) { + slidesAfter = Math.floor(slidesPerView / 2) + slidesPerGroup; + slidesBefore = Math.floor(slidesPerView / 2) + slidesPerGroup; + } else { + slidesAfter = slidesPerView + (slidesPerGroup - 1); + slidesBefore = slidesPerGroup; + } + var from = Math.max((activeIndex || 0) - slidesBefore, 0); + var to = Math.min((activeIndex || 0) + slidesAfter, slides.length - 1); + var offset = (swiper.slidesGrid[from] || 0) - (swiper.slidesGrid[0] || 0); + + Utils.extend(swiper.virtual, { + from: from, + to: to, + offset: offset, + slidesGrid: swiper.slidesGrid, + }); + + function onRendered() { + swiper.updateSlides(); + swiper.updateProgress(); + swiper.updateSlidesClasses(); + if (swiper.lazy && swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + } + + if (previousFrom === from && previousTo === to && !force) { + if (swiper.slidesGrid !== previousSlidesGrid && offset !== previousOffset) { + swiper.slides.css(offsetProp, (offset + "px")); + } + swiper.updateProgress(); + return; + } + if (swiper.params.virtual.renderExternal) { + swiper.params.virtual.renderExternal.call(swiper, { + offset: offset, + from: from, + to: to, + slides: (function getSlides() { + var slidesToRender = []; + for (var i = from; i <= to; i += 1) { + slidesToRender.push(slides[i]); + } + return slidesToRender; + }()), + }); + onRendered(); + return; + } + var prependIndexes = []; + var appendIndexes = []; + if (force) { + swiper.$wrapperEl.find(("." + (swiper.params.slideClass))).remove(); + } else { + for (var i = previousFrom; i <= previousTo; i += 1) { + if (i < from || i > to) { + swiper.$wrapperEl.find(("." + (swiper.params.slideClass) + "[data-swiper-slide-index=\"" + i + "\"]")).remove(); + } + } + } + for (var i$1 = 0; i$1 < slides.length; i$1 += 1) { + if (i$1 >= from && i$1 <= to) { + if (typeof previousTo === 'undefined' || force) { + appendIndexes.push(i$1); + } else { + if (i$1 > previousTo) { appendIndexes.push(i$1); } + if (i$1 < previousFrom) { prependIndexes.push(i$1); } + } + } + } + appendIndexes.forEach(function (index) { + swiper.$wrapperEl.append(renderSlide(slides[index], index)); + }); + prependIndexes.sort(function (a, b) { return a < b; }).forEach(function (index) { + swiper.$wrapperEl.prepend(renderSlide(slides[index], index)); + }); + swiper.$wrapperEl.children('.swiper-slide').css(offsetProp, (offset + "px")); + onRendered(); + }, + renderSlide: function renderSlide(slide, index) { + var swiper = this; + var params = swiper.params.virtual; + if (params.cache && swiper.virtual.cache[index]) { + return swiper.virtual.cache[index]; + } + var $slideEl = params.renderSlide + ? $(params.renderSlide.call(swiper, slide, index)) + : $(("
    " + slide + "
    ")); + if (!$slideEl.attr('data-swiper-slide-index')) { $slideEl.attr('data-swiper-slide-index', index); } + if (params.cache) { swiper.virtual.cache[index] = $slideEl; } + return $slideEl; + }, + appendSlide: function appendSlide(slide) { + var swiper = this; + swiper.virtual.slides.push(slide); + swiper.virtual.update(true); + }, + prependSlide: function prependSlide(slide) { + var swiper = this; + swiper.virtual.slides.unshift(slide); + if (swiper.params.virtual.cache) { + var cache = swiper.virtual.cache; + var newCache = {}; + Object.keys(cache).forEach(function (cachedIndex) { + newCache[cachedIndex + 1] = cache[cachedIndex]; + }); + swiper.virtual.cache = newCache; + } + swiper.virtual.update(true); + swiper.slideNext(0); + }, + }; + + var Virtual$1 = { + name: 'virtual', + params: { + virtual: { + enabled: false, + slides: [], + cache: true, + renderSlide: null, + renderExternal: null, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + virtual: { + update: Virtual.update.bind(swiper), + appendSlide: Virtual.appendSlide.bind(swiper), + prependSlide: Virtual.prependSlide.bind(swiper), + renderSlide: Virtual.renderSlide.bind(swiper), + slides: swiper.params.virtual.slides, + cache: {}, + }, + }); + }, + on: { + beforeInit: function beforeInit() { + var swiper = this; + if (!swiper.params.virtual.enabled) { return; } + swiper.classNames.push(((swiper.params.containerModifierClass) + "virtual")); + var overwriteParams = { + watchSlidesProgress: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + + swiper.virtual.update(); + }, + setTranslate: function setTranslate() { + var swiper = this; + if (!swiper.params.virtual.enabled) { return; } + swiper.virtual.update(); + }, + }, + }; + + var Keyboard = { + handle: function handle(event) { + var swiper = this; + var rtl = swiper.rtlTranslate; + var e = event; + if (e.originalEvent) { e = e.originalEvent; } // jquery fix + var kc = e.keyCode || e.charCode; + // Directions locks + if (!swiper.allowSlideNext && ((swiper.isHorizontal() && kc === 39) || (swiper.isVertical() && kc === 40))) { + return false; + } + if (!swiper.allowSlidePrev && ((swiper.isHorizontal() && kc === 37) || (swiper.isVertical() && kc === 38))) { + return false; + } + if (e.shiftKey || e.altKey || e.ctrlKey || e.metaKey) { + return undefined; + } + if (doc.activeElement && doc.activeElement.nodeName && (doc.activeElement.nodeName.toLowerCase() === 'input' || doc.activeElement.nodeName.toLowerCase() === 'textarea')) { + return undefined; + } + if (swiper.params.keyboard.onlyInViewport && (kc === 37 || kc === 39 || kc === 38 || kc === 40)) { + var inView = false; + // Check that swiper should be inside of visible area of window + if (swiper.$el.parents(("." + (swiper.params.slideClass))).length > 0 && swiper.$el.parents(("." + (swiper.params.slideActiveClass))).length === 0) { + return undefined; + } + var windowWidth = win.innerWidth; + var windowHeight = win.innerHeight; + var swiperOffset = swiper.$el.offset(); + if (rtl) { swiperOffset.left -= swiper.$el[0].scrollLeft; } + var swiperCoord = [ + [swiperOffset.left, swiperOffset.top], + [swiperOffset.left + swiper.width, swiperOffset.top], + [swiperOffset.left, swiperOffset.top + swiper.height], + [swiperOffset.left + swiper.width, swiperOffset.top + swiper.height] ]; + for (var i = 0; i < swiperCoord.length; i += 1) { + var point = swiperCoord[i]; + if ( + point[0] >= 0 && point[0] <= windowWidth && + point[1] >= 0 && point[1] <= windowHeight + ) { + inView = true; + } + } + if (!inView) { return undefined; } + } + if (swiper.isHorizontal()) { + if (kc === 37 || kc === 39) { + if (e.preventDefault) { e.preventDefault(); } + else { e.returnValue = false; } + } + if ((kc === 39 && !rtl) || (kc === 37 && rtl)) { swiper.slideNext(); } + if ((kc === 37 && !rtl) || (kc === 39 && rtl)) { swiper.slidePrev(); } + } else { + if (kc === 38 || kc === 40) { + if (e.preventDefault) { e.preventDefault(); } + else { e.returnValue = false; } + } + if (kc === 40) { swiper.slideNext(); } + if (kc === 38) { swiper.slidePrev(); } + } + swiper.emit('keyPress', kc); + return undefined; + }, + enable: function enable() { + var swiper = this; + if (swiper.keyboard.enabled) { return; } + $(doc).on('keydown', swiper.keyboard.handle); + swiper.keyboard.enabled = true; + }, + disable: function disable() { + var swiper = this; + if (!swiper.keyboard.enabled) { return; } + $(doc).off('keydown', swiper.keyboard.handle); + swiper.keyboard.enabled = false; + }, + }; + + var Keyboard$1 = { + name: 'keyboard', + params: { + keyboard: { + enabled: false, + onlyInViewport: true, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + keyboard: { + enabled: false, + enable: Keyboard.enable.bind(swiper), + disable: Keyboard.disable.bind(swiper), + handle: Keyboard.handle.bind(swiper), + }, + }); + }, + on: { + init: function init() { + var swiper = this; + if (swiper.params.keyboard.enabled) { + swiper.keyboard.enable(); + } + }, + destroy: function destroy() { + var swiper = this; + if (swiper.keyboard.enabled) { + swiper.keyboard.disable(); + } + }, + }, + }; + + function isEventSupported() { + var eventName = 'onwheel'; + var isSupported = eventName in doc; + + if (!isSupported) { + var element = doc.createElement('div'); + element.setAttribute(eventName, 'return;'); + isSupported = typeof element[eventName] === 'function'; + } + + if (!isSupported && + doc.implementation && + doc.implementation.hasFeature && + // always returns true in newer browsers as per the standard. + // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature + doc.implementation.hasFeature('', '') !== true + ) { + // This is the only way to test support for the `wheel` event in IE9+. + isSupported = doc.implementation.hasFeature('Events.wheel', '3.0'); + } + + return isSupported; + } + var Mousewheel = { + lastScrollTime: Utils.now(), + event: (function getEvent() { + if (win.navigator.userAgent.indexOf('firefox') > -1) { return 'DOMMouseScroll'; } + return isEventSupported() ? 'wheel' : 'mousewheel'; + }()), + normalize: function normalize(e) { + // Reasonable defaults + var PIXEL_STEP = 10; + var LINE_HEIGHT = 40; + var PAGE_HEIGHT = 800; + + var sX = 0; + var sY = 0; // spinX, spinY + var pX = 0; + var pY = 0; // pixelX, pixelY + + // Legacy + if ('detail' in e) { + sY = e.detail; + } + if ('wheelDelta' in e) { + sY = -e.wheelDelta / 120; + } + if ('wheelDeltaY' in e) { + sY = -e.wheelDeltaY / 120; + } + if ('wheelDeltaX' in e) { + sX = -e.wheelDeltaX / 120; + } + + // side scrolling on FF with DOMMouseScroll + if ('axis' in e && e.axis === e.HORIZONTAL_AXIS) { + sX = sY; + sY = 0; + } + + pX = sX * PIXEL_STEP; + pY = sY * PIXEL_STEP; + + if ('deltaY' in e) { + pY = e.deltaY; + } + if ('deltaX' in e) { + pX = e.deltaX; + } + + if ((pX || pY) && e.deltaMode) { + if (e.deltaMode === 1) { // delta in LINE units + pX *= LINE_HEIGHT; + pY *= LINE_HEIGHT; + } else { // delta in PAGE units + pX *= PAGE_HEIGHT; + pY *= PAGE_HEIGHT; + } + } + + // Fall-back if spin cannot be determined + if (pX && !sX) { + sX = (pX < 1) ? -1 : 1; + } + if (pY && !sY) { + sY = (pY < 1) ? -1 : 1; + } + + return { + spinX: sX, + spinY: sY, + pixelX: pX, + pixelY: pY, + }; + }, + handleMouseEnter: function handleMouseEnter() { + var swiper = this; + swiper.mouseEntered = true; + }, + handleMouseLeave: function handleMouseLeave() { + var swiper = this; + swiper.mouseEntered = false; + }, + handle: function handle(event) { + var e = event; + var swiper = this; + var params = swiper.params.mousewheel; + + if (!swiper.mouseEntered && !params.releaseOnEdges) { return true; } + + if (e.originalEvent) { e = e.originalEvent; } // jquery fix + var delta = 0; + var rtlFactor = swiper.rtlTranslate ? -1 : 1; + + var data = Mousewheel.normalize(e); + + if (params.forceToAxis) { + if (swiper.isHorizontal()) { + if (Math.abs(data.pixelX) > Math.abs(data.pixelY)) { delta = data.pixelX * rtlFactor; } + else { return true; } + } else if (Math.abs(data.pixelY) > Math.abs(data.pixelX)) { delta = data.pixelY; } + else { return true; } + } else { + delta = Math.abs(data.pixelX) > Math.abs(data.pixelY) ? -data.pixelX * rtlFactor : -data.pixelY; + } + + if (delta === 0) { return true; } + + if (params.invert) { delta = -delta; } + + if (!swiper.params.freeMode) { + if (Utils.now() - swiper.mousewheel.lastScrollTime > 60) { + if (delta < 0) { + if ((!swiper.isEnd || swiper.params.loop) && !swiper.animating) { + swiper.slideNext(); + swiper.emit('scroll', e); + } else if (params.releaseOnEdges) { return true; } + } else if ((!swiper.isBeginning || swiper.params.loop) && !swiper.animating) { + swiper.slidePrev(); + swiper.emit('scroll', e); + } else if (params.releaseOnEdges) { return true; } + } + swiper.mousewheel.lastScrollTime = (new win.Date()).getTime(); + } else { + // Freemode or scrollContainer: + if (swiper.params.loop) { + swiper.loopFix(); + } + var position = swiper.getTranslate() + (delta * params.sensitivity); + var wasBeginning = swiper.isBeginning; + var wasEnd = swiper.isEnd; + + if (position >= swiper.minTranslate()) { position = swiper.minTranslate(); } + if (position <= swiper.maxTranslate()) { position = swiper.maxTranslate(); } + + swiper.setTransition(0); + swiper.setTranslate(position); + swiper.updateProgress(); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + + if ((!wasBeginning && swiper.isBeginning) || (!wasEnd && swiper.isEnd)) { + swiper.updateSlidesClasses(); + } + + if (swiper.params.freeModeSticky) { + clearTimeout(swiper.mousewheel.timeout); + swiper.mousewheel.timeout = Utils.nextTick(function () { + swiper.slideToClosest(); + }, 300); + } + // Emit event + swiper.emit('scroll', e); + + // Stop autoplay + if (swiper.params.autoplay && swiper.params.autoplayDisableOnInteraction) { swiper.stopAutoplay(); } + // Return page scroll on edge positions + if (position === swiper.minTranslate() || position === swiper.maxTranslate()) { return true; } + } + + if (e.preventDefault) { e.preventDefault(); } + else { e.returnValue = false; } + return false; + }, + enable: function enable() { + var swiper = this; + if (!Mousewheel.event) { return false; } + if (swiper.mousewheel.enabled) { return false; } + var target = swiper.$el; + if (swiper.params.mousewheel.eventsTarged !== 'container') { + target = $(swiper.params.mousewheel.eventsTarged); + } + target.on('mouseenter', swiper.mousewheel.handleMouseEnter); + target.on('mouseleave', swiper.mousewheel.handleMouseLeave); + target.on(Mousewheel.event, swiper.mousewheel.handle); + swiper.mousewheel.enabled = true; + return true; + }, + disable: function disable() { + var swiper = this; + if (!Mousewheel.event) { return false; } + if (!swiper.mousewheel.enabled) { return false; } + var target = swiper.$el; + if (swiper.params.mousewheel.eventsTarged !== 'container') { + target = $(swiper.params.mousewheel.eventsTarged); + } + target.off(Mousewheel.event, swiper.mousewheel.handle); + swiper.mousewheel.enabled = false; + return true; + }, + }; + + var Mousewheel$1 = { + name: 'mousewheel', + params: { + mousewheel: { + enabled: false, + releaseOnEdges: false, + invert: false, + forceToAxis: false, + sensitivity: 1, + eventsTarged: 'container', + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + mousewheel: { + enabled: false, + enable: Mousewheel.enable.bind(swiper), + disable: Mousewheel.disable.bind(swiper), + handle: Mousewheel.handle.bind(swiper), + handleMouseEnter: Mousewheel.handleMouseEnter.bind(swiper), + handleMouseLeave: Mousewheel.handleMouseLeave.bind(swiper), + lastScrollTime: Utils.now(), + }, + }); + }, + on: { + init: function init() { + var swiper = this; + if (swiper.params.mousewheel.enabled) { swiper.mousewheel.enable(); } + }, + destroy: function destroy() { + var swiper = this; + if (swiper.mousewheel.enabled) { swiper.mousewheel.disable(); } + }, + }, + }; + + var Navigation = { + update: function update() { + // Update Navigation Buttons + var swiper = this; + var params = swiper.params.navigation; + + if (swiper.params.loop) { return; } + var ref = swiper.navigation; + var $nextEl = ref.$nextEl; + var $prevEl = ref.$prevEl; + + if ($prevEl && $prevEl.length > 0) { + if (swiper.isBeginning) { + $prevEl.addClass(params.disabledClass); + } else { + $prevEl.removeClass(params.disabledClass); + } + $prevEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + } + if ($nextEl && $nextEl.length > 0) { + if (swiper.isEnd) { + $nextEl.addClass(params.disabledClass); + } else { + $nextEl.removeClass(params.disabledClass); + } + $nextEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + } + }, + init: function init() { + var swiper = this; + var params = swiper.params.navigation; + if (!(params.nextEl || params.prevEl)) { return; } + + var $nextEl; + var $prevEl; + if (params.nextEl) { + $nextEl = $(params.nextEl); + if ( + swiper.params.uniqueNavElements && + typeof params.nextEl === 'string' && + $nextEl.length > 1 && + swiper.$el.find(params.nextEl).length === 1 + ) { + $nextEl = swiper.$el.find(params.nextEl); + } + } + if (params.prevEl) { + $prevEl = $(params.prevEl); + if ( + swiper.params.uniqueNavElements && + typeof params.prevEl === 'string' && + $prevEl.length > 1 && + swiper.$el.find(params.prevEl).length === 1 + ) { + $prevEl = swiper.$el.find(params.prevEl); + } + } + + if ($nextEl && $nextEl.length > 0) { + $nextEl.on('click', function (e) { + e.preventDefault(); + if (swiper.isEnd && !swiper.params.loop) { return; } + swiper.slideNext(); + }); + } + if ($prevEl && $prevEl.length > 0) { + $prevEl.on('click', function (e) { + e.preventDefault(); + if (swiper.isBeginning && !swiper.params.loop) { return; } + swiper.slidePrev(); + }); + } + + Utils.extend(swiper.navigation, { + $nextEl: $nextEl, + nextEl: $nextEl && $nextEl[0], + $prevEl: $prevEl, + prevEl: $prevEl && $prevEl[0], + }); + }, + destroy: function destroy() { + var swiper = this; + var ref = swiper.navigation; + var $nextEl = ref.$nextEl; + var $prevEl = ref.$prevEl; + if ($nextEl && $nextEl.length) { + $nextEl.off('click'); + $nextEl.removeClass(swiper.params.navigation.disabledClass); + } + if ($prevEl && $prevEl.length) { + $prevEl.off('click'); + $prevEl.removeClass(swiper.params.navigation.disabledClass); + } + }, + }; + + var Navigation$1 = { + name: 'navigation', + params: { + navigation: { + nextEl: null, + prevEl: null, + + hideOnClick: false, + disabledClass: 'swiper-button-disabled', + hiddenClass: 'swiper-button-hidden', + lockClass: 'swiper-button-lock', + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + navigation: { + init: Navigation.init.bind(swiper), + update: Navigation.update.bind(swiper), + destroy: Navigation.destroy.bind(swiper), + }, + }); + }, + on: { + init: function init() { + var swiper = this; + swiper.navigation.init(); + swiper.navigation.update(); + }, + toEdge: function toEdge() { + var swiper = this; + swiper.navigation.update(); + }, + fromEdge: function fromEdge() { + var swiper = this; + swiper.navigation.update(); + }, + destroy: function destroy() { + var swiper = this; + swiper.navigation.destroy(); + }, + click: function click(e) { + var swiper = this; + var ref = swiper.navigation; + var $nextEl = ref.$nextEl; + var $prevEl = ref.$prevEl; + if ( + swiper.params.navigation.hideOnClick && + !$(e.target).is($prevEl) && + !$(e.target).is($nextEl) + ) { + if ($nextEl) { $nextEl.toggleClass(swiper.params.navigation.hiddenClass); } + if ($prevEl) { $prevEl.toggleClass(swiper.params.navigation.hiddenClass); } + } + }, + }, + }; + + var Pagination = { + update: function update() { + // Render || Update Pagination bullets/items + var swiper = this; + var rtl = swiper.rtl; + var params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) { return; } + var slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length; + var $el = swiper.pagination.$el; + // Current/Total + var current; + var total = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length; + if (swiper.params.loop) { + current = Math.ceil((swiper.activeIndex - swiper.loopedSlides) / swiper.params.slidesPerGroup); + if (current > slidesLength - 1 - (swiper.loopedSlides * 2)) { + current -= (slidesLength - (swiper.loopedSlides * 2)); + } + if (current > total - 1) { current -= total; } + if (current < 0 && swiper.params.paginationType !== 'bullets') { current = total + current; } + } else if (typeof swiper.snapIndex !== 'undefined') { + current = swiper.snapIndex; + } else { + current = swiper.activeIndex || 0; + } + // Types + if (params.type === 'bullets' && swiper.pagination.bullets && swiper.pagination.bullets.length > 0) { + var bullets = swiper.pagination.bullets; + var firstIndex; + var lastIndex; + var midIndex; + if (params.dynamicBullets) { + swiper.pagination.bulletSize = bullets.eq(0)[swiper.isHorizontal() ? 'outerWidth' : 'outerHeight'](true); + $el.css(swiper.isHorizontal() ? 'width' : 'height', ((swiper.pagination.bulletSize * (params.dynamicMainBullets + 4)) + "px")); + if (params.dynamicMainBullets > 1 && swiper.previousIndex !== undefined) { + swiper.pagination.dynamicBulletIndex += (current - swiper.previousIndex); + if (swiper.pagination.dynamicBulletIndex > (params.dynamicMainBullets - 1)) { + swiper.pagination.dynamicBulletIndex = params.dynamicMainBullets - 1; + } else if (swiper.pagination.dynamicBulletIndex < 0) { + swiper.pagination.dynamicBulletIndex = 0; + } + } + firstIndex = current - swiper.pagination.dynamicBulletIndex; + lastIndex = firstIndex + (Math.min(bullets.length, params.dynamicMainBullets) - 1); + midIndex = (lastIndex + firstIndex) / 2; + } + bullets.removeClass(((params.bulletActiveClass) + " " + (params.bulletActiveClass) + "-next " + (params.bulletActiveClass) + "-next-next " + (params.bulletActiveClass) + "-prev " + (params.bulletActiveClass) + "-prev-prev " + (params.bulletActiveClass) + "-main")); + if ($el.length > 1) { + bullets.each(function (index, bullet) { + var $bullet = $(bullet); + var bulletIndex = $bullet.index(); + if (bulletIndex === current) { + $bullet.addClass(params.bulletActiveClass); + } + if (params.dynamicBullets) { + if (bulletIndex >= firstIndex && bulletIndex <= lastIndex) { + $bullet.addClass(((params.bulletActiveClass) + "-main")); + } + if (bulletIndex === firstIndex) { + $bullet + .prev() + .addClass(((params.bulletActiveClass) + "-prev")) + .prev() + .addClass(((params.bulletActiveClass) + "-prev-prev")); + } + if (bulletIndex === lastIndex) { + $bullet + .next() + .addClass(((params.bulletActiveClass) + "-next")) + .next() + .addClass(((params.bulletActiveClass) + "-next-next")); + } + } + }); + } else { + var $bullet = bullets.eq(current); + $bullet.addClass(params.bulletActiveClass); + if (params.dynamicBullets) { + var $firstDisplayedBullet = bullets.eq(firstIndex); + var $lastDisplayedBullet = bullets.eq(lastIndex); + for (var i = firstIndex; i <= lastIndex; i += 1) { + bullets.eq(i).addClass(((params.bulletActiveClass) + "-main")); + } + $firstDisplayedBullet + .prev() + .addClass(((params.bulletActiveClass) + "-prev")) + .prev() + .addClass(((params.bulletActiveClass) + "-prev-prev")); + $lastDisplayedBullet + .next() + .addClass(((params.bulletActiveClass) + "-next")) + .next() + .addClass(((params.bulletActiveClass) + "-next-next")); + } + } + if (params.dynamicBullets) { + var dynamicBulletsLength = Math.min(bullets.length, params.dynamicMainBullets + 4); + var bulletsOffset = (((swiper.pagination.bulletSize * dynamicBulletsLength) - (swiper.pagination.bulletSize)) / 2) - (midIndex * swiper.pagination.bulletSize); + var offsetProp = rtl ? 'right' : 'left'; + bullets.css(swiper.isHorizontal() ? offsetProp : 'top', (bulletsOffset + "px")); + } + } + if (params.type === 'fraction') { + $el.find(("." + (params.currentClass))).text(current + 1); + $el.find(("." + (params.totalClass))).text(total); + } + if (params.type === 'progressbar') { + var progressbarDirection; + if (params.progressbarOpposite) { + progressbarDirection = swiper.isHorizontal() ? 'vertical' : 'horizontal'; + } else { + progressbarDirection = swiper.isHorizontal() ? 'horizontal' : 'vertical'; + } + var scale = (current + 1) / total; + var scaleX = 1; + var scaleY = 1; + if (progressbarDirection === 'horizontal') { + scaleX = scale; + } else { + scaleY = scale; + } + $el.find(("." + (params.progressbarFillClass))).transform(("translate3d(0,0,0) scaleX(" + scaleX + ") scaleY(" + scaleY + ")")).transition(swiper.params.speed); + } + if (params.type === 'custom' && params.renderCustom) { + $el.html(params.renderCustom(swiper, current + 1, total)); + swiper.emit('paginationRender', swiper, $el[0]); + } else { + swiper.emit('paginationUpdate', swiper, $el[0]); + } + $el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass); + }, + render: function render() { + // Render Container + var swiper = this; + var params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) { return; } + var slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length; + + var $el = swiper.pagination.$el; + var paginationHTML = ''; + if (params.type === 'bullets') { + var numberOfBullets = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length; + for (var i = 0; i < numberOfBullets; i += 1) { + if (params.renderBullet) { + paginationHTML += params.renderBullet.call(swiper, i, params.bulletClass); + } else { + paginationHTML += "<" + (params.bulletElement) + " class=\"" + (params.bulletClass) + "\">"; + } + } + $el.html(paginationHTML); + swiper.pagination.bullets = $el.find(("." + (params.bulletClass))); + } + if (params.type === 'fraction') { + if (params.renderFraction) { + paginationHTML = params.renderFraction.call(swiper, params.currentClass, params.totalClass); + } else { + paginationHTML = + "" + + ' / ' + + ""; + } + $el.html(paginationHTML); + } + if (params.type === 'progressbar') { + if (params.renderProgressbar) { + paginationHTML = params.renderProgressbar.call(swiper, params.progressbarFillClass); + } else { + paginationHTML = ""; + } + $el.html(paginationHTML); + } + if (params.type !== 'custom') { + swiper.emit('paginationRender', swiper.pagination.$el[0]); + } + }, + init: function init() { + var swiper = this; + var params = swiper.params.pagination; + if (!params.el) { return; } + + var $el = $(params.el); + if ($el.length === 0) { return; } + + if ( + swiper.params.uniqueNavElements && + typeof params.el === 'string' && + $el.length > 1 && + swiper.$el.find(params.el).length === 1 + ) { + $el = swiper.$el.find(params.el); + } + + if (params.type === 'bullets' && params.clickable) { + $el.addClass(params.clickableClass); + } + + $el.addClass(params.modifierClass + params.type); + + if (params.type === 'bullets' && params.dynamicBullets) { + $el.addClass(("" + (params.modifierClass) + (params.type) + "-dynamic")); + swiper.pagination.dynamicBulletIndex = 0; + if (params.dynamicMainBullets < 1) { + params.dynamicMainBullets = 1; + } + } + if (params.type === 'progressbar' && params.progressbarOpposite) { + $el.addClass(params.progressbarOppositeClass); + } + + if (params.clickable) { + $el.on('click', ("." + (params.bulletClass)), function onClick(e) { + e.preventDefault(); + var index = $(this).index() * swiper.params.slidesPerGroup; + if (swiper.params.loop) { index += swiper.loopedSlides; } + swiper.slideTo(index); + }); + } + + Utils.extend(swiper.pagination, { + $el: $el, + el: $el[0], + }); + }, + destroy: function destroy() { + var swiper = this; + var params = swiper.params.pagination; + if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) { return; } + var $el = swiper.pagination.$el; + + $el.removeClass(params.hiddenClass); + $el.removeClass(params.modifierClass + params.type); + if (swiper.pagination.bullets) { swiper.pagination.bullets.removeClass(params.bulletActiveClass); } + if (params.clickable) { + $el.off('click', ("." + (params.bulletClass))); + } + }, + }; + + var Pagination$1 = { + name: 'pagination', + params: { + pagination: { + el: null, + bulletElement: 'span', + clickable: false, + hideOnClick: false, + renderBullet: null, + renderProgressbar: null, + renderFraction: null, + renderCustom: null, + progressbarOpposite: false, + type: 'bullets', // 'bullets' or 'progressbar' or 'fraction' or 'custom' + dynamicBullets: false, + dynamicMainBullets: 1, + bulletClass: 'swiper-pagination-bullet', + bulletActiveClass: 'swiper-pagination-bullet-active', + modifierClass: 'swiper-pagination-', // NEW + currentClass: 'swiper-pagination-current', + totalClass: 'swiper-pagination-total', + hiddenClass: 'swiper-pagination-hidden', + progressbarFillClass: 'swiper-pagination-progressbar-fill', + progressbarOppositeClass: 'swiper-pagination-progressbar-opposite', + clickableClass: 'swiper-pagination-clickable', // NEW + lockClass: 'swiper-pagination-lock', + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + pagination: { + init: Pagination.init.bind(swiper), + render: Pagination.render.bind(swiper), + update: Pagination.update.bind(swiper), + destroy: Pagination.destroy.bind(swiper), + dynamicBulletIndex: 0, + }, + }); + }, + on: { + init: function init() { + var swiper = this; + swiper.pagination.init(); + swiper.pagination.render(); + swiper.pagination.update(); + }, + activeIndexChange: function activeIndexChange() { + var swiper = this; + if (swiper.params.loop) { + swiper.pagination.update(); + } else if (typeof swiper.snapIndex === 'undefined') { + swiper.pagination.update(); + } + }, + snapIndexChange: function snapIndexChange() { + var swiper = this; + if (!swiper.params.loop) { + swiper.pagination.update(); + } + }, + slidesLengthChange: function slidesLengthChange() { + var swiper = this; + if (swiper.params.loop) { + swiper.pagination.render(); + swiper.pagination.update(); + } + }, + snapGridLengthChange: function snapGridLengthChange() { + var swiper = this; + if (!swiper.params.loop) { + swiper.pagination.render(); + swiper.pagination.update(); + } + }, + destroy: function destroy() { + var swiper = this; + swiper.pagination.destroy(); + }, + click: function click(e) { + var swiper = this; + if ( + swiper.params.pagination.el && + swiper.params.pagination.hideOnClick && + swiper.pagination.$el.length > 0 && + !$(e.target).hasClass(swiper.params.pagination.bulletClass) + ) { + swiper.pagination.$el.toggleClass(swiper.params.pagination.hiddenClass); + } + }, + }, + }; + + var Scrollbar = { + setTranslate: function setTranslate() { + var swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) { return; } + var scrollbar = swiper.scrollbar; + var rtl = swiper.rtlTranslate; + var progress = swiper.progress; + var dragSize = scrollbar.dragSize; + var trackSize = scrollbar.trackSize; + var $dragEl = scrollbar.$dragEl; + var $el = scrollbar.$el; + var params = swiper.params.scrollbar; + + var newSize = dragSize; + var newPos = (trackSize - dragSize) * progress; + if (rtl) { + newPos = -newPos; + if (newPos > 0) { + newSize = dragSize - newPos; + newPos = 0; + } else if (-newPos + dragSize > trackSize) { + newSize = trackSize + newPos; + } + } else if (newPos < 0) { + newSize = dragSize + newPos; + newPos = 0; + } else if (newPos + dragSize > trackSize) { + newSize = trackSize - newPos; + } + if (swiper.isHorizontal()) { + if (Support.transforms3d) { + $dragEl.transform(("translate3d(" + newPos + "px, 0, 0)")); + } else { + $dragEl.transform(("translateX(" + newPos + "px)")); + } + $dragEl[0].style.width = newSize + "px"; + } else { + if (Support.transforms3d) { + $dragEl.transform(("translate3d(0px, " + newPos + "px, 0)")); + } else { + $dragEl.transform(("translateY(" + newPos + "px)")); + } + $dragEl[0].style.height = newSize + "px"; + } + if (params.hide) { + clearTimeout(swiper.scrollbar.timeout); + $el[0].style.opacity = 1; + swiper.scrollbar.timeout = setTimeout(function () { + $el[0].style.opacity = 0; + $el.transition(400); + }, 1000); + } + }, + setTransition: function setTransition(duration) { + var swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) { return; } + swiper.scrollbar.$dragEl.transition(duration); + }, + updateSize: function updateSize() { + var swiper = this; + if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) { return; } + + var scrollbar = swiper.scrollbar; + var $dragEl = scrollbar.$dragEl; + var $el = scrollbar.$el; + + $dragEl[0].style.width = ''; + $dragEl[0].style.height = ''; + var trackSize = swiper.isHorizontal() ? $el[0].offsetWidth : $el[0].offsetHeight; + + var divider = swiper.size / swiper.virtualSize; + var moveDivider = divider * (trackSize / swiper.size); + var dragSize; + if (swiper.params.scrollbar.dragSize === 'auto') { + dragSize = trackSize * divider; + } else { + dragSize = parseInt(swiper.params.scrollbar.dragSize, 10); + } + + if (swiper.isHorizontal()) { + $dragEl[0].style.width = dragSize + "px"; + } else { + $dragEl[0].style.height = dragSize + "px"; + } + + if (divider >= 1) { + $el[0].style.display = 'none'; + } else { + $el[0].style.display = ''; + } + if (swiper.params.scrollbarHide) { + $el[0].style.opacity = 0; + } + Utils.extend(scrollbar, { + trackSize: trackSize, + divider: divider, + moveDivider: moveDivider, + dragSize: dragSize, + }); + scrollbar.$el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](swiper.params.scrollbar.lockClass); + }, + setDragPosition: function setDragPosition(e) { + var swiper = this; + var scrollbar = swiper.scrollbar; + var rtl = swiper.rtlTranslate; + var $el = scrollbar.$el; + var dragSize = scrollbar.dragSize; + var trackSize = scrollbar.trackSize; + + var pointerPosition; + if (swiper.isHorizontal()) { + pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageX : e.pageX || e.clientX); + } else { + pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageY : e.pageY || e.clientY); + } + var positionRatio; + positionRatio = ((pointerPosition) - $el.offset()[swiper.isHorizontal() ? 'left' : 'top'] - (dragSize / 2)) / (trackSize - dragSize); + positionRatio = Math.max(Math.min(positionRatio, 1), 0); + if (rtl) { + positionRatio = 1 - positionRatio; + } + + var position = swiper.minTranslate() + ((swiper.maxTranslate() - swiper.minTranslate()) * positionRatio); + + swiper.updateProgress(position); + swiper.setTranslate(position); + swiper.updateActiveIndex(); + swiper.updateSlidesClasses(); + }, + onDragStart: function onDragStart(e) { + var swiper = this; + var params = swiper.params.scrollbar; + var scrollbar = swiper.scrollbar; + var $wrapperEl = swiper.$wrapperEl; + var $el = scrollbar.$el; + var $dragEl = scrollbar.$dragEl; + swiper.scrollbar.isTouched = true; + e.preventDefault(); + e.stopPropagation(); + + $wrapperEl.transition(100); + $dragEl.transition(100); + scrollbar.setDragPosition(e); + + clearTimeout(swiper.scrollbar.dragTimeout); + + $el.transition(0); + if (params.hide) { + $el.css('opacity', 1); + } + swiper.emit('scrollbarDragStart', e); + }, + onDragMove: function onDragMove(e) { + var swiper = this; + var scrollbar = swiper.scrollbar; + var $wrapperEl = swiper.$wrapperEl; + var $el = scrollbar.$el; + var $dragEl = scrollbar.$dragEl; + + if (!swiper.scrollbar.isTouched) { return; } + if (e.preventDefault) { e.preventDefault(); } + else { e.returnValue = false; } + scrollbar.setDragPosition(e); + $wrapperEl.transition(0); + $el.transition(0); + $dragEl.transition(0); + swiper.emit('scrollbarDragMove', e); + }, + onDragEnd: function onDragEnd(e) { + var swiper = this; + + var params = swiper.params.scrollbar; + var scrollbar = swiper.scrollbar; + var $el = scrollbar.$el; + + if (!swiper.scrollbar.isTouched) { return; } + swiper.scrollbar.isTouched = false; + if (params.hide) { + clearTimeout(swiper.scrollbar.dragTimeout); + swiper.scrollbar.dragTimeout = Utils.nextTick(function () { + $el.css('opacity', 0); + $el.transition(400); + }, 1000); + } + swiper.emit('scrollbarDragEnd', e); + if (params.snapOnRelease) { + swiper.slideToClosest(); + } + }, + enableDraggable: function enableDraggable() { + var swiper = this; + if (!swiper.params.scrollbar.el) { return; } + var scrollbar = swiper.scrollbar; + var touchEvents = swiper.touchEvents; + var touchEventsDesktop = swiper.touchEventsDesktop; + var params = swiper.params; + var $el = scrollbar.$el; + var target = $el[0]; + var activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false; + var passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false; + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.addEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener); + doc.addEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener); + doc.addEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener); + } else { + if (Support.touch) { + target.addEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener); + target.addEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener); + target.addEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.addEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener); + doc.addEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener); + doc.addEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener); + } + } + }, + disableDraggable: function disableDraggable() { + var swiper = this; + if (!swiper.params.scrollbar.el) { return; } + var scrollbar = swiper.scrollbar; + var touchEvents = swiper.touchEvents; + var touchEventsDesktop = swiper.touchEventsDesktop; + var params = swiper.params; + var $el = scrollbar.$el; + var target = $el[0]; + var activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false; + var passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false; + if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) { + target.removeEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener); + doc.removeEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener); + doc.removeEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener); + } else { + if (Support.touch) { + target.removeEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener); + target.removeEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener); + target.removeEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener); + } + if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) { + target.removeEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener); + doc.removeEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener); + doc.removeEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener); + } + } + }, + init: function init() { + var swiper = this; + if (!swiper.params.scrollbar.el) { return; } + var scrollbar = swiper.scrollbar; + var $swiperEl = swiper.$el; + var params = swiper.params.scrollbar; + + var $el = $(params.el); + if (swiper.params.uniqueNavElements && typeof params.el === 'string' && $el.length > 1 && $swiperEl.find(params.el).length === 1) { + $el = $swiperEl.find(params.el); + } + + var $dragEl = $el.find(("." + (swiper.params.scrollbar.dragClass))); + if ($dragEl.length === 0) { + $dragEl = $(("
    ")); + $el.append($dragEl); + } + + Utils.extend(scrollbar, { + $el: $el, + el: $el[0], + $dragEl: $dragEl, + dragEl: $dragEl[0], + }); + + if (params.draggable) { + scrollbar.enableDraggable(); + } + }, + destroy: function destroy() { + var swiper = this; + swiper.scrollbar.disableDraggable(); + }, + }; + + var Scrollbar$1 = { + name: 'scrollbar', + params: { + scrollbar: { + el: null, + dragSize: 'auto', + hide: false, + draggable: false, + snapOnRelease: true, + lockClass: 'swiper-scrollbar-lock', + dragClass: 'swiper-scrollbar-drag', + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + scrollbar: { + init: Scrollbar.init.bind(swiper), + destroy: Scrollbar.destroy.bind(swiper), + updateSize: Scrollbar.updateSize.bind(swiper), + setTranslate: Scrollbar.setTranslate.bind(swiper), + setTransition: Scrollbar.setTransition.bind(swiper), + enableDraggable: Scrollbar.enableDraggable.bind(swiper), + disableDraggable: Scrollbar.disableDraggable.bind(swiper), + setDragPosition: Scrollbar.setDragPosition.bind(swiper), + onDragStart: Scrollbar.onDragStart.bind(swiper), + onDragMove: Scrollbar.onDragMove.bind(swiper), + onDragEnd: Scrollbar.onDragEnd.bind(swiper), + isTouched: false, + timeout: null, + dragTimeout: null, + }, + }); + }, + on: { + init: function init() { + var swiper = this; + swiper.scrollbar.init(); + swiper.scrollbar.updateSize(); + swiper.scrollbar.setTranslate(); + }, + update: function update() { + var swiper = this; + swiper.scrollbar.updateSize(); + }, + resize: function resize() { + var swiper = this; + swiper.scrollbar.updateSize(); + }, + observerUpdate: function observerUpdate() { + var swiper = this; + swiper.scrollbar.updateSize(); + }, + setTranslate: function setTranslate() { + var swiper = this; + swiper.scrollbar.setTranslate(); + }, + setTransition: function setTransition(duration) { + var swiper = this; + swiper.scrollbar.setTransition(duration); + }, + destroy: function destroy() { + var swiper = this; + swiper.scrollbar.destroy(); + }, + }, + }; + + var Parallax = { + setTransform: function setTransform(el, progress) { + var swiper = this; + var rtl = swiper.rtl; + + var $el = $(el); + var rtlFactor = rtl ? -1 : 1; + + var p = $el.attr('data-swiper-parallax') || '0'; + var x = $el.attr('data-swiper-parallax-x'); + var y = $el.attr('data-swiper-parallax-y'); + var scale = $el.attr('data-swiper-parallax-scale'); + var opacity = $el.attr('data-swiper-parallax-opacity'); + + if (x || y) { + x = x || '0'; + y = y || '0'; + } else if (swiper.isHorizontal()) { + x = p; + y = '0'; + } else { + y = p; + x = '0'; + } + + if ((x).indexOf('%') >= 0) { + x = (parseInt(x, 10) * progress * rtlFactor) + "%"; + } else { + x = (x * progress * rtlFactor) + "px"; + } + if ((y).indexOf('%') >= 0) { + y = (parseInt(y, 10) * progress) + "%"; + } else { + y = (y * progress) + "px"; + } + + if (typeof opacity !== 'undefined' && opacity !== null) { + var currentOpacity = opacity - ((opacity - 1) * (1 - Math.abs(progress))); + $el[0].style.opacity = currentOpacity; + } + if (typeof scale === 'undefined' || scale === null) { + $el.transform(("translate3d(" + x + ", " + y + ", 0px)")); + } else { + var currentScale = scale - ((scale - 1) * (1 - Math.abs(progress))); + $el.transform(("translate3d(" + x + ", " + y + ", 0px) scale(" + currentScale + ")")); + } + }, + setTranslate: function setTranslate() { + var swiper = this; + var $el = swiper.$el; + var slides = swiper.slides; + var progress = swiper.progress; + var snapGrid = swiper.snapGrid; + $el.children('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each(function (index, el) { + swiper.parallax.setTransform(el, progress); + }); + slides.each(function (slideIndex, slideEl) { + var slideProgress = slideEl.progress; + if (swiper.params.slidesPerGroup > 1 && swiper.params.slidesPerView !== 'auto') { + slideProgress += Math.ceil(slideIndex / 2) - (progress * (snapGrid.length - 1)); + } + slideProgress = Math.min(Math.max(slideProgress, -1), 1); + $(slideEl).find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each(function (index, el) { + swiper.parallax.setTransform(el, slideProgress); + }); + }); + }, + setTransition: function setTransition(duration) { + if ( duration === void 0 ) duration = this.params.speed; + + var swiper = this; + var $el = swiper.$el; + $el.find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]') + .each(function (index, parallaxEl) { + var $parallaxEl = $(parallaxEl); + var parallaxDuration = parseInt($parallaxEl.attr('data-swiper-parallax-duration'), 10) || duration; + if (duration === 0) { parallaxDuration = 0; } + $parallaxEl.transition(parallaxDuration); + }); + }, + }; + + var Parallax$1 = { + name: 'parallax', + params: { + parallax: { + enabled: false, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + parallax: { + setTransform: Parallax.setTransform.bind(swiper), + setTranslate: Parallax.setTranslate.bind(swiper), + setTransition: Parallax.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit: function beforeInit() { + var swiper = this; + if (!swiper.params.parallax.enabled) { return; } + swiper.params.watchSlidesProgress = true; + }, + init: function init() { + var swiper = this; + if (!swiper.params.parallax) { return; } + swiper.parallax.setTranslate(); + }, + setTranslate: function setTranslate() { + var swiper = this; + if (!swiper.params.parallax) { return; } + swiper.parallax.setTranslate(); + }, + setTransition: function setTransition(duration) { + var swiper = this; + if (!swiper.params.parallax) { return; } + swiper.parallax.setTransition(duration); + }, + }, + }; + + var Zoom = { + // Calc Scale From Multi-touches + getDistanceBetweenTouches: function getDistanceBetweenTouches(e) { + if (e.targetTouches.length < 2) { return 1; } + var x1 = e.targetTouches[0].pageX; + var y1 = e.targetTouches[0].pageY; + var x2 = e.targetTouches[1].pageX; + var y2 = e.targetTouches[1].pageY; + var distance = Math.sqrt((Math.pow( (x2 - x1), 2 )) + (Math.pow( (y2 - y1), 2 ))); + return distance; + }, + // Events + onGestureStart: function onGestureStart(e) { + var swiper = this; + var params = swiper.params.zoom; + var zoom = swiper.zoom; + var gesture = zoom.gesture; + zoom.fakeGestureTouched = false; + zoom.fakeGestureMoved = false; + if (!Support.gestures) { + if (e.type !== 'touchstart' || (e.type === 'touchstart' && e.targetTouches.length < 2)) { + return; + } + zoom.fakeGestureTouched = true; + gesture.scaleStart = Zoom.getDistanceBetweenTouches(e); + } + if (!gesture.$slideEl || !gesture.$slideEl.length) { + gesture.$slideEl = $(e.target).closest('.swiper-slide'); + if (gesture.$slideEl.length === 0) { gesture.$slideEl = swiper.slides.eq(swiper.activeIndex); } + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(("." + (params.containerClass))); + gesture.maxRatio = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + if (gesture.$imageWrapEl.length === 0) { + gesture.$imageEl = undefined; + return; + } + } + gesture.$imageEl.transition(0); + swiper.zoom.isScaling = true; + }, + onGestureChange: function onGestureChange(e) { + var swiper = this; + var params = swiper.params.zoom; + var zoom = swiper.zoom; + var gesture = zoom.gesture; + if (!Support.gestures) { + if (e.type !== 'touchmove' || (e.type === 'touchmove' && e.targetTouches.length < 2)) { + return; + } + zoom.fakeGestureMoved = true; + gesture.scaleMove = Zoom.getDistanceBetweenTouches(e); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; } + if (Support.gestures) { + swiper.zoom.scale = e.scale * zoom.currentScale; + } else { + zoom.scale = (gesture.scaleMove / gesture.scaleStart) * zoom.currentScale; + } + if (zoom.scale > gesture.maxRatio) { + zoom.scale = (gesture.maxRatio - 1) + (Math.pow( ((zoom.scale - gesture.maxRatio) + 1), 0.5 )); + } + if (zoom.scale < params.minRatio) { + zoom.scale = (params.minRatio + 1) - (Math.pow( ((params.minRatio - zoom.scale) + 1), 0.5 )); + } + gesture.$imageEl.transform(("translate3d(0,0,0) scale(" + (zoom.scale) + ")")); + }, + onGestureEnd: function onGestureEnd(e) { + var swiper = this; + var params = swiper.params.zoom; + var zoom = swiper.zoom; + var gesture = zoom.gesture; + if (!Support.gestures) { + if (!zoom.fakeGestureTouched || !zoom.fakeGestureMoved) { + return; + } + if (e.type !== 'touchend' || (e.type === 'touchend' && e.changedTouches.length < 2 && !Device.android)) { + return; + } + zoom.fakeGestureTouched = false; + zoom.fakeGestureMoved = false; + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; } + zoom.scale = Math.max(Math.min(zoom.scale, gesture.maxRatio), params.minRatio); + gesture.$imageEl.transition(swiper.params.speed).transform(("translate3d(0,0,0) scale(" + (zoom.scale) + ")")); + zoom.currentScale = zoom.scale; + zoom.isScaling = false; + if (zoom.scale === 1) { gesture.$slideEl = undefined; } + }, + onTouchStart: function onTouchStart(e) { + var swiper = this; + var zoom = swiper.zoom; + var gesture = zoom.gesture; + var image = zoom.image; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; } + if (image.isTouched) { return; } + if (Device.android) { e.preventDefault(); } + image.isTouched = true; + image.touchesStart.x = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX; + image.touchesStart.y = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY; + }, + onTouchMove: function onTouchMove(e) { + var swiper = this; + var zoom = swiper.zoom; + var gesture = zoom.gesture; + var image = zoom.image; + var velocity = zoom.velocity; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; } + swiper.allowClick = false; + if (!image.isTouched || !gesture.$slideEl) { return; } + + if (!image.isMoved) { + image.width = gesture.$imageEl[0].offsetWidth; + image.height = gesture.$imageEl[0].offsetHeight; + image.startX = Utils.getTranslate(gesture.$imageWrapEl[0], 'x') || 0; + image.startY = Utils.getTranslate(gesture.$imageWrapEl[0], 'y') || 0; + gesture.slideWidth = gesture.$slideEl[0].offsetWidth; + gesture.slideHeight = gesture.$slideEl[0].offsetHeight; + gesture.$imageWrapEl.transition(0); + if (swiper.rtl) { + image.startX = -image.startX; + image.startY = -image.startY; + } + } + // Define if we need image drag + var scaledWidth = image.width * zoom.scale; + var scaledHeight = image.height * zoom.scale; + + if (scaledWidth < gesture.slideWidth && scaledHeight < gesture.slideHeight) { return; } + + image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0); + image.maxX = -image.minX; + image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0); + image.maxY = -image.minY; + + image.touchesCurrent.x = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX; + image.touchesCurrent.y = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY; + + if (!image.isMoved && !zoom.isScaling) { + if ( + swiper.isHorizontal() && + ( + (Math.floor(image.minX) === Math.floor(image.startX) && image.touchesCurrent.x < image.touchesStart.x) || + (Math.floor(image.maxX) === Math.floor(image.startX) && image.touchesCurrent.x > image.touchesStart.x) + ) + ) { + image.isTouched = false; + return; + } else if ( + !swiper.isHorizontal() && + ( + (Math.floor(image.minY) === Math.floor(image.startY) && image.touchesCurrent.y < image.touchesStart.y) || + (Math.floor(image.maxY) === Math.floor(image.startY) && image.touchesCurrent.y > image.touchesStart.y) + ) + ) { + image.isTouched = false; + return; + } + } + e.preventDefault(); + e.stopPropagation(); + + image.isMoved = true; + image.currentX = (image.touchesCurrent.x - image.touchesStart.x) + image.startX; + image.currentY = (image.touchesCurrent.y - image.touchesStart.y) + image.startY; + + if (image.currentX < image.minX) { + image.currentX = (image.minX + 1) - (Math.pow( ((image.minX - image.currentX) + 1), 0.8 )); + } + if (image.currentX > image.maxX) { + image.currentX = (image.maxX - 1) + (Math.pow( ((image.currentX - image.maxX) + 1), 0.8 )); + } + + if (image.currentY < image.minY) { + image.currentY = (image.minY + 1) - (Math.pow( ((image.minY - image.currentY) + 1), 0.8 )); + } + if (image.currentY > image.maxY) { + image.currentY = (image.maxY - 1) + (Math.pow( ((image.currentY - image.maxY) + 1), 0.8 )); + } + + // Velocity + if (!velocity.prevPositionX) { velocity.prevPositionX = image.touchesCurrent.x; } + if (!velocity.prevPositionY) { velocity.prevPositionY = image.touchesCurrent.y; } + if (!velocity.prevTime) { velocity.prevTime = Date.now(); } + velocity.x = (image.touchesCurrent.x - velocity.prevPositionX) / (Date.now() - velocity.prevTime) / 2; + velocity.y = (image.touchesCurrent.y - velocity.prevPositionY) / (Date.now() - velocity.prevTime) / 2; + if (Math.abs(image.touchesCurrent.x - velocity.prevPositionX) < 2) { velocity.x = 0; } + if (Math.abs(image.touchesCurrent.y - velocity.prevPositionY) < 2) { velocity.y = 0; } + velocity.prevPositionX = image.touchesCurrent.x; + velocity.prevPositionY = image.touchesCurrent.y; + velocity.prevTime = Date.now(); + + gesture.$imageWrapEl.transform(("translate3d(" + (image.currentX) + "px, " + (image.currentY) + "px,0)")); + }, + onTouchEnd: function onTouchEnd() { + var swiper = this; + var zoom = swiper.zoom; + var gesture = zoom.gesture; + var image = zoom.image; + var velocity = zoom.velocity; + if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; } + if (!image.isTouched || !image.isMoved) { + image.isTouched = false; + image.isMoved = false; + return; + } + image.isTouched = false; + image.isMoved = false; + var momentumDurationX = 300; + var momentumDurationY = 300; + var momentumDistanceX = velocity.x * momentumDurationX; + var newPositionX = image.currentX + momentumDistanceX; + var momentumDistanceY = velocity.y * momentumDurationY; + var newPositionY = image.currentY + momentumDistanceY; + + // Fix duration + if (velocity.x !== 0) { momentumDurationX = Math.abs((newPositionX - image.currentX) / velocity.x); } + if (velocity.y !== 0) { momentumDurationY = Math.abs((newPositionY - image.currentY) / velocity.y); } + var momentumDuration = Math.max(momentumDurationX, momentumDurationY); + + image.currentX = newPositionX; + image.currentY = newPositionY; + + // Define if we need image drag + var scaledWidth = image.width * zoom.scale; + var scaledHeight = image.height * zoom.scale; + image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0); + image.maxX = -image.minX; + image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0); + image.maxY = -image.minY; + image.currentX = Math.max(Math.min(image.currentX, image.maxX), image.minX); + image.currentY = Math.max(Math.min(image.currentY, image.maxY), image.minY); + + gesture.$imageWrapEl.transition(momentumDuration).transform(("translate3d(" + (image.currentX) + "px, " + (image.currentY) + "px,0)")); + }, + onTransitionEnd: function onTransitionEnd() { + var swiper = this; + var zoom = swiper.zoom; + var gesture = zoom.gesture; + if (gesture.$slideEl && swiper.previousIndex !== swiper.activeIndex) { + gesture.$imageEl.transform('translate3d(0,0,0) scale(1)'); + gesture.$imageWrapEl.transform('translate3d(0,0,0)'); + gesture.$slideEl = undefined; + gesture.$imageEl = undefined; + gesture.$imageWrapEl = undefined; + + zoom.scale = 1; + zoom.currentScale = 1; + } + }, + // Toggle Zoom + toggle: function toggle(e) { + var swiper = this; + var zoom = swiper.zoom; + + if (zoom.scale && zoom.scale !== 1) { + // Zoom Out + zoom.out(); + } else { + // Zoom In + zoom.in(e); + } + }, + in: function in$1(e) { + var swiper = this; + + var zoom = swiper.zoom; + var params = swiper.params.zoom; + var gesture = zoom.gesture; + var image = zoom.image; + + if (!gesture.$slideEl) { + gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(("." + (params.containerClass))); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; } + + gesture.$slideEl.addClass(("" + (params.zoomedSlideClass))); + + var touchX; + var touchY; + var offsetX; + var offsetY; + var diffX; + var diffY; + var translateX; + var translateY; + var imageWidth; + var imageHeight; + var scaledWidth; + var scaledHeight; + var translateMinX; + var translateMinY; + var translateMaxX; + var translateMaxY; + var slideWidth; + var slideHeight; + + if (typeof image.touchesStart.x === 'undefined' && e) { + touchX = e.type === 'touchend' ? e.changedTouches[0].pageX : e.pageX; + touchY = e.type === 'touchend' ? e.changedTouches[0].pageY : e.pageY; + } else { + touchX = image.touchesStart.x; + touchY = image.touchesStart.y; + } + + zoom.scale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + zoom.currentScale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio; + if (e) { + slideWidth = gesture.$slideEl[0].offsetWidth; + slideHeight = gesture.$slideEl[0].offsetHeight; + offsetX = gesture.$slideEl.offset().left; + offsetY = gesture.$slideEl.offset().top; + diffX = (offsetX + (slideWidth / 2)) - touchX; + diffY = (offsetY + (slideHeight / 2)) - touchY; + + imageWidth = gesture.$imageEl[0].offsetWidth; + imageHeight = gesture.$imageEl[0].offsetHeight; + scaledWidth = imageWidth * zoom.scale; + scaledHeight = imageHeight * zoom.scale; + + translateMinX = Math.min(((slideWidth / 2) - (scaledWidth / 2)), 0); + translateMinY = Math.min(((slideHeight / 2) - (scaledHeight / 2)), 0); + translateMaxX = -translateMinX; + translateMaxY = -translateMinY; + + translateX = diffX * zoom.scale; + translateY = diffY * zoom.scale; + + if (translateX < translateMinX) { + translateX = translateMinX; + } + if (translateX > translateMaxX) { + translateX = translateMaxX; + } + + if (translateY < translateMinY) { + translateY = translateMinY; + } + if (translateY > translateMaxY) { + translateY = translateMaxY; + } + } else { + translateX = 0; + translateY = 0; + } + gesture.$imageWrapEl.transition(300).transform(("translate3d(" + translateX + "px, " + translateY + "px,0)")); + gesture.$imageEl.transition(300).transform(("translate3d(0,0,0) scale(" + (zoom.scale) + ")")); + }, + out: function out() { + var swiper = this; + + var zoom = swiper.zoom; + var params = swiper.params.zoom; + var gesture = zoom.gesture; + + if (!gesture.$slideEl) { + gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex); + gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas'); + gesture.$imageWrapEl = gesture.$imageEl.parent(("." + (params.containerClass))); + } + if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; } + + zoom.scale = 1; + zoom.currentScale = 1; + gesture.$imageWrapEl.transition(300).transform('translate3d(0,0,0)'); + gesture.$imageEl.transition(300).transform('translate3d(0,0,0) scale(1)'); + gesture.$slideEl.removeClass(("" + (params.zoomedSlideClass))); + gesture.$slideEl = undefined; + }, + // Attach/Detach Events + enable: function enable() { + var swiper = this; + var zoom = swiper.zoom; + if (zoom.enabled) { return; } + zoom.enabled = true; + + var passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false; + + // Scale image + if (Support.gestures) { + swiper.$wrapperEl.on('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.on('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.on('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener); + } else if (swiper.touchEvents.start === 'touchstart') { + swiper.$wrapperEl.on(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.on(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.on(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener); + } + + // Move image + swiper.$wrapperEl.on(swiper.touchEvents.move, ("." + (swiper.params.zoom.containerClass)), zoom.onTouchMove); + }, + disable: function disable() { + var swiper = this; + var zoom = swiper.zoom; + if (!zoom.enabled) { return; } + + swiper.zoom.enabled = false; + + var passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false; + + // Scale image + if (Support.gestures) { + swiper.$wrapperEl.off('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.off('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.off('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener); + } else if (swiper.touchEvents.start === 'touchstart') { + swiper.$wrapperEl.off(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener); + swiper.$wrapperEl.off(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener); + swiper.$wrapperEl.off(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener); + } + + // Move image + swiper.$wrapperEl.off(swiper.touchEvents.move, ("." + (swiper.params.zoom.containerClass)), zoom.onTouchMove); + }, + }; + + var Zoom$1 = { + name: 'zoom', + params: { + zoom: { + enabled: false, + maxRatio: 3, + minRatio: 1, + toggle: true, + containerClass: 'swiper-zoom-container', + zoomedSlideClass: 'swiper-slide-zoomed', + }, + }, + create: function create() { + var swiper = this; + var zoom = { + enabled: false, + scale: 1, + currentScale: 1, + isScaling: false, + gesture: { + $slideEl: undefined, + slideWidth: undefined, + slideHeight: undefined, + $imageEl: undefined, + $imageWrapEl: undefined, + maxRatio: 3, + }, + image: { + isTouched: undefined, + isMoved: undefined, + currentX: undefined, + currentY: undefined, + minX: undefined, + minY: undefined, + maxX: undefined, + maxY: undefined, + width: undefined, + height: undefined, + startX: undefined, + startY: undefined, + touchesStart: {}, + touchesCurrent: {}, + }, + velocity: { + x: undefined, + y: undefined, + prevPositionX: undefined, + prevPositionY: undefined, + prevTime: undefined, + }, + }; + ('onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out').split(' ').forEach(function (methodName) { + zoom[methodName] = Zoom[methodName].bind(swiper); + }); + Utils.extend(swiper, { + zoom: zoom, + }); + }, + on: { + init: function init() { + var swiper = this; + if (swiper.params.zoom.enabled) { + swiper.zoom.enable(); + } + }, + destroy: function destroy() { + var swiper = this; + swiper.zoom.disable(); + }, + touchStart: function touchStart(e) { + var swiper = this; + if (!swiper.zoom.enabled) { return; } + swiper.zoom.onTouchStart(e); + }, + touchEnd: function touchEnd(e) { + var swiper = this; + if (!swiper.zoom.enabled) { return; } + swiper.zoom.onTouchEnd(e); + }, + doubleTap: function doubleTap(e) { + var swiper = this; + if (swiper.params.zoom.enabled && swiper.zoom.enabled && swiper.params.zoom.toggle) { + swiper.zoom.toggle(e); + } + }, + transitionEnd: function transitionEnd() { + var swiper = this; + if (swiper.zoom.enabled && swiper.params.zoom.enabled) { + swiper.zoom.onTransitionEnd(); + } + }, + }, + }; + + var Lazy = { + loadInSlide: function loadInSlide(index, loadInDuplicate) { + if ( loadInDuplicate === void 0 ) loadInDuplicate = true; + + var swiper = this; + var params = swiper.params.lazy; + if (typeof index === 'undefined') { return; } + if (swiper.slides.length === 0) { return; } + var isVirtual = swiper.virtual && swiper.params.virtual.enabled; + + var $slideEl = isVirtual + ? swiper.$wrapperEl.children(("." + (swiper.params.slideClass) + "[data-swiper-slide-index=\"" + index + "\"]")) + : swiper.slides.eq(index); + + var $images = $slideEl.find(("." + (params.elementClass) + ":not(." + (params.loadedClass) + "):not(." + (params.loadingClass) + ")")); + if ($slideEl.hasClass(params.elementClass) && !$slideEl.hasClass(params.loadedClass) && !$slideEl.hasClass(params.loadingClass)) { + $images = $images.add($slideEl[0]); + } + if ($images.length === 0) { return; } + + $images.each(function (imageIndex, imageEl) { + var $imageEl = $(imageEl); + $imageEl.addClass(params.loadingClass); + + var background = $imageEl.attr('data-background'); + var src = $imageEl.attr('data-src'); + var srcset = $imageEl.attr('data-srcset'); + var sizes = $imageEl.attr('data-sizes'); + + swiper.loadImage($imageEl[0], (src || background), srcset, sizes, false, function () { + if (typeof swiper === 'undefined' || swiper === null || !swiper || (swiper && !swiper.params) || swiper.destroyed) { return; } + if (background) { + $imageEl.css('background-image', ("url(\"" + background + "\")")); + $imageEl.removeAttr('data-background'); + } else { + if (srcset) { + $imageEl.attr('srcset', srcset); + $imageEl.removeAttr('data-srcset'); + } + if (sizes) { + $imageEl.attr('sizes', sizes); + $imageEl.removeAttr('data-sizes'); + } + if (src) { + $imageEl.attr('src', src); + $imageEl.removeAttr('data-src'); + } + } + + $imageEl.addClass(params.loadedClass).removeClass(params.loadingClass); + $slideEl.find(("." + (params.preloaderClass))).remove(); + if (swiper.params.loop && loadInDuplicate) { + var slideOriginalIndex = $slideEl.attr('data-swiper-slide-index'); + if ($slideEl.hasClass(swiper.params.slideDuplicateClass)) { + var originalSlide = swiper.$wrapperEl.children(("[data-swiper-slide-index=\"" + slideOriginalIndex + "\"]:not(." + (swiper.params.slideDuplicateClass) + ")")); + swiper.lazy.loadInSlide(originalSlide.index(), false); + } else { + var duplicatedSlide = swiper.$wrapperEl.children(("." + (swiper.params.slideDuplicateClass) + "[data-swiper-slide-index=\"" + slideOriginalIndex + "\"]")); + swiper.lazy.loadInSlide(duplicatedSlide.index(), false); + } + } + swiper.emit('lazyImageReady', $slideEl[0], $imageEl[0]); + }); + + swiper.emit('lazyImageLoad', $slideEl[0], $imageEl[0]); + }); + }, + load: function load() { + var swiper = this; + var $wrapperEl = swiper.$wrapperEl; + var swiperParams = swiper.params; + var slides = swiper.slides; + var activeIndex = swiper.activeIndex; + var isVirtual = swiper.virtual && swiperParams.virtual.enabled; + var params = swiperParams.lazy; + + var slidesPerView = swiperParams.slidesPerView; + if (slidesPerView === 'auto') { + slidesPerView = 0; + } + + function slideExist(index) { + if (isVirtual) { + if ($wrapperEl.children(("." + (swiperParams.slideClass) + "[data-swiper-slide-index=\"" + index + "\"]")).length) { + return true; + } + } else if (slides[index]) { return true; } + return false; + } + function slideIndex(slideEl) { + if (isVirtual) { + return $(slideEl).attr('data-swiper-slide-index'); + } + return $(slideEl).index(); + } + + if (!swiper.lazy.initialImageLoaded) { swiper.lazy.initialImageLoaded = true; } + if (swiper.params.watchSlidesVisibility) { + $wrapperEl.children(("." + (swiperParams.slideVisibleClass))).each(function (elIndex, slideEl) { + var index = isVirtual ? $(slideEl).attr('data-swiper-slide-index') : $(slideEl).index(); + swiper.lazy.loadInSlide(index); + }); + } else if (slidesPerView > 1) { + for (var i = activeIndex; i < activeIndex + slidesPerView; i += 1) { + if (slideExist(i)) { swiper.lazy.loadInSlide(i); } + } + } else { + swiper.lazy.loadInSlide(activeIndex); + } + if (params.loadPrevNext) { + if (slidesPerView > 1 || (params.loadPrevNextAmount && params.loadPrevNextAmount > 1)) { + var amount = params.loadPrevNextAmount; + var spv = slidesPerView; + var maxIndex = Math.min(activeIndex + spv + Math.max(amount, spv), slides.length); + var minIndex = Math.max(activeIndex - Math.max(spv, amount), 0); + // Next Slides + for (var i$1 = activeIndex + slidesPerView; i$1 < maxIndex; i$1 += 1) { + if (slideExist(i$1)) { swiper.lazy.loadInSlide(i$1); } + } + // Prev Slides + for (var i$2 = minIndex; i$2 < activeIndex; i$2 += 1) { + if (slideExist(i$2)) { swiper.lazy.loadInSlide(i$2); } + } + } else { + var nextSlide = $wrapperEl.children(("." + (swiperParams.slideNextClass))); + if (nextSlide.length > 0) { swiper.lazy.loadInSlide(slideIndex(nextSlide)); } + + var prevSlide = $wrapperEl.children(("." + (swiperParams.slidePrevClass))); + if (prevSlide.length > 0) { swiper.lazy.loadInSlide(slideIndex(prevSlide)); } + } + } + }, + }; + + var Lazy$1 = { + name: 'lazy', + params: { + lazy: { + enabled: false, + loadPrevNext: false, + loadPrevNextAmount: 1, + loadOnTransitionStart: false, + + elementClass: 'swiper-lazy', + loadingClass: 'swiper-lazy-loading', + loadedClass: 'swiper-lazy-loaded', + preloaderClass: 'swiper-lazy-preloader', + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + lazy: { + initialImageLoaded: false, + load: Lazy.load.bind(swiper), + loadInSlide: Lazy.loadInSlide.bind(swiper), + }, + }); + }, + on: { + beforeInit: function beforeInit() { + var swiper = this; + if (swiper.params.lazy.enabled && swiper.params.preloadImages) { + swiper.params.preloadImages = false; + } + }, + init: function init() { + var swiper = this; + if (swiper.params.lazy.enabled && !swiper.params.loop && swiper.params.initialSlide === 0) { + swiper.lazy.load(); + } + }, + scroll: function scroll() { + var swiper = this; + if (swiper.params.freeMode && !swiper.params.freeModeSticky) { + swiper.lazy.load(); + } + }, + resize: function resize() { + var swiper = this; + if (swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + }, + scrollbarDragMove: function scrollbarDragMove() { + var swiper = this; + if (swiper.params.lazy.enabled) { + swiper.lazy.load(); + } + }, + transitionStart: function transitionStart() { + var swiper = this; + if (swiper.params.lazy.enabled) { + if (swiper.params.lazy.loadOnTransitionStart || (!swiper.params.lazy.loadOnTransitionStart && !swiper.lazy.initialImageLoaded)) { + swiper.lazy.load(); + } + } + }, + transitionEnd: function transitionEnd() { + var swiper = this; + if (swiper.params.lazy.enabled && !swiper.params.lazy.loadOnTransitionStart) { + swiper.lazy.load(); + } + }, + }, + }; + + /* eslint no-bitwise: ["error", { "allow": [">>"] }] */ + + var Controller = { + LinearSpline: function LinearSpline(x, y) { + var binarySearch = (function search() { + var maxIndex; + var minIndex; + var guess; + return function (array, val) { + minIndex = -1; + maxIndex = array.length; + while (maxIndex - minIndex > 1) { + guess = maxIndex + minIndex >> 1; + if (array[guess] <= val) { + minIndex = guess; + } else { + maxIndex = guess; + } + } + return maxIndex; + }; + }()); + this.x = x; + this.y = y; + this.lastIndex = x.length - 1; + // Given an x value (x2), return the expected y2 value: + // (x1,y1) is the known point before given value, + // (x3,y3) is the known point after given value. + var i1; + var i3; + + this.interpolate = function interpolate(x2) { + if (!x2) { return 0; } + + // Get the indexes of x1 and x3 (the array indexes before and after given x2): + i3 = binarySearch(this.x, x2); + i1 = i3 - 1; + + // We have our indexes i1 & i3, so we can calculate already: + // y2 := ((x2−x1) × (y3−y1)) ÷ (x3−x1) + y1 + return (((x2 - this.x[i1]) * (this.y[i3] - this.y[i1])) / (this.x[i3] - this.x[i1])) + this.y[i1]; + }; + return this; + }, + // xxx: for now i will just save one spline function to to + getInterpolateFunction: function getInterpolateFunction(c) { + var swiper = this; + if (!swiper.controller.spline) { + swiper.controller.spline = swiper.params.loop ? + new Controller.LinearSpline(swiper.slidesGrid, c.slidesGrid) : + new Controller.LinearSpline(swiper.snapGrid, c.snapGrid); + } + }, + setTranslate: function setTranslate(setTranslate$1, byController) { + var swiper = this; + var controlled = swiper.controller.control; + var multiplier; + var controlledTranslate; + function setControlledTranslate(c) { + // this will create an Interpolate function based on the snapGrids + // x is the Grid of the scrolled scroller and y will be the controlled scroller + // it makes sense to create this only once and recall it for the interpolation + // the function does a lot of value caching for performance + var translate = swiper.rtlTranslate ? -swiper.translate : swiper.translate; + if (swiper.params.controller.by === 'slide') { + swiper.controller.getInterpolateFunction(c); + // i am not sure why the values have to be multiplicated this way, tried to invert the snapGrid + // but it did not work out + controlledTranslate = -swiper.controller.spline.interpolate(-translate); + } + + if (!controlledTranslate || swiper.params.controller.by === 'container') { + multiplier = (c.maxTranslate() - c.minTranslate()) / (swiper.maxTranslate() - swiper.minTranslate()); + controlledTranslate = ((translate - swiper.minTranslate()) * multiplier) + c.minTranslate(); + } + + if (swiper.params.controller.inverse) { + controlledTranslate = c.maxTranslate() - controlledTranslate; + } + c.updateProgress(controlledTranslate); + c.setTranslate(controlledTranslate, swiper); + c.updateActiveIndex(); + c.updateSlidesClasses(); + } + if (Array.isArray(controlled)) { + for (var i = 0; i < controlled.length; i += 1) { + if (controlled[i] !== byController && controlled[i] instanceof Swiper) { + setControlledTranslate(controlled[i]); + } + } + } else if (controlled instanceof Swiper && byController !== controlled) { + setControlledTranslate(controlled); + } + }, + setTransition: function setTransition(duration, byController) { + var swiper = this; + var controlled = swiper.controller.control; + var i; + function setControlledTransition(c) { + c.setTransition(duration, swiper); + if (duration !== 0) { + c.transitionStart(); + c.$wrapperEl.transitionEnd(function () { + if (!controlled) { return; } + if (c.params.loop && swiper.params.controller.by === 'slide') { + c.loopFix(); + } + c.transitionEnd(); + }); + } + } + if (Array.isArray(controlled)) { + for (i = 0; i < controlled.length; i += 1) { + if (controlled[i] !== byController && controlled[i] instanceof Swiper) { + setControlledTransition(controlled[i]); + } + } + } else if (controlled instanceof Swiper && byController !== controlled) { + setControlledTransition(controlled); + } + }, + }; + var Controller$1 = { + name: 'controller', + params: { + controller: { + control: undefined, + inverse: false, + by: 'slide', // or 'container' + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + controller: { + control: swiper.params.controller.control, + getInterpolateFunction: Controller.getInterpolateFunction.bind(swiper), + setTranslate: Controller.setTranslate.bind(swiper), + setTransition: Controller.setTransition.bind(swiper), + }, + }); + }, + on: { + update: function update() { + var swiper = this; + if (!swiper.controller.control) { return; } + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + resize: function resize() { + var swiper = this; + if (!swiper.controller.control) { return; } + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + observerUpdate: function observerUpdate() { + var swiper = this; + if (!swiper.controller.control) { return; } + if (swiper.controller.spline) { + swiper.controller.spline = undefined; + delete swiper.controller.spline; + } + }, + setTranslate: function setTranslate(translate, byController) { + var swiper = this; + if (!swiper.controller.control) { return; } + swiper.controller.setTranslate(translate, byController); + }, + setTransition: function setTransition(duration, byController) { + var swiper = this; + if (!swiper.controller.control) { return; } + swiper.controller.setTransition(duration, byController); + }, + }, + }; + + var a11y = { + makeElFocusable: function makeElFocusable($el) { + $el.attr('tabIndex', '0'); + return $el; + }, + addElRole: function addElRole($el, role) { + $el.attr('role', role); + return $el; + }, + addElLabel: function addElLabel($el, label) { + $el.attr('aria-label', label); + return $el; + }, + disableEl: function disableEl($el) { + $el.attr('aria-disabled', true); + return $el; + }, + enableEl: function enableEl($el) { + $el.attr('aria-disabled', false); + return $el; + }, + onEnterKey: function onEnterKey(e) { + var swiper = this; + var params = swiper.params.a11y; + if (e.keyCode !== 13) { return; } + var $targetEl = $(e.target); + if (swiper.navigation && swiper.navigation.$nextEl && $targetEl.is(swiper.navigation.$nextEl)) { + if (!(swiper.isEnd && !swiper.params.loop)) { + swiper.slideNext(); + } + if (swiper.isEnd) { + swiper.a11y.notify(params.lastSlideMessage); + } else { + swiper.a11y.notify(params.nextSlideMessage); + } + } + if (swiper.navigation && swiper.navigation.$prevEl && $targetEl.is(swiper.navigation.$prevEl)) { + if (!(swiper.isBeginning && !swiper.params.loop)) { + swiper.slidePrev(); + } + if (swiper.isBeginning) { + swiper.a11y.notify(params.firstSlideMessage); + } else { + swiper.a11y.notify(params.prevSlideMessage); + } + } + if (swiper.pagination && $targetEl.is(("." + (swiper.params.pagination.bulletClass)))) { + $targetEl[0].click(); + } + }, + notify: function notify(message) { + var swiper = this; + var notification = swiper.a11y.liveRegion; + if (notification.length === 0) { return; } + notification.html(''); + notification.html(message); + }, + updateNavigation: function updateNavigation() { + var swiper = this; + + if (swiper.params.loop) { return; } + var ref = swiper.navigation; + var $nextEl = ref.$nextEl; + var $prevEl = ref.$prevEl; + + if ($prevEl && $prevEl.length > 0) { + if (swiper.isBeginning) { + swiper.a11y.disableEl($prevEl); + } else { + swiper.a11y.enableEl($prevEl); + } + } + if ($nextEl && $nextEl.length > 0) { + if (swiper.isEnd) { + swiper.a11y.disableEl($nextEl); + } else { + swiper.a11y.enableEl($nextEl); + } + } + }, + updatePagination: function updatePagination() { + var swiper = this; + var params = swiper.params.a11y; + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.bullets.each(function (bulletIndex, bulletEl) { + var $bulletEl = $(bulletEl); + swiper.a11y.makeElFocusable($bulletEl); + swiper.a11y.addElRole($bulletEl, 'button'); + swiper.a11y.addElLabel($bulletEl, params.paginationBulletMessage.replace(/{{index}}/, $bulletEl.index() + 1)); + }); + } + }, + init: function init() { + var swiper = this; + + swiper.$el.append(swiper.a11y.liveRegion); + + // Navigation + var params = swiper.params.a11y; + var $nextEl; + var $prevEl; + if (swiper.navigation && swiper.navigation.$nextEl) { + $nextEl = swiper.navigation.$nextEl; + } + if (swiper.navigation && swiper.navigation.$prevEl) { + $prevEl = swiper.navigation.$prevEl; + } + if ($nextEl) { + swiper.a11y.makeElFocusable($nextEl); + swiper.a11y.addElRole($nextEl, 'button'); + swiper.a11y.addElLabel($nextEl, params.nextSlideMessage); + $nextEl.on('keydown', swiper.a11y.onEnterKey); + } + if ($prevEl) { + swiper.a11y.makeElFocusable($prevEl); + swiper.a11y.addElRole($prevEl, 'button'); + swiper.a11y.addElLabel($prevEl, params.prevSlideMessage); + $prevEl.on('keydown', swiper.a11y.onEnterKey); + } + + // Pagination + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.$el.on('keydown', ("." + (swiper.params.pagination.bulletClass)), swiper.a11y.onEnterKey); + } + }, + destroy: function destroy() { + var swiper = this; + if (swiper.a11y.liveRegion && swiper.a11y.liveRegion.length > 0) { swiper.a11y.liveRegion.remove(); } + + var $nextEl; + var $prevEl; + if (swiper.navigation && swiper.navigation.$nextEl) { + $nextEl = swiper.navigation.$nextEl; + } + if (swiper.navigation && swiper.navigation.$prevEl) { + $prevEl = swiper.navigation.$prevEl; + } + if ($nextEl) { + $nextEl.off('keydown', swiper.a11y.onEnterKey); + } + if ($prevEl) { + $prevEl.off('keydown', swiper.a11y.onEnterKey); + } + + // Pagination + if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) { + swiper.pagination.$el.off('keydown', ("." + (swiper.params.pagination.bulletClass)), swiper.a11y.onEnterKey); + } + }, + }; + var A11y = { + name: 'a11y', + params: { + a11y: { + enabled: true, + notificationClass: 'swiper-notification', + prevSlideMessage: 'Previous slide', + nextSlideMessage: 'Next slide', + firstSlideMessage: 'This is the first slide', + lastSlideMessage: 'This is the last slide', + paginationBulletMessage: 'Go to slide {{index}}', + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + a11y: { + liveRegion: $(("")), + }, + }); + Object.keys(a11y).forEach(function (methodName) { + swiper.a11y[methodName] = a11y[methodName].bind(swiper); + }); + }, + on: { + init: function init() { + var swiper = this; + if (!swiper.params.a11y.enabled) { return; } + swiper.a11y.init(); + swiper.a11y.updateNavigation(); + }, + toEdge: function toEdge() { + var swiper = this; + if (!swiper.params.a11y.enabled) { return; } + swiper.a11y.updateNavigation(); + }, + fromEdge: function fromEdge() { + var swiper = this; + if (!swiper.params.a11y.enabled) { return; } + swiper.a11y.updateNavigation(); + }, + paginationUpdate: function paginationUpdate() { + var swiper = this; + if (!swiper.params.a11y.enabled) { return; } + swiper.a11y.updatePagination(); + }, + destroy: function destroy() { + var swiper = this; + if (!swiper.params.a11y.enabled) { return; } + swiper.a11y.destroy(); + }, + }, + }; + + var History = { + init: function init() { + var swiper = this; + if (!swiper.params.history) { return; } + if (!win.history || !win.history.pushState) { + swiper.params.history.enabled = false; + swiper.params.hashNavigation.enabled = true; + return; + } + var history = swiper.history; + history.initialized = true; + history.paths = History.getPathValues(); + if (!history.paths.key && !history.paths.value) { return; } + history.scrollToSlide(0, history.paths.value, swiper.params.runCallbacksOnInit); + if (!swiper.params.history.replaceState) { + win.addEventListener('popstate', swiper.history.setHistoryPopState); + } + }, + destroy: function destroy() { + var swiper = this; + if (!swiper.params.history.replaceState) { + win.removeEventListener('popstate', swiper.history.setHistoryPopState); + } + }, + setHistoryPopState: function setHistoryPopState() { + var swiper = this; + swiper.history.paths = History.getPathValues(); + swiper.history.scrollToSlide(swiper.params.speed, swiper.history.paths.value, false); + }, + getPathValues: function getPathValues() { + var pathArray = win.location.pathname.slice(1).split('/').filter(function (part) { return part !== ''; }); + var total = pathArray.length; + var key = pathArray[total - 2]; + var value = pathArray[total - 1]; + return { key: key, value: value }; + }, + setHistory: function setHistory(key, index) { + var swiper = this; + if (!swiper.history.initialized || !swiper.params.history.enabled) { return; } + var slide = swiper.slides.eq(index); + var value = History.slugify(slide.attr('data-history')); + if (!win.location.pathname.includes(key)) { + value = key + "/" + value; + } + var currentState = win.history.state; + if (currentState && currentState.value === value) { + return; + } + if (swiper.params.history.replaceState) { + win.history.replaceState({ value: value }, null, value); + } else { + win.history.pushState({ value: value }, null, value); + } + }, + slugify: function slugify(text) { + return text.toString().toLowerCase() + .replace(/\s+/g, '-') + .replace(/[^\w-]+/g, '') + .replace(/--+/g, '-') + .replace(/^-+/, '') + .replace(/-+$/, ''); + }, + scrollToSlide: function scrollToSlide(speed, value, runCallbacks) { + var swiper = this; + if (value) { + for (var i = 0, length = swiper.slides.length; i < length; i += 1) { + var slide = swiper.slides.eq(i); + var slideHistory = History.slugify(slide.attr('data-history')); + if (slideHistory === value && !slide.hasClass(swiper.params.slideDuplicateClass)) { + var index = slide.index(); + swiper.slideTo(index, speed, runCallbacks); + } + } + } else { + swiper.slideTo(0, speed, runCallbacks); + } + }, + }; + + var History$1 = { + name: 'history', + params: { + history: { + enabled: false, + replaceState: false, + key: 'slides', + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + history: { + init: History.init.bind(swiper), + setHistory: History.setHistory.bind(swiper), + setHistoryPopState: History.setHistoryPopState.bind(swiper), + scrollToSlide: History.scrollToSlide.bind(swiper), + destroy: History.destroy.bind(swiper), + }, + }); + }, + on: { + init: function init() { + var swiper = this; + if (swiper.params.history.enabled) { + swiper.history.init(); + } + }, + destroy: function destroy() { + var swiper = this; + if (swiper.params.history.enabled) { + swiper.history.destroy(); + } + }, + transitionEnd: function transitionEnd() { + var swiper = this; + if (swiper.history.initialized) { + swiper.history.setHistory(swiper.params.history.key, swiper.activeIndex); + } + }, + }, + }; + + var HashNavigation = { + onHashCange: function onHashCange() { + var swiper = this; + var newHash = doc.location.hash.replace('#', ''); + var activeSlideHash = swiper.slides.eq(swiper.activeIndex).attr('data-hash'); + if (newHash !== activeSlideHash) { + swiper.slideTo(swiper.$wrapperEl.children(("." + (swiper.params.slideClass) + "[data-hash=\"" + newHash + "\"]")).index()); + } + }, + setHash: function setHash() { + var swiper = this; + if (!swiper.hashNavigation.initialized || !swiper.params.hashNavigation.enabled) { return; } + if (swiper.params.hashNavigation.replaceState && win.history && win.history.replaceState) { + win.history.replaceState(null, null, (("#" + (swiper.slides.eq(swiper.activeIndex).attr('data-hash'))) || '')); + } else { + var slide = swiper.slides.eq(swiper.activeIndex); + var hash = slide.attr('data-hash') || slide.attr('data-history'); + doc.location.hash = hash || ''; + } + }, + init: function init() { + var swiper = this; + if (!swiper.params.hashNavigation.enabled || (swiper.params.history && swiper.params.history.enabled)) { return; } + swiper.hashNavigation.initialized = true; + var hash = doc.location.hash.replace('#', ''); + if (hash) { + var speed = 0; + for (var i = 0, length = swiper.slides.length; i < length; i += 1) { + var slide = swiper.slides.eq(i); + var slideHash = slide.attr('data-hash') || slide.attr('data-history'); + if (slideHash === hash && !slide.hasClass(swiper.params.slideDuplicateClass)) { + var index = slide.index(); + swiper.slideTo(index, speed, swiper.params.runCallbacksOnInit, true); + } + } + } + if (swiper.params.hashNavigation.watchState) { + $(win).on('hashchange', swiper.hashNavigation.onHashCange); + } + }, + destroy: function destroy() { + var swiper = this; + if (swiper.params.hashNavigation.watchState) { + $(win).off('hashchange', swiper.hashNavigation.onHashCange); + } + }, + }; + var HashNavigation$1 = { + name: 'hash-navigation', + params: { + hashNavigation: { + enabled: false, + replaceState: false, + watchState: false, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + hashNavigation: { + initialized: false, + init: HashNavigation.init.bind(swiper), + destroy: HashNavigation.destroy.bind(swiper), + setHash: HashNavigation.setHash.bind(swiper), + onHashCange: HashNavigation.onHashCange.bind(swiper), + }, + }); + }, + on: { + init: function init() { + var swiper = this; + if (swiper.params.hashNavigation.enabled) { + swiper.hashNavigation.init(); + } + }, + destroy: function destroy() { + var swiper = this; + if (swiper.params.hashNavigation.enabled) { + swiper.hashNavigation.destroy(); + } + }, + transitionEnd: function transitionEnd() { + var swiper = this; + if (swiper.hashNavigation.initialized) { + swiper.hashNavigation.setHash(); + } + }, + }, + }; + + /* eslint no-underscore-dangle: "off" */ + + var Autoplay = { + run: function run() { + var swiper = this; + var $activeSlideEl = swiper.slides.eq(swiper.activeIndex); + var delay = swiper.params.autoplay.delay; + if ($activeSlideEl.attr('data-swiper-autoplay')) { + delay = $activeSlideEl.attr('data-swiper-autoplay') || swiper.params.autoplay.delay; + } + swiper.autoplay.timeout = Utils.nextTick(function () { + if (swiper.params.autoplay.reverseDirection) { + if (swiper.params.loop) { + swiper.loopFix(); + swiper.slidePrev(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.isBeginning) { + swiper.slidePrev(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.params.autoplay.stopOnLastSlide) { + swiper.slideTo(swiper.slides.length - 1, swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else { + swiper.autoplay.stop(); + } + } else if (swiper.params.loop) { + swiper.loopFix(); + swiper.slideNext(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.isEnd) { + swiper.slideNext(swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else if (!swiper.params.autoplay.stopOnLastSlide) { + swiper.slideTo(0, swiper.params.speed, true, true); + swiper.emit('autoplay'); + } else { + swiper.autoplay.stop(); + } + }, delay); + }, + start: function start() { + var swiper = this; + if (typeof swiper.autoplay.timeout !== 'undefined') { return false; } + if (swiper.autoplay.running) { return false; } + swiper.autoplay.running = true; + swiper.emit('autoplayStart'); + swiper.autoplay.run(); + return true; + }, + stop: function stop() { + var swiper = this; + if (!swiper.autoplay.running) { return false; } + if (typeof swiper.autoplay.timeout === 'undefined') { return false; } + + if (swiper.autoplay.timeout) { + clearTimeout(swiper.autoplay.timeout); + swiper.autoplay.timeout = undefined; + } + swiper.autoplay.running = false; + swiper.emit('autoplayStop'); + return true; + }, + pause: function pause(speed) { + var swiper = this; + if (!swiper.autoplay.running) { return; } + if (swiper.autoplay.paused) { return; } + if (swiper.autoplay.timeout) { clearTimeout(swiper.autoplay.timeout); } + swiper.autoplay.paused = true; + if (speed === 0 || !swiper.params.autoplay.waitForTransition) { + swiper.autoplay.paused = false; + swiper.autoplay.run(); + } else { + swiper.$wrapperEl[0].addEventListener('transitionend', swiper.autoplay.onTransitionEnd); + swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd); + } + }, + }; + + var Autoplay$1 = { + name: 'autoplay', + params: { + autoplay: { + enabled: false, + delay: 3000, + waitForTransition: true, + disableOnInteraction: true, + stopOnLastSlide: false, + reverseDirection: false, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + autoplay: { + running: false, + paused: false, + run: Autoplay.run.bind(swiper), + start: Autoplay.start.bind(swiper), + stop: Autoplay.stop.bind(swiper), + pause: Autoplay.pause.bind(swiper), + onTransitionEnd: function onTransitionEnd(e) { + if (!swiper || swiper.destroyed || !swiper.$wrapperEl) { return; } + if (e.target !== this) { return; } + swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.autoplay.onTransitionEnd); + swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd); + swiper.autoplay.paused = false; + if (!swiper.autoplay.running) { + swiper.autoplay.stop(); + } else { + swiper.autoplay.run(); + } + }, + }, + }); + }, + on: { + init: function init() { + var swiper = this; + if (swiper.params.autoplay.enabled) { + swiper.autoplay.start(); + } + }, + beforeTransitionStart: function beforeTransitionStart(speed, internal) { + var swiper = this; + if (swiper.autoplay.running) { + if (internal || !swiper.params.autoplay.disableOnInteraction) { + swiper.autoplay.pause(speed); + } else { + swiper.autoplay.stop(); + } + } + }, + sliderFirstMove: function sliderFirstMove() { + var swiper = this; + if (swiper.autoplay.running) { + if (swiper.params.autoplay.disableOnInteraction) { + swiper.autoplay.stop(); + } else { + swiper.autoplay.pause(); + } + } + }, + destroy: function destroy() { + var swiper = this; + if (swiper.autoplay.running) { + swiper.autoplay.stop(); + } + }, + }, + }; + + var Fade = { + setTranslate: function setTranslate() { + var swiper = this; + var slides = swiper.slides; + for (var i = 0; i < slides.length; i += 1) { + var $slideEl = swiper.slides.eq(i); + var offset = $slideEl[0].swiperSlideOffset; + var tx = -offset; + if (!swiper.params.virtualTranslate) { tx -= swiper.translate; } + var ty = 0; + if (!swiper.isHorizontal()) { + ty = tx; + tx = 0; + } + var slideOpacity = swiper.params.fadeEffect.crossFade ? + Math.max(1 - Math.abs($slideEl[0].progress), 0) : + 1 + Math.min(Math.max($slideEl[0].progress, -1), 0); + $slideEl + .css({ + opacity: slideOpacity, + }) + .transform(("translate3d(" + tx + "px, " + ty + "px, 0px)")); + } + }, + setTransition: function setTransition(duration) { + var swiper = this; + var slides = swiper.slides; + var $wrapperEl = swiper.$wrapperEl; + slides.transition(duration); + if (swiper.params.virtualTranslate && duration !== 0) { + var eventTriggered = false; + slides.transitionEnd(function () { + if (eventTriggered) { return; } + if (!swiper || swiper.destroyed) { return; } + eventTriggered = true; + swiper.animating = false; + var triggerEvents = ['webkitTransitionEnd', 'transitionend']; + for (var i = 0; i < triggerEvents.length; i += 1) { + $wrapperEl.trigger(triggerEvents[i]); + } + }); + } + }, + }; + + var EffectFade = { + name: 'effect-fade', + params: { + fadeEffect: { + crossFade: false, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + fadeEffect: { + setTranslate: Fade.setTranslate.bind(swiper), + setTransition: Fade.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit: function beforeInit() { + var swiper = this; + if (swiper.params.effect !== 'fade') { return; } + swiper.classNames.push(((swiper.params.containerModifierClass) + "fade")); + var overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + spaceBetween: 0, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate: function setTranslate() { + var swiper = this; + if (swiper.params.effect !== 'fade') { return; } + swiper.fadeEffect.setTranslate(); + }, + setTransition: function setTransition(duration) { + var swiper = this; + if (swiper.params.effect !== 'fade') { return; } + swiper.fadeEffect.setTransition(duration); + }, + }, + }; + + var Cube = { + setTranslate: function setTranslate() { + var swiper = this; + var $el = swiper.$el; + var $wrapperEl = swiper.$wrapperEl; + var slides = swiper.slides; + var swiperWidth = swiper.width; + var swiperHeight = swiper.height; + var rtl = swiper.rtlTranslate; + var swiperSize = swiper.size; + var params = swiper.params.cubeEffect; + var isHorizontal = swiper.isHorizontal(); + var isVirtual = swiper.virtual && swiper.params.virtual.enabled; + var wrapperRotate = 0; + var $cubeShadowEl; + if (params.shadow) { + if (isHorizontal) { + $cubeShadowEl = $wrapperEl.find('.swiper-cube-shadow'); + if ($cubeShadowEl.length === 0) { + $cubeShadowEl = $('
    '); + $wrapperEl.append($cubeShadowEl); + } + $cubeShadowEl.css({ height: (swiperWidth + "px") }); + } else { + $cubeShadowEl = $el.find('.swiper-cube-shadow'); + if ($cubeShadowEl.length === 0) { + $cubeShadowEl = $('
    '); + $el.append($cubeShadowEl); + } + } + } + for (var i = 0; i < slides.length; i += 1) { + var $slideEl = slides.eq(i); + var slideIndex = i; + if (isVirtual) { + slideIndex = parseInt($slideEl.attr('data-swiper-slide-index'), 10); + } + var slideAngle = slideIndex * 90; + var round = Math.floor(slideAngle / 360); + if (rtl) { + slideAngle = -slideAngle; + round = Math.floor(-slideAngle / 360); + } + var progress = Math.max(Math.min($slideEl[0].progress, 1), -1); + var tx = 0; + var ty = 0; + var tz = 0; + if (slideIndex % 4 === 0) { + tx = -round * 4 * swiperSize; + tz = 0; + } else if ((slideIndex - 1) % 4 === 0) { + tx = 0; + tz = -round * 4 * swiperSize; + } else if ((slideIndex - 2) % 4 === 0) { + tx = swiperSize + (round * 4 * swiperSize); + tz = swiperSize; + } else if ((slideIndex - 3) % 4 === 0) { + tx = -swiperSize; + tz = (3 * swiperSize) + (swiperSize * 4 * round); + } + if (rtl) { + tx = -tx; + } + + if (!isHorizontal) { + ty = tx; + tx = 0; + } + + var transform = "rotateX(" + (isHorizontal ? 0 : -slideAngle) + "deg) rotateY(" + (isHorizontal ? slideAngle : 0) + "deg) translate3d(" + tx + "px, " + ty + "px, " + tz + "px)"; + if (progress <= 1 && progress > -1) { + wrapperRotate = (slideIndex * 90) + (progress * 90); + if (rtl) { wrapperRotate = (-slideIndex * 90) - (progress * 90); } + } + $slideEl.transform(transform); + if (params.slideShadows) { + // Set shadows + var shadowBefore = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + var shadowAfter = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if (shadowBefore.length === 0) { + shadowBefore = $(("
    ")); + $slideEl.append(shadowBefore); + } + if (shadowAfter.length === 0) { + shadowAfter = $(("
    ")); + $slideEl.append(shadowAfter); + } + if (shadowBefore.length) { shadowBefore[0].style.opacity = Math.max(-progress, 0); } + if (shadowAfter.length) { shadowAfter[0].style.opacity = Math.max(progress, 0); } + } + } + $wrapperEl.css({ + '-webkit-transform-origin': ("50% 50% -" + (swiperSize / 2) + "px"), + '-moz-transform-origin': ("50% 50% -" + (swiperSize / 2) + "px"), + '-ms-transform-origin': ("50% 50% -" + (swiperSize / 2) + "px"), + 'transform-origin': ("50% 50% -" + (swiperSize / 2) + "px"), + }); + + if (params.shadow) { + if (isHorizontal) { + $cubeShadowEl.transform(("translate3d(0px, " + ((swiperWidth / 2) + params.shadowOffset) + "px, " + (-swiperWidth / 2) + "px) rotateX(90deg) rotateZ(0deg) scale(" + (params.shadowScale) + ")")); + } else { + var shadowAngle = Math.abs(wrapperRotate) - (Math.floor(Math.abs(wrapperRotate) / 90) * 90); + var multiplier = 1.5 - ( + (Math.sin((shadowAngle * 2 * Math.PI) / 360) / 2) + + (Math.cos((shadowAngle * 2 * Math.PI) / 360) / 2) + ); + var scale1 = params.shadowScale; + var scale2 = params.shadowScale / multiplier; + var offset = params.shadowOffset; + $cubeShadowEl.transform(("scale3d(" + scale1 + ", 1, " + scale2 + ") translate3d(0px, " + ((swiperHeight / 2) + offset) + "px, " + (-swiperHeight / 2 / scale2) + "px) rotateX(-90deg)")); + } + } + var zFactor = (Browser.isSafari || Browser.isUiWebView) ? (-swiperSize / 2) : 0; + $wrapperEl + .transform(("translate3d(0px,0," + zFactor + "px) rotateX(" + (swiper.isHorizontal() ? 0 : wrapperRotate) + "deg) rotateY(" + (swiper.isHorizontal() ? -wrapperRotate : 0) + "deg)")); + }, + setTransition: function setTransition(duration) { + var swiper = this; + var $el = swiper.$el; + var slides = swiper.slides; + slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + if (swiper.params.cubeEffect.shadow && !swiper.isHorizontal()) { + $el.find('.swiper-cube-shadow').transition(duration); + } + }, + }; + + var EffectCube = { + name: 'effect-cube', + params: { + cubeEffect: { + slideShadows: true, + shadow: true, + shadowOffset: 20, + shadowScale: 0.94, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + cubeEffect: { + setTranslate: Cube.setTranslate.bind(swiper), + setTransition: Cube.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit: function beforeInit() { + var swiper = this; + if (swiper.params.effect !== 'cube') { return; } + swiper.classNames.push(((swiper.params.containerModifierClass) + "cube")); + swiper.classNames.push(((swiper.params.containerModifierClass) + "3d")); + var overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + resistanceRatio: 0, + spaceBetween: 0, + centeredSlides: false, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate: function setTranslate() { + var swiper = this; + if (swiper.params.effect !== 'cube') { return; } + swiper.cubeEffect.setTranslate(); + }, + setTransition: function setTransition(duration) { + var swiper = this; + if (swiper.params.effect !== 'cube') { return; } + swiper.cubeEffect.setTransition(duration); + }, + }, + }; + + var Flip = { + setTranslate: function setTranslate() { + var swiper = this; + var slides = swiper.slides; + var rtl = swiper.rtlTranslate; + for (var i = 0; i < slides.length; i += 1) { + var $slideEl = slides.eq(i); + var progress = $slideEl[0].progress; + if (swiper.params.flipEffect.limitRotation) { + progress = Math.max(Math.min($slideEl[0].progress, 1), -1); + } + var offset = $slideEl[0].swiperSlideOffset; + var rotate = -180 * progress; + var rotateY = rotate; + var rotateX = 0; + var tx = -offset; + var ty = 0; + if (!swiper.isHorizontal()) { + ty = tx; + tx = 0; + rotateX = -rotateY; + rotateY = 0; + } else if (rtl) { + rotateY = -rotateY; + } + + $slideEl[0].style.zIndex = -Math.abs(Math.round(progress)) + slides.length; + + if (swiper.params.flipEffect.slideShadows) { + // Set shadows + var shadowBefore = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + var shadowAfter = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if (shadowBefore.length === 0) { + shadowBefore = $(("
    ")); + $slideEl.append(shadowBefore); + } + if (shadowAfter.length === 0) { + shadowAfter = $(("
    ")); + $slideEl.append(shadowAfter); + } + if (shadowBefore.length) { shadowBefore[0].style.opacity = Math.max(-progress, 0); } + if (shadowAfter.length) { shadowAfter[0].style.opacity = Math.max(progress, 0); } + } + $slideEl + .transform(("translate3d(" + tx + "px, " + ty + "px, 0px) rotateX(" + rotateX + "deg) rotateY(" + rotateY + "deg)")); + } + }, + setTransition: function setTransition(duration) { + var swiper = this; + var slides = swiper.slides; + var activeIndex = swiper.activeIndex; + var $wrapperEl = swiper.$wrapperEl; + slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + if (swiper.params.virtualTranslate && duration !== 0) { + var eventTriggered = false; + // eslint-disable-next-line + slides.eq(activeIndex).transitionEnd(function onTransitionEnd() { + if (eventTriggered) { return; } + if (!swiper || swiper.destroyed) { return; } + // if (!$(this).hasClass(swiper.params.slideActiveClass)) return; + eventTriggered = true; + swiper.animating = false; + var triggerEvents = ['webkitTransitionEnd', 'transitionend']; + for (var i = 0; i < triggerEvents.length; i += 1) { + $wrapperEl.trigger(triggerEvents[i]); + } + }); + } + }, + }; + + var EffectFlip = { + name: 'effect-flip', + params: { + flipEffect: { + slideShadows: true, + limitRotation: true, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + flipEffect: { + setTranslate: Flip.setTranslate.bind(swiper), + setTransition: Flip.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit: function beforeInit() { + var swiper = this; + if (swiper.params.effect !== 'flip') { return; } + swiper.classNames.push(((swiper.params.containerModifierClass) + "flip")); + swiper.classNames.push(((swiper.params.containerModifierClass) + "3d")); + var overwriteParams = { + slidesPerView: 1, + slidesPerColumn: 1, + slidesPerGroup: 1, + watchSlidesProgress: true, + spaceBetween: 0, + virtualTranslate: true, + }; + Utils.extend(swiper.params, overwriteParams); + Utils.extend(swiper.originalParams, overwriteParams); + }, + setTranslate: function setTranslate() { + var swiper = this; + if (swiper.params.effect !== 'flip') { return; } + swiper.flipEffect.setTranslate(); + }, + setTransition: function setTransition(duration) { + var swiper = this; + if (swiper.params.effect !== 'flip') { return; } + swiper.flipEffect.setTransition(duration); + }, + }, + }; + + var Coverflow = { + setTranslate: function setTranslate() { + var swiper = this; + var swiperWidth = swiper.width; + var swiperHeight = swiper.height; + var slides = swiper.slides; + var $wrapperEl = swiper.$wrapperEl; + var slidesSizesGrid = swiper.slidesSizesGrid; + var params = swiper.params.coverflowEffect; + var isHorizontal = swiper.isHorizontal(); + var transform = swiper.translate; + var center = isHorizontal ? -transform + (swiperWidth / 2) : -transform + (swiperHeight / 2); + var rotate = isHorizontal ? params.rotate : -params.rotate; + var translate = params.depth; + // Each slide offset from center + for (var i = 0, length = slides.length; i < length; i += 1) { + var $slideEl = slides.eq(i); + var slideSize = slidesSizesGrid[i]; + var slideOffset = $slideEl[0].swiperSlideOffset; + var offsetMultiplier = ((center - slideOffset - (slideSize / 2)) / slideSize) * params.modifier; + + var rotateY = isHorizontal ? rotate * offsetMultiplier : 0; + var rotateX = isHorizontal ? 0 : rotate * offsetMultiplier; + // var rotateZ = 0 + var translateZ = -translate * Math.abs(offsetMultiplier); + + var translateY = isHorizontal ? 0 : params.stretch * (offsetMultiplier); + var translateX = isHorizontal ? params.stretch * (offsetMultiplier) : 0; + + // Fix for ultra small values + if (Math.abs(translateX) < 0.001) { translateX = 0; } + if (Math.abs(translateY) < 0.001) { translateY = 0; } + if (Math.abs(translateZ) < 0.001) { translateZ = 0; } + if (Math.abs(rotateY) < 0.001) { rotateY = 0; } + if (Math.abs(rotateX) < 0.001) { rotateX = 0; } + + var slideTransform = "translate3d(" + translateX + "px," + translateY + "px," + translateZ + "px) rotateX(" + rotateX + "deg) rotateY(" + rotateY + "deg)"; + + $slideEl.transform(slideTransform); + $slideEl[0].style.zIndex = -Math.abs(Math.round(offsetMultiplier)) + 1; + if (params.slideShadows) { + // Set shadows + var $shadowBeforeEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top'); + var $shadowAfterEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom'); + if ($shadowBeforeEl.length === 0) { + $shadowBeforeEl = $(("
    ")); + $slideEl.append($shadowBeforeEl); + } + if ($shadowAfterEl.length === 0) { + $shadowAfterEl = $(("
    ")); + $slideEl.append($shadowAfterEl); + } + if ($shadowBeforeEl.length) { $shadowBeforeEl[0].style.opacity = offsetMultiplier > 0 ? offsetMultiplier : 0; } + if ($shadowAfterEl.length) { $shadowAfterEl[0].style.opacity = (-offsetMultiplier) > 0 ? -offsetMultiplier : 0; } + } + } + + // Set correct perspective for IE10 + if (Support.pointerEvents || Support.prefixedPointerEvents) { + var ws = $wrapperEl[0].style; + ws.perspectiveOrigin = center + "px 50%"; + } + }, + setTransition: function setTransition(duration) { + var swiper = this; + swiper.slides + .transition(duration) + .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left') + .transition(duration); + }, + }; + + var EffectCoverflow = { + name: 'effect-coverflow', + params: { + coverflowEffect: { + rotate: 50, + stretch: 0, + depth: 100, + modifier: 1, + slideShadows: true, + }, + }, + create: function create() { + var swiper = this; + Utils.extend(swiper, { + coverflowEffect: { + setTranslate: Coverflow.setTranslate.bind(swiper), + setTransition: Coverflow.setTransition.bind(swiper), + }, + }); + }, + on: { + beforeInit: function beforeInit() { + var swiper = this; + if (swiper.params.effect !== 'coverflow') { return; } + + swiper.classNames.push(((swiper.params.containerModifierClass) + "coverflow")); + swiper.classNames.push(((swiper.params.containerModifierClass) + "3d")); + + swiper.params.watchSlidesProgress = true; + swiper.originalParams.watchSlidesProgress = true; + }, + setTranslate: function setTranslate() { + var swiper = this; + if (swiper.params.effect !== 'coverflow') { return; } + swiper.coverflowEffect.setTranslate(); + }, + setTransition: function setTransition(duration) { + var swiper = this; + if (swiper.params.effect !== 'coverflow') { return; } + swiper.coverflowEffect.setTransition(duration); + }, + }, + }; + + // Swiper Class + + var components = [ + Device$1, + Support$1, + Browser$1, + Resize, + Observer$1, + Virtual$1, + Keyboard$1, + Mousewheel$1, + Navigation$1, + Pagination$1, + Scrollbar$1, + Parallax$1, + Zoom$1, + Lazy$1, + Controller$1, + A11y, + History$1, + HashNavigation$1, + Autoplay$1, + EffectFade, + EffectCube, + EffectFlip, + EffectCoverflow + ]; + + if (typeof Swiper.use === 'undefined') { + Swiper.use = Swiper.Class.use; + Swiper.installModule = Swiper.Class.installModule; + } + + Swiper.use(components); + + return Swiper; + +}))); diff --git a/static/swiper/js/swiper.min.js b/static/swiper/js/swiper.min.js new file mode 100644 index 0000000..3d5dbee --- /dev/null +++ b/static/swiper/js/swiper.min.js @@ -0,0 +1,13 @@ +/** + * Swiper 4.2.6 + * Most modern mobile touch slider and framework with hardware accelerated transitions + * http://www.idangero.us/swiper/ + * + * Copyright 2014-2018 Vladimir Kharlampidi + * + * Released under the MIT License + * + * Released on: May 1, 2018 + */ +!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):e.Swiper=t()}(this,function(){"use strict";var e="undefined"==typeof document?{body:{},addEventListener:function(){},removeEventListener:function(){},activeElement:{blur:function(){},nodeName:""},querySelector:function(){return null},querySelectorAll:function(){return[]},getElementById:function(){return null},createEvent:function(){return{initEvent:function(){}}},createElement:function(){return{children:[],childNodes:[],style:{},setAttribute:function(){},getElementsByTagName:function(){return[]}}},location:{hash:""}}:document,t="undefined"==typeof window?{document:e,navigator:{userAgent:""},location:{},history:{},CustomEvent:function(){return this},addEventListener:function(){},removeEventListener:function(){},getComputedStyle:function(){return{getPropertyValue:function(){return""}}},Image:function(){},Date:function(){},screen:{},setTimeout:function(){},clearTimeout:function(){}}:window,i=function(e){for(var t=0;t=0&&d.indexOf(">")>=0){var h="div";for(0===d.indexOf(":~]/)?(a||e).querySelectorAll(s.trim()):[e.getElementById(s.trim().split("#")[1])],n=0;n0&&s[0].nodeType)for(n=0;n=0;u-=1){var v=c[u];r&&v.listener===r?(p.removeEventListener(d,v.proxyListener,n),c.splice(u,1)):r||(p.removeEventListener(d,v.proxyListener,n),c.splice(u,1))}}return this},trigger:function(){for(var i=[],s=arguments.length;s--;)i[s]=arguments[s];for(var a=i[0].split(" "),r=i[1],n=0;n0}),d.dispatchEvent(h),d.dom7EventData=[],delete d.dom7EventData}return this},transitionEnd:function(e){var t,i=["webkitTransitionEnd","transitionend"],s=this;function a(r){if(r.target===this)for(e.call(this,r),t=0;t0){if(e){var t=this.styles();return this[0].offsetWidth+parseFloat(t.getPropertyValue("margin-right"))+parseFloat(t.getPropertyValue("margin-left"))}return this[0].offsetWidth}return null},outerHeight:function(e){if(this.length>0){if(e){var t=this.styles();return this[0].offsetHeight+parseFloat(t.getPropertyValue("margin-top"))+parseFloat(t.getPropertyValue("margin-bottom"))}return this[0].offsetHeight}return null},offset:function(){if(this.length>0){var i=this[0],s=i.getBoundingClientRect(),a=e.body,r=i.clientTop||a.clientTop||0,n=i.clientLeft||a.clientLeft||0,o=i===t?t.scrollY:i.scrollTop,l=i===t?t.scrollX:i.scrollLeft;return{top:s.top+o-r,left:s.left+l-n}}return null},css:function(e,i){var s;if(1===arguments.length){if("string"!=typeof e){for(s=0;ss-1?[]:e<0?(t=s+e)<0?[]:[this[t]]:[this[e]])},append:function(){for(var t,s=[],a=arguments.length;a--;)s[a]=arguments[a];for(var r=0;r=0;a-=1)this[s].insertBefore(r.childNodes[a],this[s].childNodes[0])}else if(t instanceof i)for(a=0;a0?e?this[0].nextElementSibling&&s(this[0].nextElementSibling).is(e)?new i([this[0].nextElementSibling]):new i([]):this[0].nextElementSibling?new i([this[0].nextElementSibling]):new i([]):new i([])},nextAll:function(e){var t=[],a=this[0];if(!a)return new i([]);for(;a.nextElementSibling;){var r=a.nextElementSibling;e?s(r).is(e)&&t.push(r):t.push(r),a=r}return new i(t)},prev:function(e){if(this.length>0){var t=this[0];return e?t.previousElementSibling&&s(t.previousElementSibling).is(e)?new i([t.previousElementSibling]):new i([]):t.previousElementSibling?new i([t.previousElementSibling]):new i([])}return new i([])},prevAll:function(e){var t=[],a=this[0];if(!a)return new i([]);for(;a.previousElementSibling;){var r=a.previousElementSibling;e?s(r).is(e)&&t.push(r):t.push(r),a=r}return new i(t)},parent:function(e){for(var t=[],i=0;i6&&(a=a.split(", ").map(function(e){return e.replace(",",".")}).join(", ")),r=new t.WebKitCSSMatrix("none"===a?"":a)):s=(r=n.MozTransform||n.OTransform||n.MsTransform||n.msTransform||n.transform||n.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,")).toString().split(","),"x"===i&&(a=t.WebKitCSSMatrix?r.m41:16===s.length?parseFloat(s[12]):parseFloat(s[4])),"y"===i&&(a=t.WebKitCSSMatrix?r.m42:16===s.length?parseFloat(s[13]):parseFloat(s[5])),a||0},parseUrlQuery:function(e){var i,s,a,r,n={},o=e||t.location.href;if("string"==typeof o&&o.length)for(r=(s=(o=o.indexOf("?")>-1?o.replace(/\S*\?/,""):"").split("&").filter(function(e){return""!==e})).length,i=0;i0;)t[i]=arguments[i+1];var s=this;s.prototype.modules||(s.prototype.modules={});var a=e.name||Object.keys(s.prototype.modules).length+"_"+d.now();return s.prototype.modules[a]=e,e.proto&&Object.keys(e.proto).forEach(function(t){s.prototype[t]=e.proto[t]}),e.static&&Object.keys(e.static).forEach(function(t){s[t]=e.static[t]}),e.install&&e.install.apply(s,t),s},p.use=function(e){for(var t=[],i=arguments.length-1;i-- >0;)t[i]=arguments[i+1];var s=this;return Array.isArray(e)?(e.forEach(function(e){return s.installModule(e)}),s):s.installModule.apply(s,[e].concat(t))},Object.defineProperties(p,c);var u={updateSize:function(){var e,t,i=this.$el;e=void 0!==this.params.width?this.params.width:i[0].clientWidth,t=void 0!==this.params.height?this.params.height:i[0].clientHeight,0===e&&this.isHorizontal()||0===t&&this.isVertical()||(e=e-parseInt(i.css("padding-left"),10)-parseInt(i.css("padding-right"),10),t=t-parseInt(i.css("padding-top"),10)-parseInt(i.css("padding-bottom"),10),d.extend(this,{width:e,height:t,size:this.isHorizontal()?e:t}))},updateSlides:function(){var e=this.params,i=this.$wrapperEl,s=this.size,a=this.rtlTranslate,r=this.wrongRTL,n=i.children("."+this.params.slideClass),o=this.virtual&&e.virtual.enabled?this.virtual.slides.length:n.length,l=[],p=[],c=[],u=e.slidesOffsetBefore;"function"==typeof u&&(u=e.slidesOffsetBefore.call(this));var v=e.slidesOffsetAfter;"function"==typeof v&&(v=e.slidesOffsetAfter.call(this));var f=o,m=this.snapGrid.length,g=this.snapGrid.length,b=e.spaceBetween,w=-u,y=0,x=0;if(void 0!==s){var E,T;"string"==typeof b&&b.indexOf("%")>=0&&(b=parseFloat(b.replace("%",""))/100*s),this.virtualSize=-b,a?n.css({marginLeft:"",marginTop:""}):n.css({marginRight:"",marginBottom:""}),e.slidesPerColumn>1&&(E=Math.floor(o/e.slidesPerColumn)===o/this.params.slidesPerColumn?o:Math.ceil(o/e.slidesPerColumn)*e.slidesPerColumn,"auto"!==e.slidesPerView&&"row"===e.slidesPerColumnFill&&(E=Math.max(E,e.slidesPerView*e.slidesPerColumn)));for(var S,C=e.slidesPerColumn,M=E/C,z=M-(e.slidesPerColumn*M-o),k=0;k1){var $=void 0,L=void 0,I=void 0;"column"===e.slidesPerColumnFill?(I=k-(L=Math.floor(k/C))*C,(L>z||L===z&&I===C-1)&&(I+=1)>=C&&(I=0,L+=1),$=L+I*E/C,P.css({"-webkit-box-ordinal-group":$,"-moz-box-ordinal-group":$,"-ms-flex-order":$,"-webkit-order":$,order:$})):L=k-(I=Math.floor(k/M))*M,P.css("margin-"+(this.isHorizontal()?"top":"left"),0!==I&&e.spaceBetween&&e.spaceBetween+"px").attr("data-swiper-column",L).attr("data-swiper-row",I)}if("none"!==P.css("display")){if("auto"===e.slidesPerView){var D=t.getComputedStyle(P[0],null),O=P[0].style.transform;O&&(P[0].style.transform="none"),T=this.isHorizontal()?P[0].getBoundingClientRect().width+parseFloat(D.getPropertyValue("margin-left"))+parseFloat(D.getPropertyValue("margin-right")):P[0].getBoundingClientRect().height+parseFloat(D.getPropertyValue("margin-top"))+parseFloat(D.getPropertyValue("margin-bottom")),O&&(P[0].style.transform=O),e.roundLengths&&(T=Math.floor(T))}else T=(s-(e.slidesPerView-1)*b)/e.slidesPerView,e.roundLengths&&(T=Math.floor(T)),n[k]&&(this.isHorizontal()?n[k].style.width=T+"px":n[k].style.height=T+"px");n[k]&&(n[k].swiperSlideSize=T),c.push(T),e.centeredSlides?(w=w+T/2+y/2+b,0===y&&0!==k&&(w=w-s/2-b),0===k&&(w=w-s/2-b),Math.abs(w)<.001&&(w=0),x%e.slidesPerGroup==0&&l.push(w),p.push(w)):(x%e.slidesPerGroup==0&&l.push(w),p.push(w),w=w+T+b),this.virtualSize+=T+b,y=T,x+=1}}if(this.virtualSize=Math.max(this.virtualSize,s)+v,a&&r&&("slide"===e.effect||"coverflow"===e.effect)&&i.css({width:this.virtualSize+e.spaceBetween+"px"}),h.flexbox&&!e.setWrapperSize||(this.isHorizontal()?i.css({width:this.virtualSize+e.spaceBetween+"px"}):i.css({height:this.virtualSize+e.spaceBetween+"px"})),e.slidesPerColumn>1&&(this.virtualSize=(T+e.spaceBetween)*E,this.virtualSize=Math.ceil(this.virtualSize/e.slidesPerColumn)-e.spaceBetween,this.isHorizontal()?i.css({width:this.virtualSize+e.spaceBetween+"px"}):i.css({height:this.virtualSize+e.spaceBetween+"px"}),e.centeredSlides)){S=[];for(var A=0;A1&&l.push(this.virtualSize-s)}0===l.length&&(l=[0]),0!==e.spaceBetween&&(this.isHorizontal()?a?n.css({marginLeft:b+"px"}):n.css({marginRight:b+"px"}):n.css({marginBottom:b+"px"})),d.extend(this,{slides:n,snapGrid:l,slidesGrid:p,slidesSizesGrid:c}),o!==f&&this.emit("slidesLengthChange"),l.length!==m&&(this.params.watchOverflow&&this.checkOverflow(),this.emit("snapGridLengthChange")),p.length!==g&&this.emit("slidesGridLengthChange"),(e.watchSlidesProgress||e.watchSlidesVisibility)&&this.updateSlidesOffset()}},updateAutoHeight:function(e){var t,i=[],s=0;if("number"==typeof e?this.setTransition(e):!0===e&&this.setTransition(this.params.speed),"auto"!==this.params.slidesPerView&&this.params.slidesPerView>1)for(t=0;tthis.slides.length)break;i.push(this.slides.eq(a)[0])}else i.push(this.slides.eq(this.activeIndex)[0]);for(t=0;ts?r:s}s&&this.$wrapperEl.css("height",s+"px")},updateSlidesOffset:function(){for(var e=this.slides,t=0;t=0&&l0&&d<=this.size||l<=0&&d>=this.size)&&i.eq(r).addClass(t.slideVisibleClass)}n.progress=s?-o:o}}},updateProgress:function(e){void 0===e&&(e=this&&this.translate||0);var t=this.params,i=this.maxTranslate()-this.minTranslate(),s=this.progress,a=this.isBeginning,r=this.isEnd,n=a,o=r;0===i?(s=0,a=!0,r=!0):(a=(s=(e-this.minTranslate())/i)<=0,r=s>=1),d.extend(this,{progress:s,isBeginning:a,isEnd:r}),(t.watchSlidesProgress||t.watchSlidesVisibility)&&this.updateSlidesProgress(e),a&&!n&&this.emit("reachBeginning toEdge"),r&&!o&&this.emit("reachEnd toEdge"),(n&&!a||o&&!r)&&this.emit("fromEdge"),this.emit("progress",s)},updateSlidesClasses:function(){var e,t=this.slides,i=this.params,s=this.$wrapperEl,a=this.activeIndex,r=this.realIndex,n=this.virtual&&i.virtual.enabled;t.removeClass(i.slideActiveClass+" "+i.slideNextClass+" "+i.slidePrevClass+" "+i.slideDuplicateActiveClass+" "+i.slideDuplicateNextClass+" "+i.slideDuplicatePrevClass),(e=n?this.$wrapperEl.find("."+i.slideClass+'[data-swiper-slide-index="'+a+'"]'):t.eq(a)).addClass(i.slideActiveClass),i.loop&&(e.hasClass(i.slideDuplicateClass)?s.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+r+'"]').addClass(i.slideDuplicateActiveClass):s.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+r+'"]').addClass(i.slideDuplicateActiveClass));var o=e.nextAll("."+i.slideClass).eq(0).addClass(i.slideNextClass);i.loop&&0===o.length&&(o=t.eq(0)).addClass(i.slideNextClass);var l=e.prevAll("."+i.slideClass).eq(0).addClass(i.slidePrevClass);i.loop&&0===l.length&&(l=t.eq(-1)).addClass(i.slidePrevClass),i.loop&&(o.hasClass(i.slideDuplicateClass)?s.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+o.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicateNextClass):s.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+o.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicateNextClass),l.hasClass(i.slideDuplicateClass)?s.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+l.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicatePrevClass):s.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+l.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicatePrevClass))},updateActiveIndex:function(e){var t,i=this.rtlTranslate?this.translate:-this.translate,s=this.slidesGrid,a=this.snapGrid,r=this.params,n=this.activeIndex,o=this.realIndex,l=this.snapIndex,h=e;if(void 0===h){for(var p=0;p=s[p]&&i=s[p]&&i=s[p]&&(h=p);r.normalizeSlideIndex&&(h<0||void 0===h)&&(h=0)}if((t=a.indexOf(i)>=0?a.indexOf(i):Math.floor(h/r.slidesPerGroup))>=a.length&&(t=a.length-1),h!==n){var c=parseInt(this.slides.eq(h).attr("data-swiper-slide-index")||h,10);d.extend(this,{snapIndex:t,realIndex:c,previousIndex:n,activeIndex:h}),this.emit("activeIndexChange"),this.emit("snapIndexChange"),o!==c&&this.emit("realIndexChange"),this.emit("slideChange")}else t!==l&&(this.snapIndex=t,this.emit("snapIndexChange"))},updateClickedSlide:function(e){var t=this.params,i=s(e.target).closest("."+t.slideClass)[0],a=!1;if(i)for(var r=0;ra?"next":is?"next":i=o.length&&(u=o.length-1),(p||n.initialSlide||0)===(d||0)&&i&&a.emit("beforeSlideChangeStart");var v,f=-o[u];if(a.updateProgress(f),n.normalizeSlideIndex)for(var m=0;m=Math.floor(100*l[m])&&(r=m);if(a.initialized&&r!==p){if(!a.allowSlideNext&&fa.translate&&f>a.maxTranslate()&&(p||0)!==r)return!1}return v=r>p?"next":r(this.snapGrid[a+1]-n)/2&&(s=this.params.slidesPerGroup)}return this.slideTo(s,e,t,i)},slideToClickedSlide:function(){var e,t=this,i=t.params,a=t.$wrapperEl,r="auto"===i.slidesPerView?t.slidesPerViewDynamic():i.slidesPerView,n=t.clickedIndex;if(i.loop){if(t.animating)return;e=parseInt(s(t.clickedSlide).attr("data-swiper-slide-index"),10),i.centeredSlides?nt.slides.length-t.loopedSlides+r/2?(t.loopFix(),n=a.children("."+i.slideClass+'[data-swiper-slide-index="'+e+'"]:not(.'+i.slideDuplicateClass+")").eq(0).index(),d.nextTick(function(){t.slideTo(n)})):t.slideTo(n):n>t.slides.length-r?(t.loopFix(),n=a.children("."+i.slideClass+'[data-swiper-slide-index="'+e+'"]:not(.'+i.slideDuplicateClass+")").eq(0).index(),d.nextTick(function(){t.slideTo(n)})):t.slideTo(n)}else t.slideTo(n)}};var g={loopCreate:function(){var t=this,i=t.params,a=t.$wrapperEl;a.children("."+i.slideClass+"."+i.slideDuplicateClass).remove();var r=a.children("."+i.slideClass);if(i.loopFillGroupWithBlank){var n=i.slidesPerGroup-r.length%i.slidesPerGroup;if(n!==i.slidesPerGroup){for(var o=0;or.length&&(t.loopedSlides=r.length);var d=[],h=[];r.each(function(e,i){var a=s(i);e=r.length-t.loopedSlides&&d.push(i),a.attr("data-swiper-slide-index",e)});for(var p=0;p=0;c-=1)a.prepend(s(d[c].cloneNode(!0)).addClass(i.slideDuplicateClass))},loopFix:function(){var e,t=this.params,i=this.activeIndex,s=this.slides,a=this.loopedSlides,r=this.allowSlidePrev,n=this.allowSlideNext,o=this.snapGrid,l=this.rtlTranslate;this.allowSlidePrev=!0,this.allowSlideNext=!0;var d=-o[i]-this.getTranslate();i=2*a||i>s.length-2*t.slidesPerView)&&(e=-s.length+i+a,e+=a,this.slideTo(e,0,!1,!0)&&0!==d&&this.setTranslate((l?-this.translate:this.translate)-d));this.allowSlidePrev=r,this.allowSlideNext=n},loopDestroy:function(){var e=this.$wrapperEl,t=this.params,i=this.slides;e.children("."+t.slideClass+"."+t.slideDuplicateClass).remove(),i.removeAttr("data-swiper-slide-index")}};var b={setGrabCursor:function(e){if(!(h.touch||!this.params.simulateTouch||this.params.watchOverflow&&this.isLocked)){var t=this.el;t.style.cursor="move",t.style.cursor=e?"-webkit-grabbing":"-webkit-grab",t.style.cursor=e?"-moz-grabbin":"-moz-grab",t.style.cursor=e?"grabbing":"grab"}},unsetGrabCursor:function(){h.touch||this.params.watchOverflow&&this.isLocked||(this.el.style.cursor="")}};var w={appendSlide:function(e){var t=this.$wrapperEl,i=this.params;if(i.loop&&this.loopDestroy(),"object"==typeof e&&"length"in e)for(var s=0;s=0),(n||l||o)&&(s.os="ios",s.ios=!0),l&&!o&&(s.osVersion=l[2].replace(/_/g,"."),s.iphone=!0),n&&(s.osVersion=n[2].replace(/_/g,"."),s.ipad=!0),o&&(s.osVersion=o[3]?o[3].replace(/_/g,"."):null,s.iphone=!0),s.ios&&s.osVersion&&i.indexOf("Version/")>=0&&"10"===s.osVersion.split(".")[0]&&(s.osVersion=i.toLowerCase().split("version/")[1].split(" ")[0]),s.desktop=!(s.os||s.android||s.webView),s.webView=(l||n||o)&&i.match(/.*AppleWebKit(?!.*Safari)/i),s.os&&"ios"===s.os){var d=s.osVersion.split("."),h=e.querySelector('meta[name="viewport"]');s.minimalUi=!s.webView&&(o||l)&&(1*d[0]==7?1*d[1]>=1:1*d[0]>7)&&h&&h.getAttribute("content").indexOf("minimal-ui")>=0}return s.pixelRatio=t.devicePixelRatio||1,s}();function x(){var e=this.params,t=this.el;if(!t||0!==t.offsetWidth){e.breakpoints&&this.setBreakpoint();var i=this.allowSlideNext,s=this.allowSlidePrev,a=this.snapGrid;if(this.allowSlideNext=!0,this.allowSlidePrev=!0,this.updateSize(),this.updateSlides(),e.freeMode){var r=Math.min(Math.max(this.translate,this.maxTranslate()),this.minTranslate());this.setTranslate(r),this.updateActiveIndex(),this.updateSlidesClasses(),e.autoHeight&&this.updateAutoHeight()}else this.updateSlidesClasses(),("auto"===e.slidesPerView||e.slidesPerView>1)&&this.isEnd&&!this.params.centeredSlides?this.slideTo(this.slides.length-1,0,!1,!0):this.slideTo(this.activeIndex,0,!1,!0);this.allowSlidePrev=s,this.allowSlideNext=i,this.params.watchOverflow&&a!==this.snapGrid&&this.checkOverflow()}}var E={attachEvents:function(){var i=this.params,a=this.touchEvents,r=this.el,n=this.wrapperEl;this.onTouchStart=function(i){var a=this.touchEventsData,r=this.params,n=this.touches;if(!this.animating||!r.preventIntercationOnTransition){var o=i;if(o.originalEvent&&(o=o.originalEvent),a.isTouchEvent="touchstart"===o.type,(a.isTouchEvent||!("which"in o)||3!==o.which)&&(!a.isTouched||!a.isMoved))if(r.noSwiping&&s(o.target).closest(r.noSwipingSelector?r.noSwipingSelector:"."+r.noSwipingClass)[0])this.allowClick=!0;else if(!r.swipeHandler||s(o).closest(r.swipeHandler)[0]){n.currentX="touchstart"===o.type?o.targetTouches[0].pageX:o.pageX,n.currentY="touchstart"===o.type?o.targetTouches[0].pageY:o.pageY;var l=n.currentX,h=n.currentY;if(!(y.ios&&!y.cordova&&r.iOSEdgeSwipeDetection&&l<=r.iOSEdgeSwipeThreshold&&l>=t.screen.width-r.iOSEdgeSwipeThreshold)){if(d.extend(a,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),n.startX=l,n.startY=h,a.touchStartTime=d.now(),this.allowClick=!0,this.updateSize(),this.swipeDirection=void 0,r.threshold>0&&(a.allowThresholdMove=!1),"touchstart"!==o.type){var p=!0;s(o.target).is(a.formElements)&&(p=!1),e.activeElement&&s(e.activeElement).is(a.formElements)&&e.activeElement!==o.target&&e.activeElement.blur(),p&&this.allowTouchMove&&o.preventDefault()}this.emit("touchStart",o)}}}}.bind(this),this.onTouchMove=function(t){var i=this.touchEventsData,a=this.params,r=this.touches,n=this.rtlTranslate,o=t;if(o.originalEvent&&(o=o.originalEvent),i.isTouched){if(!i.isTouchEvent||"mousemove"!==o.type){var l="touchmove"===o.type?o.targetTouches[0].pageX:o.pageX,h="touchmove"===o.type?o.targetTouches[0].pageY:o.pageY;if(o.preventedByNestedSwiper)return r.startX=l,void(r.startY=h);if(!this.allowTouchMove)return this.allowClick=!1,void(i.isTouched&&(d.extend(r,{startX:l,startY:h,currentX:l,currentY:h}),i.touchStartTime=d.now()));if(i.isTouchEvent&&a.touchReleaseOnEdges&&!a.loop)if(this.isVertical()){if(hr.startY&&this.translate>=this.minTranslate())return i.isTouched=!1,void(i.isMoved=!1)}else if(lr.startX&&this.translate>=this.minTranslate())return;if(i.isTouchEvent&&e.activeElement&&o.target===e.activeElement&&s(o.target).is(i.formElements))return i.isMoved=!0,void(this.allowClick=!1);if(i.allowTouchCallbacks&&this.emit("touchMove",o),!(o.targetTouches&&o.targetTouches.length>1)){r.currentX=l,r.currentY=h;var p,c=r.currentX-r.startX,u=r.currentY-r.startY;if(void 0===i.isScrolling&&(this.isHorizontal()&&r.currentY===r.startY||this.isVertical()&&r.currentX===r.startX?i.isScrolling=!1:c*c+u*u>=25&&(p=180*Math.atan2(Math.abs(u),Math.abs(c))/Math.PI,i.isScrolling=this.isHorizontal()?p>a.touchAngle:90-p>a.touchAngle)),i.isScrolling&&this.emit("touchMoveOpposite",o),"undefined"==typeof startMoving&&(r.currentX===r.startX&&r.currentY===r.startY||(i.startMoving=!0)),i.isScrolling)i.isTouched=!1;else if(i.startMoving){this.allowClick=!1,o.preventDefault(),a.touchMoveStopPropagation&&!a.nested&&o.stopPropagation(),i.isMoved||(a.loop&&this.loopFix(),i.startTranslate=this.getTranslate(),this.setTransition(0),this.animating&&this.$wrapperEl.trigger("webkitTransitionEnd transitionend"),i.allowMomentumBounce=!1,!a.grabCursor||!0!==this.allowSlideNext&&!0!==this.allowSlidePrev||this.setGrabCursor(!0),this.emit("sliderFirstMove",o)),this.emit("sliderMove",o),i.isMoved=!0;var v=this.isHorizontal()?c:u;r.diff=v,v*=a.touchRatio,n&&(v=-v),this.swipeDirection=v>0?"prev":"next",i.currentTranslate=v+i.startTranslate;var f=!0,m=a.resistanceRatio;if(a.touchReleaseOnEdges&&(m=0),v>0&&i.currentTranslate>this.minTranslate()?(f=!1,a.resistance&&(i.currentTranslate=this.minTranslate()-1+Math.pow(-this.minTranslate()+i.startTranslate+v,m))):v<0&&i.currentTranslatei.startTranslate&&(i.currentTranslate=i.startTranslate),a.threshold>0){if(!(Math.abs(v)>a.threshold||i.allowThresholdMove))return void(i.currentTranslate=i.startTranslate);if(!i.allowThresholdMove)return i.allowThresholdMove=!0,r.startX=r.currentX,r.startY=r.currentY,i.currentTranslate=i.startTranslate,void(r.diff=this.isHorizontal()?r.currentX-r.startX:r.currentY-r.startY)}a.followFinger&&((a.freeMode||a.watchSlidesProgress||a.watchSlidesVisibility)&&(this.updateActiveIndex(),this.updateSlidesClasses()),a.freeMode&&(0===i.velocities.length&&i.velocities.push({position:r[this.isHorizontal()?"startX":"startY"],time:i.touchStartTime}),i.velocities.push({position:r[this.isHorizontal()?"currentX":"currentY"],time:d.now()})),this.updateProgress(i.currentTranslate),this.setTranslate(i.currentTranslate))}}}}else i.startMoving&&i.isScrolling&&this.emit("touchMoveOpposite",o)}.bind(this),this.onTouchEnd=function(e){var t=this,i=t.touchEventsData,s=t.params,a=t.touches,r=t.rtlTranslate,n=t.$wrapperEl,o=t.slidesGrid,l=t.snapGrid,h=e;if(h.originalEvent&&(h=h.originalEvent),i.allowTouchCallbacks&&t.emit("touchEnd",h),i.allowTouchCallbacks=!1,!i.isTouched)return i.isMoved&&s.grabCursor&&t.setGrabCursor(!1),i.isMoved=!1,void(i.startMoving=!1);s.grabCursor&&i.isMoved&&i.isTouched&&(!0===t.allowSlideNext||!0===t.allowSlidePrev)&&t.setGrabCursor(!1);var p,c=d.now(),u=c-i.touchStartTime;if(t.allowClick&&(t.updateClickedSlide(h),t.emit("tap",h),u<300&&c-i.lastClickTime>300&&(i.clickTimeout&&clearTimeout(i.clickTimeout),i.clickTimeout=d.nextTick(function(){t&&!t.destroyed&&t.emit("click",h)},300)),u<300&&c-i.lastClickTime<300&&(i.clickTimeout&&clearTimeout(i.clickTimeout),t.emit("doubleTap",h))),i.lastClickTime=d.now(),d.nextTick(function(){t.destroyed||(t.allowClick=!0)}),!i.isTouched||!i.isMoved||!t.swipeDirection||0===a.diff||i.currentTranslate===i.startTranslate)return i.isTouched=!1,i.isMoved=!1,void(i.startMoving=!1);if(i.isTouched=!1,i.isMoved=!1,i.startMoving=!1,p=s.followFinger?r?t.translate:-t.translate:-i.currentTranslate,s.freeMode){if(p<-t.minTranslate())return void t.slideTo(t.activeIndex);if(p>-t.maxTranslate())return void(t.slides.length1){var v=i.velocities.pop(),f=i.velocities.pop(),m=v.position-f.position,g=v.time-f.time;t.velocity=m/g,t.velocity/=2,Math.abs(t.velocity)150||d.now()-v.time>300)&&(t.velocity=0)}else t.velocity=0;t.velocity*=s.freeModeMomentumVelocityRatio,i.velocities.length=0;var b=1e3*s.freeModeMomentumRatio,w=t.velocity*b,y=t.translate+w;r&&(y=-y);var x,E,T=!1,S=20*Math.abs(t.velocity)*s.freeModeMomentumBounceRatio;if(yt.minTranslate())s.freeModeMomentumBounce?(y-t.minTranslate()>S&&(y=t.minTranslate()+S),x=t.minTranslate(),T=!0,i.allowMomentumBounce=!0):y=t.minTranslate(),s.loop&&s.centeredSlides&&(E=!0);else if(s.freeModeSticky){for(var C,M=0;M-y){C=M;break}y=-(y=Math.abs(l[C]-y)=s.longSwipesMs)&&(t.updateProgress(),t.updateActiveIndex(),t.updateSlidesClasses())}else{for(var z=0,k=t.slidesSizesGrid[0],P=0;P=o[P]&&p=o[P]&&(z=P,k=o[o.length-1]-o[o.length-2]);var $=(p-o[z])/k;if(u>s.longSwipesMs){if(!s.longSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&($>=s.longSwipesRatio?t.slideTo(z+s.slidesPerGroup):t.slideTo(z)),"prev"===t.swipeDirection&&($>1-s.longSwipesRatio?t.slideTo(z+s.slidesPerGroup):t.slideTo(z))}else{if(!s.shortSwipes)return void t.slideTo(t.activeIndex);"next"===t.swipeDirection&&t.slideTo(z+s.slidesPerGroup),"prev"===t.swipeDirection&&t.slideTo(z)}}}.bind(this),this.onClick=function(e){this.allowClick||(this.params.preventClicks&&e.preventDefault(),this.params.preventClicksPropagation&&this.animating&&(e.stopPropagation(),e.stopImmediatePropagation()))}.bind(this);var o="container"===i.touchEventsTarget?r:n,l=!!i.nested;if(h.touch||!h.pointerEvents&&!h.prefixedPointerEvents){if(h.touch){var p=!("touchstart"!==a.start||!h.passiveListener||!i.passiveListeners)&&{passive:!0,capture:!1};o.addEventListener(a.start,this.onTouchStart,p),o.addEventListener(a.move,this.onTouchMove,h.passiveListener?{passive:!1,capture:l}:l),o.addEventListener(a.end,this.onTouchEnd,p)}(i.simulateTouch&&!y.ios&&!y.android||i.simulateTouch&&!h.touch&&y.ios)&&(o.addEventListener("mousedown",this.onTouchStart,!1),e.addEventListener("mousemove",this.onTouchMove,l),e.addEventListener("mouseup",this.onTouchEnd,!1))}else o.addEventListener(a.start,this.onTouchStart,!1),e.addEventListener(a.move,this.onTouchMove,l),e.addEventListener(a.end,this.onTouchEnd,!1);(i.preventClicks||i.preventClicksPropagation)&&o.addEventListener("click",this.onClick,!0),this.on("resize observerUpdate",x,!0)},detachEvents:function(){var t=this.params,i=this.touchEvents,s=this.el,a=this.wrapperEl,r="container"===t.touchEventsTarget?s:a,n=!!t.nested;if(h.touch||!h.pointerEvents&&!h.prefixedPointerEvents){if(h.touch){var o=!("onTouchStart"!==i.start||!h.passiveListener||!t.passiveListeners)&&{passive:!0,capture:!1};r.removeEventListener(i.start,this.onTouchStart,o),r.removeEventListener(i.move,this.onTouchMove,n),r.removeEventListener(i.end,this.onTouchEnd,o)}(t.simulateTouch&&!y.ios&&!y.android||t.simulateTouch&&!h.touch&&y.ios)&&(r.removeEventListener("mousedown",this.onTouchStart,!1),e.removeEventListener("mousemove",this.onTouchMove,n),e.removeEventListener("mouseup",this.onTouchEnd,!1))}else r.removeEventListener(i.start,this.onTouchStart,!1),e.removeEventListener(i.move,this.onTouchMove,n),e.removeEventListener(i.end,this.onTouchEnd,!1);(t.preventClicks||t.preventClicksPropagation)&&r.removeEventListener("click",this.onClick,!0),this.off("resize observerUpdate",x)}};var T={setBreakpoint:function(){var e=this.activeIndex,t=this.initialized,i=this.loopedSlides;void 0===i&&(i=0);var s=this.params,a=s.breakpoints;if(a&&(!a||0!==Object.keys(a).length)){var r=this.getBreakpoint(a);if(r&&this.currentBreakpoint!==r){var n=r in a?a[r]:this.originalParams,o=s.loop&&n.slidesPerView!==s.slidesPerView;d.extend(this.params,n),d.extend(this,{allowTouchMove:this.params.allowTouchMove,allowSlideNext:this.params.allowSlideNext,allowSlidePrev:this.params.allowSlidePrev}),this.currentBreakpoint=r,o&&t&&(this.loopDestroy(),this.loopCreate(),this.updateSlides(),this.slideTo(e-i+this.loopedSlides,0,!1)),this.emit("breakpoint",n)}}},getBreakpoint:function(e){if(e){var i=!1,s=[];Object.keys(e).forEach(function(e){s.push(e)}),s.sort(function(e,t){return parseInt(e,10)-parseInt(t,10)});for(var a=0;a=t.innerWidth&&!i&&(i=r)}return i||"max"}}},S=function(){return{isIE:!!t.navigator.userAgent.match(/Trident/g)||!!t.navigator.userAgent.match(/MSIE/g),isSafari:(e=t.navigator.userAgent.toLowerCase(),e.indexOf("safari")>=0&&e.indexOf("chrome")<0&&e.indexOf("android")<0),isUiWebView:/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(t.navigator.userAgent)};var e}();var C={init:!0,direction:"horizontal",touchEventsTarget:"container",initialSlide:0,speed:300,preventIntercationOnTransition:!1,iOSEdgeSwipeDetection:!1,iOSEdgeSwipeThreshold:20,freeMode:!1,freeModeMomentum:!0,freeModeMomentumRatio:1,freeModeMomentumBounce:!0,freeModeMomentumBounceRatio:1,freeModeMomentumVelocityRatio:1,freeModeSticky:!1,freeModeMinimumVelocity:.02,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,spaceBetween:0,slidesPerView:1,slidesPerColumn:1,slidesPerColumnFill:"column",slidesPerGroup:1,centeredSlides:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,watchOverflow:!1,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:0,touchMoveStopPropagation:!0,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,watchSlidesVisibility:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,preloadImages:!0,updateOnImagesReady:!0,loop:!1,loopAdditionalSlides:0,loopedSlides:null,loopFillGroupWithBlank:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,containerModifierClass:"swiper-container-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-invisible-blank",slideActiveClass:"swiper-slide-active",slideDuplicateActiveClass:"swiper-slide-duplicate-active",slideVisibleClass:"swiper-slide-visible",slideDuplicateClass:"swiper-slide-duplicate",slideNextClass:"swiper-slide-next",slideDuplicateNextClass:"swiper-slide-duplicate-next",slidePrevClass:"swiper-slide-prev",slideDuplicatePrevClass:"swiper-slide-duplicate-prev",wrapperClass:"swiper-wrapper",runCallbacksOnInit:!0},M={update:u,translate:v,transition:f,slide:m,loop:g,grabCursor:b,manipulation:w,events:E,breakpoints:T,checkOverflow:{checkOverflow:function(){var e=this.isLocked;this.isLocked=1===this.snapGrid.length,this.allowSlideNext=!this.isLocked,this.allowSlidePrev=!this.isLocked,e!==this.isLocked&&this.emit(this.isLocked?"lock":"unlock"),e&&e!==this.isLocked&&(this.isEnd=!1,this.navigation.update())}},classes:{addClasses:function(){var e=this.classNames,t=this.params,i=this.rtl,s=this.$el,a=[];a.push(t.direction),t.freeMode&&a.push("free-mode"),h.flexbox||a.push("no-flexbox"),t.autoHeight&&a.push("autoheight"),i&&a.push("rtl"),t.slidesPerColumn>1&&a.push("multirow"),y.android&&a.push("android"),y.ios&&a.push("ios"),S.isIE&&(h.pointerEvents||h.prefixedPointerEvents)&&a.push("wp8-"+t.direction),a.forEach(function(i){e.push(t.containerModifierClass+i)}),s.addClass(e.join(" "))},removeClasses:function(){var e=this.$el,t=this.classNames;e.removeClass(t.join(" "))}},images:{loadImage:function(e,i,s,a,r,n){var o;function l(){n&&n()}e.complete&&r?l():i?((o=new t.Image).onload=l,o.onerror=l,a&&(o.sizes=a),s&&(o.srcset=s),i&&(o.src=i)):l()},preloadImages:function(){var e=this;function t(){void 0!==e&&null!==e&&e&&!e.destroyed&&(void 0!==e.imagesLoaded&&(e.imagesLoaded+=1),e.imagesLoaded===e.imagesToLoad.length&&(e.params.updateOnImagesReady&&e.update(),e.emit("imagesReady")))}e.imagesToLoad=e.$el.find("img");for(var i=0;i1){var u=[];return c.each(function(e,i){var s=d.extend({},r,{el:i});u.push(new t(s))}),u}a.swiper=l,c.data("swiper",l);var v,f,m=c.children("."+l.params.wrapperClass);return d.extend(l,{$el:c,el:a,$wrapperEl:m,wrapperEl:m[0],classNames:[],slides:s(),slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:function(){return"horizontal"===l.params.direction},isVertical:function(){return"vertical"===l.params.direction},rtl:"rtl"===a.dir.toLowerCase()||"rtl"===c.css("direction"),rtlTranslate:"horizontal"===l.params.direction&&("rtl"===a.dir.toLowerCase()||"rtl"===c.css("direction")),wrongRTL:"-webkit-box"===m.css("display"),activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,progress:0,velocity:0,animating:!1,allowSlideNext:l.params.allowSlideNext,allowSlidePrev:l.params.allowSlidePrev,touchEvents:(v=["touchstart","touchmove","touchend"],f=["mousedown","mousemove","mouseup"],h.pointerEvents?f=["pointerdown","pointermove","pointerup"]:h.prefixedPointerEvents&&(f=["MSPointerDown","MSPointerMove","MSPointerUp"]),l.touchEventsTouch={start:v[0],move:v[1],end:v[2]},l.touchEventsDesktop={start:f[0],move:f[1],end:f[2]},h.touch||!l.params.simulateTouch?l.touchEventsTouch:l.touchEventsDesktop),touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,formElements:"input, select, option, textarea, button, video",lastClickTime:d.now(),clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,isTouchEvent:void 0,startMoving:void 0},allowClick:!0,allowTouchMove:l.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),l.useModules(),l.params.init&&l.init(),l}}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var i={extendedDefaults:{configurable:!0},defaults:{configurable:!0},Class:{configurable:!0},$:{configurable:!0}};return t.prototype.slidesPerViewDynamic=function(){var e=this.params,t=this.slides,i=this.slidesGrid,s=this.size,a=this.activeIndex,r=1;if(e.centeredSlides){for(var n,o=t[a].swiperSlideSize,l=a+1;ls&&(n=!0));for(var d=a-1;d>=0;d-=1)t[d]&&!n&&(r+=1,(o+=t[d].swiperSlideSize)>s&&(n=!0))}else for(var h=a+1;h1)&&e.isEnd&&!e.params.centeredSlides?e.slideTo(e.slides.length-1,0,!1,!0):e.slideTo(e.activeIndex,0,!1,!0))||s(),i.watchOverflow&&t!==e.snapGrid&&e.checkOverflow(),e.emit("update")}function s(){var t=e.rtlTranslate?-1*e.translate:e.translate,i=Math.min(Math.max(t,e.maxTranslate()),e.minTranslate());e.setTranslate(i),e.updateActiveIndex(),e.updateSlidesClasses()}},t.prototype.init=function(){this.initialized||(this.emit("beforeInit"),this.params.breakpoints&&this.setBreakpoint(),this.addClasses(),this.params.loop&&this.loopCreate(),this.updateSize(),this.updateSlides(),this.params.watchOverflow&&this.checkOverflow(),this.params.grabCursor&&this.setGrabCursor(),this.params.preloadImages&&this.preloadImages(),this.params.loop?this.slideTo(this.params.initialSlide+this.loopedSlides,0,this.params.runCallbacksOnInit):this.slideTo(this.params.initialSlide,0,this.params.runCallbacksOnInit),this.attachEvents(),this.initialized=!0,this.emit("init"))},t.prototype.destroy=function(e,t){void 0===e&&(e=!0),void 0===t&&(t=!0);var i=this,s=i.params,a=i.$el,r=i.$wrapperEl,n=i.slides;return void 0===i.params||i.destroyed?null:(i.emit("beforeDestroy"),i.initialized=!1,i.detachEvents(),s.loop&&i.loopDestroy(),t&&(i.removeClasses(),a.removeAttr("style"),r.removeAttr("style"),n&&n.length&&n.removeClass([s.slideVisibleClass,s.slideActiveClass,s.slideNextClass,s.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index").removeAttr("data-swiper-column").removeAttr("data-swiper-row")),i.emit("destroy"),Object.keys(i.eventsListeners).forEach(function(e){i.off(e)}),!1!==e&&(i.$el[0].swiper=null,i.$el.data("swiper",null),d.deleteProps(i)),i.destroyed=!0,null)},t.extendDefaults=function(e){d.extend(z,e)},i.extendedDefaults.get=function(){return z},i.defaults.get=function(){return C},i.Class.get=function(){return e},i.$.get=function(){return s},Object.defineProperties(t,i),t}(p),P={name:"device",proto:{device:y},static:{device:y}},$={name:"support",proto:{support:h},static:{support:h}},L={name:"browser",proto:{browser:S},static:{browser:S}},I={name:"resize",create:function(){var e=this;d.extend(e,{resize:{resizeHandler:function(){e&&!e.destroyed&&e.initialized&&(e.emit("beforeResize"),e.emit("resize"))},orientationChangeHandler:function(){e&&!e.destroyed&&e.initialized&&e.emit("orientationchange")}}})},on:{init:function(){t.addEventListener("resize",this.resize.resizeHandler),t.addEventListener("orientationchange",this.resize.orientationChangeHandler)},destroy:function(){t.removeEventListener("resize",this.resize.resizeHandler),t.removeEventListener("orientationchange",this.resize.orientationChangeHandler)}}},D={func:t.MutationObserver||t.WebkitMutationObserver,attach:function(e,t){void 0===t&&(t={});var i=this,s=new(0,D.func)(function(e){e.forEach(function(e){i.emit("observerUpdate",e)})});s.observe(e,{attributes:void 0===t.attributes||t.attributes,childList:void 0===t.childList||t.childList,characterData:void 0===t.characterData||t.characterData}),i.observer.observers.push(s)},init:function(){if(h.observer&&this.params.observer){if(this.params.observeParents)for(var e=this.$el.parents(),t=0;tw)&&t.$wrapperEl.find("."+t.params.slideClass+'[data-swiper-slide-index="'+S+'"]').remove();for(var C=0;C=b&&C<=w&&(void 0===l||e?T.push(C):(C>l&&T.push(C),C'+e+"");return a.attr("data-swiper-slide-index")||a.attr("data-swiper-slide-index",t),i.cache&&(this.virtual.cache[t]=a),a},appendSlide:function(e){this.virtual.slides.push(e),this.virtual.update(!0)},prependSlide:function(e){if(this.virtual.slides.unshift(e),this.params.virtual.cache){var t=this.virtual.cache,i={};Object.keys(t).forEach(function(e){i[e+1]=t[e]}),this.virtual.cache=i}this.virtual.update(!0),this.slideNext(0)}},G={name:"virtual",params:{virtual:{enabled:!1,slides:[],cache:!0,renderSlide:null,renderExternal:null}},create:function(){d.extend(this,{virtual:{update:A.update.bind(this),appendSlide:A.appendSlide.bind(this),prependSlide:A.prependSlide.bind(this),renderSlide:A.renderSlide.bind(this),slides:this.params.virtual.slides,cache:{}}})},on:{beforeInit:function(){if(this.params.virtual.enabled){this.classNames.push(this.params.containerModifierClass+"virtual");var e={watchSlidesProgress:!0};d.extend(this.params,e),d.extend(this.originalParams,e),this.virtual.update()}},setTranslate:function(){this.params.virtual.enabled&&this.virtual.update()}}},H={handle:function(i){var s=this.rtlTranslate,a=i;a.originalEvent&&(a=a.originalEvent);var r=a.keyCode||a.charCode;if(!this.allowSlideNext&&(this.isHorizontal()&&39===r||this.isVertical()&&40===r))return!1;if(!this.allowSlidePrev&&(this.isHorizontal()&&37===r||this.isVertical()&&38===r))return!1;if(!(a.shiftKey||a.altKey||a.ctrlKey||a.metaKey||e.activeElement&&e.activeElement.nodeName&&("input"===e.activeElement.nodeName.toLowerCase()||"textarea"===e.activeElement.nodeName.toLowerCase()))){if(this.params.keyboard.onlyInViewport&&(37===r||39===r||38===r||40===r)){var n=!1;if(this.$el.parents("."+this.params.slideClass).length>0&&0===this.$el.parents("."+this.params.slideActiveClass).length)return;var o=t.innerWidth,l=t.innerHeight,d=this.$el.offset();s&&(d.left-=this.$el[0].scrollLeft);for(var h=[[d.left,d.top],[d.left+this.width,d.top],[d.left,d.top+this.height],[d.left+this.width,d.top+this.height]],p=0;p=0&&c[0]<=o&&c[1]>=0&&c[1]<=l&&(n=!0)}if(!n)return}this.isHorizontal()?(37!==r&&39!==r||(a.preventDefault?a.preventDefault():a.returnValue=!1),(39===r&&!s||37===r&&s)&&this.slideNext(),(37===r&&!s||39===r&&s)&&this.slidePrev()):(38!==r&&40!==r||(a.preventDefault?a.preventDefault():a.returnValue=!1),40===r&&this.slideNext(),38===r&&this.slidePrev()),this.emit("keyPress",r)}},enable:function(){this.keyboard.enabled||(s(e).on("keydown",this.keyboard.handle),this.keyboard.enabled=!0)},disable:function(){this.keyboard.enabled&&(s(e).off("keydown",this.keyboard.handle),this.keyboard.enabled=!1)}},N={name:"keyboard",params:{keyboard:{enabled:!1,onlyInViewport:!0}},create:function(){d.extend(this,{keyboard:{enabled:!1,enable:H.enable.bind(this),disable:H.disable.bind(this),handle:H.handle.bind(this)}})},on:{init:function(){this.params.keyboard.enabled&&this.keyboard.enable()},destroy:function(){this.keyboard.enabled&&this.keyboard.disable()}}};var B={lastScrollTime:d.now(),event:t.navigator.userAgent.indexOf("firefox")>-1?"DOMMouseScroll":function(){var t="onwheel"in e;if(!t){var i=e.createElement("div");i.setAttribute("onwheel","return;"),t="function"==typeof i.onwheel}return!t&&e.implementation&&e.implementation.hasFeature&&!0!==e.implementation.hasFeature("","")&&(t=e.implementation.hasFeature("Events.wheel","3.0")),t}()?"wheel":"mousewheel",normalize:function(e){var t=0,i=0,s=0,a=0;return"detail"in e&&(i=e.detail),"wheelDelta"in e&&(i=-e.wheelDelta/120),"wheelDeltaY"in e&&(i=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=i,i=0),s=10*t,a=10*i,"deltaY"in e&&(a=e.deltaY),"deltaX"in e&&(s=e.deltaX),(s||a)&&e.deltaMode&&(1===e.deltaMode?(s*=40,a*=40):(s*=800,a*=800)),s&&!t&&(t=s<1?-1:1),a&&!i&&(i=a<1?-1:1),{spinX:t,spinY:i,pixelX:s,pixelY:a}},handleMouseEnter:function(){this.mouseEntered=!0},handleMouseLeave:function(){this.mouseEntered=!1},handle:function(e){var i=e,s=this,a=s.params.mousewheel;if(!s.mouseEntered&&!a.releaseOnEdges)return!0;i.originalEvent&&(i=i.originalEvent);var r=0,n=s.rtlTranslate?-1:1,o=B.normalize(i);if(a.forceToAxis)if(s.isHorizontal()){if(!(Math.abs(o.pixelX)>Math.abs(o.pixelY)))return!0;r=o.pixelX*n}else{if(!(Math.abs(o.pixelY)>Math.abs(o.pixelX)))return!0;r=o.pixelY}else r=Math.abs(o.pixelX)>Math.abs(o.pixelY)?-o.pixelX*n:-o.pixelY;if(0===r)return!0;if(a.invert&&(r=-r),s.params.freeMode){s.params.loop&&s.loopFix();var l=s.getTranslate()+r*a.sensitivity,h=s.isBeginning,p=s.isEnd;if(l>=s.minTranslate()&&(l=s.minTranslate()),l<=s.maxTranslate()&&(l=s.maxTranslate()),s.setTransition(0),s.setTranslate(l),s.updateProgress(),s.updateActiveIndex(),s.updateSlidesClasses(),(!h&&s.isBeginning||!p&&s.isEnd)&&s.updateSlidesClasses(),s.params.freeModeSticky&&(clearTimeout(s.mousewheel.timeout),s.mousewheel.timeout=d.nextTick(function(){s.slideToClosest()},300)),s.emit("scroll",i),s.params.autoplay&&s.params.autoplayDisableOnInteraction&&s.stopAutoplay(),l===s.minTranslate()||l===s.maxTranslate())return!0}else{if(d.now()-s.mousewheel.lastScrollTime>60)if(r<0)if(s.isEnd&&!s.params.loop||s.animating){if(a.releaseOnEdges)return!0}else s.slideNext(),s.emit("scroll",i);else if(s.isBeginning&&!s.params.loop||s.animating){if(a.releaseOnEdges)return!0}else s.slidePrev(),s.emit("scroll",i);s.mousewheel.lastScrollTime=(new t.Date).getTime()}return i.preventDefault?i.preventDefault():i.returnValue=!1,!1},enable:function(){if(!B.event)return!1;if(this.mousewheel.enabled)return!1;var e=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(e=s(this.params.mousewheel.eventsTarged)),e.on("mouseenter",this.mousewheel.handleMouseEnter),e.on("mouseleave",this.mousewheel.handleMouseLeave),e.on(B.event,this.mousewheel.handle),this.mousewheel.enabled=!0,!0},disable:function(){if(!B.event)return!1;if(!this.mousewheel.enabled)return!1;var e=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(e=s(this.params.mousewheel.eventsTarged)),e.off(B.event,this.mousewheel.handle),this.mousewheel.enabled=!1,!0}},X={update:function(){var e=this.params.navigation;if(!this.params.loop){var t=this.navigation,i=t.$nextEl,s=t.$prevEl;s&&s.length>0&&(this.isBeginning?s.addClass(e.disabledClass):s.removeClass(e.disabledClass),s[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](e.lockClass)),i&&i.length>0&&(this.isEnd?i.addClass(e.disabledClass):i.removeClass(e.disabledClass),i[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](e.lockClass))}},init:function(){var e,t,i=this,a=i.params.navigation;(a.nextEl||a.prevEl)&&(a.nextEl&&(e=s(a.nextEl),i.params.uniqueNavElements&&"string"==typeof a.nextEl&&e.length>1&&1===i.$el.find(a.nextEl).length&&(e=i.$el.find(a.nextEl))),a.prevEl&&(t=s(a.prevEl),i.params.uniqueNavElements&&"string"==typeof a.prevEl&&t.length>1&&1===i.$el.find(a.prevEl).length&&(t=i.$el.find(a.prevEl))),e&&e.length>0&&e.on("click",function(e){e.preventDefault(),i.isEnd&&!i.params.loop||i.slideNext()}),t&&t.length>0&&t.on("click",function(e){e.preventDefault(),i.isBeginning&&!i.params.loop||i.slidePrev()}),d.extend(i.navigation,{$nextEl:e,nextEl:e&&e[0],$prevEl:t,prevEl:t&&t[0]}))},destroy:function(){var e=this.navigation,t=e.$nextEl,i=e.$prevEl;t&&t.length&&(t.off("click"),t.removeClass(this.params.navigation.disabledClass)),i&&i.length&&(i.off("click"),i.removeClass(this.params.navigation.disabledClass))}},Y={update:function(){var e=this.rtl,t=this.params.pagination;if(t.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var i,a=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,r=this.pagination.$el,n=this.params.loop?Math.ceil((a-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length;if(this.params.loop?((i=Math.ceil((this.activeIndex-this.loopedSlides)/this.params.slidesPerGroup))>a-1-2*this.loopedSlides&&(i-=a-2*this.loopedSlides),i>n-1&&(i-=n),i<0&&"bullets"!==this.params.paginationType&&(i=n+i)):i=void 0!==this.snapIndex?this.snapIndex:this.activeIndex||0,"bullets"===t.type&&this.pagination.bullets&&this.pagination.bullets.length>0){var o,l,d,h=this.pagination.bullets;if(t.dynamicBullets&&(this.pagination.bulletSize=h.eq(0)[this.isHorizontal()?"outerWidth":"outerHeight"](!0),r.css(this.isHorizontal()?"width":"height",this.pagination.bulletSize*(t.dynamicMainBullets+4)+"px"),t.dynamicMainBullets>1&&void 0!==this.previousIndex&&(this.pagination.dynamicBulletIndex+=i-this.previousIndex,this.pagination.dynamicBulletIndex>t.dynamicMainBullets-1?this.pagination.dynamicBulletIndex=t.dynamicMainBullets-1:this.pagination.dynamicBulletIndex<0&&(this.pagination.dynamicBulletIndex=0)),o=i-this.pagination.dynamicBulletIndex,d=((l=o+(Math.min(h.length,t.dynamicMainBullets)-1))+o)/2),h.removeClass(t.bulletActiveClass+" "+t.bulletActiveClass+"-next "+t.bulletActiveClass+"-next-next "+t.bulletActiveClass+"-prev "+t.bulletActiveClass+"-prev-prev "+t.bulletActiveClass+"-main"),r.length>1)h.each(function(e,a){var r=s(a),n=r.index();n===i&&r.addClass(t.bulletActiveClass),t.dynamicBullets&&(n>=o&&n<=l&&r.addClass(t.bulletActiveClass+"-main"),n===o&&r.prev().addClass(t.bulletActiveClass+"-prev").prev().addClass(t.bulletActiveClass+"-prev-prev"),n===l&&r.next().addClass(t.bulletActiveClass+"-next").next().addClass(t.bulletActiveClass+"-next-next"))});else if(h.eq(i).addClass(t.bulletActiveClass),t.dynamicBullets){for(var p=h.eq(o),c=h.eq(l),u=o;u<=l;u+=1)h.eq(u).addClass(t.bulletActiveClass+"-main");p.prev().addClass(t.bulletActiveClass+"-prev").prev().addClass(t.bulletActiveClass+"-prev-prev"),c.next().addClass(t.bulletActiveClass+"-next").next().addClass(t.bulletActiveClass+"-next-next")}if(t.dynamicBullets){var v=Math.min(h.length,t.dynamicMainBullets+4),f=(this.pagination.bulletSize*v-this.pagination.bulletSize)/2-d*this.pagination.bulletSize,m=e?"right":"left";h.css(this.isHorizontal()?m:"top",f+"px")}}if("fraction"===t.type&&(r.find("."+t.currentClass).text(i+1),r.find("."+t.totalClass).text(n)),"progressbar"===t.type){var g;g=t.progressbarOpposite?this.isHorizontal()?"vertical":"horizontal":this.isHorizontal()?"horizontal":"vertical";var b=(i+1)/n,w=1,y=1;"horizontal"===g?w=b:y=b,r.find("."+t.progressbarFillClass).transform("translate3d(0,0,0) scaleX("+w+") scaleY("+y+")").transition(this.params.speed)}"custom"===t.type&&t.renderCustom?(r.html(t.renderCustom(this,i+1,n)),this.emit("paginationRender",this,r[0])):this.emit("paginationUpdate",this,r[0]),r[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](t.lockClass)}},render:function(){var e=this.params.pagination;if(e.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var t=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,i=this.pagination.$el,s="";if("bullets"===e.type){for(var a=this.params.loop?Math.ceil((t-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length,r=0;r";i.html(s),this.pagination.bullets=i.find("."+e.bulletClass)}"fraction"===e.type&&(s=e.renderFraction?e.renderFraction.call(this,e.currentClass,e.totalClass):' / ',i.html(s)),"progressbar"===e.type&&(s=e.renderProgressbar?e.renderProgressbar.call(this,e.progressbarFillClass):'',i.html(s)),"custom"!==e.type&&this.emit("paginationRender",this.pagination.$el[0])}},init:function(){var e=this,t=e.params.pagination;if(t.el){var i=s(t.el);0!==i.length&&(e.params.uniqueNavElements&&"string"==typeof t.el&&i.length>1&&1===e.$el.find(t.el).length&&(i=e.$el.find(t.el)),"bullets"===t.type&&t.clickable&&i.addClass(t.clickableClass),i.addClass(t.modifierClass+t.type),"bullets"===t.type&&t.dynamicBullets&&(i.addClass(""+t.modifierClass+t.type+"-dynamic"),e.pagination.dynamicBulletIndex=0,t.dynamicMainBullets<1&&(t.dynamicMainBullets=1)),"progressbar"===t.type&&t.progressbarOpposite&&i.addClass(t.progressbarOppositeClass),t.clickable&&i.on("click","."+t.bulletClass,function(t){t.preventDefault();var i=s(this).index()*e.params.slidesPerGroup;e.params.loop&&(i+=e.loopedSlides),e.slideTo(i)}),d.extend(e.pagination,{$el:i,el:i[0]}))}},destroy:function(){var e=this.params.pagination;if(e.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var t=this.pagination.$el;t.removeClass(e.hiddenClass),t.removeClass(e.modifierClass+e.type),this.pagination.bullets&&this.pagination.bullets.removeClass(e.bulletActiveClass),e.clickable&&t.off("click","."+e.bulletClass)}}},V={setTranslate:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var e=this.scrollbar,t=this.rtlTranslate,i=this.progress,s=e.dragSize,a=e.trackSize,r=e.$dragEl,n=e.$el,o=this.params.scrollbar,l=s,d=(a-s)*i;t?(d=-d)>0?(l=s-d,d=0):-d+s>a&&(l=a+d):d<0?(l=s+d,d=0):d+s>a&&(l=a-d),this.isHorizontal()?(h.transforms3d?r.transform("translate3d("+d+"px, 0, 0)"):r.transform("translateX("+d+"px)"),r[0].style.width=l+"px"):(h.transforms3d?r.transform("translate3d(0px, "+d+"px, 0)"):r.transform("translateY("+d+"px)"),r[0].style.height=l+"px"),o.hide&&(clearTimeout(this.scrollbar.timeout),n[0].style.opacity=1,this.scrollbar.timeout=setTimeout(function(){n[0].style.opacity=0,n.transition(400)},1e3))}},setTransition:function(e){this.params.scrollbar.el&&this.scrollbar.el&&this.scrollbar.$dragEl.transition(e)},updateSize:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var e=this.scrollbar,t=e.$dragEl,i=e.$el;t[0].style.width="",t[0].style.height="";var s,a=this.isHorizontal()?i[0].offsetWidth:i[0].offsetHeight,r=this.size/this.virtualSize,n=r*(a/this.size);s="auto"===this.params.scrollbar.dragSize?a*r:parseInt(this.params.scrollbar.dragSize,10),this.isHorizontal()?t[0].style.width=s+"px":t[0].style.height=s+"px",i[0].style.display=r>=1?"none":"",this.params.scrollbarHide&&(i[0].style.opacity=0),d.extend(e,{trackSize:a,divider:r,moveDivider:n,dragSize:s}),e.$el[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](this.params.scrollbar.lockClass)}},setDragPosition:function(e){var t,i=this.scrollbar,s=this.rtlTranslate,a=i.$el,r=i.dragSize,n=i.trackSize;t=((this.isHorizontal()?"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].pageX:e.pageX||e.clientX:"touchstart"===e.type||"touchmove"===e.type?e.targetTouches[0].pageY:e.pageY||e.clientY)-a.offset()[this.isHorizontal()?"left":"top"]-r/2)/(n-r),t=Math.max(Math.min(t,1),0),s&&(t=1-t);var o=this.minTranslate()+(this.maxTranslate()-this.minTranslate())*t;this.updateProgress(o),this.setTranslate(o),this.updateActiveIndex(),this.updateSlidesClasses()},onDragStart:function(e){var t=this.params.scrollbar,i=this.scrollbar,s=this.$wrapperEl,a=i.$el,r=i.$dragEl;this.scrollbar.isTouched=!0,e.preventDefault(),e.stopPropagation(),s.transition(100),r.transition(100),i.setDragPosition(e),clearTimeout(this.scrollbar.dragTimeout),a.transition(0),t.hide&&a.css("opacity",1),this.emit("scrollbarDragStart",e)},onDragMove:function(e){var t=this.scrollbar,i=this.$wrapperEl,s=t.$el,a=t.$dragEl;this.scrollbar.isTouched&&(e.preventDefault?e.preventDefault():e.returnValue=!1,t.setDragPosition(e),i.transition(0),s.transition(0),a.transition(0),this.emit("scrollbarDragMove",e))},onDragEnd:function(e){var t=this.params.scrollbar,i=this.scrollbar.$el;this.scrollbar.isTouched&&(this.scrollbar.isTouched=!1,t.hide&&(clearTimeout(this.scrollbar.dragTimeout),this.scrollbar.dragTimeout=d.nextTick(function(){i.css("opacity",0),i.transition(400)},1e3)),this.emit("scrollbarDragEnd",e),t.snapOnRelease&&this.slideToClosest())},enableDraggable:function(){if(this.params.scrollbar.el){var t=this.scrollbar,i=this.touchEvents,s=this.touchEventsDesktop,a=this.params,r=t.$el[0],n=!(!h.passiveListener||!a.passiveListener)&&{passive:!1,capture:!1},o=!(!h.passiveListener||!a.passiveListener)&&{passive:!0,capture:!1};h.touch||!h.pointerEvents&&!h.prefixedPointerEvents?(h.touch&&(r.addEventListener(i.start,this.scrollbar.onDragStart,n),r.addEventListener(i.move,this.scrollbar.onDragMove,n),r.addEventListener(i.end,this.scrollbar.onDragEnd,o)),(a.simulateTouch&&!y.ios&&!y.android||a.simulateTouch&&!h.touch&&y.ios)&&(r.addEventListener("mousedown",this.scrollbar.onDragStart,n),e.addEventListener("mousemove",this.scrollbar.onDragMove,n),e.addEventListener("mouseup",this.scrollbar.onDragEnd,o))):(r.addEventListener(s.start,this.scrollbar.onDragStart,n),e.addEventListener(s.move,this.scrollbar.onDragMove,n),e.addEventListener(s.end,this.scrollbar.onDragEnd,o))}},disableDraggable:function(){if(this.params.scrollbar.el){var t=this.scrollbar,i=this.touchEvents,s=this.touchEventsDesktop,a=this.params,r=t.$el[0],n=!(!h.passiveListener||!a.passiveListener)&&{passive:!1,capture:!1},o=!(!h.passiveListener||!a.passiveListener)&&{passive:!0,capture:!1};h.touch||!h.pointerEvents&&!h.prefixedPointerEvents?(h.touch&&(r.removeEventListener(i.start,this.scrollbar.onDragStart,n),r.removeEventListener(i.move,this.scrollbar.onDragMove,n),r.removeEventListener(i.end,this.scrollbar.onDragEnd,o)),(a.simulateTouch&&!y.ios&&!y.android||a.simulateTouch&&!h.touch&&y.ios)&&(r.removeEventListener("mousedown",this.scrollbar.onDragStart,n),e.removeEventListener("mousemove",this.scrollbar.onDragMove,n),e.removeEventListener("mouseup",this.scrollbar.onDragEnd,o))):(r.removeEventListener(s.start,this.scrollbar.onDragStart,n),e.removeEventListener(s.move,this.scrollbar.onDragMove,n),e.removeEventListener(s.end,this.scrollbar.onDragEnd,o))}},init:function(){if(this.params.scrollbar.el){var e=this.scrollbar,t=this.$el,i=this.params.scrollbar,a=s(i.el);this.params.uniqueNavElements&&"string"==typeof i.el&&a.length>1&&1===t.find(i.el).length&&(a=t.find(i.el));var r=a.find("."+this.params.scrollbar.dragClass);0===r.length&&(r=s('
    '),a.append(r)),d.extend(e,{$el:a,el:a[0],$dragEl:r,dragEl:r[0]}),i.draggable&&e.enableDraggable()}},destroy:function(){this.scrollbar.disableDraggable()}},R={setTransform:function(e,t){var i=this.rtl,a=s(e),r=i?-1:1,n=a.attr("data-swiper-parallax")||"0",o=a.attr("data-swiper-parallax-x"),l=a.attr("data-swiper-parallax-y"),d=a.attr("data-swiper-parallax-scale"),h=a.attr("data-swiper-parallax-opacity");if(o||l?(o=o||"0",l=l||"0"):this.isHorizontal()?(o=n,l="0"):(l=n,o="0"),o=o.indexOf("%")>=0?parseInt(o,10)*t*r+"%":o*t*r+"px",l=l.indexOf("%")>=0?parseInt(l,10)*t+"%":l*t+"px",void 0!==h&&null!==h){var p=h-(h-1)*(1-Math.abs(t));a[0].style.opacity=p}if(void 0===d||null===d)a.transform("translate3d("+o+", "+l+", 0px)");else{var c=d-(d-1)*(1-Math.abs(t));a.transform("translate3d("+o+", "+l+", 0px) scale("+c+")")}},setTranslate:function(){var e=this,t=e.$el,i=e.slides,a=e.progress,r=e.snapGrid;t.children("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function(t,i){e.parallax.setTransform(i,a)}),i.each(function(t,i){var n=i.progress;e.params.slidesPerGroup>1&&"auto"!==e.params.slidesPerView&&(n+=Math.ceil(t/2)-a*(r.length-1)),n=Math.min(Math.max(n,-1),1),s(i).find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function(t,i){e.parallax.setTransform(i,n)})})},setTransition:function(e){void 0===e&&(e=this.params.speed);this.$el.find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]").each(function(t,i){var a=s(i),r=parseInt(a.attr("data-swiper-parallax-duration"),10)||e;0===e&&(r=0),a.transition(r)})}},F={getDistanceBetweenTouches:function(e){if(e.targetTouches.length<2)return 1;var t=e.targetTouches[0].pageX,i=e.targetTouches[0].pageY,s=e.targetTouches[1].pageX,a=e.targetTouches[1].pageY;return Math.sqrt(Math.pow(s-t,2)+Math.pow(a-i,2))},onGestureStart:function(e){var t=this.params.zoom,i=this.zoom,a=i.gesture;if(i.fakeGestureTouched=!1,i.fakeGestureMoved=!1,!h.gestures){if("touchstart"!==e.type||"touchstart"===e.type&&e.targetTouches.length<2)return;i.fakeGestureTouched=!0,a.scaleStart=F.getDistanceBetweenTouches(e)}a.$slideEl&&a.$slideEl.length||(a.$slideEl=s(e.target).closest(".swiper-slide"),0===a.$slideEl.length&&(a.$slideEl=this.slides.eq(this.activeIndex)),a.$imageEl=a.$slideEl.find("img, svg, canvas"),a.$imageWrapEl=a.$imageEl.parent("."+t.containerClass),a.maxRatio=a.$imageWrapEl.attr("data-swiper-zoom")||t.maxRatio,0!==a.$imageWrapEl.length)?(a.$imageEl.transition(0),this.zoom.isScaling=!0):a.$imageEl=void 0},onGestureChange:function(e){var t=this.params.zoom,i=this.zoom,s=i.gesture;if(!h.gestures){if("touchmove"!==e.type||"touchmove"===e.type&&e.targetTouches.length<2)return;i.fakeGestureMoved=!0,s.scaleMove=F.getDistanceBetweenTouches(e)}s.$imageEl&&0!==s.$imageEl.length&&(h.gestures?this.zoom.scale=e.scale*i.currentScale:i.scale=s.scaleMove/s.scaleStart*i.currentScale,i.scale>s.maxRatio&&(i.scale=s.maxRatio-1+Math.pow(i.scale-s.maxRatio+1,.5)),i.scales.touchesStart.x))return void(s.isTouched=!1);if(!this.isHorizontal()&&(Math.floor(s.minY)===Math.floor(s.startY)&&s.touchesCurrent.ys.touchesStart.y))return void(s.isTouched=!1)}e.preventDefault(),e.stopPropagation(),s.isMoved=!0,s.currentX=s.touchesCurrent.x-s.touchesStart.x+s.startX,s.currentY=s.touchesCurrent.y-s.touchesStart.y+s.startY,s.currentXs.maxX&&(s.currentX=s.maxX-1+Math.pow(s.currentX-s.maxX+1,.8)),s.currentYs.maxY&&(s.currentY=s.maxY-1+Math.pow(s.currentY-s.maxY+1,.8)),a.prevPositionX||(a.prevPositionX=s.touchesCurrent.x),a.prevPositionY||(a.prevPositionY=s.touchesCurrent.y),a.prevTime||(a.prevTime=Date.now()),a.x=(s.touchesCurrent.x-a.prevPositionX)/(Date.now()-a.prevTime)/2,a.y=(s.touchesCurrent.y-a.prevPositionY)/(Date.now()-a.prevTime)/2,Math.abs(s.touchesCurrent.x-a.prevPositionX)<2&&(a.x=0),Math.abs(s.touchesCurrent.y-a.prevPositionY)<2&&(a.y=0),a.prevPositionX=s.touchesCurrent.x,a.prevPositionY=s.touchesCurrent.y,a.prevTime=Date.now(),i.$imageWrapEl.transform("translate3d("+s.currentX+"px, "+s.currentY+"px,0)")}}},onTouchEnd:function(){var e=this.zoom,t=e.gesture,i=e.image,s=e.velocity;if(t.$imageEl&&0!==t.$imageEl.length){if(!i.isTouched||!i.isMoved)return i.isTouched=!1,void(i.isMoved=!1);i.isTouched=!1,i.isMoved=!1;var a=300,r=300,n=s.x*a,o=i.currentX+n,l=s.y*r,d=i.currentY+l;0!==s.x&&(a=Math.abs((o-i.currentX)/s.x)),0!==s.y&&(r=Math.abs((d-i.currentY)/s.y));var h=Math.max(a,r);i.currentX=o,i.currentY=d;var p=i.width*e.scale,c=i.height*e.scale;i.minX=Math.min(t.slideWidth/2-p/2,0),i.maxX=-i.minX,i.minY=Math.min(t.slideHeight/2-c/2,0),i.maxY=-i.minY,i.currentX=Math.max(Math.min(i.currentX,i.maxX),i.minX),i.currentY=Math.max(Math.min(i.currentY,i.maxY),i.minY),t.$imageWrapEl.transition(h).transform("translate3d("+i.currentX+"px, "+i.currentY+"px,0)")}},onTransitionEnd:function(){var e=this.zoom,t=e.gesture;t.$slideEl&&this.previousIndex!==this.activeIndex&&(t.$imageEl.transform("translate3d(0,0,0) scale(1)"),t.$imageWrapEl.transform("translate3d(0,0,0)"),t.$slideEl=void 0,t.$imageEl=void 0,t.$imageWrapEl=void 0,e.scale=1,e.currentScale=1)},toggle:function(e){var t=this.zoom;t.scale&&1!==t.scale?t.out():t.in(e)},in:function(e){var t,i,a,r,n,o,l,d,h,p,c,u,v,f,m,g,b=this.zoom,w=this.params.zoom,y=b.gesture,x=b.image;(y.$slideEl||(y.$slideEl=this.clickedSlide?s(this.clickedSlide):this.slides.eq(this.activeIndex),y.$imageEl=y.$slideEl.find("img, svg, canvas"),y.$imageWrapEl=y.$imageEl.parent("."+w.containerClass)),y.$imageEl&&0!==y.$imageEl.length)&&(y.$slideEl.addClass(""+w.zoomedSlideClass),void 0===x.touchesStart.x&&e?(t="touchend"===e.type?e.changedTouches[0].pageX:e.pageX,i="touchend"===e.type?e.changedTouches[0].pageY:e.pageY):(t=x.touchesStart.x,i=x.touchesStart.y),b.scale=y.$imageWrapEl.attr("data-swiper-zoom")||w.maxRatio,b.currentScale=y.$imageWrapEl.attr("data-swiper-zoom")||w.maxRatio,e?(m=y.$slideEl[0].offsetWidth,g=y.$slideEl[0].offsetHeight,a=y.$slideEl.offset().left+m/2-t,r=y.$slideEl.offset().top+g/2-i,l=y.$imageEl[0].offsetWidth,d=y.$imageEl[0].offsetHeight,h=l*b.scale,p=d*b.scale,v=-(c=Math.min(m/2-h/2,0)),f=-(u=Math.min(g/2-p/2,0)),n=a*b.scale,o=r*b.scale,nv&&(n=v),of&&(o=f)):(n=0,o=0),y.$imageWrapEl.transition(300).transform("translate3d("+n+"px, "+o+"px,0)"),y.$imageEl.transition(300).transform("translate3d(0,0,0) scale("+b.scale+")"))},out:function(){var e=this.zoom,t=this.params.zoom,i=e.gesture;i.$slideEl||(i.$slideEl=this.clickedSlide?s(this.clickedSlide):this.slides.eq(this.activeIndex),i.$imageEl=i.$slideEl.find("img, svg, canvas"),i.$imageWrapEl=i.$imageEl.parent("."+t.containerClass)),i.$imageEl&&0!==i.$imageEl.length&&(e.scale=1,e.currentScale=1,i.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"),i.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"),i.$slideEl.removeClass(""+t.zoomedSlideClass),i.$slideEl=void 0)},enable:function(){var e=this.zoom;if(!e.enabled){e.enabled=!0;var t=!("touchstart"!==this.touchEvents.start||!h.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1};h.gestures?(this.$wrapperEl.on("gesturestart",".swiper-slide",e.onGestureStart,t),this.$wrapperEl.on("gesturechange",".swiper-slide",e.onGestureChange,t),this.$wrapperEl.on("gestureend",".swiper-slide",e.onGestureEnd,t)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.on(this.touchEvents.start,".swiper-slide",e.onGestureStart,t),this.$wrapperEl.on(this.touchEvents.move,".swiper-slide",e.onGestureChange,t),this.$wrapperEl.on(this.touchEvents.end,".swiper-slide",e.onGestureEnd,t)),this.$wrapperEl.on(this.touchEvents.move,"."+this.params.zoom.containerClass,e.onTouchMove)}},disable:function(){var e=this.zoom;if(e.enabled){this.zoom.enabled=!1;var t=!("touchstart"!==this.touchEvents.start||!h.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1};h.gestures?(this.$wrapperEl.off("gesturestart",".swiper-slide",e.onGestureStart,t),this.$wrapperEl.off("gesturechange",".swiper-slide",e.onGestureChange,t),this.$wrapperEl.off("gestureend",".swiper-slide",e.onGestureEnd,t)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.off(this.touchEvents.start,".swiper-slide",e.onGestureStart,t),this.$wrapperEl.off(this.touchEvents.move,".swiper-slide",e.onGestureChange,t),this.$wrapperEl.off(this.touchEvents.end,".swiper-slide",e.onGestureEnd,t)),this.$wrapperEl.off(this.touchEvents.move,"."+this.params.zoom.containerClass,e.onTouchMove)}}},W={loadInSlide:function(e,t){void 0===t&&(t=!0);var i=this,a=i.params.lazy;if(void 0!==e&&0!==i.slides.length){var r=i.virtual&&i.params.virtual.enabled?i.$wrapperEl.children("."+i.params.slideClass+'[data-swiper-slide-index="'+e+'"]'):i.slides.eq(e),n=r.find("."+a.elementClass+":not(."+a.loadedClass+"):not(."+a.loadingClass+")");!r.hasClass(a.elementClass)||r.hasClass(a.loadedClass)||r.hasClass(a.loadingClass)||(n=n.add(r[0])),0!==n.length&&n.each(function(e,n){var o=s(n);o.addClass(a.loadingClass);var l=o.attr("data-background"),d=o.attr("data-src"),h=o.attr("data-srcset"),p=o.attr("data-sizes");i.loadImage(o[0],d||l,h,p,!1,function(){if(void 0!==i&&null!==i&&i&&(!i||i.params)&&!i.destroyed){if(l?(o.css("background-image",'url("'+l+'")'),o.removeAttr("data-background")):(h&&(o.attr("srcset",h),o.removeAttr("data-srcset")),p&&(o.attr("sizes",p),o.removeAttr("data-sizes")),d&&(o.attr("src",d),o.removeAttr("data-src"))),o.addClass(a.loadedClass).removeClass(a.loadingClass),r.find("."+a.preloaderClass).remove(),i.params.loop&&t){var e=r.attr("data-swiper-slide-index");if(r.hasClass(i.params.slideDuplicateClass)){var s=i.$wrapperEl.children('[data-swiper-slide-index="'+e+'"]:not(.'+i.params.slideDuplicateClass+")");i.lazy.loadInSlide(s.index(),!1)}else{var n=i.$wrapperEl.children("."+i.params.slideDuplicateClass+'[data-swiper-slide-index="'+e+'"]');i.lazy.loadInSlide(n.index(),!1)}}i.emit("lazyImageReady",r[0],o[0])}}),i.emit("lazyImageLoad",r[0],o[0])})}},load:function(){var e=this,t=e.$wrapperEl,i=e.params,a=e.slides,r=e.activeIndex,n=e.virtual&&i.virtual.enabled,o=i.lazy,l=i.slidesPerView;function d(e){if(n){if(t.children("."+i.slideClass+'[data-swiper-slide-index="'+e+'"]').length)return!0}else if(a[e])return!0;return!1}function h(e){return n?s(e).attr("data-swiper-slide-index"):s(e).index()}if("auto"===l&&(l=0),e.lazy.initialImageLoaded||(e.lazy.initialImageLoaded=!0),e.params.watchSlidesVisibility)t.children("."+i.slideVisibleClass).each(function(t,i){var a=n?s(i).attr("data-swiper-slide-index"):s(i).index();e.lazy.loadInSlide(a)});else if(l>1)for(var p=r;p1||o.loadPrevNextAmount&&o.loadPrevNextAmount>1){for(var c=o.loadPrevNextAmount,u=l,v=Math.min(r+u+Math.max(c,u),a.length),f=Math.max(r-Math.max(u,c),0),m=r+l;m0&&e.lazy.loadInSlide(h(b));var w=t.children("."+i.slidePrevClass);w.length>0&&e.lazy.loadInSlide(h(w))}}},q={LinearSpline:function(e,t){var i,s,a,r,n,o=function(e,t){for(s=-1,i=e.length;i-s>1;)e[a=i+s>>1]<=t?s=a:i=a;return i};return this.x=e,this.y=t,this.lastIndex=e.length-1,this.interpolate=function(e){return e?(n=o(this.x,e),r=n-1,(e-this.x[r])*(this.y[n]-this.y[r])/(this.x[n]-this.x[r])+this.y[r]):0},this},getInterpolateFunction:function(e){this.controller.spline||(this.controller.spline=this.params.loop?new q.LinearSpline(this.slidesGrid,e.slidesGrid):new q.LinearSpline(this.snapGrid,e.snapGrid))},setTranslate:function(e,t){var i,s,a=this,r=a.controller.control;function n(e){var t=a.rtlTranslate?-a.translate:a.translate;"slide"===a.params.controller.by&&(a.controller.getInterpolateFunction(e),s=-a.controller.spline.interpolate(-t)),s&&"container"!==a.params.controller.by||(i=(e.maxTranslate()-e.minTranslate())/(a.maxTranslate()-a.minTranslate()),s=(t-a.minTranslate())*i+e.minTranslate()),a.params.controller.inverse&&(s=e.maxTranslate()-s),e.updateProgress(s),e.setTranslate(s,a),e.updateActiveIndex(),e.updateSlidesClasses()}if(Array.isArray(r))for(var o=0;o0&&(this.isBeginning?this.a11y.disableEl(i):this.a11y.enableEl(i)),t&&t.length>0&&(this.isEnd?this.a11y.disableEl(t):this.a11y.enableEl(t))}},updatePagination:function(){var e=this,t=e.params.a11y;e.pagination&&e.params.pagination.clickable&&e.pagination.bullets&&e.pagination.bullets.length&&e.pagination.bullets.each(function(i,a){var r=s(a);e.a11y.makeElFocusable(r),e.a11y.addElRole(r,"button"),e.a11y.addElLabel(r,t.paginationBulletMessage.replace(/{{index}}/,r.index()+1))})},init:function(){this.$el.append(this.a11y.liveRegion);var e,t,i=this.params.a11y;this.navigation&&this.navigation.$nextEl&&(e=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(t=this.navigation.$prevEl),e&&(this.a11y.makeElFocusable(e),this.a11y.addElRole(e,"button"),this.a11y.addElLabel(e,i.nextSlideMessage),e.on("keydown",this.a11y.onEnterKey)),t&&(this.a11y.makeElFocusable(t),this.a11y.addElRole(t,"button"),this.a11y.addElLabel(t,i.prevSlideMessage),t.on("keydown",this.a11y.onEnterKey)),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.on("keydown","."+this.params.pagination.bulletClass,this.a11y.onEnterKey)},destroy:function(){var e,t;this.a11y.liveRegion&&this.a11y.liveRegion.length>0&&this.a11y.liveRegion.remove(),this.navigation&&this.navigation.$nextEl&&(e=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(t=this.navigation.$prevEl),e&&e.off("keydown",this.a11y.onEnterKey),t&&t.off("keydown",this.a11y.onEnterKey),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.off("keydown","."+this.params.pagination.bulletClass,this.a11y.onEnterKey)}},K={init:function(){if(this.params.history){if(!t.history||!t.history.pushState)return this.params.history.enabled=!1,void(this.params.hashNavigation.enabled=!0);var e=this.history;e.initialized=!0,e.paths=K.getPathValues(),(e.paths.key||e.paths.value)&&(e.scrollToSlide(0,e.paths.value,this.params.runCallbacksOnInit),this.params.history.replaceState||t.addEventListener("popstate",this.history.setHistoryPopState))}},destroy:function(){this.params.history.replaceState||t.removeEventListener("popstate",this.history.setHistoryPopState)},setHistoryPopState:function(){this.history.paths=K.getPathValues(),this.history.scrollToSlide(this.params.speed,this.history.paths.value,!1)},getPathValues:function(){var e=t.location.pathname.slice(1).split("/").filter(function(e){return""!==e}),i=e.length;return{key:e[i-2],value:e[i-1]}},setHistory:function(e,i){if(this.history.initialized&&this.params.history.enabled){var s=this.slides.eq(i),a=K.slugify(s.attr("data-history"));t.location.pathname.includes(e)||(a=e+"/"+a);var r=t.history.state;r&&r.value===a||(this.params.history.replaceState?t.history.replaceState({value:a},null,a):t.history.pushState({value:a},null,a))}},slugify:function(e){return e.toString().toLowerCase().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,"")},scrollToSlide:function(e,t,i){if(t)for(var s=0,a=this.slides.length;s'),i.append(e)),e.css({height:r+"px"})):0===(e=t.find(".swiper-cube-shadow")).length&&(e=s('
    '),t.append(e)));for(var u=0;u-1&&(c=90*f+90*b,o&&(c=90*-f-90*b)),v.transform(E),d.slideShadows){var T=h?v.find(".swiper-slide-shadow-left"):v.find(".swiper-slide-shadow-top"),C=h?v.find(".swiper-slide-shadow-right"):v.find(".swiper-slide-shadow-bottom");0===T.length&&(T=s('
    '),v.append(T)),0===C.length&&(C=s('
    '),v.append(C)),T.length&&(T[0].style.opacity=Math.max(-b,0)),C.length&&(C[0].style.opacity=Math.max(b,0))}}if(i.css({"-webkit-transform-origin":"50% 50% -"+l/2+"px","-moz-transform-origin":"50% 50% -"+l/2+"px","-ms-transform-origin":"50% 50% -"+l/2+"px","transform-origin":"50% 50% -"+l/2+"px"}),d.shadow)if(h)e.transform("translate3d(0px, "+(r/2+d.shadowOffset)+"px, "+-r/2+"px) rotateX(90deg) rotateZ(0deg) scale("+d.shadowScale+")");else{var M=Math.abs(c)-90*Math.floor(Math.abs(c)/90),z=1.5-(Math.sin(2*M*Math.PI/360)/2+Math.cos(2*M*Math.PI/360)/2),k=d.shadowScale,P=d.shadowScale/z,$=d.shadowOffset;e.transform("scale3d("+k+", 1, "+P+") translate3d(0px, "+(n/2+$)+"px, "+-n/2/P+"px) rotateX(-90deg)")}var L=S.isSafari||S.isUiWebView?-l/2:0;i.transform("translate3d(0px,0,"+L+"px) rotateX("+(this.isHorizontal()?0:c)+"deg) rotateY("+(this.isHorizontal()?-c:0)+"deg)")},setTransition:function(e){var t=this.$el;this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),this.params.cubeEffect.shadow&&!this.isHorizontal()&&t.find(".swiper-cube-shadow").transition(e)}},J={setTranslate:function(){for(var e=this.slides,t=this.rtlTranslate,i=0;i'),a.append(h)),0===p.length&&(p=s('
    '),a.append(p)),h.length&&(h[0].style.opacity=Math.max(-r,0)),p.length&&(p[0].style.opacity=Math.max(r,0))}a.transform("translate3d("+l+"px, "+d+"px, 0px) rotateX("+o+"deg) rotateY("+n+"deg)")}},setTransition:function(e){var t=this,i=t.slides,s=t.activeIndex,a=t.$wrapperEl;if(i.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e),t.params.virtualTranslate&&0!==e){var r=!1;i.eq(s).transitionEnd(function(){if(!r&&t&&!t.destroyed){r=!0,t.animating=!1;for(var e=["webkitTransitionEnd","transitionend"],i=0;i'),f.append(S)),0===C.length&&(C=s('
    '),f.append(C)),S.length&&(S[0].style.opacity=g>0?g:0),C.length&&(C[0].style.opacity=-g>0?-g:0)}}(h.pointerEvents||h.prefixedPointerEvents)&&(a[0].style.perspectiveOrigin=d+"px 50%")},setTransition:function(e){this.slides.transition(e).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(e)}},te=[P,$,L,I,O,G,N,{name:"mousewheel",params:{mousewheel:{enabled:!1,releaseOnEdges:!1,invert:!1,forceToAxis:!1,sensitivity:1,eventsTarged:"container"}},create:function(){d.extend(this,{mousewheel:{enabled:!1,enable:B.enable.bind(this),disable:B.disable.bind(this),handle:B.handle.bind(this),handleMouseEnter:B.handleMouseEnter.bind(this),handleMouseLeave:B.handleMouseLeave.bind(this),lastScrollTime:d.now()}})},on:{init:function(){this.params.mousewheel.enabled&&this.mousewheel.enable()},destroy:function(){this.mousewheel.enabled&&this.mousewheel.disable()}}},{name:"navigation",params:{navigation:{nextEl:null,prevEl:null,hideOnClick:!1,disabledClass:"swiper-button-disabled",hiddenClass:"swiper-button-hidden",lockClass:"swiper-button-lock"}},create:function(){d.extend(this,{navigation:{init:X.init.bind(this),update:X.update.bind(this),destroy:X.destroy.bind(this)}})},on:{init:function(){this.navigation.init(),this.navigation.update()},toEdge:function(){this.navigation.update()},fromEdge:function(){this.navigation.update()},destroy:function(){this.navigation.destroy()},click:function(e){var t=this.navigation,i=t.$nextEl,a=t.$prevEl;!this.params.navigation.hideOnClick||s(e.target).is(a)||s(e.target).is(i)||(i&&i.toggleClass(this.params.navigation.hiddenClass),a&&a.toggleClass(this.params.navigation.hiddenClass))}}},{name:"pagination",params:{pagination:{el:null,bulletElement:"span",clickable:!1,hideOnClick:!1,renderBullet:null,renderProgressbar:null,renderFraction:null,renderCustom:null,progressbarOpposite:!1,type:"bullets",dynamicBullets:!1,dynamicMainBullets:1,bulletClass:"swiper-pagination-bullet",bulletActiveClass:"swiper-pagination-bullet-active",modifierClass:"swiper-pagination-",currentClass:"swiper-pagination-current",totalClass:"swiper-pagination-total",hiddenClass:"swiper-pagination-hidden",progressbarFillClass:"swiper-pagination-progressbar-fill",progressbarOppositeClass:"swiper-pagination-progressbar-opposite",clickableClass:"swiper-pagination-clickable",lockClass:"swiper-pagination-lock"}},create:function(){d.extend(this,{pagination:{init:Y.init.bind(this),render:Y.render.bind(this),update:Y.update.bind(this),destroy:Y.destroy.bind(this),dynamicBulletIndex:0}})},on:{init:function(){this.pagination.init(),this.pagination.render(),this.pagination.update()},activeIndexChange:function(){this.params.loop?this.pagination.update():void 0===this.snapIndex&&this.pagination.update()},snapIndexChange:function(){this.params.loop||this.pagination.update()},slidesLengthChange:function(){this.params.loop&&(this.pagination.render(),this.pagination.update())},snapGridLengthChange:function(){this.params.loop||(this.pagination.render(),this.pagination.update())},destroy:function(){this.pagination.destroy()},click:function(e){this.params.pagination.el&&this.params.pagination.hideOnClick&&this.pagination.$el.length>0&&!s(e.target).hasClass(this.params.pagination.bulletClass)&&this.pagination.$el.toggleClass(this.params.pagination.hiddenClass)}}},{name:"scrollbar",params:{scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag"}},create:function(){d.extend(this,{scrollbar:{init:V.init.bind(this),destroy:V.destroy.bind(this),updateSize:V.updateSize.bind(this),setTranslate:V.setTranslate.bind(this),setTransition:V.setTransition.bind(this),enableDraggable:V.enableDraggable.bind(this),disableDraggable:V.disableDraggable.bind(this),setDragPosition:V.setDragPosition.bind(this),onDragStart:V.onDragStart.bind(this),onDragMove:V.onDragMove.bind(this),onDragEnd:V.onDragEnd.bind(this),isTouched:!1,timeout:null,dragTimeout:null}})},on:{init:function(){this.scrollbar.init(),this.scrollbar.updateSize(),this.scrollbar.setTranslate()},update:function(){this.scrollbar.updateSize()},resize:function(){this.scrollbar.updateSize()},observerUpdate:function(){this.scrollbar.updateSize()},setTranslate:function(){this.scrollbar.setTranslate()},setTransition:function(e){this.scrollbar.setTransition(e)},destroy:function(){this.scrollbar.destroy()}}},{name:"parallax",params:{parallax:{enabled:!1}},create:function(){d.extend(this,{parallax:{setTransform:R.setTransform.bind(this),setTranslate:R.setTranslate.bind(this),setTransition:R.setTransition.bind(this)}})},on:{beforeInit:function(){this.params.parallax.enabled&&(this.params.watchSlidesProgress=!0)},init:function(){this.params.parallax&&this.parallax.setTranslate()},setTranslate:function(){this.params.parallax&&this.parallax.setTranslate()},setTransition:function(e){this.params.parallax&&this.parallax.setTransition(e)}}},{name:"zoom",params:{zoom:{enabled:!1,maxRatio:3,minRatio:1,toggle:!0,containerClass:"swiper-zoom-container",zoomedSlideClass:"swiper-slide-zoomed"}},create:function(){var e=this,t={enabled:!1,scale:1,currentScale:1,isScaling:!1,gesture:{$slideEl:void 0,slideWidth:void 0,slideHeight:void 0,$imageEl:void 0,$imageWrapEl:void 0,maxRatio:3},image:{isTouched:void 0,isMoved:void 0,currentX:void 0,currentY:void 0,minX:void 0,minY:void 0,maxX:void 0,maxY:void 0,width:void 0,height:void 0,startX:void 0,startY:void 0,touchesStart:{},touchesCurrent:{}},velocity:{x:void 0,y:void 0,prevPositionX:void 0,prevPositionY:void 0,prevTime:void 0}};"onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out".split(" ").forEach(function(i){t[i]=F[i].bind(e)}),d.extend(e,{zoom:t})},on:{init:function(){this.params.zoom.enabled&&this.zoom.enable()},destroy:function(){this.zoom.disable()},touchStart:function(e){this.zoom.enabled&&this.zoom.onTouchStart(e)},touchEnd:function(e){this.zoom.enabled&&this.zoom.onTouchEnd(e)},doubleTap:function(e){this.params.zoom.enabled&&this.zoom.enabled&&this.params.zoom.toggle&&this.zoom.toggle(e)},transitionEnd:function(){this.zoom.enabled&&this.params.zoom.enabled&&this.zoom.onTransitionEnd()}}},{name:"lazy",params:{lazy:{enabled:!1,loadPrevNext:!1,loadPrevNextAmount:1,loadOnTransitionStart:!1,elementClass:"swiper-lazy",loadingClass:"swiper-lazy-loading",loadedClass:"swiper-lazy-loaded",preloaderClass:"swiper-lazy-preloader"}},create:function(){d.extend(this,{lazy:{initialImageLoaded:!1,load:W.load.bind(this),loadInSlide:W.loadInSlide.bind(this)}})},on:{beforeInit:function(){this.params.lazy.enabled&&this.params.preloadImages&&(this.params.preloadImages=!1)},init:function(){this.params.lazy.enabled&&!this.params.loop&&0===this.params.initialSlide&&this.lazy.load()},scroll:function(){this.params.freeMode&&!this.params.freeModeSticky&&this.lazy.load()},resize:function(){this.params.lazy.enabled&&this.lazy.load()},scrollbarDragMove:function(){this.params.lazy.enabled&&this.lazy.load()},transitionStart:function(){this.params.lazy.enabled&&(this.params.lazy.loadOnTransitionStart||!this.params.lazy.loadOnTransitionStart&&!this.lazy.initialImageLoaded)&&this.lazy.load()},transitionEnd:function(){this.params.lazy.enabled&&!this.params.lazy.loadOnTransitionStart&&this.lazy.load()}}},{name:"controller",params:{controller:{control:void 0,inverse:!1,by:"slide"}},create:function(){d.extend(this,{controller:{control:this.params.controller.control,getInterpolateFunction:q.getInterpolateFunction.bind(this),setTranslate:q.setTranslate.bind(this),setTransition:q.setTransition.bind(this)}})},on:{update:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},resize:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},observerUpdate:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},setTranslate:function(e,t){this.controller.control&&this.controller.setTranslate(e,t)},setTransition:function(e,t){this.controller.control&&this.controller.setTransition(e,t)}}},{name:"a11y",params:{a11y:{enabled:!0,notificationClass:"swiper-notification",prevSlideMessage:"Previous slide",nextSlideMessage:"Next slide",firstSlideMessage:"This is the first slide",lastSlideMessage:"This is the last slide",paginationBulletMessage:"Go to slide {{index}}"}},create:function(){var e=this;d.extend(e,{a11y:{liveRegion:s('')}}),Object.keys(j).forEach(function(t){e.a11y[t]=j[t].bind(e)})},on:{init:function(){this.params.a11y.enabled&&(this.a11y.init(),this.a11y.updateNavigation())},toEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},fromEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},paginationUpdate:function(){this.params.a11y.enabled&&this.a11y.updatePagination()},destroy:function(){this.params.a11y.enabled&&this.a11y.destroy()}}},{name:"history",params:{history:{enabled:!1,replaceState:!1,key:"slides"}},create:function(){d.extend(this,{history:{init:K.init.bind(this),setHistory:K.setHistory.bind(this),setHistoryPopState:K.setHistoryPopState.bind(this),scrollToSlide:K.scrollToSlide.bind(this),destroy:K.destroy.bind(this)}})},on:{init:function(){this.params.history.enabled&&this.history.init()},destroy:function(){this.params.history.enabled&&this.history.destroy()},transitionEnd:function(){this.history.initialized&&this.history.setHistory(this.params.history.key,this.activeIndex)}}},{name:"hash-navigation",params:{hashNavigation:{enabled:!1,replaceState:!1,watchState:!1}},create:function(){d.extend(this,{hashNavigation:{initialized:!1,init:U.init.bind(this),destroy:U.destroy.bind(this),setHash:U.setHash.bind(this),onHashCange:U.onHashCange.bind(this)}})},on:{init:function(){this.params.hashNavigation.enabled&&this.hashNavigation.init()},destroy:function(){this.params.hashNavigation.enabled&&this.hashNavigation.destroy()},transitionEnd:function(){this.hashNavigation.initialized&&this.hashNavigation.setHash()}}},{name:"autoplay",params:{autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!0,stopOnLastSlide:!1,reverseDirection:!1}},create:function(){var e=this;d.extend(e,{autoplay:{running:!1,paused:!1,run:_.run.bind(e),start:_.start.bind(e),stop:_.stop.bind(e),pause:_.pause.bind(e),onTransitionEnd:function(t){e&&!e.destroyed&&e.$wrapperEl&&t.target===this&&(e.$wrapperEl[0].removeEventListener("transitionend",e.autoplay.onTransitionEnd),e.$wrapperEl[0].removeEventListener("webkitTransitionEnd",e.autoplay.onTransitionEnd),e.autoplay.paused=!1,e.autoplay.running?e.autoplay.run():e.autoplay.stop())}}})},on:{init:function(){this.params.autoplay.enabled&&this.autoplay.start()},beforeTransitionStart:function(e,t){this.autoplay.running&&(t||!this.params.autoplay.disableOnInteraction?this.autoplay.pause(e):this.autoplay.stop())},sliderFirstMove:function(){this.autoplay.running&&(this.params.autoplay.disableOnInteraction?this.autoplay.stop():this.autoplay.pause())},destroy:function(){this.autoplay.running&&this.autoplay.stop()}}},{name:"effect-fade",params:{fadeEffect:{crossFade:!1}},create:function(){d.extend(this,{fadeEffect:{setTranslate:Z.setTranslate.bind(this),setTransition:Z.setTransition.bind(this)}})},on:{beforeInit:function(){if("fade"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"fade");var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};d.extend(this.params,e),d.extend(this.originalParams,e)}},setTranslate:function(){"fade"===this.params.effect&&this.fadeEffect.setTranslate()},setTransition:function(e){"fade"===this.params.effect&&this.fadeEffect.setTransition(e)}}},{name:"effect-cube",params:{cubeEffect:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94}},create:function(){d.extend(this,{cubeEffect:{setTranslate:Q.setTranslate.bind(this),setTransition:Q.setTransition.bind(this)}})},on:{beforeInit:function(){if("cube"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"cube"),this.classNames.push(this.params.containerModifierClass+"3d");var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,resistanceRatio:0,spaceBetween:0,centeredSlides:!1,virtualTranslate:!0};d.extend(this.params,e),d.extend(this.originalParams,e)}},setTranslate:function(){"cube"===this.params.effect&&this.cubeEffect.setTranslate()},setTransition:function(e){"cube"===this.params.effect&&this.cubeEffect.setTransition(e)}}},{name:"effect-flip",params:{flipEffect:{slideShadows:!0,limitRotation:!0}},create:function(){d.extend(this,{flipEffect:{setTranslate:J.setTranslate.bind(this),setTransition:J.setTransition.bind(this)}})},on:{beforeInit:function(){if("flip"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"flip"),this.classNames.push(this.params.containerModifierClass+"3d");var e={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};d.extend(this.params,e),d.extend(this.originalParams,e)}},setTranslate:function(){"flip"===this.params.effect&&this.flipEffect.setTranslate()},setTransition:function(e){"flip"===this.params.effect&&this.flipEffect.setTransition(e)}}},{name:"effect-coverflow",params:{coverflowEffect:{rotate:50,stretch:0,depth:100,modifier:1,slideShadows:!0}},create:function(){d.extend(this,{coverflowEffect:{setTranslate:ee.setTranslate.bind(this),setTransition:ee.setTransition.bind(this)}})},on:{beforeInit:function(){"coverflow"===this.params.effect&&(this.classNames.push(this.params.containerModifierClass+"coverflow"),this.classNames.push(this.params.containerModifierClass+"3d"),this.params.watchSlidesProgress=!0,this.originalParams.watchSlidesProgress=!0)},setTranslate:function(){"coverflow"===this.params.effect&&this.coverflowEffect.setTranslate()},setTransition:function(e){"coverflow"===this.params.effect&&this.coverflowEffect.setTransition(e)}}}];return void 0===k.use&&(k.use=k.Class.use,k.installModule=k.Class.installModule),k.use(te),k}); +//# sourceMappingURL=swiper.min.js.map diff --git a/static/swiper/js/swiper.min.js.map b/static/swiper/js/swiper.min.js.map new file mode 100644 index 0000000..746ef4f --- /dev/null +++ b/static/swiper/js/swiper.min.js.map @@ -0,0 +1 @@ +{"version":3,"sources":["swiper.js"],"names":["global","factory","exports","module","define","amd","Swiper","this","doc","document","body","addEventListener","removeEventListener","activeElement","blur","nodeName","querySelector","querySelectorAll","getElementById","createEvent","initEvent","createElement","children","childNodes","style","setAttribute","getElementsByTagName","location","hash","win","window","navigator","userAgent","history","CustomEvent","getComputedStyle","getPropertyValue","Image","Date","screen","setTimeout","clearTimeout","Dom7","arr","i","length","$","selector","context","els","tempParent","html","trim","indexOf","toCreate","innerHTML","push","match","split","nodeType","unique","uniqueArray","fn","prototype","Class","Methods","addClass","className","classes","j","classList","add","removeClass","remove","hasClass","contains","toggleClass","toggle","attr","attrs","value","arguments$1","arguments","getAttribute","attrName","removeAttr","removeAttribute","data","key","el","dom7ElementDataStorage","dataKey","transform","elStyle","webkitTransform","transition","duration","webkitTransitionDuration","transitionDuration","on","assign","args","len","eventType","targetSelector","listener","capture","handleLiveEvent","e","target","eventData","dom7EventData","unshift","is","apply","parents","k","handleEvent","undefined","events","event$1","dom7LiveListeners","proxyListener","event","dom7Listeners","off","handlers","handler","splice","trigger","evt","detail","bubbles","cancelable","filter","dataIndex","dispatchEvent","transitionEnd","callback","dom","fireCallBack","call","outerWidth","includeMargins","styles","offsetWidth","parseFloat","outerHeight","offsetHeight","offset","box","getBoundingClientRect","clientTop","clientLeft","scrollTop","scrollY","scrollLeft","scrollX","top","left","css","props","prop","each","text","textContent","compareWith","matches","webkitMatchesSelector","msMatchesSelector","index","child","previousSibling","eq","returnIndex","append","newChild","tempDiv","firstChild","appendChild","prepend","insertBefore","next","nextElementSibling","nextAll","nextEls","prev","previousElementSibling","prevAll","prevEls","parent","parentNode","closest","find","foundElements","found","removeChild","toAdd","Object","keys","forEach","methodName","testDiv","Utils","deleteProps","obj","object","nextTick","delay","now","getTranslate","axis","matrix","curTransform","transformMatrix","curStyle","WebKitCSSMatrix","map","a","replace","join","MozTransform","OTransform","MsTransform","msTransform","toString","m41","m42","parseUrlQuery","url","params","param","query","urlToParse","href","paramsPart","decodeURIComponent","isObject","o","constructor","extend","len$1","to","nextSource","keysArray","nextIndex","nextKey","desc","getOwnPropertyDescriptor","enumerable","Support","touch","Modernizr","DocumentTouch","pointerEvents","pointerEnabled","PointerEvent","prefixedPointerEvents","msPointerEnabled","transforms3d","csstransforms3d","flexbox","observer","passiveListener","supportsPassive","opts","defineProperty","get","gestures","SwiperClass","self","eventsListeners","eventName","staticAccessors","components","configurable","priority","method","once","onceHandler","eventHandler","emit","Array","isArray","slice","useModulesParams","instanceParams","instance","modules","moduleName","useModules","modulesParams","moduleParams","modulePropName","moduleProp","bind","moduleEventName","create","set","use","installModule","name","proto","static","install","m","concat","defineProperties","update","updateSize","width","height","$el","clientWidth","clientHeight","isHorizontal","isVertical","parseInt","size","updateSlides","$wrapperEl","swiperSize","rtl","rtlTranslate","wrongRTL","slides","slidesLength","virtual","enabled","snapGrid","slidesGrid","slidesSizesGrid","offsetBefore","slidesOffsetBefore","offsetAfter","slidesOffsetAfter","previousSlidesLength","previousSnapGridLength","previousSlidesGridLength","spaceBetween","slidePosition","prevSlideSize","slidesNumberEvenToRows","slideSize","virtualSize","marginLeft","marginTop","marginRight","marginBottom","slidesPerColumn","Math","floor","ceil","slidesPerView","slidesPerColumnFill","max","newSlidesGrid","slidesPerRow","numFullColumns","slide","newSlideOrderIndex","column","row","-webkit-box-ordinal-group","-moz-box-ordinal-group","-ms-flex-order","-webkit-order","order","slideStyles","currentTransform","roundLengths","swiperSlideSize","centeredSlides","abs","slidesPerGroup","effect","setWrapperSize","i$1","i$2","watchOverflow","checkOverflow","watchSlidesProgress","watchSlidesVisibility","updateSlidesOffset","updateAutoHeight","speed","activeSlides","newHeight","setTransition","activeIndex","swiperSlideOffset","offsetLeft","offsetTop","updateSlidesProgress","translate","offsetCenter","slideVisibleClass","slideProgress","minTranslate","slideBefore","slideAfter","progress","updateProgress","translatesDiff","maxTranslate","isBeginning","isEnd","wasBeginning","wasEnd","updateSlidesClasses","activeSlide","realIndex","isVirtual","slideActiveClass","loop","slideDuplicateClass","slideDuplicateActiveClass","nextSlide","slideNextClass","prevSlide","slidePrevClass","slideDuplicateNextClass","slideDuplicatePrevClass","updateActiveIndex","newActiveIndex","snapIndex","previousIndex","previousRealIndex","previousSnapIndex","normalizeSlideIndex","updateClickedSlide","slideFound","clickedSlide","clickedIndex","slideToClickedSlide","virtualTranslate","currentTranslate","setTranslate","byController","x","y","transition$1","transitionStart","runCallbacks","direction","autoHeight","dir","animating","slideTo","internal","swiper","slideIndex","preventIntercationOnTransition","initialSlide","initialized","allowSlideNext","allowSlidePrev","onSlideToWrapperTransitionEnd","destroyed","slideToLoop","newIndex","loopedSlides","slideNext","loopFix","_clientLeft","slidePrev","prevIndex","prevSnap","slideReset","slideToClosest","currentSnap","slidesPerViewDynamic","slideToIndex","loopCreate","loopFillGroupWithBlank","blankSlidesNum","blankNode","loopAdditionalSlides","prependSlides","appendSlides","cloneNode","diff","loopDestroy","grabCursor","setGrabCursor","moving","simulateTouch","isLocked","cursor","unsetGrabCursor","manipulation","appendSlide","prependSlide","removeSlide","slidesIndexes","indexToRemove","removeAllSlides","Device","ua","device","ios","android","androidChrome","desktop","windows","iphone","ipod","ipad","cordova","phonegap","os","osVersion","toLowerCase","webView","osVersionArr","metaViewport","minimalUi","pixelRatio","devicePixelRatio","onResize","breakpoints","setBreakpoint","freeMode","newTranslate","min","attachEvents","touchEvents","wrapperEl","onTouchStart","touchEventsData","touches","originalEvent","isTouchEvent","type","which","isTouched","isMoved","noSwiping","noSwipingSelector","allowClick","swipeHandler","currentX","targetTouches","pageX","currentY","pageY","startX","startY","iOSEdgeSwipeDetection","iOSEdgeSwipeThreshold","allowTouchCallbacks","isScrolling","startMoving","touchStartTime","swipeDirection","threshold","allowThresholdMove","preventDefault","formElements","allowTouchMove","onTouchMove","preventedByNestedSwiper","touchReleaseOnEdges","touchAngle","diffX","diffY","atan2","PI","touchMoveStopPropagation","nested","stopPropagation","startTranslate","allowMomentumBounce","touchRatio","disableParentSwiper","resistanceRatio","resistance","pow","followFinger","velocities","position","time","onTouchEnd","currentPos","touchEndTime","timeDiff","lastClickTime","clickTimeout","freeModeMomentum","lastMoveEvent","pop","velocityEvent","distance","velocity","freeModeMinimumVelocity","freeModeMomentumVelocityRatio","momentumDuration","freeModeMomentumRatio","momentumDistance","newPosition","afterBouncePosition","needsLoopFix","doBounce","bounceAmount","freeModeMomentumBounceRatio","freeModeMomentumBounce","freeModeSticky","longSwipesMs","stopIndex","groupSize","ratio","longSwipes","longSwipesRatio","shortSwipes","onClick","preventClicks","preventClicksPropagation","stopImmediatePropagation","touchEventsTarget","start","passiveListeners","passive","move","end","detachEvents","breakpoint","getBreakpoint","currentBreakpoint","breakPointsParams","originalParams","needsReLoop","points","point","sort","b","innerWidth","Browser","isIE","isSafari","isUiWebView","test","defaults","init","uniqueNavElements","preloadImages","updateOnImagesReady","noSwipingClass","containerModifierClass","slideClass","slideBlankClass","wrapperClass","runCallbacksOnInit","prototypes","wasLocked","navigation","addClasses","classNames","suffixes","suffix","removeClasses","images","loadImage","imageEl","src","srcset","sizes","checkForComplete","image","onReady","complete","onload","onerror","imagesLoaded","imagesToLoad","currentSrc","extendedDefaults","SwiperClass$$1","prototypeGroup","protoMethod","moduleParamName","swiperParams","passedParams","swipers","containerEl","newParams","touchEventsTouch","touchEventsDesktop","__proto__","spv","breakLoop","translateValue","destroy","deleteInstance","cleanStyles","extendDefaults","newDefaults","Device$1","Support$1","support","Browser$1","browser","Resize","resize","resizeHandler","orientationChangeHandler","Observer","func","MutationObserver","WebkitMutationObserver","attach","options","ObserverFunc","mutations","mutation","observe","attributes","childList","characterData","observers","observeParents","containerParents","disconnect","Observer$1","Virtual","force","ref","ref$1","previousFrom","from","previousTo","previousSlidesGrid","renderSlide","previousOffset","offsetProp","slidesAfter","slidesBefore","onRendered","lazy","load","renderExternal","slidesToRender","prependIndexes","appendIndexes","cache","$slideEl","newCache","cachedIndex","Virtual$1","beforeInit","overwriteParams","Keyboard","handle","kc","keyCode","charCode","shiftKey","altKey","ctrlKey","metaKey","keyboard","onlyInViewport","inView","windowWidth","windowHeight","innerHeight","swiperOffset","swiperCoord","returnValue","enable","disable","Keyboard$1","Mousewheel","lastScrollTime","isSupported","element","implementation","hasFeature","isEventSupported","normalize","sX","sY","pX","pY","wheelDelta","wheelDeltaY","wheelDeltaX","HORIZONTAL_AXIS","deltaY","deltaX","deltaMode","spinX","spinY","pixelX","pixelY","handleMouseEnter","mouseEntered","handleMouseLeave","mousewheel","releaseOnEdges","delta","rtlFactor","forceToAxis","invert","sensitivity","timeout","autoplay","autoplayDisableOnInteraction","stopAutoplay","getTime","eventsTarged","Navigation","$nextEl","$prevEl","disabledClass","lockClass","nextEl","prevEl","Pagination","pagination","current","total","paginationType","bullets","firstIndex","lastIndex","midIndex","dynamicBullets","bulletSize","dynamicMainBullets","dynamicBulletIndex","bullet","$bullet","bulletIndex","bulletActiveClass","$firstDisplayedBullet","$lastDisplayedBullet","dynamicBulletsLength","bulletsOffset","progressbarDirection","progressbarOpposite","scale","scaleX","scaleY","renderCustom","render","paginationHTML","numberOfBullets","renderBullet","bulletClass","renderFraction","currentClass","totalClass","renderProgressbar","progressbarFillClass","clickable","clickableClass","modifierClass","progressbarOppositeClass","hiddenClass","Scrollbar","scrollbar","dragSize","trackSize","$dragEl","newSize","newPos","hide","opacity","divider","moveDivider","display","scrollbarHide","setDragPosition","positionRatio","clientX","clientY","onDragStart","dragTimeout","onDragMove","onDragEnd","snapOnRelease","enableDraggable","activeListener","disableDraggable","$swiperEl","dragEl","draggable","Parallax","setTransform","p","currentOpacity","currentScale","parallax","slideEl","parallaxEl","$parallaxEl","parallaxDuration","Zoom","getDistanceBetweenTouches","x1","y1","x2","y2","sqrt","onGestureStart","zoom","gesture","fakeGestureTouched","fakeGestureMoved","scaleStart","$imageEl","$imageWrapEl","maxRatio","isScaling","onGestureChange","scaleMove","minRatio","onGestureEnd","changedTouches","touchesStart","slideWidth","slideHeight","scaledWidth","scaledHeight","minX","maxX","minY","maxY","touchesCurrent","prevPositionX","prevPositionY","prevTime","momentumDurationX","momentumDurationY","momentumDistanceX","newPositionX","momentumDistanceY","newPositionY","onTransitionEnd","out","in","touchX","touchY","translateX","translateY","imageWidth","imageHeight","translateMinX","translateMinY","translateMaxX","translateMaxY","Lazy","loadInSlide","loadInDuplicate","$images","elementClass","loadedClass","loadingClass","imageIndex","background","slideOriginalIndex","originalSlide","duplicatedSlide","slideExist","initialImageLoaded","elIndex","loadPrevNext","loadPrevNextAmount","amount","maxIndex","minIndex","Controller","LinearSpline","guess","i1","i3","binarySearch","array","val","interpolate","getInterpolateFunction","c","controller","spline","setTranslate$1","multiplier","controlledTranslate","controlled","control","setControlledTranslate","by","inverse","setControlledTransition","a11y","makeElFocusable","addElRole","role","addElLabel","label","disableEl","enableEl","onEnterKey","$targetEl","notify","lastSlideMessage","nextSlideMessage","firstSlideMessage","prevSlideMessage","click","message","notification","liveRegion","updateNavigation","updatePagination","bulletEl","$bulletEl","paginationBulletMessage","History","pushState","hashNavigation","paths","getPathValues","scrollToSlide","replaceState","setHistoryPopState","pathArray","pathname","part","setHistory","slugify","includes","currentState","state","HashNavigation","onHashCange","newHash","setHash","watchState","Autoplay","run","$activeSlideEl","reverseDirection","stopOnLastSlide","stop","running","pause","paused","waitForTransition","Fade","tx","ty","slideOpacity","fadeEffect","crossFade","eventTriggered","triggerEvents","Cube","$cubeShadowEl","swiperWidth","swiperHeight","cubeEffect","wrapperRotate","shadow","slideAngle","round","tz","slideShadows","shadowBefore","shadowAfter","-webkit-transform-origin","-moz-transform-origin","-ms-transform-origin","transform-origin","shadowOffset","shadowAngle","sin","cos","scale1","shadowScale","scale2","zFactor","Flip","flipEffect","limitRotation","rotateY","rotateX","zIndex","Coverflow","coverflowEffect","center","rotate","depth","offsetMultiplier","modifier","translateZ","stretch","slideTransform","$shadowBeforeEl","$shadowAfterEl","perspectiveOrigin","hideOnClick","toEdge","fromEdge","bulletElement","activeIndexChange","snapIndexChange","slidesLengthChange","snapGridLengthChange","dragClass","observerUpdate","containerClass","zoomedSlideClass","touchStart","touchEnd","doubleTap","loadOnTransitionStart","preloaderClass","scroll","scrollbarDragMove","notificationClass","paginationUpdate","disableOnInteraction","beforeTransitionStart","sliderFirstMove"],"mappings":";;;;;;;;;;;CAYC,SAAUA,EAAQC,GACE,iBAAZC,SAA0C,oBAAXC,OAAyBA,OAAOD,QAAUD,IAC9D,mBAAXG,QAAyBA,OAAOC,IAAMD,OAAOH,GACnDD,EAAOM,OAASL,IAHnB,CAIEM,KAAM,WAAe,aAarB,IA0CIC,EAzCoB,oBAAbC,UAEPC,QACAC,iBAAkB,aAClBC,oBAAqB,aACrBC,eACEC,KAAM,aACNC,SAAU,IAEZC,cAAe,WACb,OAAO,MAETC,iBAAkB,WAChB,UAEFC,eAAgB,WACd,OAAO,MAETC,YAAa,WACX,OACEC,UAAW,eAGfC,cAAe,WACb,OACEC,YACAC,cACAC,S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AGlBjwB,OAAQ,WAEN9F,EAAMqC,OADOzO,MAEXyjC,iBACE3oB,aAAc0oB,GAAU1oB,aAAa9I,KAH5BhS,MAIT6X,cAAe2rB,GAAU3rB,cAAc7F,KAJ9BhS,UAQf4F,IACEyoB,WAAY,WAEmB,cADhBruB,KACF+N,OAAOiJ,SADLhX,KAGNyoB,WAAWxlB,KAHLjD,KAGmB+N,OAA6B,uBAAI,aAHpD/N,KAINyoB,WAAWxlB,KAJLjD,KAImB+N,OAA6B,uBAAI,MAJpD/N,KAMN+N,OAAOuJ,qBAAsB,EANvBtX,KAON8mB,eAAexP,qBAAsB,IAE9CwD,aAAc,WAEiB,cADhB9a,KACF+N,OAAOiJ,QADLhX,KAENyjC,gBAAgB3oB,gBAEzBjD,cAAe,SAAuBpS,GAEP,cADhBzF,KACF+N,OAAOiJ,QADLhX,KAENyjC,gBAAgB5rB,cAAcpS,OAwC3C,YAP0B,IAAf1F,EAAOqS,MAChBrS,EAAOqS,IAAMrS,EAAO0D,MAAM2O,IAC1BrS,EAAOsS,cAAgBtS,EAAO0D,MAAM4O,eAGtCtS,EAAOqS,IAAIzB,IAEJ5Q","file":"swiper.min.js","sourcesContent":["/**\n * Swiper 4.2.6\n * Most modern mobile touch slider and framework with hardware accelerated transitions\n * http://www.idangero.us/swiper/\n *\n * Copyright 2014-2018 Vladimir Kharlampidi\n *\n * Released under the MIT License\n *\n * Released on: May 1, 2018\n */\n\n(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n typeof define === 'function' && define.amd ? define(factory) :\n (global.Swiper = factory());\n}(this, (function () { 'use strict';\n\n /**\n * SSR Window 1.0.0\n * Better handling for window object in SSR environment\n * https://github.com/nolimits4web/ssr-window\n *\n * Copyright 2018, Vladimir Kharlampidi\n *\n * Licensed under MIT\n *\n * Released on: February 10, 2018\n */\n var d;\n if (typeof document === 'undefined') {\n d = {\n body: {},\n addEventListener: function addEventListener() {},\n removeEventListener: function removeEventListener() {},\n activeElement: {\n blur: function blur() {},\n nodeName: '',\n },\n querySelector: function querySelector() {\n return null;\n },\n querySelectorAll: function querySelectorAll() {\n return [];\n },\n getElementById: function getElementById() {\n return null;\n },\n createEvent: function createEvent() {\n return {\n initEvent: function initEvent() {},\n };\n },\n createElement: function createElement() {\n return {\n children: [],\n childNodes: [],\n style: {},\n setAttribute: function setAttribute() {},\n getElementsByTagName: function getElementsByTagName() {\n return [];\n },\n };\n },\n location: { hash: '' },\n };\n } else {\n // eslint-disable-next-line\n d = document;\n }\n\n var doc = d;\n\n var w;\n if (typeof window === 'undefined') {\n w = {\n document: doc,\n navigator: {\n userAgent: '',\n },\n location: {},\n history: {},\n CustomEvent: function CustomEvent() {\n return this;\n },\n addEventListener: function addEventListener() {},\n removeEventListener: function removeEventListener() {},\n getComputedStyle: function getComputedStyle() {\n return {\n getPropertyValue: function getPropertyValue() {\n return '';\n },\n };\n },\n Image: function Image() {},\n Date: function Date() {},\n screen: {},\n setTimeout: function setTimeout() {},\n clearTimeout: function clearTimeout() {},\n };\n } else {\n // eslint-disable-next-line\n w = window;\n }\n\n var win = w;\n\n /**\n * Dom7 2.0.5\n * Minimalistic JavaScript library for DOM manipulation, with a jQuery-compatible API\n * http://framework7.io/docs/dom.html\n *\n * Copyright 2018, Vladimir Kharlampidi\n * The iDangero.us\n * http://www.idangero.us/\n *\n * Licensed under MIT\n *\n * Released on: April 20, 2018\n */\n\n var Dom7 = function Dom7(arr) {\n var self = this;\n // Create array-like object\n for (var i = 0; i < arr.length; i += 1) {\n self[i] = arr[i];\n }\n self.length = arr.length;\n // Return collection with methods\n return this;\n };\n\n function $(selector, context) {\n var arr = [];\n var i = 0;\n if (selector && !context) {\n if (selector instanceof Dom7) {\n return selector;\n }\n }\n if (selector) {\n // String\n if (typeof selector === 'string') {\n var els;\n var tempParent;\n var html = selector.trim();\n if (html.indexOf('<') >= 0 && html.indexOf('>') >= 0) {\n var toCreate = 'div';\n if (html.indexOf(':~]/)) {\n // Pure ID selector\n els = [doc.getElementById(selector.trim().split('#')[1])];\n } else {\n // Other selectors\n els = (context || doc).querySelectorAll(selector.trim());\n }\n for (i = 0; i < els.length; i += 1) {\n if (els[i]) { arr.push(els[i]); }\n }\n }\n } else if (selector.nodeType || selector === win || selector === doc) {\n // Node/element\n arr.push(selector);\n } else if (selector.length > 0 && selector[0].nodeType) {\n // Array of elements or instance of Dom\n for (i = 0; i < selector.length; i += 1) {\n arr.push(selector[i]);\n }\n }\n }\n return new Dom7(arr);\n }\n\n $.fn = Dom7.prototype;\n $.Class = Dom7;\n $.Dom7 = Dom7;\n\n function unique(arr) {\n var uniqueArray = [];\n for (var i = 0; i < arr.length; i += 1) {\n if (uniqueArray.indexOf(arr[i]) === -1) { uniqueArray.push(arr[i]); }\n }\n return uniqueArray;\n }\n\n // Classes and attributes\n function addClass(className) {\n var this$1 = this;\n\n if (typeof className === 'undefined') {\n return this;\n }\n var classes = className.split(' ');\n for (var i = 0; i < classes.length; i += 1) {\n for (var j = 0; j < this.length; j += 1) {\n if (typeof this$1[j].classList !== 'undefined') { this$1[j].classList.add(classes[i]); }\n }\n }\n return this;\n }\n function removeClass(className) {\n var this$1 = this;\n\n var classes = className.split(' ');\n for (var i = 0; i < classes.length; i += 1) {\n for (var j = 0; j < this.length; j += 1) {\n if (typeof this$1[j].classList !== 'undefined') { this$1[j].classList.remove(classes[i]); }\n }\n }\n return this;\n }\n function hasClass(className) {\n if (!this[0]) { return false; }\n return this[0].classList.contains(className);\n }\n function toggleClass(className) {\n var this$1 = this;\n\n var classes = className.split(' ');\n for (var i = 0; i < classes.length; i += 1) {\n for (var j = 0; j < this.length; j += 1) {\n if (typeof this$1[j].classList !== 'undefined') { this$1[j].classList.toggle(classes[i]); }\n }\n }\n return this;\n }\n function attr(attrs, value) {\n var arguments$1 = arguments;\n var this$1 = this;\n\n if (arguments.length === 1 && typeof attrs === 'string') {\n // Get attr\n if (this[0]) { return this[0].getAttribute(attrs); }\n return undefined;\n }\n\n // Set attrs\n for (var i = 0; i < this.length; i += 1) {\n if (arguments$1.length === 2) {\n // String\n this$1[i].setAttribute(attrs, value);\n } else {\n // Object\n // eslint-disable-next-line\n for (var attrName in attrs) {\n this$1[i][attrName] = attrs[attrName];\n this$1[i].setAttribute(attrName, attrs[attrName]);\n }\n }\n }\n return this;\n }\n // eslint-disable-next-line\n function removeAttr(attr) {\n var this$1 = this;\n\n for (var i = 0; i < this.length; i += 1) {\n this$1[i].removeAttribute(attr);\n }\n return this;\n }\n function data(key, value) {\n var this$1 = this;\n\n var el;\n if (typeof value === 'undefined') {\n el = this[0];\n // Get value\n if (el) {\n if (el.dom7ElementDataStorage && (key in el.dom7ElementDataStorage)) {\n return el.dom7ElementDataStorage[key];\n }\n\n var dataKey = el.getAttribute((\"data-\" + key));\n if (dataKey) {\n return dataKey;\n }\n return undefined;\n }\n return undefined;\n }\n\n // Set value\n for (var i = 0; i < this.length; i += 1) {\n el = this$1[i];\n if (!el.dom7ElementDataStorage) { el.dom7ElementDataStorage = {}; }\n el.dom7ElementDataStorage[key] = value;\n }\n return this;\n }\n // Transforms\n // eslint-disable-next-line\n function transform(transform) {\n var this$1 = this;\n\n for (var i = 0; i < this.length; i += 1) {\n var elStyle = this$1[i].style;\n elStyle.webkitTransform = transform;\n elStyle.transform = transform;\n }\n return this;\n }\n function transition(duration) {\n var this$1 = this;\n\n if (typeof duration !== 'string') {\n duration = duration + \"ms\"; // eslint-disable-line\n }\n for (var i = 0; i < this.length; i += 1) {\n var elStyle = this$1[i].style;\n elStyle.webkitTransitionDuration = duration;\n elStyle.transitionDuration = duration;\n }\n return this;\n }\n // Events\n function on() {\n var this$1 = this;\n var assign;\n\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n var eventType = args[0];\n var targetSelector = args[1];\n var listener = args[2];\n var capture = args[3];\n if (typeof args[1] === 'function') {\n (assign = args, eventType = assign[0], listener = assign[1], capture = assign[2]);\n targetSelector = undefined;\n }\n if (!capture) { capture = false; }\n\n function handleLiveEvent(e) {\n var target = e.target;\n if (!target) { return; }\n var eventData = e.target.dom7EventData || [];\n if (eventData.indexOf(e) < 0) {\n eventData.unshift(e);\n }\n if ($(target).is(targetSelector)) { listener.apply(target, eventData); }\n else {\n var parents = $(target).parents(); // eslint-disable-line\n for (var k = 0; k < parents.length; k += 1) {\n if ($(parents[k]).is(targetSelector)) { listener.apply(parents[k], eventData); }\n }\n }\n }\n function handleEvent(e) {\n var eventData = e && e.target ? e.target.dom7EventData || [] : [];\n if (eventData.indexOf(e) < 0) {\n eventData.unshift(e);\n }\n listener.apply(this, eventData);\n }\n var events = eventType.split(' ');\n var j;\n for (var i = 0; i < this.length; i += 1) {\n var el = this$1[i];\n if (!targetSelector) {\n for (j = 0; j < events.length; j += 1) {\n var event = events[j];\n if (!el.dom7Listeners) { el.dom7Listeners = {}; }\n if (!el.dom7Listeners[event]) { el.dom7Listeners[event] = []; }\n el.dom7Listeners[event].push({\n listener: listener,\n proxyListener: handleEvent,\n });\n el.addEventListener(event, handleEvent, capture);\n }\n } else {\n // Live events\n for (j = 0; j < events.length; j += 1) {\n var event$1 = events[j];\n if (!el.dom7LiveListeners) { el.dom7LiveListeners = {}; }\n if (!el.dom7LiveListeners[event$1]) { el.dom7LiveListeners[event$1] = []; }\n el.dom7LiveListeners[event$1].push({\n listener: listener,\n proxyListener: handleLiveEvent,\n });\n el.addEventListener(event$1, handleLiveEvent, capture);\n }\n }\n }\n return this;\n }\n function off() {\n var this$1 = this;\n var assign;\n\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n var eventType = args[0];\n var targetSelector = args[1];\n var listener = args[2];\n var capture = args[3];\n if (typeof args[1] === 'function') {\n (assign = args, eventType = assign[0], listener = assign[1], capture = assign[2]);\n targetSelector = undefined;\n }\n if (!capture) { capture = false; }\n\n var events = eventType.split(' ');\n for (var i = 0; i < events.length; i += 1) {\n var event = events[i];\n for (var j = 0; j < this.length; j += 1) {\n var el = this$1[j];\n var handlers = (void 0);\n if (!targetSelector && el.dom7Listeners) {\n handlers = el.dom7Listeners[event];\n } else if (targetSelector && el.dom7LiveListeners) {\n handlers = el.dom7LiveListeners[event];\n }\n for (var k = handlers.length - 1; k >= 0; k -= 1) {\n var handler = handlers[k];\n if (listener && handler.listener === listener) {\n el.removeEventListener(event, handler.proxyListener, capture);\n handlers.splice(k, 1);\n } else if (!listener) {\n el.removeEventListener(event, handler.proxyListener, capture);\n handlers.splice(k, 1);\n }\n }\n }\n }\n return this;\n }\n function trigger() {\n var this$1 = this;\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n\n var events = args[0].split(' ');\n var eventData = args[1];\n for (var i = 0; i < events.length; i += 1) {\n var event = events[i];\n for (var j = 0; j < this.length; j += 1) {\n var el = this$1[j];\n var evt = (void 0);\n try {\n evt = new win.CustomEvent(event, {\n detail: eventData,\n bubbles: true,\n cancelable: true,\n });\n } catch (e) {\n evt = doc.createEvent('Event');\n evt.initEvent(event, true, true);\n evt.detail = eventData;\n }\n // eslint-disable-next-line\n el.dom7EventData = args.filter(function (data, dataIndex) { return dataIndex > 0; });\n el.dispatchEvent(evt);\n el.dom7EventData = [];\n delete el.dom7EventData;\n }\n }\n return this;\n }\n function transitionEnd(callback) {\n var events = ['webkitTransitionEnd', 'transitionend'];\n var dom = this;\n var i;\n function fireCallBack(e) {\n /* jshint validthis:true */\n if (e.target !== this) { return; }\n callback.call(this, e);\n for (i = 0; i < events.length; i += 1) {\n dom.off(events[i], fireCallBack);\n }\n }\n if (callback) {\n for (i = 0; i < events.length; i += 1) {\n dom.on(events[i], fireCallBack);\n }\n }\n return this;\n }\n function outerWidth(includeMargins) {\n if (this.length > 0) {\n if (includeMargins) {\n // eslint-disable-next-line\n var styles = this.styles();\n return this[0].offsetWidth + parseFloat(styles.getPropertyValue('margin-right')) + parseFloat(styles.getPropertyValue('margin-left'));\n }\n return this[0].offsetWidth;\n }\n return null;\n }\n function outerHeight(includeMargins) {\n if (this.length > 0) {\n if (includeMargins) {\n // eslint-disable-next-line\n var styles = this.styles();\n return this[0].offsetHeight + parseFloat(styles.getPropertyValue('margin-top')) + parseFloat(styles.getPropertyValue('margin-bottom'));\n }\n return this[0].offsetHeight;\n }\n return null;\n }\n function offset() {\n if (this.length > 0) {\n var el = this[0];\n var box = el.getBoundingClientRect();\n var body = doc.body;\n var clientTop = el.clientTop || body.clientTop || 0;\n var clientLeft = el.clientLeft || body.clientLeft || 0;\n var scrollTop = el === win ? win.scrollY : el.scrollTop;\n var scrollLeft = el === win ? win.scrollX : el.scrollLeft;\n return {\n top: (box.top + scrollTop) - clientTop,\n left: (box.left + scrollLeft) - clientLeft,\n };\n }\n\n return null;\n }\n function styles() {\n if (this[0]) { return win.getComputedStyle(this[0], null); }\n return {};\n }\n function css(props, value) {\n var this$1 = this;\n\n var i;\n if (arguments.length === 1) {\n if (typeof props === 'string') {\n if (this[0]) { return win.getComputedStyle(this[0], null).getPropertyValue(props); }\n } else {\n for (i = 0; i < this.length; i += 1) {\n // eslint-disable-next-line\n for (var prop in props) {\n this$1[i].style[prop] = props[prop];\n }\n }\n return this;\n }\n }\n if (arguments.length === 2 && typeof props === 'string') {\n for (i = 0; i < this.length; i += 1) {\n this$1[i].style[props] = value;\n }\n return this;\n }\n return this;\n }\n // Iterate over the collection passing elements to `callback`\n function each(callback) {\n var this$1 = this;\n\n // Don't bother continuing without a callback\n if (!callback) { return this; }\n // Iterate over the current collection\n for (var i = 0; i < this.length; i += 1) {\n // If the callback returns false\n if (callback.call(this$1[i], i, this$1[i]) === false) {\n // End the loop early\n return this$1;\n }\n }\n // Return `this` to allow chained DOM operations\n return this;\n }\n // eslint-disable-next-line\n function html(html) {\n var this$1 = this;\n\n if (typeof html === 'undefined') {\n return this[0] ? this[0].innerHTML : undefined;\n }\n\n for (var i = 0; i < this.length; i += 1) {\n this$1[i].innerHTML = html;\n }\n return this;\n }\n // eslint-disable-next-line\n function text(text) {\n var this$1 = this;\n\n if (typeof text === 'undefined') {\n if (this[0]) {\n return this[0].textContent.trim();\n }\n return null;\n }\n\n for (var i = 0; i < this.length; i += 1) {\n this$1[i].textContent = text;\n }\n return this;\n }\n function is(selector) {\n var el = this[0];\n var compareWith;\n var i;\n if (!el || typeof selector === 'undefined') { return false; }\n if (typeof selector === 'string') {\n if (el.matches) { return el.matches(selector); }\n else if (el.webkitMatchesSelector) { return el.webkitMatchesSelector(selector); }\n else if (el.msMatchesSelector) { return el.msMatchesSelector(selector); }\n\n compareWith = $(selector);\n for (i = 0; i < compareWith.length; i += 1) {\n if (compareWith[i] === el) { return true; }\n }\n return false;\n } else if (selector === doc) { return el === doc; }\n else if (selector === win) { return el === win; }\n\n if (selector.nodeType || selector instanceof Dom7) {\n compareWith = selector.nodeType ? [selector] : selector;\n for (i = 0; i < compareWith.length; i += 1) {\n if (compareWith[i] === el) { return true; }\n }\n return false;\n }\n return false;\n }\n function index() {\n var child = this[0];\n var i;\n if (child) {\n i = 0;\n // eslint-disable-next-line\n while ((child = child.previousSibling) !== null) {\n if (child.nodeType === 1) { i += 1; }\n }\n return i;\n }\n return undefined;\n }\n // eslint-disable-next-line\n function eq(index) {\n if (typeof index === 'undefined') { return this; }\n var length = this.length;\n var returnIndex;\n if (index > length - 1) {\n return new Dom7([]);\n }\n if (index < 0) {\n returnIndex = length + index;\n if (returnIndex < 0) { return new Dom7([]); }\n return new Dom7([this[returnIndex]]);\n }\n return new Dom7([this[index]]);\n }\n function append() {\n var this$1 = this;\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n\n var newChild;\n\n for (var k = 0; k < args.length; k += 1) {\n newChild = args[k];\n for (var i = 0; i < this.length; i += 1) {\n if (typeof newChild === 'string') {\n var tempDiv = doc.createElement('div');\n tempDiv.innerHTML = newChild;\n while (tempDiv.firstChild) {\n this$1[i].appendChild(tempDiv.firstChild);\n }\n } else if (newChild instanceof Dom7) {\n for (var j = 0; j < newChild.length; j += 1) {\n this$1[i].appendChild(newChild[j]);\n }\n } else {\n this$1[i].appendChild(newChild);\n }\n }\n }\n\n return this;\n }\n function prepend(newChild) {\n var this$1 = this;\n\n var i;\n var j;\n for (i = 0; i < this.length; i += 1) {\n if (typeof newChild === 'string') {\n var tempDiv = doc.createElement('div');\n tempDiv.innerHTML = newChild;\n for (j = tempDiv.childNodes.length - 1; j >= 0; j -= 1) {\n this$1[i].insertBefore(tempDiv.childNodes[j], this$1[i].childNodes[0]);\n }\n } else if (newChild instanceof Dom7) {\n for (j = 0; j < newChild.length; j += 1) {\n this$1[i].insertBefore(newChild[j], this$1[i].childNodes[0]);\n }\n } else {\n this$1[i].insertBefore(newChild, this$1[i].childNodes[0]);\n }\n }\n return this;\n }\n function next(selector) {\n if (this.length > 0) {\n if (selector) {\n if (this[0].nextElementSibling && $(this[0].nextElementSibling).is(selector)) {\n return new Dom7([this[0].nextElementSibling]);\n }\n return new Dom7([]);\n }\n\n if (this[0].nextElementSibling) { return new Dom7([this[0].nextElementSibling]); }\n return new Dom7([]);\n }\n return new Dom7([]);\n }\n function nextAll(selector) {\n var nextEls = [];\n var el = this[0];\n if (!el) { return new Dom7([]); }\n while (el.nextElementSibling) {\n var next = el.nextElementSibling; // eslint-disable-line\n if (selector) {\n if ($(next).is(selector)) { nextEls.push(next); }\n } else { nextEls.push(next); }\n el = next;\n }\n return new Dom7(nextEls);\n }\n function prev(selector) {\n if (this.length > 0) {\n var el = this[0];\n if (selector) {\n if (el.previousElementSibling && $(el.previousElementSibling).is(selector)) {\n return new Dom7([el.previousElementSibling]);\n }\n return new Dom7([]);\n }\n\n if (el.previousElementSibling) { return new Dom7([el.previousElementSibling]); }\n return new Dom7([]);\n }\n return new Dom7([]);\n }\n function prevAll(selector) {\n var prevEls = [];\n var el = this[0];\n if (!el) { return new Dom7([]); }\n while (el.previousElementSibling) {\n var prev = el.previousElementSibling; // eslint-disable-line\n if (selector) {\n if ($(prev).is(selector)) { prevEls.push(prev); }\n } else { prevEls.push(prev); }\n el = prev;\n }\n return new Dom7(prevEls);\n }\n function parent(selector) {\n var this$1 = this;\n\n var parents = []; // eslint-disable-line\n for (var i = 0; i < this.length; i += 1) {\n if (this$1[i].parentNode !== null) {\n if (selector) {\n if ($(this$1[i].parentNode).is(selector)) { parents.push(this$1[i].parentNode); }\n } else {\n parents.push(this$1[i].parentNode);\n }\n }\n }\n return $(unique(parents));\n }\n function parents(selector) {\n var this$1 = this;\n\n var parents = []; // eslint-disable-line\n for (var i = 0; i < this.length; i += 1) {\n var parent = this$1[i].parentNode; // eslint-disable-line\n while (parent) {\n if (selector) {\n if ($(parent).is(selector)) { parents.push(parent); }\n } else {\n parents.push(parent);\n }\n parent = parent.parentNode;\n }\n }\n return $(unique(parents));\n }\n function closest(selector) {\n var closest = this; // eslint-disable-line\n if (typeof selector === 'undefined') {\n return new Dom7([]);\n }\n if (!closest.is(selector)) {\n closest = closest.parents(selector).eq(0);\n }\n return closest;\n }\n function find(selector) {\n var this$1 = this;\n\n var foundElements = [];\n for (var i = 0; i < this.length; i += 1) {\n var found = this$1[i].querySelectorAll(selector);\n for (var j = 0; j < found.length; j += 1) {\n foundElements.push(found[j]);\n }\n }\n return new Dom7(foundElements);\n }\n function children(selector) {\n var this$1 = this;\n\n var children = []; // eslint-disable-line\n for (var i = 0; i < this.length; i += 1) {\n var childNodes = this$1[i].childNodes;\n\n for (var j = 0; j < childNodes.length; j += 1) {\n if (!selector) {\n if (childNodes[j].nodeType === 1) { children.push(childNodes[j]); }\n } else if (childNodes[j].nodeType === 1 && $(childNodes[j]).is(selector)) {\n children.push(childNodes[j]);\n }\n }\n }\n return new Dom7(unique(children));\n }\n function remove() {\n var this$1 = this;\n\n for (var i = 0; i < this.length; i += 1) {\n if (this$1[i].parentNode) { this$1[i].parentNode.removeChild(this$1[i]); }\n }\n return this;\n }\n function add() {\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n\n var dom = this;\n var i;\n var j;\n for (i = 0; i < args.length; i += 1) {\n var toAdd = $(args[i]);\n for (j = 0; j < toAdd.length; j += 1) {\n dom[dom.length] = toAdd[j];\n dom.length += 1;\n }\n }\n return dom;\n }\n\n var Methods = {\n addClass: addClass,\n removeClass: removeClass,\n hasClass: hasClass,\n toggleClass: toggleClass,\n attr: attr,\n removeAttr: removeAttr,\n data: data,\n transform: transform,\n transition: transition,\n on: on,\n off: off,\n trigger: trigger,\n transitionEnd: transitionEnd,\n outerWidth: outerWidth,\n outerHeight: outerHeight,\n offset: offset,\n css: css,\n each: each,\n html: html,\n text: text,\n is: is,\n index: index,\n eq: eq,\n append: append,\n prepend: prepend,\n next: next,\n nextAll: nextAll,\n prev: prev,\n prevAll: prevAll,\n parent: parent,\n parents: parents,\n closest: closest,\n find: find,\n children: children,\n remove: remove,\n add: add,\n styles: styles,\n };\n\n Object.keys(Methods).forEach(function (methodName) {\n $.fn[methodName] = Methods[methodName];\n });\n\n var Utils = {\n deleteProps: function deleteProps(obj) {\n var object = obj;\n Object.keys(object).forEach(function (key) {\n try {\n object[key] = null;\n } catch (e) {\n // no getter for object\n }\n try {\n delete object[key];\n } catch (e) {\n // something got wrong\n }\n });\n },\n nextTick: function nextTick(callback, delay) {\n if ( delay === void 0 ) delay = 0;\n\n return setTimeout(callback, delay);\n },\n now: function now() {\n return Date.now();\n },\n getTranslate: function getTranslate(el, axis) {\n if ( axis === void 0 ) axis = 'x';\n\n var matrix;\n var curTransform;\n var transformMatrix;\n\n var curStyle = win.getComputedStyle(el, null);\n\n if (win.WebKitCSSMatrix) {\n curTransform = curStyle.transform || curStyle.webkitTransform;\n if (curTransform.split(',').length > 6) {\n curTransform = curTransform.split(', ').map(function (a) { return a.replace(',', '.'); }).join(', ');\n }\n // Some old versions of Webkit choke when 'none' is passed; pass\n // empty string instead in this case\n transformMatrix = new win.WebKitCSSMatrix(curTransform === 'none' ? '' : curTransform);\n } else {\n transformMatrix = curStyle.MozTransform || curStyle.OTransform || curStyle.MsTransform || curStyle.msTransform || curStyle.transform || curStyle.getPropertyValue('transform').replace('translate(', 'matrix(1, 0, 0, 1,');\n matrix = transformMatrix.toString().split(',');\n }\n\n if (axis === 'x') {\n // Latest Chrome and webkits Fix\n if (win.WebKitCSSMatrix) { curTransform = transformMatrix.m41; }\n // Crazy IE10 Matrix\n else if (matrix.length === 16) { curTransform = parseFloat(matrix[12]); }\n // Normal Browsers\n else { curTransform = parseFloat(matrix[4]); }\n }\n if (axis === 'y') {\n // Latest Chrome and webkits Fix\n if (win.WebKitCSSMatrix) { curTransform = transformMatrix.m42; }\n // Crazy IE10 Matrix\n else if (matrix.length === 16) { curTransform = parseFloat(matrix[13]); }\n // Normal Browsers\n else { curTransform = parseFloat(matrix[5]); }\n }\n return curTransform || 0;\n },\n parseUrlQuery: function parseUrlQuery(url) {\n var query = {};\n var urlToParse = url || win.location.href;\n var i;\n var params;\n var param;\n var length;\n if (typeof urlToParse === 'string' && urlToParse.length) {\n urlToParse = urlToParse.indexOf('?') > -1 ? urlToParse.replace(/\\S*\\?/, '') : '';\n params = urlToParse.split('&').filter(function (paramsPart) { return paramsPart !== ''; });\n length = params.length;\n\n for (i = 0; i < length; i += 1) {\n param = params[i].replace(/#\\S+/g, '').split('=');\n query[decodeURIComponent(param[0])] = typeof param[1] === 'undefined' ? undefined : decodeURIComponent(param[1]) || '';\n }\n }\n return query;\n },\n isObject: function isObject(o) {\n return typeof o === 'object' && o !== null && o.constructor && o.constructor === Object;\n },\n extend: function extend() {\n var args = [], len$1 = arguments.length;\n while ( len$1-- ) args[ len$1 ] = arguments[ len$1 ];\n\n var to = Object(args[0]);\n for (var i = 1; i < args.length; i += 1) {\n var nextSource = args[i];\n if (nextSource !== undefined && nextSource !== null) {\n var keysArray = Object.keys(Object(nextSource));\n for (var nextIndex = 0, len = keysArray.length; nextIndex < len; nextIndex += 1) {\n var nextKey = keysArray[nextIndex];\n var desc = Object.getOwnPropertyDescriptor(nextSource, nextKey);\n if (desc !== undefined && desc.enumerable) {\n if (Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) {\n Utils.extend(to[nextKey], nextSource[nextKey]);\n } else if (!Utils.isObject(to[nextKey]) && Utils.isObject(nextSource[nextKey])) {\n to[nextKey] = {};\n Utils.extend(to[nextKey], nextSource[nextKey]);\n } else {\n to[nextKey] = nextSource[nextKey];\n }\n }\n }\n }\n }\n return to;\n },\n };\n\n var Support = (function Support() {\n var testDiv = doc.createElement('div');\n return {\n touch: (win.Modernizr && win.Modernizr.touch === true) || (function checkTouch() {\n return !!(('ontouchstart' in win) || (win.DocumentTouch && doc instanceof win.DocumentTouch));\n }()),\n\n pointerEvents: !!(win.navigator.pointerEnabled || win.PointerEvent),\n prefixedPointerEvents: !!win.navigator.msPointerEnabled,\n\n transition: (function checkTransition() {\n var style = testDiv.style;\n return ('transition' in style || 'webkitTransition' in style || 'MozTransition' in style);\n }()),\n transforms3d: (win.Modernizr && win.Modernizr.csstransforms3d === true) || (function checkTransforms3d() {\n var style = testDiv.style;\n return ('webkitPerspective' in style || 'MozPerspective' in style || 'OPerspective' in style || 'MsPerspective' in style || 'perspective' in style);\n }()),\n\n flexbox: (function checkFlexbox() {\n var style = testDiv.style;\n var styles = ('alignItems webkitAlignItems webkitBoxAlign msFlexAlign mozBoxAlign webkitFlexDirection msFlexDirection mozBoxDirection mozBoxOrient webkitBoxDirection webkitBoxOrient').split(' ');\n for (var i = 0; i < styles.length; i += 1) {\n if (styles[i] in style) { return true; }\n }\n return false;\n }()),\n\n observer: (function checkObserver() {\n return ('MutationObserver' in win || 'WebkitMutationObserver' in win);\n }()),\n\n passiveListener: (function checkPassiveListener() {\n var supportsPassive = false;\n try {\n var opts = Object.defineProperty({}, 'passive', {\n // eslint-disable-next-line\n get: function get() {\n supportsPassive = true;\n },\n });\n win.addEventListener('testPassiveListener', null, opts);\n } catch (e) {\n // No support\n }\n return supportsPassive;\n }()),\n\n gestures: (function checkGestures() {\n return 'ongesturestart' in win;\n }()),\n };\n }());\n\n var SwiperClass = function SwiperClass(params) {\n if ( params === void 0 ) params = {};\n\n var self = this;\n self.params = params;\n\n // Events\n self.eventsListeners = {};\n\n if (self.params && self.params.on) {\n Object.keys(self.params.on).forEach(function (eventName) {\n self.on(eventName, self.params.on[eventName]);\n });\n }\n };\n\n var staticAccessors = { components: { configurable: true } };\n SwiperClass.prototype.on = function on (events, handler, priority) {\n var self = this;\n if (typeof handler !== 'function') { return self; }\n var method = priority ? 'unshift' : 'push';\n events.split(' ').forEach(function (event) {\n if (!self.eventsListeners[event]) { self.eventsListeners[event] = []; }\n self.eventsListeners[event][method](handler);\n });\n return self;\n };\n SwiperClass.prototype.once = function once (events, handler, priority) {\n var self = this;\n if (typeof handler !== 'function') { return self; }\n function onceHandler() {\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n\n handler.apply(self, args);\n self.off(events, onceHandler);\n }\n return self.on(events, onceHandler, priority);\n };\n SwiperClass.prototype.off = function off (events, handler) {\n var self = this;\n if (!self.eventsListeners) { return self; }\n events.split(' ').forEach(function (event) {\n if (typeof handler === 'undefined') {\n self.eventsListeners[event] = [];\n } else {\n self.eventsListeners[event].forEach(function (eventHandler, index) {\n if (eventHandler === handler) {\n self.eventsListeners[event].splice(index, 1);\n }\n });\n }\n });\n return self;\n };\n SwiperClass.prototype.emit = function emit () {\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n\n var self = this;\n if (!self.eventsListeners) { return self; }\n var events;\n var data;\n var context;\n if (typeof args[0] === 'string' || Array.isArray(args[0])) {\n events = args[0];\n data = args.slice(1, args.length);\n context = self;\n } else {\n events = args[0].events;\n data = args[0].data;\n context = args[0].context || self;\n }\n var eventsArray = Array.isArray(events) ? events : events.split(' ');\n eventsArray.forEach(function (event) {\n if (self.eventsListeners && self.eventsListeners[event]) {\n var handlers = [];\n self.eventsListeners[event].forEach(function (eventHandler) {\n handlers.push(eventHandler);\n });\n handlers.forEach(function (eventHandler) {\n eventHandler.apply(context, data);\n });\n }\n });\n return self;\n };\n SwiperClass.prototype.useModulesParams = function useModulesParams (instanceParams) {\n var instance = this;\n if (!instance.modules) { return; }\n Object.keys(instance.modules).forEach(function (moduleName) {\n var module = instance.modules[moduleName];\n // Extend params\n if (module.params) {\n Utils.extend(instanceParams, module.params);\n }\n });\n };\n SwiperClass.prototype.useModules = function useModules (modulesParams) {\n if ( modulesParams === void 0 ) modulesParams = {};\n\n var instance = this;\n if (!instance.modules) { return; }\n Object.keys(instance.modules).forEach(function (moduleName) {\n var module = instance.modules[moduleName];\n var moduleParams = modulesParams[moduleName] || {};\n // Extend instance methods and props\n if (module.instance) {\n Object.keys(module.instance).forEach(function (modulePropName) {\n var moduleProp = module.instance[modulePropName];\n if (typeof moduleProp === 'function') {\n instance[modulePropName] = moduleProp.bind(instance);\n } else {\n instance[modulePropName] = moduleProp;\n }\n });\n }\n // Add event listeners\n if (module.on && instance.on) {\n Object.keys(module.on).forEach(function (moduleEventName) {\n instance.on(moduleEventName, module.on[moduleEventName]);\n });\n }\n\n // Module create callback\n if (module.create) {\n module.create.bind(instance)(moduleParams);\n }\n });\n };\n staticAccessors.components.set = function (components) {\n var Class = this;\n if (!Class.use) { return; }\n Class.use(components);\n };\n SwiperClass.installModule = function installModule (module) {\n var params = [], len = arguments.length - 1;\n while ( len-- > 0 ) params[ len ] = arguments[ len + 1 ];\n\n var Class = this;\n if (!Class.prototype.modules) { Class.prototype.modules = {}; }\n var name = module.name || (((Object.keys(Class.prototype.modules).length) + \"_\" + (Utils.now())));\n Class.prototype.modules[name] = module;\n // Prototype\n if (module.proto) {\n Object.keys(module.proto).forEach(function (key) {\n Class.prototype[key] = module.proto[key];\n });\n }\n // Class\n if (module.static) {\n Object.keys(module.static).forEach(function (key) {\n Class[key] = module.static[key];\n });\n }\n // Callback\n if (module.install) {\n module.install.apply(Class, params);\n }\n return Class;\n };\n SwiperClass.use = function use (module) {\n var params = [], len = arguments.length - 1;\n while ( len-- > 0 ) params[ len ] = arguments[ len + 1 ];\n\n var Class = this;\n if (Array.isArray(module)) {\n module.forEach(function (m) { return Class.installModule(m); });\n return Class;\n }\n return Class.installModule.apply(Class, [ module ].concat( params ));\n };\n\n Object.defineProperties( SwiperClass, staticAccessors );\n\n function updateSize () {\n var swiper = this;\n var width;\n var height;\n var $el = swiper.$el;\n if (typeof swiper.params.width !== 'undefined') {\n width = swiper.params.width;\n } else {\n width = $el[0].clientWidth;\n }\n if (typeof swiper.params.height !== 'undefined') {\n height = swiper.params.height;\n } else {\n height = $el[0].clientHeight;\n }\n if ((width === 0 && swiper.isHorizontal()) || (height === 0 && swiper.isVertical())) {\n return;\n }\n\n // Subtract paddings\n width = width - parseInt($el.css('padding-left'), 10) - parseInt($el.css('padding-right'), 10);\n height = height - parseInt($el.css('padding-top'), 10) - parseInt($el.css('padding-bottom'), 10);\n\n Utils.extend(swiper, {\n width: width,\n height: height,\n size: swiper.isHorizontal() ? width : height,\n });\n }\n\n function updateSlides () {\n var swiper = this;\n var params = swiper.params;\n\n var $wrapperEl = swiper.$wrapperEl;\n var swiperSize = swiper.size;\n var rtl = swiper.rtlTranslate;\n var wrongRTL = swiper.wrongRTL;\n var slides = $wrapperEl.children((\".\" + (swiper.params.slideClass)));\n var isVirtual = swiper.virtual && params.virtual.enabled;\n var slidesLength = isVirtual ? swiper.virtual.slides.length : slides.length;\n var snapGrid = [];\n var slidesGrid = [];\n var slidesSizesGrid = [];\n\n var offsetBefore = params.slidesOffsetBefore;\n if (typeof offsetBefore === 'function') {\n offsetBefore = params.slidesOffsetBefore.call(swiper);\n }\n\n var offsetAfter = params.slidesOffsetAfter;\n if (typeof offsetAfter === 'function') {\n offsetAfter = params.slidesOffsetAfter.call(swiper);\n }\n\n var previousSlidesLength = slidesLength;\n var previousSnapGridLength = swiper.snapGrid.length;\n var previousSlidesGridLength = swiper.snapGrid.length;\n\n var spaceBetween = params.spaceBetween;\n var slidePosition = -offsetBefore;\n var prevSlideSize = 0;\n var index = 0;\n if (typeof swiperSize === 'undefined') {\n return;\n }\n if (typeof spaceBetween === 'string' && spaceBetween.indexOf('%') >= 0) {\n spaceBetween = (parseFloat(spaceBetween.replace('%', '')) / 100) * swiperSize;\n }\n\n swiper.virtualSize = -spaceBetween;\n\n // reset margins\n if (rtl) { slides.css({ marginLeft: '', marginTop: '' }); }\n else { slides.css({ marginRight: '', marginBottom: '' }); }\n\n var slidesNumberEvenToRows;\n if (params.slidesPerColumn > 1) {\n if (Math.floor(slidesLength / params.slidesPerColumn) === slidesLength / swiper.params.slidesPerColumn) {\n slidesNumberEvenToRows = slidesLength;\n } else {\n slidesNumberEvenToRows = Math.ceil(slidesLength / params.slidesPerColumn) * params.slidesPerColumn;\n }\n if (params.slidesPerView !== 'auto' && params.slidesPerColumnFill === 'row') {\n slidesNumberEvenToRows = Math.max(slidesNumberEvenToRows, params.slidesPerView * params.slidesPerColumn);\n }\n }\n\n // Calc slides\n var slideSize;\n var slidesPerColumn = params.slidesPerColumn;\n var slidesPerRow = slidesNumberEvenToRows / slidesPerColumn;\n var numFullColumns = slidesPerRow - ((params.slidesPerColumn * slidesPerRow) - slidesLength);\n for (var i = 0; i < slidesLength; i += 1) {\n slideSize = 0;\n var slide = slides.eq(i);\n if (params.slidesPerColumn > 1) {\n // Set slides order\n var newSlideOrderIndex = (void 0);\n var column = (void 0);\n var row = (void 0);\n if (params.slidesPerColumnFill === 'column') {\n column = Math.floor(i / slidesPerColumn);\n row = i - (column * slidesPerColumn);\n if (column > numFullColumns || (column === numFullColumns && row === slidesPerColumn - 1)) {\n row += 1;\n if (row >= slidesPerColumn) {\n row = 0;\n column += 1;\n }\n }\n newSlideOrderIndex = column + ((row * slidesNumberEvenToRows) / slidesPerColumn);\n slide\n .css({\n '-webkit-box-ordinal-group': newSlideOrderIndex,\n '-moz-box-ordinal-group': newSlideOrderIndex,\n '-ms-flex-order': newSlideOrderIndex,\n '-webkit-order': newSlideOrderIndex,\n order: newSlideOrderIndex,\n });\n } else {\n row = Math.floor(i / slidesPerRow);\n column = i - (row * slidesPerRow);\n }\n slide\n .css(\n (\"margin-\" + (swiper.isHorizontal() ? 'top' : 'left')),\n (row !== 0 && params.spaceBetween) && (((params.spaceBetween) + \"px\"))\n )\n .attr('data-swiper-column', column)\n .attr('data-swiper-row', row);\n }\n if (slide.css('display') === 'none') { continue; } // eslint-disable-line\n\n if (params.slidesPerView === 'auto') {\n var slideStyles = win.getComputedStyle(slide[0], null);\n var currentTransform = slide[0].style.transform;\n if (currentTransform) {\n slide[0].style.transform = 'none';\n }\n if (swiper.isHorizontal()) {\n slideSize = slide[0].getBoundingClientRect().width +\n parseFloat(slideStyles.getPropertyValue('margin-left')) +\n parseFloat(slideStyles.getPropertyValue('margin-right'));\n } else {\n slideSize = slide[0].getBoundingClientRect().height +\n parseFloat(slideStyles.getPropertyValue('margin-top')) +\n parseFloat(slideStyles.getPropertyValue('margin-bottom'));\n }\n if (currentTransform) {\n slide[0].style.transform = currentTransform;\n }\n if (params.roundLengths) { slideSize = Math.floor(slideSize); }\n } else {\n slideSize = (swiperSize - ((params.slidesPerView - 1) * spaceBetween)) / params.slidesPerView;\n if (params.roundLengths) { slideSize = Math.floor(slideSize); }\n\n if (slides[i]) {\n if (swiper.isHorizontal()) {\n slides[i].style.width = slideSize + \"px\";\n } else {\n slides[i].style.height = slideSize + \"px\";\n }\n }\n }\n if (slides[i]) {\n slides[i].swiperSlideSize = slideSize;\n }\n slidesSizesGrid.push(slideSize);\n\n\n if (params.centeredSlides) {\n slidePosition = slidePosition + (slideSize / 2) + (prevSlideSize / 2) + spaceBetween;\n if (prevSlideSize === 0 && i !== 0) { slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; }\n if (i === 0) { slidePosition = slidePosition - (swiperSize / 2) - spaceBetween; }\n if (Math.abs(slidePosition) < 1 / 1000) { slidePosition = 0; }\n if ((index) % params.slidesPerGroup === 0) { snapGrid.push(slidePosition); }\n slidesGrid.push(slidePosition);\n } else {\n if ((index) % params.slidesPerGroup === 0) { snapGrid.push(slidePosition); }\n slidesGrid.push(slidePosition);\n slidePosition = slidePosition + slideSize + spaceBetween;\n }\n\n swiper.virtualSize += slideSize + spaceBetween;\n\n prevSlideSize = slideSize;\n\n index += 1;\n }\n swiper.virtualSize = Math.max(swiper.virtualSize, swiperSize) + offsetAfter;\n var newSlidesGrid;\n\n if (\n rtl && wrongRTL && (params.effect === 'slide' || params.effect === 'coverflow')) {\n $wrapperEl.css({ width: ((swiper.virtualSize + params.spaceBetween) + \"px\") });\n }\n if (!Support.flexbox || params.setWrapperSize) {\n if (swiper.isHorizontal()) { $wrapperEl.css({ width: ((swiper.virtualSize + params.spaceBetween) + \"px\") }); }\n else { $wrapperEl.css({ height: ((swiper.virtualSize + params.spaceBetween) + \"px\") }); }\n }\n\n if (params.slidesPerColumn > 1) {\n swiper.virtualSize = (slideSize + params.spaceBetween) * slidesNumberEvenToRows;\n swiper.virtualSize = Math.ceil(swiper.virtualSize / params.slidesPerColumn) - params.spaceBetween;\n if (swiper.isHorizontal()) { $wrapperEl.css({ width: ((swiper.virtualSize + params.spaceBetween) + \"px\") }); }\n else { $wrapperEl.css({ height: ((swiper.virtualSize + params.spaceBetween) + \"px\") }); }\n if (params.centeredSlides) {\n newSlidesGrid = [];\n for (var i$1 = 0; i$1 < snapGrid.length; i$1 += 1) {\n if (snapGrid[i$1] < swiper.virtualSize + snapGrid[0]) { newSlidesGrid.push(snapGrid[i$1]); }\n }\n snapGrid = newSlidesGrid;\n }\n }\n\n // Remove last grid elements depending on width\n if (!params.centeredSlides) {\n newSlidesGrid = [];\n for (var i$2 = 0; i$2 < snapGrid.length; i$2 += 1) {\n if (snapGrid[i$2] <= swiper.virtualSize - swiperSize) {\n newSlidesGrid.push(snapGrid[i$2]);\n }\n }\n snapGrid = newSlidesGrid;\n if (Math.floor(swiper.virtualSize - swiperSize) - Math.floor(snapGrid[snapGrid.length - 1]) > 1) {\n snapGrid.push(swiper.virtualSize - swiperSize);\n }\n }\n if (snapGrid.length === 0) { snapGrid = [0]; }\n\n if (params.spaceBetween !== 0) {\n if (swiper.isHorizontal()) {\n if (rtl) { slides.css({ marginLeft: (spaceBetween + \"px\") }); }\n else { slides.css({ marginRight: (spaceBetween + \"px\") }); }\n } else { slides.css({ marginBottom: (spaceBetween + \"px\") }); }\n }\n\n Utils.extend(swiper, {\n slides: slides,\n snapGrid: snapGrid,\n slidesGrid: slidesGrid,\n slidesSizesGrid: slidesSizesGrid,\n });\n\n if (slidesLength !== previousSlidesLength) {\n swiper.emit('slidesLengthChange');\n }\n if (snapGrid.length !== previousSnapGridLength) {\n if (swiper.params.watchOverflow) { swiper.checkOverflow(); }\n swiper.emit('snapGridLengthChange');\n }\n if (slidesGrid.length !== previousSlidesGridLength) {\n swiper.emit('slidesGridLengthChange');\n }\n\n if (params.watchSlidesProgress || params.watchSlidesVisibility) {\n swiper.updateSlidesOffset();\n }\n }\n\n function updateAutoHeight (speed) {\n var swiper = this;\n var activeSlides = [];\n var newHeight = 0;\n var i;\n if (typeof speed === 'number') {\n swiper.setTransition(speed);\n } else if (speed === true) {\n swiper.setTransition(swiper.params.speed);\n }\n // Find slides currently in view\n if (swiper.params.slidesPerView !== 'auto' && swiper.params.slidesPerView > 1) {\n for (i = 0; i < Math.ceil(swiper.params.slidesPerView); i += 1) {\n var index = swiper.activeIndex + i;\n if (index > swiper.slides.length) { break; }\n activeSlides.push(swiper.slides.eq(index)[0]);\n }\n } else {\n activeSlides.push(swiper.slides.eq(swiper.activeIndex)[0]);\n }\n\n // Find new height from highest slide in view\n for (i = 0; i < activeSlides.length; i += 1) {\n if (typeof activeSlides[i] !== 'undefined') {\n var height = activeSlides[i].offsetHeight;\n newHeight = height > newHeight ? height : newHeight;\n }\n }\n\n // Update Height\n if (newHeight) { swiper.$wrapperEl.css('height', (newHeight + \"px\")); }\n }\n\n function updateSlidesOffset () {\n var swiper = this;\n var slides = swiper.slides;\n for (var i = 0; i < slides.length; i += 1) {\n slides[i].swiperSlideOffset = swiper.isHorizontal() ? slides[i].offsetLeft : slides[i].offsetTop;\n }\n }\n\n function updateSlidesProgress (translate) {\n if ( translate === void 0 ) translate = (this && this.translate) || 0;\n\n var swiper = this;\n var params = swiper.params;\n\n var slides = swiper.slides;\n var rtl = swiper.rtlTranslate;\n\n if (slides.length === 0) { return; }\n if (typeof slides[0].swiperSlideOffset === 'undefined') { swiper.updateSlidesOffset(); }\n\n var offsetCenter = -translate;\n if (rtl) { offsetCenter = translate; }\n\n // Visible Slides\n slides.removeClass(params.slideVisibleClass);\n\n for (var i = 0; i < slides.length; i += 1) {\n var slide = slides[i];\n var slideProgress =\n (\n (offsetCenter + (params.centeredSlides ? swiper.minTranslate() : 0)) - slide.swiperSlideOffset\n ) / (slide.swiperSlideSize + params.spaceBetween);\n if (params.watchSlidesVisibility) {\n var slideBefore = -(offsetCenter - slide.swiperSlideOffset);\n var slideAfter = slideBefore + swiper.slidesSizesGrid[i];\n var isVisible =\n (slideBefore >= 0 && slideBefore < swiper.size) ||\n (slideAfter > 0 && slideAfter <= swiper.size) ||\n (slideBefore <= 0 && slideAfter >= swiper.size);\n if (isVisible) {\n slides.eq(i).addClass(params.slideVisibleClass);\n }\n }\n slide.progress = rtl ? -slideProgress : slideProgress;\n }\n }\n\n function updateProgress (translate) {\n if ( translate === void 0 ) translate = (this && this.translate) || 0;\n\n var swiper = this;\n var params = swiper.params;\n\n var translatesDiff = swiper.maxTranslate() - swiper.minTranslate();\n var progress = swiper.progress;\n var isBeginning = swiper.isBeginning;\n var isEnd = swiper.isEnd;\n var wasBeginning = isBeginning;\n var wasEnd = isEnd;\n if (translatesDiff === 0) {\n progress = 0;\n isBeginning = true;\n isEnd = true;\n } else {\n progress = (translate - swiper.minTranslate()) / (translatesDiff);\n isBeginning = progress <= 0;\n isEnd = progress >= 1;\n }\n Utils.extend(swiper, {\n progress: progress,\n isBeginning: isBeginning,\n isEnd: isEnd,\n });\n\n if (params.watchSlidesProgress || params.watchSlidesVisibility) { swiper.updateSlidesProgress(translate); }\n\n if (isBeginning && !wasBeginning) {\n swiper.emit('reachBeginning toEdge');\n }\n if (isEnd && !wasEnd) {\n swiper.emit('reachEnd toEdge');\n }\n if ((wasBeginning && !isBeginning) || (wasEnd && !isEnd)) {\n swiper.emit('fromEdge');\n }\n\n swiper.emit('progress', progress);\n }\n\n function updateSlidesClasses () {\n var swiper = this;\n\n var slides = swiper.slides;\n var params = swiper.params;\n var $wrapperEl = swiper.$wrapperEl;\n var activeIndex = swiper.activeIndex;\n var realIndex = swiper.realIndex;\n var isVirtual = swiper.virtual && params.virtual.enabled;\n\n slides.removeClass(((params.slideActiveClass) + \" \" + (params.slideNextClass) + \" \" + (params.slidePrevClass) + \" \" + (params.slideDuplicateActiveClass) + \" \" + (params.slideDuplicateNextClass) + \" \" + (params.slideDuplicatePrevClass)));\n\n var activeSlide;\n if (isVirtual) {\n activeSlide = swiper.$wrapperEl.find((\".\" + (params.slideClass) + \"[data-swiper-slide-index=\\\"\" + activeIndex + \"\\\"]\"));\n } else {\n activeSlide = slides.eq(activeIndex);\n }\n\n // Active classes\n activeSlide.addClass(params.slideActiveClass);\n\n if (params.loop) {\n // Duplicate to all looped slides\n if (activeSlide.hasClass(params.slideDuplicateClass)) {\n $wrapperEl\n .children((\".\" + (params.slideClass) + \":not(.\" + (params.slideDuplicateClass) + \")[data-swiper-slide-index=\\\"\" + realIndex + \"\\\"]\"))\n .addClass(params.slideDuplicateActiveClass);\n } else {\n $wrapperEl\n .children((\".\" + (params.slideClass) + \".\" + (params.slideDuplicateClass) + \"[data-swiper-slide-index=\\\"\" + realIndex + \"\\\"]\"))\n .addClass(params.slideDuplicateActiveClass);\n }\n }\n // Next Slide\n var nextSlide = activeSlide.nextAll((\".\" + (params.slideClass))).eq(0).addClass(params.slideNextClass);\n if (params.loop && nextSlide.length === 0) {\n nextSlide = slides.eq(0);\n nextSlide.addClass(params.slideNextClass);\n }\n // Prev Slide\n var prevSlide = activeSlide.prevAll((\".\" + (params.slideClass))).eq(0).addClass(params.slidePrevClass);\n if (params.loop && prevSlide.length === 0) {\n prevSlide = slides.eq(-1);\n prevSlide.addClass(params.slidePrevClass);\n }\n if (params.loop) {\n // Duplicate to all looped slides\n if (nextSlide.hasClass(params.slideDuplicateClass)) {\n $wrapperEl\n .children((\".\" + (params.slideClass) + \":not(.\" + (params.slideDuplicateClass) + \")[data-swiper-slide-index=\\\"\" + (nextSlide.attr('data-swiper-slide-index')) + \"\\\"]\"))\n .addClass(params.slideDuplicateNextClass);\n } else {\n $wrapperEl\n .children((\".\" + (params.slideClass) + \".\" + (params.slideDuplicateClass) + \"[data-swiper-slide-index=\\\"\" + (nextSlide.attr('data-swiper-slide-index')) + \"\\\"]\"))\n .addClass(params.slideDuplicateNextClass);\n }\n if (prevSlide.hasClass(params.slideDuplicateClass)) {\n $wrapperEl\n .children((\".\" + (params.slideClass) + \":not(.\" + (params.slideDuplicateClass) + \")[data-swiper-slide-index=\\\"\" + (prevSlide.attr('data-swiper-slide-index')) + \"\\\"]\"))\n .addClass(params.slideDuplicatePrevClass);\n } else {\n $wrapperEl\n .children((\".\" + (params.slideClass) + \".\" + (params.slideDuplicateClass) + \"[data-swiper-slide-index=\\\"\" + (prevSlide.attr('data-swiper-slide-index')) + \"\\\"]\"))\n .addClass(params.slideDuplicatePrevClass);\n }\n }\n }\n\n function updateActiveIndex (newActiveIndex) {\n var swiper = this;\n var translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate;\n var slidesGrid = swiper.slidesGrid;\n var snapGrid = swiper.snapGrid;\n var params = swiper.params;\n var previousIndex = swiper.activeIndex;\n var previousRealIndex = swiper.realIndex;\n var previousSnapIndex = swiper.snapIndex;\n var activeIndex = newActiveIndex;\n var snapIndex;\n if (typeof activeIndex === 'undefined') {\n for (var i = 0; i < slidesGrid.length; i += 1) {\n if (typeof slidesGrid[i + 1] !== 'undefined') {\n if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1] - ((slidesGrid[i + 1] - slidesGrid[i]) / 2)) {\n activeIndex = i;\n } else if (translate >= slidesGrid[i] && translate < slidesGrid[i + 1]) {\n activeIndex = i + 1;\n }\n } else if (translate >= slidesGrid[i]) {\n activeIndex = i;\n }\n }\n // Normalize slideIndex\n if (params.normalizeSlideIndex) {\n if (activeIndex < 0 || typeof activeIndex === 'undefined') { activeIndex = 0; }\n }\n }\n if (snapGrid.indexOf(translate) >= 0) {\n snapIndex = snapGrid.indexOf(translate);\n } else {\n snapIndex = Math.floor(activeIndex / params.slidesPerGroup);\n }\n if (snapIndex >= snapGrid.length) { snapIndex = snapGrid.length - 1; }\n if (activeIndex === previousIndex) {\n if (snapIndex !== previousSnapIndex) {\n swiper.snapIndex = snapIndex;\n swiper.emit('snapIndexChange');\n }\n return;\n }\n\n // Get real index\n var realIndex = parseInt(swiper.slides.eq(activeIndex).attr('data-swiper-slide-index') || activeIndex, 10);\n\n Utils.extend(swiper, {\n snapIndex: snapIndex,\n realIndex: realIndex,\n previousIndex: previousIndex,\n activeIndex: activeIndex,\n });\n swiper.emit('activeIndexChange');\n swiper.emit('snapIndexChange');\n if (previousRealIndex !== realIndex) {\n swiper.emit('realIndexChange');\n }\n swiper.emit('slideChange');\n }\n\n function updateClickedSlide (e) {\n var swiper = this;\n var params = swiper.params;\n var slide = $(e.target).closest((\".\" + (params.slideClass)))[0];\n var slideFound = false;\n if (slide) {\n for (var i = 0; i < swiper.slides.length; i += 1) {\n if (swiper.slides[i] === slide) { slideFound = true; }\n }\n }\n\n if (slide && slideFound) {\n swiper.clickedSlide = slide;\n if (swiper.virtual && swiper.params.virtual.enabled) {\n swiper.clickedIndex = parseInt($(slide).attr('data-swiper-slide-index'), 10);\n } else {\n swiper.clickedIndex = $(slide).index();\n }\n } else {\n swiper.clickedSlide = undefined;\n swiper.clickedIndex = undefined;\n return;\n }\n if (params.slideToClickedSlide && swiper.clickedIndex !== undefined && swiper.clickedIndex !== swiper.activeIndex) {\n swiper.slideToClickedSlide();\n }\n }\n\n var update = {\n updateSize: updateSize,\n updateSlides: updateSlides,\n updateAutoHeight: updateAutoHeight,\n updateSlidesOffset: updateSlidesOffset,\n updateSlidesProgress: updateSlidesProgress,\n updateProgress: updateProgress,\n updateSlidesClasses: updateSlidesClasses,\n updateActiveIndex: updateActiveIndex,\n updateClickedSlide: updateClickedSlide,\n };\n\n function getTranslate (axis) {\n if ( axis === void 0 ) axis = this.isHorizontal() ? 'x' : 'y';\n\n var swiper = this;\n\n var params = swiper.params;\n var rtl = swiper.rtlTranslate;\n var translate = swiper.translate;\n var $wrapperEl = swiper.$wrapperEl;\n\n if (params.virtualTranslate) {\n return rtl ? -translate : translate;\n }\n\n var currentTranslate = Utils.getTranslate($wrapperEl[0], axis);\n if (rtl) { currentTranslate = -currentTranslate; }\n\n return currentTranslate || 0;\n }\n\n function setTranslate (translate, byController) {\n var swiper = this;\n var rtl = swiper.rtlTranslate;\n var params = swiper.params;\n var $wrapperEl = swiper.$wrapperEl;\n var progress = swiper.progress;\n var x = 0;\n var y = 0;\n var z = 0;\n\n if (swiper.isHorizontal()) {\n x = rtl ? -translate : translate;\n } else {\n y = translate;\n }\n\n if (params.roundLengths) {\n x = Math.floor(x);\n y = Math.floor(y);\n }\n\n if (!params.virtualTranslate) {\n if (Support.transforms3d) { $wrapperEl.transform((\"translate3d(\" + x + \"px, \" + y + \"px, \" + z + \"px)\")); }\n else { $wrapperEl.transform((\"translate(\" + x + \"px, \" + y + \"px)\")); }\n }\n\n swiper.translate = swiper.isHorizontal() ? x : y;\n\n // Check if we need to update progress\n var newProgress;\n var translatesDiff = swiper.maxTranslate() - swiper.minTranslate();\n if (translatesDiff === 0) {\n newProgress = 0;\n } else {\n newProgress = (translate - swiper.minTranslate()) / (translatesDiff);\n }\n if (newProgress !== progress) {\n swiper.updateProgress(translate);\n }\n\n swiper.emit('setTranslate', swiper.translate, byController);\n }\n\n function minTranslate () {\n return (-this.snapGrid[0]);\n }\n\n function maxTranslate () {\n return (-this.snapGrid[this.snapGrid.length - 1]);\n }\n\n var translate = {\n getTranslate: getTranslate,\n setTranslate: setTranslate,\n minTranslate: minTranslate,\n maxTranslate: maxTranslate,\n };\n\n function setTransition (duration, byController) {\n var swiper = this;\n\n swiper.$wrapperEl.transition(duration);\n\n swiper.emit('setTransition', duration, byController);\n }\n\n function transitionStart (runCallbacks, direction) {\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n var activeIndex = swiper.activeIndex;\n var params = swiper.params;\n var previousIndex = swiper.previousIndex;\n if (params.autoHeight) {\n swiper.updateAutoHeight();\n }\n\n var dir = direction;\n if (!dir) {\n if (activeIndex > previousIndex) { dir = 'next'; }\n else if (activeIndex < previousIndex) { dir = 'prev'; }\n else { dir = 'reset'; }\n }\n\n swiper.emit('transitionStart');\n\n if (runCallbacks && activeIndex !== previousIndex) {\n if (dir === 'reset') {\n swiper.emit('slideResetTransitionStart');\n return;\n }\n swiper.emit('slideChangeTransitionStart');\n if (dir === 'next') {\n swiper.emit('slideNextTransitionStart');\n } else {\n swiper.emit('slidePrevTransitionStart');\n }\n }\n }\n\n function transitionEnd$1 (runCallbacks, direction) {\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n var activeIndex = swiper.activeIndex;\n var previousIndex = swiper.previousIndex;\n swiper.animating = false;\n swiper.setTransition(0);\n\n var dir = direction;\n if (!dir) {\n if (activeIndex > previousIndex) { dir = 'next'; }\n else if (activeIndex < previousIndex) { dir = 'prev'; }\n else { dir = 'reset'; }\n }\n\n swiper.emit('transitionEnd');\n\n if (runCallbacks && activeIndex !== previousIndex) {\n if (dir === 'reset') {\n swiper.emit('slideResetTransitionEnd');\n return;\n }\n swiper.emit('slideChangeTransitionEnd');\n if (dir === 'next') {\n swiper.emit('slideNextTransitionEnd');\n } else {\n swiper.emit('slidePrevTransitionEnd');\n }\n }\n }\n\n var transition$1 = {\n setTransition: setTransition,\n transitionStart: transitionStart,\n transitionEnd: transitionEnd$1,\n };\n\n function slideTo (index, speed, runCallbacks, internal) {\n if ( index === void 0 ) index = 0;\n if ( speed === void 0 ) speed = this.params.speed;\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n var slideIndex = index;\n if (slideIndex < 0) { slideIndex = 0; }\n\n var params = swiper.params;\n var snapGrid = swiper.snapGrid;\n var slidesGrid = swiper.slidesGrid;\n var previousIndex = swiper.previousIndex;\n var activeIndex = swiper.activeIndex;\n var rtl = swiper.rtlTranslate;\n if (swiper.animating && params.preventIntercationOnTransition) {\n return false;\n }\n\n var snapIndex = Math.floor(slideIndex / params.slidesPerGroup);\n if (snapIndex >= snapGrid.length) { snapIndex = snapGrid.length - 1; }\n\n if ((activeIndex || params.initialSlide || 0) === (previousIndex || 0) && runCallbacks) {\n swiper.emit('beforeSlideChangeStart');\n }\n\n var translate = -snapGrid[snapIndex];\n\n // Update progress\n swiper.updateProgress(translate);\n\n // Normalize slideIndex\n if (params.normalizeSlideIndex) {\n for (var i = 0; i < slidesGrid.length; i += 1) {\n if (-Math.floor(translate * 100) >= Math.floor(slidesGrid[i] * 100)) {\n slideIndex = i;\n }\n }\n }\n // Directions locks\n if (swiper.initialized && slideIndex !== activeIndex) {\n if (!swiper.allowSlideNext && translate < swiper.translate && translate < swiper.minTranslate()) {\n return false;\n }\n if (!swiper.allowSlidePrev && translate > swiper.translate && translate > swiper.maxTranslate()) {\n if ((activeIndex || 0) !== slideIndex) { return false; }\n }\n }\n\n var direction;\n if (slideIndex > activeIndex) { direction = 'next'; }\n else if (slideIndex < activeIndex) { direction = 'prev'; }\n else { direction = 'reset'; }\n\n\n // Update Index\n if ((rtl && -translate === swiper.translate) || (!rtl && translate === swiper.translate)) {\n swiper.updateActiveIndex(slideIndex);\n // Update Height\n if (params.autoHeight) {\n swiper.updateAutoHeight();\n }\n swiper.updateSlidesClasses();\n if (params.effect !== 'slide') {\n swiper.setTranslate(translate);\n }\n if (direction !== 'reset') {\n swiper.transitionStart(runCallbacks, direction);\n swiper.transitionEnd(runCallbacks, direction);\n }\n return false;\n }\n\n if (speed === 0 || !Support.transition) {\n swiper.setTransition(0);\n swiper.setTranslate(translate);\n swiper.updateActiveIndex(slideIndex);\n swiper.updateSlidesClasses();\n swiper.emit('beforeTransitionStart', speed, internal);\n swiper.transitionStart(runCallbacks, direction);\n swiper.transitionEnd(runCallbacks, direction);\n } else {\n swiper.setTransition(speed);\n swiper.setTranslate(translate);\n swiper.updateActiveIndex(slideIndex);\n swiper.updateSlidesClasses();\n swiper.emit('beforeTransitionStart', speed, internal);\n swiper.transitionStart(runCallbacks, direction);\n if (!swiper.animating) {\n swiper.animating = true;\n if (!swiper.onSlideToWrapperTransitionEnd) {\n swiper.onSlideToWrapperTransitionEnd = function transitionEnd(e) {\n if (!swiper || swiper.destroyed) { return; }\n if (e.target !== this) { return; }\n swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd);\n swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd);\n swiper.transitionEnd(runCallbacks, direction);\n };\n }\n swiper.$wrapperEl[0].addEventListener('transitionend', swiper.onSlideToWrapperTransitionEnd);\n swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.onSlideToWrapperTransitionEnd);\n }\n }\n\n return true;\n }\n\n function slideToLoop (index, speed, runCallbacks, internal) {\n if ( index === void 0 ) index = 0;\n if ( speed === void 0 ) speed = this.params.speed;\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n var newIndex = index;\n if (swiper.params.loop) {\n newIndex += swiper.loopedSlides;\n }\n\n return swiper.slideTo(newIndex, speed, runCallbacks, internal);\n }\n\n /* eslint no-unused-vars: \"off\" */\n function slideNext (speed, runCallbacks, internal) {\n if ( speed === void 0 ) speed = this.params.speed;\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n var params = swiper.params;\n var animating = swiper.animating;\n if (params.loop) {\n if (animating) { return false; }\n swiper.loopFix();\n // eslint-disable-next-line\n swiper._clientLeft = swiper.$wrapperEl[0].clientLeft;\n return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal);\n }\n return swiper.slideTo(swiper.activeIndex + params.slidesPerGroup, speed, runCallbacks, internal);\n }\n\n /* eslint no-unused-vars: \"off\" */\n function slidePrev (speed, runCallbacks, internal) {\n if ( speed === void 0 ) speed = this.params.speed;\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n var params = swiper.params;\n var animating = swiper.animating;\n var snapGrid = swiper.snapGrid;\n var slidesGrid = swiper.slidesGrid;\n var rtlTranslate = swiper.rtlTranslate;\n\n if (params.loop) {\n if (animating) { return false; }\n swiper.loopFix();\n // eslint-disable-next-line\n swiper._clientLeft = swiper.$wrapperEl[0].clientLeft;\n }\n var translate = rtlTranslate ? swiper.translate : -swiper.translate;\n var currentSnap = snapGrid[snapGrid.indexOf(translate)];\n var prevSnap = snapGrid[snapGrid.indexOf(translate) - 1];\n var prevIndex;\n\n if (prevSnap) {\n prevIndex = slidesGrid.indexOf(prevSnap);\n if (prevIndex < 0) { prevIndex = swiper.activeIndex - 1; }\n }\n return swiper.slideTo(prevIndex, speed, runCallbacks, internal);\n }\n\n /* eslint no-unused-vars: \"off\" */\n function slideReset (speed, runCallbacks, internal) {\n if ( speed === void 0 ) speed = this.params.speed;\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n return swiper.slideTo(swiper.activeIndex, speed, runCallbacks, internal);\n }\n\n /* eslint no-unused-vars: \"off\" */\n function slideToClosest (speed, runCallbacks, internal) {\n if ( speed === void 0 ) speed = this.params.speed;\n if ( runCallbacks === void 0 ) runCallbacks = true;\n\n var swiper = this;\n var index = swiper.activeIndex;\n var snapIndex = Math.floor(index / swiper.params.slidesPerGroup);\n\n if (snapIndex < swiper.snapGrid.length - 1) {\n var translate = swiper.rtlTranslate ? swiper.translate : -swiper.translate;\n\n var currentSnap = swiper.snapGrid[snapIndex];\n var nextSnap = swiper.snapGrid[snapIndex + 1];\n\n if ((translate - currentSnap) > (nextSnap - currentSnap) / 2) {\n index = swiper.params.slidesPerGroup;\n }\n }\n\n return swiper.slideTo(index, speed, runCallbacks, internal);\n }\n\n function slideToClickedSlide () {\n var swiper = this;\n var params = swiper.params;\n var $wrapperEl = swiper.$wrapperEl;\n\n var slidesPerView = params.slidesPerView === 'auto' ? swiper.slidesPerViewDynamic() : params.slidesPerView;\n var slideToIndex = swiper.clickedIndex;\n var realIndex;\n if (params.loop) {\n if (swiper.animating) { return; }\n realIndex = parseInt($(swiper.clickedSlide).attr('data-swiper-slide-index'), 10);\n if (params.centeredSlides) {\n if (\n (slideToIndex < swiper.loopedSlides - (slidesPerView / 2)) ||\n (slideToIndex > (swiper.slides.length - swiper.loopedSlides) + (slidesPerView / 2))\n ) {\n swiper.loopFix();\n slideToIndex = $wrapperEl\n .children((\".\" + (params.slideClass) + \"[data-swiper-slide-index=\\\"\" + realIndex + \"\\\"]:not(.\" + (params.slideDuplicateClass) + \")\"))\n .eq(0)\n .index();\n\n Utils.nextTick(function () {\n swiper.slideTo(slideToIndex);\n });\n } else {\n swiper.slideTo(slideToIndex);\n }\n } else if (slideToIndex > swiper.slides.length - slidesPerView) {\n swiper.loopFix();\n slideToIndex = $wrapperEl\n .children((\".\" + (params.slideClass) + \"[data-swiper-slide-index=\\\"\" + realIndex + \"\\\"]:not(.\" + (params.slideDuplicateClass) + \")\"))\n .eq(0)\n .index();\n\n Utils.nextTick(function () {\n swiper.slideTo(slideToIndex);\n });\n } else {\n swiper.slideTo(slideToIndex);\n }\n } else {\n swiper.slideTo(slideToIndex);\n }\n }\n\n var slide = {\n slideTo: slideTo,\n slideToLoop: slideToLoop,\n slideNext: slideNext,\n slidePrev: slidePrev,\n slideReset: slideReset,\n slideToClosest: slideToClosest,\n slideToClickedSlide: slideToClickedSlide,\n };\n\n function loopCreate () {\n var swiper = this;\n var params = swiper.params;\n var $wrapperEl = swiper.$wrapperEl;\n // Remove duplicated slides\n $wrapperEl.children((\".\" + (params.slideClass) + \".\" + (params.slideDuplicateClass))).remove();\n\n var slides = $wrapperEl.children((\".\" + (params.slideClass)));\n\n if (params.loopFillGroupWithBlank) {\n var blankSlidesNum = params.slidesPerGroup - (slides.length % params.slidesPerGroup);\n if (blankSlidesNum !== params.slidesPerGroup) {\n for (var i = 0; i < blankSlidesNum; i += 1) {\n var blankNode = $(doc.createElement('div')).addClass(((params.slideClass) + \" \" + (params.slideBlankClass)));\n $wrapperEl.append(blankNode);\n }\n slides = $wrapperEl.children((\".\" + (params.slideClass)));\n }\n }\n\n if (params.slidesPerView === 'auto' && !params.loopedSlides) { params.loopedSlides = slides.length; }\n\n swiper.loopedSlides = parseInt(params.loopedSlides || params.slidesPerView, 10);\n swiper.loopedSlides += params.loopAdditionalSlides;\n if (swiper.loopedSlides > slides.length) {\n swiper.loopedSlides = slides.length;\n }\n\n var prependSlides = [];\n var appendSlides = [];\n slides.each(function (index, el) {\n var slide = $(el);\n if (index < swiper.loopedSlides) { appendSlides.push(el); }\n if (index < slides.length && index >= slides.length - swiper.loopedSlides) { prependSlides.push(el); }\n slide.attr('data-swiper-slide-index', index);\n });\n for (var i$1 = 0; i$1 < appendSlides.length; i$1 += 1) {\n $wrapperEl.append($(appendSlides[i$1].cloneNode(true)).addClass(params.slideDuplicateClass));\n }\n for (var i$2 = prependSlides.length - 1; i$2 >= 0; i$2 -= 1) {\n $wrapperEl.prepend($(prependSlides[i$2].cloneNode(true)).addClass(params.slideDuplicateClass));\n }\n }\n\n function loopFix () {\n var swiper = this;\n var params = swiper.params;\n var activeIndex = swiper.activeIndex;\n var slides = swiper.slides;\n var loopedSlides = swiper.loopedSlides;\n var allowSlidePrev = swiper.allowSlidePrev;\n var allowSlideNext = swiper.allowSlideNext;\n var snapGrid = swiper.snapGrid;\n var rtl = swiper.rtlTranslate;\n var newIndex;\n swiper.allowSlidePrev = true;\n swiper.allowSlideNext = true;\n\n var snapTranslate = -snapGrid[activeIndex];\n var diff = snapTranslate - swiper.getTranslate();\n\n\n // Fix For Negative Oversliding\n if (activeIndex < loopedSlides) {\n newIndex = (slides.length - (loopedSlides * 3)) + activeIndex;\n newIndex += loopedSlides;\n var slideChanged = swiper.slideTo(newIndex, 0, false, true);\n if (slideChanged && diff !== 0) {\n swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff);\n }\n } else if ((params.slidesPerView === 'auto' && activeIndex >= loopedSlides * 2) || (activeIndex > slides.length - (params.slidesPerView * 2))) {\n // Fix For Positive Oversliding\n newIndex = -slides.length + activeIndex + loopedSlides;\n newIndex += loopedSlides;\n var slideChanged$1 = swiper.slideTo(newIndex, 0, false, true);\n if (slideChanged$1 && diff !== 0) {\n swiper.setTranslate((rtl ? -swiper.translate : swiper.translate) - diff);\n }\n }\n swiper.allowSlidePrev = allowSlidePrev;\n swiper.allowSlideNext = allowSlideNext;\n }\n\n function loopDestroy () {\n var swiper = this;\n var $wrapperEl = swiper.$wrapperEl;\n var params = swiper.params;\n var slides = swiper.slides;\n $wrapperEl.children((\".\" + (params.slideClass) + \".\" + (params.slideDuplicateClass))).remove();\n slides.removeAttr('data-swiper-slide-index');\n }\n\n var loop = {\n loopCreate: loopCreate,\n loopFix: loopFix,\n loopDestroy: loopDestroy,\n };\n\n function setGrabCursor (moving) {\n var swiper = this;\n if (Support.touch || !swiper.params.simulateTouch || (swiper.params.watchOverflow && swiper.isLocked)) { return; }\n var el = swiper.el;\n el.style.cursor = 'move';\n el.style.cursor = moving ? '-webkit-grabbing' : '-webkit-grab';\n el.style.cursor = moving ? '-moz-grabbin' : '-moz-grab';\n el.style.cursor = moving ? 'grabbing' : 'grab';\n }\n\n function unsetGrabCursor () {\n var swiper = this;\n if (Support.touch || (swiper.params.watchOverflow && swiper.isLocked)) { return; }\n swiper.el.style.cursor = '';\n }\n\n var grabCursor = {\n setGrabCursor: setGrabCursor,\n unsetGrabCursor: unsetGrabCursor,\n };\n\n function appendSlide (slides) {\n var swiper = this;\n var $wrapperEl = swiper.$wrapperEl;\n var params = swiper.params;\n if (params.loop) {\n swiper.loopDestroy();\n }\n if (typeof slides === 'object' && 'length' in slides) {\n for (var i = 0; i < slides.length; i += 1) {\n if (slides[i]) { $wrapperEl.append(slides[i]); }\n }\n } else {\n $wrapperEl.append(slides);\n }\n if (params.loop) {\n swiper.loopCreate();\n }\n if (!(params.observer && Support.observer)) {\n swiper.update();\n }\n }\n\n function prependSlide (slides) {\n var swiper = this;\n var params = swiper.params;\n var $wrapperEl = swiper.$wrapperEl;\n var activeIndex = swiper.activeIndex;\n\n if (params.loop) {\n swiper.loopDestroy();\n }\n var newActiveIndex = activeIndex + 1;\n if (typeof slides === 'object' && 'length' in slides) {\n for (var i = 0; i < slides.length; i += 1) {\n if (slides[i]) { $wrapperEl.prepend(slides[i]); }\n }\n newActiveIndex = activeIndex + slides.length;\n } else {\n $wrapperEl.prepend(slides);\n }\n if (params.loop) {\n swiper.loopCreate();\n }\n if (!(params.observer && Support.observer)) {\n swiper.update();\n }\n swiper.slideTo(newActiveIndex, 0, false);\n }\n\n function removeSlide (slidesIndexes) {\n var swiper = this;\n var params = swiper.params;\n var $wrapperEl = swiper.$wrapperEl;\n var activeIndex = swiper.activeIndex;\n\n if (params.loop) {\n swiper.loopDestroy();\n swiper.slides = $wrapperEl.children((\".\" + (params.slideClass)));\n }\n var newActiveIndex = activeIndex;\n var indexToRemove;\n\n if (typeof slidesIndexes === 'object' && 'length' in slidesIndexes) {\n for (var i = 0; i < slidesIndexes.length; i += 1) {\n indexToRemove = slidesIndexes[i];\n if (swiper.slides[indexToRemove]) { swiper.slides.eq(indexToRemove).remove(); }\n if (indexToRemove < newActiveIndex) { newActiveIndex -= 1; }\n }\n newActiveIndex = Math.max(newActiveIndex, 0);\n } else {\n indexToRemove = slidesIndexes;\n if (swiper.slides[indexToRemove]) { swiper.slides.eq(indexToRemove).remove(); }\n if (indexToRemove < newActiveIndex) { newActiveIndex -= 1; }\n newActiveIndex = Math.max(newActiveIndex, 0);\n }\n\n if (params.loop) {\n swiper.loopCreate();\n }\n\n if (!(params.observer && Support.observer)) {\n swiper.update();\n }\n if (params.loop) {\n swiper.slideTo(newActiveIndex + swiper.loopedSlides, 0, false);\n } else {\n swiper.slideTo(newActiveIndex, 0, false);\n }\n }\n\n function removeAllSlides () {\n var swiper = this;\n\n var slidesIndexes = [];\n for (var i = 0; i < swiper.slides.length; i += 1) {\n slidesIndexes.push(i);\n }\n swiper.removeSlide(slidesIndexes);\n }\n\n var manipulation = {\n appendSlide: appendSlide,\n prependSlide: prependSlide,\n removeSlide: removeSlide,\n removeAllSlides: removeAllSlides,\n };\n\n var Device = (function Device() {\n var ua = win.navigator.userAgent;\n\n var device = {\n ios: false,\n android: false,\n androidChrome: false,\n desktop: false,\n windows: false,\n iphone: false,\n ipod: false,\n ipad: false,\n cordova: win.cordova || win.phonegap,\n phonegap: win.cordova || win.phonegap,\n };\n\n var windows = ua.match(/(Windows Phone);?[\\s\\/]+([\\d.]+)?/); // eslint-disable-line\n var android = ua.match(/(Android);?[\\s\\/]+([\\d.]+)?/); // eslint-disable-line\n var ipad = ua.match(/(iPad).*OS\\s([\\d_]+)/);\n var ipod = ua.match(/(iPod)(.*OS\\s([\\d_]+))?/);\n var iphone = !ipad && ua.match(/(iPhone\\sOS|iOS)\\s([\\d_]+)/);\n\n\n // Windows\n if (windows) {\n device.os = 'windows';\n device.osVersion = windows[2];\n device.windows = true;\n }\n // Android\n if (android && !windows) {\n device.os = 'android';\n device.osVersion = android[2];\n device.android = true;\n device.androidChrome = ua.toLowerCase().indexOf('chrome') >= 0;\n }\n if (ipad || iphone || ipod) {\n device.os = 'ios';\n device.ios = true;\n }\n // iOS\n if (iphone && !ipod) {\n device.osVersion = iphone[2].replace(/_/g, '.');\n device.iphone = true;\n }\n if (ipad) {\n device.osVersion = ipad[2].replace(/_/g, '.');\n device.ipad = true;\n }\n if (ipod) {\n device.osVersion = ipod[3] ? ipod[3].replace(/_/g, '.') : null;\n device.iphone = true;\n }\n // iOS 8+ changed UA\n if (device.ios && device.osVersion && ua.indexOf('Version/') >= 0) {\n if (device.osVersion.split('.')[0] === '10') {\n device.osVersion = ua.toLowerCase().split('version/')[1].split(' ')[0];\n }\n }\n\n // Desktop\n device.desktop = !(device.os || device.android || device.webView);\n\n // Webview\n device.webView = (iphone || ipad || ipod) && ua.match(/.*AppleWebKit(?!.*Safari)/i);\n\n // Minimal UI\n if (device.os && device.os === 'ios') {\n var osVersionArr = device.osVersion.split('.');\n var metaViewport = doc.querySelector('meta[name=\"viewport\"]');\n device.minimalUi =\n !device.webView &&\n (ipod || iphone) &&\n (osVersionArr[0] * 1 === 7 ? osVersionArr[1] * 1 >= 1 : osVersionArr[0] * 1 > 7) &&\n metaViewport && metaViewport.getAttribute('content').indexOf('minimal-ui') >= 0;\n }\n\n // Pixel Ratio\n device.pixelRatio = win.devicePixelRatio || 1;\n\n // Export object\n return device;\n }());\n\n function onTouchStart (event) {\n var swiper = this;\n var data = swiper.touchEventsData;\n var params = swiper.params;\n var touches = swiper.touches;\n if (swiper.animating && params.preventIntercationOnTransition) {\n return;\n }\n var e = event;\n if (e.originalEvent) { e = e.originalEvent; }\n data.isTouchEvent = e.type === 'touchstart';\n if (!data.isTouchEvent && 'which' in e && e.which === 3) { return; }\n if (data.isTouched && data.isMoved) { return; }\n if (params.noSwiping && $(e.target).closest(params.noSwipingSelector ? params.noSwipingSelector : (\".\" + (params.noSwipingClass)))[0]) {\n swiper.allowClick = true;\n return;\n }\n if (params.swipeHandler) {\n if (!$(e).closest(params.swipeHandler)[0]) { return; }\n }\n\n touches.currentX = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX;\n touches.currentY = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY;\n var startX = touches.currentX;\n var startY = touches.currentY;\n\n // Do NOT start if iOS edge swipe is detected. Otherwise iOS app (UIWebView) cannot swipe-to-go-back anymore\n\n if (\n Device.ios &&\n !Device.cordova &&\n params.iOSEdgeSwipeDetection &&\n (startX <= params.iOSEdgeSwipeThreshold) &&\n (startX >= win.screen.width - params.iOSEdgeSwipeThreshold)\n ) {\n return;\n }\n\n Utils.extend(data, {\n isTouched: true,\n isMoved: false,\n allowTouchCallbacks: true,\n isScrolling: undefined,\n startMoving: undefined,\n });\n\n touches.startX = startX;\n touches.startY = startY;\n data.touchStartTime = Utils.now();\n swiper.allowClick = true;\n swiper.updateSize();\n swiper.swipeDirection = undefined;\n if (params.threshold > 0) { data.allowThresholdMove = false; }\n if (e.type !== 'touchstart') {\n var preventDefault = true;\n if ($(e.target).is(data.formElements)) { preventDefault = false; }\n if (\n doc.activeElement &&\n $(doc.activeElement).is(data.formElements) &&\n doc.activeElement !== e.target\n ) {\n doc.activeElement.blur();\n }\n if (preventDefault && swiper.allowTouchMove) {\n e.preventDefault();\n }\n }\n swiper.emit('touchStart', e);\n }\n\n function onTouchMove (event) {\n var swiper = this;\n var data = swiper.touchEventsData;\n var params = swiper.params;\n var touches = swiper.touches;\n var rtl = swiper.rtlTranslate;\n var e = event;\n if (e.originalEvent) { e = e.originalEvent; }\n if (!data.isTouched) {\n if (data.startMoving && data.isScrolling) {\n swiper.emit('touchMoveOpposite', e);\n }\n return;\n }\n if (data.isTouchEvent && e.type === 'mousemove') { return; }\n var pageX = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX;\n var pageY = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY;\n if (e.preventedByNestedSwiper) {\n touches.startX = pageX;\n touches.startY = pageY;\n return;\n }\n if (!swiper.allowTouchMove) {\n // isMoved = true;\n swiper.allowClick = false;\n if (data.isTouched) {\n Utils.extend(touches, {\n startX: pageX,\n startY: pageY,\n currentX: pageX,\n currentY: pageY,\n });\n data.touchStartTime = Utils.now();\n }\n return;\n }\n if (data.isTouchEvent && params.touchReleaseOnEdges && !params.loop) {\n if (swiper.isVertical()) {\n // Vertical\n if (\n (pageY < touches.startY && swiper.translate <= swiper.maxTranslate()) ||\n (pageY > touches.startY && swiper.translate >= swiper.minTranslate())\n ) {\n data.isTouched = false;\n data.isMoved = false;\n return;\n }\n } else if (\n (pageX < touches.startX && swiper.translate <= swiper.maxTranslate()) ||\n (pageX > touches.startX && swiper.translate >= swiper.minTranslate())\n ) {\n return;\n }\n }\n if (data.isTouchEvent && doc.activeElement) {\n if (e.target === doc.activeElement && $(e.target).is(data.formElements)) {\n data.isMoved = true;\n swiper.allowClick = false;\n return;\n }\n }\n if (data.allowTouchCallbacks) {\n swiper.emit('touchMove', e);\n }\n if (e.targetTouches && e.targetTouches.length > 1) { return; }\n\n touches.currentX = pageX;\n touches.currentY = pageY;\n\n var diffX = touches.currentX - touches.startX;\n var diffY = touches.currentY - touches.startY;\n\n if (typeof data.isScrolling === 'undefined') {\n var touchAngle;\n if ((swiper.isHorizontal() && touches.currentY === touches.startY) || (swiper.isVertical() && touches.currentX === touches.startX)) {\n data.isScrolling = false;\n } else {\n // eslint-disable-next-line\n if ((diffX * diffX) + (diffY * diffY) >= 25) {\n touchAngle = (Math.atan2(Math.abs(diffY), Math.abs(diffX)) * 180) / Math.PI;\n data.isScrolling = swiper.isHorizontal() ? touchAngle > params.touchAngle : (90 - touchAngle > params.touchAngle);\n }\n }\n }\n if (data.isScrolling) {\n swiper.emit('touchMoveOpposite', e);\n }\n if (typeof startMoving === 'undefined') {\n if (touches.currentX !== touches.startX || touches.currentY !== touches.startY) {\n data.startMoving = true;\n }\n }\n if (data.isScrolling) {\n data.isTouched = false;\n return;\n }\n if (!data.startMoving) {\n return;\n }\n swiper.allowClick = false;\n e.preventDefault();\n if (params.touchMoveStopPropagation && !params.nested) {\n e.stopPropagation();\n }\n\n if (!data.isMoved) {\n if (params.loop) {\n swiper.loopFix();\n }\n data.startTranslate = swiper.getTranslate();\n swiper.setTransition(0);\n if (swiper.animating) {\n swiper.$wrapperEl.trigger('webkitTransitionEnd transitionend');\n }\n data.allowMomentumBounce = false;\n // Grab Cursor\n if (params.grabCursor && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) {\n swiper.setGrabCursor(true);\n }\n swiper.emit('sliderFirstMove', e);\n }\n swiper.emit('sliderMove', e);\n data.isMoved = true;\n\n var diff = swiper.isHorizontal() ? diffX : diffY;\n touches.diff = diff;\n\n diff *= params.touchRatio;\n if (rtl) { diff = -diff; }\n\n swiper.swipeDirection = diff > 0 ? 'prev' : 'next';\n data.currentTranslate = diff + data.startTranslate;\n\n var disableParentSwiper = true;\n var resistanceRatio = params.resistanceRatio;\n if (params.touchReleaseOnEdges) {\n resistanceRatio = 0;\n }\n if ((diff > 0 && data.currentTranslate > swiper.minTranslate())) {\n disableParentSwiper = false;\n if (params.resistance) { data.currentTranslate = (swiper.minTranslate() - 1) + (Math.pow( (-swiper.minTranslate() + data.startTranslate + diff), resistanceRatio )); }\n } else if (diff < 0 && data.currentTranslate < swiper.maxTranslate()) {\n disableParentSwiper = false;\n if (params.resistance) { data.currentTranslate = (swiper.maxTranslate() + 1) - (Math.pow( (swiper.maxTranslate() - data.startTranslate - diff), resistanceRatio )); }\n }\n\n if (disableParentSwiper) {\n e.preventedByNestedSwiper = true;\n }\n\n // Directions locks\n if (!swiper.allowSlideNext && swiper.swipeDirection === 'next' && data.currentTranslate < data.startTranslate) {\n data.currentTranslate = data.startTranslate;\n }\n if (!swiper.allowSlidePrev && swiper.swipeDirection === 'prev' && data.currentTranslate > data.startTranslate) {\n data.currentTranslate = data.startTranslate;\n }\n\n\n // Threshold\n if (params.threshold > 0) {\n if (Math.abs(diff) > params.threshold || data.allowThresholdMove) {\n if (!data.allowThresholdMove) {\n data.allowThresholdMove = true;\n touches.startX = touches.currentX;\n touches.startY = touches.currentY;\n data.currentTranslate = data.startTranslate;\n touches.diff = swiper.isHorizontal() ? touches.currentX - touches.startX : touches.currentY - touches.startY;\n return;\n }\n } else {\n data.currentTranslate = data.startTranslate;\n return;\n }\n }\n\n if (!params.followFinger) { return; }\n\n // Update active index in free mode\n if (params.freeMode || params.watchSlidesProgress || params.watchSlidesVisibility) {\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n if (params.freeMode) {\n // Velocity\n if (data.velocities.length === 0) {\n data.velocities.push({\n position: touches[swiper.isHorizontal() ? 'startX' : 'startY'],\n time: data.touchStartTime,\n });\n }\n data.velocities.push({\n position: touches[swiper.isHorizontal() ? 'currentX' : 'currentY'],\n time: Utils.now(),\n });\n }\n // Update progress\n swiper.updateProgress(data.currentTranslate);\n // Update translate\n swiper.setTranslate(data.currentTranslate);\n }\n\n function onTouchEnd (event) {\n var swiper = this;\n var data = swiper.touchEventsData;\n\n var params = swiper.params;\n var touches = swiper.touches;\n var rtl = swiper.rtlTranslate;\n var $wrapperEl = swiper.$wrapperEl;\n var slidesGrid = swiper.slidesGrid;\n var snapGrid = swiper.snapGrid;\n var e = event;\n if (e.originalEvent) { e = e.originalEvent; }\n if (data.allowTouchCallbacks) {\n swiper.emit('touchEnd', e);\n }\n data.allowTouchCallbacks = false;\n if (!data.isTouched) {\n if (data.isMoved && params.grabCursor) {\n swiper.setGrabCursor(false);\n }\n data.isMoved = false;\n data.startMoving = false;\n return;\n }\n // Return Grab Cursor\n if (params.grabCursor && data.isMoved && data.isTouched && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) {\n swiper.setGrabCursor(false);\n }\n\n // Time diff\n var touchEndTime = Utils.now();\n var timeDiff = touchEndTime - data.touchStartTime;\n\n // Tap, doubleTap, Click\n if (swiper.allowClick) {\n swiper.updateClickedSlide(e);\n swiper.emit('tap', e);\n if (timeDiff < 300 && (touchEndTime - data.lastClickTime) > 300) {\n if (data.clickTimeout) { clearTimeout(data.clickTimeout); }\n data.clickTimeout = Utils.nextTick(function () {\n if (!swiper || swiper.destroyed) { return; }\n swiper.emit('click', e);\n }, 300);\n }\n if (timeDiff < 300 && (touchEndTime - data.lastClickTime) < 300) {\n if (data.clickTimeout) { clearTimeout(data.clickTimeout); }\n swiper.emit('doubleTap', e);\n }\n }\n\n data.lastClickTime = Utils.now();\n Utils.nextTick(function () {\n if (!swiper.destroyed) { swiper.allowClick = true; }\n });\n\n if (!data.isTouched || !data.isMoved || !swiper.swipeDirection || touches.diff === 0 || data.currentTranslate === data.startTranslate) {\n data.isTouched = false;\n data.isMoved = false;\n data.startMoving = false;\n return;\n }\n data.isTouched = false;\n data.isMoved = false;\n data.startMoving = false;\n\n var currentPos;\n if (params.followFinger) {\n currentPos = rtl ? swiper.translate : -swiper.translate;\n } else {\n currentPos = -data.currentTranslate;\n }\n\n if (params.freeMode) {\n if (currentPos < -swiper.minTranslate()) {\n swiper.slideTo(swiper.activeIndex);\n return;\n } else if (currentPos > -swiper.maxTranslate()) {\n if (swiper.slides.length < snapGrid.length) {\n swiper.slideTo(snapGrid.length - 1);\n } else {\n swiper.slideTo(swiper.slides.length - 1);\n }\n return;\n }\n\n if (params.freeModeMomentum) {\n if (data.velocities.length > 1) {\n var lastMoveEvent = data.velocities.pop();\n var velocityEvent = data.velocities.pop();\n\n var distance = lastMoveEvent.position - velocityEvent.position;\n var time = lastMoveEvent.time - velocityEvent.time;\n swiper.velocity = distance / time;\n swiper.velocity /= 2;\n if (Math.abs(swiper.velocity) < params.freeModeMinimumVelocity) {\n swiper.velocity = 0;\n }\n // this implies that the user stopped moving a finger then released.\n // There would be no events with distance zero, so the last event is stale.\n if (time > 150 || (Utils.now() - lastMoveEvent.time) > 300) {\n swiper.velocity = 0;\n }\n } else {\n swiper.velocity = 0;\n }\n swiper.velocity *= params.freeModeMomentumVelocityRatio;\n\n data.velocities.length = 0;\n var momentumDuration = 1000 * params.freeModeMomentumRatio;\n var momentumDistance = swiper.velocity * momentumDuration;\n\n var newPosition = swiper.translate + momentumDistance;\n if (rtl) { newPosition = -newPosition; }\n\n var doBounce = false;\n var afterBouncePosition;\n var bounceAmount = Math.abs(swiper.velocity) * 20 * params.freeModeMomentumBounceRatio;\n var needsLoopFix;\n if (newPosition < swiper.maxTranslate()) {\n if (params.freeModeMomentumBounce) {\n if (newPosition + swiper.maxTranslate() < -bounceAmount) {\n newPosition = swiper.maxTranslate() - bounceAmount;\n }\n afterBouncePosition = swiper.maxTranslate();\n doBounce = true;\n data.allowMomentumBounce = true;\n } else {\n newPosition = swiper.maxTranslate();\n }\n if (params.loop && params.centeredSlides) { needsLoopFix = true; }\n } else if (newPosition > swiper.minTranslate()) {\n if (params.freeModeMomentumBounce) {\n if (newPosition - swiper.minTranslate() > bounceAmount) {\n newPosition = swiper.minTranslate() + bounceAmount;\n }\n afterBouncePosition = swiper.minTranslate();\n doBounce = true;\n data.allowMomentumBounce = true;\n } else {\n newPosition = swiper.minTranslate();\n }\n if (params.loop && params.centeredSlides) { needsLoopFix = true; }\n } else if (params.freeModeSticky) {\n var nextSlide;\n for (var j = 0; j < snapGrid.length; j += 1) {\n if (snapGrid[j] > -newPosition) {\n nextSlide = j;\n break;\n }\n }\n\n if (Math.abs(snapGrid[nextSlide] - newPosition) < Math.abs(snapGrid[nextSlide - 1] - newPosition) || swiper.swipeDirection === 'next') {\n newPosition = snapGrid[nextSlide];\n } else {\n newPosition = snapGrid[nextSlide - 1];\n }\n newPosition = -newPosition;\n }\n if (needsLoopFix) {\n swiper.once('transitionEnd', function () {\n swiper.loopFix();\n });\n }\n // Fix duration\n if (swiper.velocity !== 0) {\n if (rtl) {\n momentumDuration = Math.abs((-newPosition - swiper.translate) / swiper.velocity);\n } else {\n momentumDuration = Math.abs((newPosition - swiper.translate) / swiper.velocity);\n }\n } else if (params.freeModeSticky) {\n swiper.slideToClosest();\n return;\n }\n\n if (params.freeModeMomentumBounce && doBounce) {\n swiper.updateProgress(afterBouncePosition);\n swiper.setTransition(momentumDuration);\n swiper.setTranslate(newPosition);\n swiper.transitionStart(true, swiper.swipeDirection);\n swiper.animating = true;\n $wrapperEl.transitionEnd(function () {\n if (!swiper || swiper.destroyed || !data.allowMomentumBounce) { return; }\n swiper.emit('momentumBounce');\n\n swiper.setTransition(params.speed);\n swiper.setTranslate(afterBouncePosition);\n $wrapperEl.transitionEnd(function () {\n if (!swiper || swiper.destroyed) { return; }\n swiper.transitionEnd();\n });\n });\n } else if (swiper.velocity) {\n swiper.updateProgress(newPosition);\n swiper.setTransition(momentumDuration);\n swiper.setTranslate(newPosition);\n swiper.transitionStart(true, swiper.swipeDirection);\n if (!swiper.animating) {\n swiper.animating = true;\n $wrapperEl.transitionEnd(function () {\n if (!swiper || swiper.destroyed) { return; }\n swiper.transitionEnd();\n });\n }\n } else {\n swiper.updateProgress(newPosition);\n }\n\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n } else if (params.freeModeSticky) {\n swiper.slideToClosest();\n return;\n }\n\n if (!params.freeModeMomentum || timeDiff >= params.longSwipesMs) {\n swiper.updateProgress();\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n return;\n }\n\n // Find current slide\n var stopIndex = 0;\n var groupSize = swiper.slidesSizesGrid[0];\n for (var i = 0; i < slidesGrid.length; i += params.slidesPerGroup) {\n if (typeof slidesGrid[i + params.slidesPerGroup] !== 'undefined') {\n if (currentPos >= slidesGrid[i] && currentPos < slidesGrid[i + params.slidesPerGroup]) {\n stopIndex = i;\n groupSize = slidesGrid[i + params.slidesPerGroup] - slidesGrid[i];\n }\n } else if (currentPos >= slidesGrid[i]) {\n stopIndex = i;\n groupSize = slidesGrid[slidesGrid.length - 1] - slidesGrid[slidesGrid.length - 2];\n }\n }\n\n // Find current slide size\n var ratio = (currentPos - slidesGrid[stopIndex]) / groupSize;\n\n if (timeDiff > params.longSwipesMs) {\n // Long touches\n if (!params.longSwipes) {\n swiper.slideTo(swiper.activeIndex);\n return;\n }\n if (swiper.swipeDirection === 'next') {\n if (ratio >= params.longSwipesRatio) { swiper.slideTo(stopIndex + params.slidesPerGroup); }\n else { swiper.slideTo(stopIndex); }\n }\n if (swiper.swipeDirection === 'prev') {\n if (ratio > (1 - params.longSwipesRatio)) { swiper.slideTo(stopIndex + params.slidesPerGroup); }\n else { swiper.slideTo(stopIndex); }\n }\n } else {\n // Short swipes\n if (!params.shortSwipes) {\n swiper.slideTo(swiper.activeIndex);\n return;\n }\n if (swiper.swipeDirection === 'next') {\n swiper.slideTo(stopIndex + params.slidesPerGroup);\n }\n if (swiper.swipeDirection === 'prev') {\n swiper.slideTo(stopIndex);\n }\n }\n }\n\n function onResize () {\n var swiper = this;\n\n var params = swiper.params;\n var el = swiper.el;\n\n if (el && el.offsetWidth === 0) { return; }\n\n // Breakpoints\n if (params.breakpoints) {\n swiper.setBreakpoint();\n }\n\n // Save locks\n var allowSlideNext = swiper.allowSlideNext;\n var allowSlidePrev = swiper.allowSlidePrev;\n var snapGrid = swiper.snapGrid;\n\n // Disable locks on resize\n swiper.allowSlideNext = true;\n swiper.allowSlidePrev = true;\n\n swiper.updateSize();\n swiper.updateSlides();\n\n if (params.freeMode) {\n var newTranslate = Math.min(Math.max(swiper.translate, swiper.maxTranslate()), swiper.minTranslate());\n swiper.setTranslate(newTranslate);\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n\n if (params.autoHeight) {\n swiper.updateAutoHeight();\n }\n } else {\n swiper.updateSlidesClasses();\n if ((params.slidesPerView === 'auto' || params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) {\n swiper.slideTo(swiper.slides.length - 1, 0, false, true);\n } else {\n swiper.slideTo(swiper.activeIndex, 0, false, true);\n }\n }\n // Return locks after resize\n swiper.allowSlidePrev = allowSlidePrev;\n swiper.allowSlideNext = allowSlideNext;\n\n if (swiper.params.watchOverflow && snapGrid !== swiper.snapGrid) {\n swiper.checkOverflow();\n }\n }\n\n function onClick (e) {\n var swiper = this;\n if (!swiper.allowClick) {\n if (swiper.params.preventClicks) { e.preventDefault(); }\n if (swiper.params.preventClicksPropagation && swiper.animating) {\n e.stopPropagation();\n e.stopImmediatePropagation();\n }\n }\n }\n\n function attachEvents() {\n var swiper = this;\n var params = swiper.params;\n var touchEvents = swiper.touchEvents;\n var el = swiper.el;\n var wrapperEl = swiper.wrapperEl;\n\n {\n swiper.onTouchStart = onTouchStart.bind(swiper);\n swiper.onTouchMove = onTouchMove.bind(swiper);\n swiper.onTouchEnd = onTouchEnd.bind(swiper);\n }\n\n swiper.onClick = onClick.bind(swiper);\n\n var target = params.touchEventsTarget === 'container' ? el : wrapperEl;\n var capture = !!params.nested;\n\n // Touch Events\n {\n if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) {\n target.addEventListener(touchEvents.start, swiper.onTouchStart, false);\n doc.addEventListener(touchEvents.move, swiper.onTouchMove, capture);\n doc.addEventListener(touchEvents.end, swiper.onTouchEnd, false);\n } else {\n if (Support.touch) {\n var passiveListener = touchEvents.start === 'touchstart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false;\n target.addEventListener(touchEvents.start, swiper.onTouchStart, passiveListener);\n target.addEventListener(touchEvents.move, swiper.onTouchMove, Support.passiveListener ? { passive: false, capture: capture } : capture);\n target.addEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener);\n }\n if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) {\n target.addEventListener('mousedown', swiper.onTouchStart, false);\n doc.addEventListener('mousemove', swiper.onTouchMove, capture);\n doc.addEventListener('mouseup', swiper.onTouchEnd, false);\n }\n }\n // Prevent Links Clicks\n if (params.preventClicks || params.preventClicksPropagation) {\n target.addEventListener('click', swiper.onClick, true);\n }\n }\n\n // Resize handler\n swiper.on('resize observerUpdate', onResize, true);\n }\n\n function detachEvents() {\n var swiper = this;\n\n var params = swiper.params;\n var touchEvents = swiper.touchEvents;\n var el = swiper.el;\n var wrapperEl = swiper.wrapperEl;\n\n var target = params.touchEventsTarget === 'container' ? el : wrapperEl;\n var capture = !!params.nested;\n\n // Touch Events\n {\n if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) {\n target.removeEventListener(touchEvents.start, swiper.onTouchStart, false);\n doc.removeEventListener(touchEvents.move, swiper.onTouchMove, capture);\n doc.removeEventListener(touchEvents.end, swiper.onTouchEnd, false);\n } else {\n if (Support.touch) {\n var passiveListener = touchEvents.start === 'onTouchStart' && Support.passiveListener && params.passiveListeners ? { passive: true, capture: false } : false;\n target.removeEventListener(touchEvents.start, swiper.onTouchStart, passiveListener);\n target.removeEventListener(touchEvents.move, swiper.onTouchMove, capture);\n target.removeEventListener(touchEvents.end, swiper.onTouchEnd, passiveListener);\n }\n if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) {\n target.removeEventListener('mousedown', swiper.onTouchStart, false);\n doc.removeEventListener('mousemove', swiper.onTouchMove, capture);\n doc.removeEventListener('mouseup', swiper.onTouchEnd, false);\n }\n }\n // Prevent Links Clicks\n if (params.preventClicks || params.preventClicksPropagation) {\n target.removeEventListener('click', swiper.onClick, true);\n }\n }\n\n // Resize handler\n swiper.off('resize observerUpdate', onResize);\n }\n\n var events = {\n attachEvents: attachEvents,\n detachEvents: detachEvents,\n };\n\n function setBreakpoint () {\n var swiper = this;\n var activeIndex = swiper.activeIndex;\n var initialized = swiper.initialized;\n var loopedSlides = swiper.loopedSlides; if ( loopedSlides === void 0 ) loopedSlides = 0;\n var params = swiper.params;\n var breakpoints = params.breakpoints;\n if (!breakpoints || (breakpoints && Object.keys(breakpoints).length === 0)) { return; }\n // Set breakpoint for window width and update parameters\n var breakpoint = swiper.getBreakpoint(breakpoints);\n if (breakpoint && swiper.currentBreakpoint !== breakpoint) {\n var breakPointsParams = breakpoint in breakpoints ? breakpoints[breakpoint] : swiper.originalParams;\n var needsReLoop = params.loop && (breakPointsParams.slidesPerView !== params.slidesPerView);\n\n Utils.extend(swiper.params, breakPointsParams);\n\n Utils.extend(swiper, {\n allowTouchMove: swiper.params.allowTouchMove,\n allowSlideNext: swiper.params.allowSlideNext,\n allowSlidePrev: swiper.params.allowSlidePrev,\n });\n\n swiper.currentBreakpoint = breakpoint;\n\n if (needsReLoop && initialized) {\n swiper.loopDestroy();\n swiper.loopCreate();\n swiper.updateSlides();\n swiper.slideTo((activeIndex - loopedSlides) + swiper.loopedSlides, 0, false);\n }\n swiper.emit('breakpoint', breakPointsParams);\n }\n }\n\n function getBreakpoint (breakpoints) {\n // Get breakpoint for window width\n if (!breakpoints) { return undefined; }\n var breakpoint = false;\n var points = [];\n Object.keys(breakpoints).forEach(function (point) {\n points.push(point);\n });\n points.sort(function (a, b) { return parseInt(a, 10) - parseInt(b, 10); });\n for (var i = 0; i < points.length; i += 1) {\n var point = points[i];\n if (point >= win.innerWidth && !breakpoint) {\n breakpoint = point;\n }\n }\n return breakpoint || 'max';\n }\n\n var breakpoints = { setBreakpoint: setBreakpoint, getBreakpoint: getBreakpoint };\n\n var Browser = (function Browser() {\n function isSafari() {\n var ua = win.navigator.userAgent.toLowerCase();\n return (ua.indexOf('safari') >= 0 && ua.indexOf('chrome') < 0 && ua.indexOf('android') < 0);\n }\n return {\n isIE: !!win.navigator.userAgent.match(/Trident/g) || !!win.navigator.userAgent.match(/MSIE/g),\n isSafari: isSafari(),\n isUiWebView: /(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(win.navigator.userAgent),\n };\n }());\n\n function addClasses () {\n var swiper = this;\n var classNames = swiper.classNames;\n var params = swiper.params;\n var rtl = swiper.rtl;\n var $el = swiper.$el;\n var suffixes = [];\n\n suffixes.push(params.direction);\n\n if (params.freeMode) {\n suffixes.push('free-mode');\n }\n if (!Support.flexbox) {\n suffixes.push('no-flexbox');\n }\n if (params.autoHeight) {\n suffixes.push('autoheight');\n }\n if (rtl) {\n suffixes.push('rtl');\n }\n if (params.slidesPerColumn > 1) {\n suffixes.push('multirow');\n }\n if (Device.android) {\n suffixes.push('android');\n }\n if (Device.ios) {\n suffixes.push('ios');\n }\n // WP8 Touch Events Fix\n if (Browser.isIE && (Support.pointerEvents || Support.prefixedPointerEvents)) {\n suffixes.push((\"wp8-\" + (params.direction)));\n }\n\n suffixes.forEach(function (suffix) {\n classNames.push(params.containerModifierClass + suffix);\n });\n\n $el.addClass(classNames.join(' '));\n }\n\n function removeClasses () {\n var swiper = this;\n var $el = swiper.$el;\n var classNames = swiper.classNames;\n\n $el.removeClass(classNames.join(' '));\n }\n\n var classes = { addClasses: addClasses, removeClasses: removeClasses };\n\n function loadImage (imageEl, src, srcset, sizes, checkForComplete, callback) {\n var image;\n function onReady() {\n if (callback) { callback(); }\n }\n if (!imageEl.complete || !checkForComplete) {\n if (src) {\n image = new win.Image();\n image.onload = onReady;\n image.onerror = onReady;\n if (sizes) {\n image.sizes = sizes;\n }\n if (srcset) {\n image.srcset = srcset;\n }\n if (src) {\n image.src = src;\n }\n } else {\n onReady();\n }\n } else {\n // image already loaded...\n onReady();\n }\n }\n\n function preloadImages () {\n var swiper = this;\n swiper.imagesToLoad = swiper.$el.find('img');\n function onReady() {\n if (typeof swiper === 'undefined' || swiper === null || !swiper || swiper.destroyed) { return; }\n if (swiper.imagesLoaded !== undefined) { swiper.imagesLoaded += 1; }\n if (swiper.imagesLoaded === swiper.imagesToLoad.length) {\n if (swiper.params.updateOnImagesReady) { swiper.update(); }\n swiper.emit('imagesReady');\n }\n }\n for (var i = 0; i < swiper.imagesToLoad.length; i += 1) {\n var imageEl = swiper.imagesToLoad[i];\n swiper.loadImage(\n imageEl,\n imageEl.currentSrc || imageEl.getAttribute('src'),\n imageEl.srcset || imageEl.getAttribute('srcset'),\n imageEl.sizes || imageEl.getAttribute('sizes'),\n true,\n onReady\n );\n }\n }\n\n var images = {\n loadImage: loadImage,\n preloadImages: preloadImages,\n };\n\n function checkOverflow() {\n var swiper = this;\n var wasLocked = swiper.isLocked;\n\n swiper.isLocked = swiper.snapGrid.length === 1;\n swiper.allowSlideNext = !swiper.isLocked;\n swiper.allowSlidePrev = !swiper.isLocked;\n\n // events\n if (wasLocked !== swiper.isLocked) { swiper.emit(swiper.isLocked ? 'lock' : 'unlock'); }\n\n if (wasLocked && wasLocked !== swiper.isLocked) {\n swiper.isEnd = false;\n swiper.navigation.update();\n }\n }\n\n var checkOverflow$1 = { checkOverflow: checkOverflow };\n\n var defaults = {\n init: true,\n direction: 'horizontal',\n touchEventsTarget: 'container',\n initialSlide: 0,\n speed: 300,\n //\n preventIntercationOnTransition: false,\n\n // To support iOS's swipe-to-go-back gesture (when being used in-app, with UIWebView).\n iOSEdgeSwipeDetection: false,\n iOSEdgeSwipeThreshold: 20,\n\n // Free mode\n freeMode: false,\n freeModeMomentum: true,\n freeModeMomentumRatio: 1,\n freeModeMomentumBounce: true,\n freeModeMomentumBounceRatio: 1,\n freeModeMomentumVelocityRatio: 1,\n freeModeSticky: false,\n freeModeMinimumVelocity: 0.02,\n\n // Autoheight\n autoHeight: false,\n\n // Set wrapper width\n setWrapperSize: false,\n\n // Virtual Translate\n virtualTranslate: false,\n\n // Effects\n effect: 'slide', // 'slide' or 'fade' or 'cube' or 'coverflow' or 'flip'\n\n // Breakpoints\n breakpoints: undefined,\n\n // Slides grid\n spaceBetween: 0,\n slidesPerView: 1,\n slidesPerColumn: 1,\n slidesPerColumnFill: 'column',\n slidesPerGroup: 1,\n centeredSlides: false,\n slidesOffsetBefore: 0, // in px\n slidesOffsetAfter: 0, // in px\n normalizeSlideIndex: true,\n\n // Disable swiper and hide navigation when container not overflow\n watchOverflow: false,\n\n // Round length\n roundLengths: false,\n\n // Touches\n touchRatio: 1,\n touchAngle: 45,\n simulateTouch: true,\n shortSwipes: true,\n longSwipes: true,\n longSwipesRatio: 0.5,\n longSwipesMs: 300,\n followFinger: true,\n allowTouchMove: true,\n threshold: 0,\n touchMoveStopPropagation: true,\n touchReleaseOnEdges: false,\n\n // Unique Navigation Elements\n uniqueNavElements: true,\n\n // Resistance\n resistance: true,\n resistanceRatio: 0.85,\n\n // Progress\n watchSlidesProgress: false,\n watchSlidesVisibility: false,\n\n // Cursor\n grabCursor: false,\n\n // Clicks\n preventClicks: true,\n preventClicksPropagation: true,\n slideToClickedSlide: false,\n\n // Images\n preloadImages: true,\n updateOnImagesReady: true,\n\n // loop\n loop: false,\n loopAdditionalSlides: 0,\n loopedSlides: null,\n loopFillGroupWithBlank: false,\n\n // Swiping/no swiping\n allowSlidePrev: true,\n allowSlideNext: true,\n swipeHandler: null, // '.swipe-handler',\n noSwiping: true,\n noSwipingClass: 'swiper-no-swiping',\n noSwipingSelector: null,\n\n // Passive Listeners\n passiveListeners: true,\n\n // NS\n containerModifierClass: 'swiper-container-', // NEW\n slideClass: 'swiper-slide',\n slideBlankClass: 'swiper-slide-invisible-blank',\n slideActiveClass: 'swiper-slide-active',\n slideDuplicateActiveClass: 'swiper-slide-duplicate-active',\n slideVisibleClass: 'swiper-slide-visible',\n slideDuplicateClass: 'swiper-slide-duplicate',\n slideNextClass: 'swiper-slide-next',\n slideDuplicateNextClass: 'swiper-slide-duplicate-next',\n slidePrevClass: 'swiper-slide-prev',\n slideDuplicatePrevClass: 'swiper-slide-duplicate-prev',\n wrapperClass: 'swiper-wrapper',\n\n // Callbacks\n runCallbacksOnInit: true,\n };\n\n var prototypes = {\n update: update,\n translate: translate,\n transition: transition$1,\n slide: slide,\n loop: loop,\n grabCursor: grabCursor,\n manipulation: manipulation,\n events: events,\n breakpoints: breakpoints,\n checkOverflow: checkOverflow$1,\n classes: classes,\n images: images,\n };\n\n var extendedDefaults = {};\n\n var Swiper = (function (SwiperClass$$1) {\n function Swiper() {\n var assign;\n\n var args = [], len = arguments.length;\n while ( len-- ) args[ len ] = arguments[ len ];\n var el;\n var params;\n if (args.length === 1 && args[0].constructor && args[0].constructor === Object) {\n params = args[0];\n } else {\n (assign = args, el = assign[0], params = assign[1]);\n }\n if (!params) { params = {}; }\n\n params = Utils.extend({}, params);\n if (el && !params.el) { params.el = el; }\n\n SwiperClass$$1.call(this, params);\n\n Object.keys(prototypes).forEach(function (prototypeGroup) {\n Object.keys(prototypes[prototypeGroup]).forEach(function (protoMethod) {\n if (!Swiper.prototype[protoMethod]) {\n Swiper.prototype[protoMethod] = prototypes[prototypeGroup][protoMethod];\n }\n });\n });\n\n // Swiper Instance\n var swiper = this;\n if (typeof swiper.modules === 'undefined') {\n swiper.modules = {};\n }\n Object.keys(swiper.modules).forEach(function (moduleName) {\n var module = swiper.modules[moduleName];\n if (module.params) {\n var moduleParamName = Object.keys(module.params)[0];\n var moduleParams = module.params[moduleParamName];\n if (typeof moduleParams !== 'object') { return; }\n if (!(moduleParamName in params && 'enabled' in moduleParams)) { return; }\n if (params[moduleParamName] === true) {\n params[moduleParamName] = { enabled: true };\n }\n if (\n typeof params[moduleParamName] === 'object' &&\n !('enabled' in params[moduleParamName])\n ) {\n params[moduleParamName].enabled = true;\n }\n if (!params[moduleParamName]) { params[moduleParamName] = { enabled: false }; }\n }\n });\n\n // Extend defaults with modules params\n var swiperParams = Utils.extend({}, defaults);\n swiper.useModulesParams(swiperParams);\n\n // Extend defaults with passed params\n swiper.params = Utils.extend({}, swiperParams, extendedDefaults, params);\n swiper.originalParams = Utils.extend({}, swiper.params);\n swiper.passedParams = Utils.extend({}, params);\n\n // Save Dom lib\n swiper.$ = $;\n\n // Find el\n var $el = $(swiper.params.el);\n el = $el[0];\n\n if (!el) {\n return undefined;\n }\n\n if ($el.length > 1) {\n var swipers = [];\n $el.each(function (index, containerEl) {\n var newParams = Utils.extend({}, params, { el: containerEl });\n swipers.push(new Swiper(newParams));\n });\n return swipers;\n }\n\n el.swiper = swiper;\n $el.data('swiper', swiper);\n\n // Find Wrapper\n var $wrapperEl = $el.children((\".\" + (swiper.params.wrapperClass)));\n\n // Extend Swiper\n Utils.extend(swiper, {\n $el: $el,\n el: el,\n $wrapperEl: $wrapperEl,\n wrapperEl: $wrapperEl[0],\n\n // Classes\n classNames: [],\n\n // Slides\n slides: $(),\n slidesGrid: [],\n snapGrid: [],\n slidesSizesGrid: [],\n\n // isDirection\n isHorizontal: function isHorizontal() {\n return swiper.params.direction === 'horizontal';\n },\n isVertical: function isVertical() {\n return swiper.params.direction === 'vertical';\n },\n // RTL\n rtl: (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'),\n rtlTranslate: swiper.params.direction === 'horizontal' && (el.dir.toLowerCase() === 'rtl' || $el.css('direction') === 'rtl'),\n wrongRTL: $wrapperEl.css('display') === '-webkit-box',\n\n // Indexes\n activeIndex: 0,\n realIndex: 0,\n\n //\n isBeginning: true,\n isEnd: false,\n\n // Props\n translate: 0,\n progress: 0,\n velocity: 0,\n animating: false,\n\n // Locks\n allowSlideNext: swiper.params.allowSlideNext,\n allowSlidePrev: swiper.params.allowSlidePrev,\n\n // Touch Events\n touchEvents: (function touchEvents() {\n var touch = ['touchstart', 'touchmove', 'touchend'];\n var desktop = ['mousedown', 'mousemove', 'mouseup'];\n if (Support.pointerEvents) {\n desktop = ['pointerdown', 'pointermove', 'pointerup'];\n } else if (Support.prefixedPointerEvents) {\n desktop = ['MSPointerDown', 'MSPointerMove', 'MSPointerUp'];\n }\n swiper.touchEventsTouch = {\n start: touch[0],\n move: touch[1],\n end: touch[2],\n };\n swiper.touchEventsDesktop = {\n start: desktop[0],\n move: desktop[1],\n end: desktop[2],\n };\n return Support.touch || !swiper.params.simulateTouch ? swiper.touchEventsTouch : swiper.touchEventsDesktop;\n }()),\n touchEventsData: {\n isTouched: undefined,\n isMoved: undefined,\n allowTouchCallbacks: undefined,\n touchStartTime: undefined,\n isScrolling: undefined,\n currentTranslate: undefined,\n startTranslate: undefined,\n allowThresholdMove: undefined,\n // Form elements to match\n formElements: 'input, select, option, textarea, button, video',\n // Last click time\n lastClickTime: Utils.now(),\n clickTimeout: undefined,\n // Velocities\n velocities: [],\n allowMomentumBounce: undefined,\n isTouchEvent: undefined,\n startMoving: undefined,\n },\n\n // Clicks\n allowClick: true,\n\n // Touches\n allowTouchMove: swiper.params.allowTouchMove,\n\n touches: {\n startX: 0,\n startY: 0,\n currentX: 0,\n currentY: 0,\n diff: 0,\n },\n\n // Images\n imagesToLoad: [],\n imagesLoaded: 0,\n\n });\n\n // Install Modules\n swiper.useModules();\n\n // Init\n if (swiper.params.init) {\n swiper.init();\n }\n\n // Return app instance\n return swiper;\n }\n\n if ( SwiperClass$$1 ) Swiper.__proto__ = SwiperClass$$1;\n Swiper.prototype = Object.create( SwiperClass$$1 && SwiperClass$$1.prototype );\n Swiper.prototype.constructor = Swiper;\n\n var staticAccessors = { extendedDefaults: { configurable: true },defaults: { configurable: true },Class: { configurable: true },$: { configurable: true } };\n Swiper.prototype.slidesPerViewDynamic = function slidesPerViewDynamic () {\n var swiper = this;\n var params = swiper.params;\n var slides = swiper.slides;\n var slidesGrid = swiper.slidesGrid;\n var swiperSize = swiper.size;\n var activeIndex = swiper.activeIndex;\n var spv = 1;\n if (params.centeredSlides) {\n var slideSize = slides[activeIndex].swiperSlideSize;\n var breakLoop;\n for (var i = activeIndex + 1; i < slides.length; i += 1) {\n if (slides[i] && !breakLoop) {\n slideSize += slides[i].swiperSlideSize;\n spv += 1;\n if (slideSize > swiperSize) { breakLoop = true; }\n }\n }\n for (var i$1 = activeIndex - 1; i$1 >= 0; i$1 -= 1) {\n if (slides[i$1] && !breakLoop) {\n slideSize += slides[i$1].swiperSlideSize;\n spv += 1;\n if (slideSize > swiperSize) { breakLoop = true; }\n }\n }\n } else {\n for (var i$2 = activeIndex + 1; i$2 < slides.length; i$2 += 1) {\n if (slidesGrid[i$2] - slidesGrid[activeIndex] < swiperSize) {\n spv += 1;\n }\n }\n }\n return spv;\n };\n Swiper.prototype.update = function update$$1 () {\n var swiper = this;\n if (!swiper || swiper.destroyed) { return; }\n var snapGrid = swiper.snapGrid;\n var params = swiper.params;\n // Breakpoints\n if (params.breakpoints) {\n swiper.setBreakpoint();\n }\n swiper.updateSize();\n swiper.updateSlides();\n swiper.updateProgress();\n swiper.updateSlidesClasses();\n\n function setTranslate() {\n var translateValue = swiper.rtlTranslate ? swiper.translate * -1 : swiper.translate;\n var newTranslate = Math.min(Math.max(translateValue, swiper.maxTranslate()), swiper.minTranslate());\n swiper.setTranslate(newTranslate);\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n }\n var translated;\n if (swiper.params.freeMode) {\n setTranslate();\n if (swiper.params.autoHeight) {\n swiper.updateAutoHeight();\n }\n } else {\n if ((swiper.params.slidesPerView === 'auto' || swiper.params.slidesPerView > 1) && swiper.isEnd && !swiper.params.centeredSlides) {\n translated = swiper.slideTo(swiper.slides.length - 1, 0, false, true);\n } else {\n translated = swiper.slideTo(swiper.activeIndex, 0, false, true);\n }\n if (!translated) {\n setTranslate();\n }\n }\n if (params.watchOverflow && snapGrid !== swiper.snapGrid) {\n swiper.checkOverflow();\n }\n swiper.emit('update');\n };\n Swiper.prototype.init = function init () {\n var swiper = this;\n if (swiper.initialized) { return; }\n\n swiper.emit('beforeInit');\n\n // Set breakpoint\n if (swiper.params.breakpoints) {\n swiper.setBreakpoint();\n }\n\n // Add Classes\n swiper.addClasses();\n\n // Create loop\n if (swiper.params.loop) {\n swiper.loopCreate();\n }\n\n // Update size\n swiper.updateSize();\n\n // Update slides\n swiper.updateSlides();\n\n if (swiper.params.watchOverflow) {\n swiper.checkOverflow();\n }\n\n // Set Grab Cursor\n if (swiper.params.grabCursor) {\n swiper.setGrabCursor();\n }\n\n if (swiper.params.preloadImages) {\n swiper.preloadImages();\n }\n\n // Slide To Initial Slide\n if (swiper.params.loop) {\n swiper.slideTo(swiper.params.initialSlide + swiper.loopedSlides, 0, swiper.params.runCallbacksOnInit);\n } else {\n swiper.slideTo(swiper.params.initialSlide, 0, swiper.params.runCallbacksOnInit);\n }\n\n // Attach events\n swiper.attachEvents();\n\n // Init Flag\n swiper.initialized = true;\n\n // Emit\n swiper.emit('init');\n };\n Swiper.prototype.destroy = function destroy (deleteInstance, cleanStyles) {\n if ( deleteInstance === void 0 ) deleteInstance = true;\n if ( cleanStyles === void 0 ) cleanStyles = true;\n\n var swiper = this;\n var params = swiper.params;\n var $el = swiper.$el;\n var $wrapperEl = swiper.$wrapperEl;\n var slides = swiper.slides;\n\n if (typeof swiper.params === 'undefined' || swiper.destroyed) {\n return null;\n }\n\n swiper.emit('beforeDestroy');\n\n // Init Flag\n swiper.initialized = false;\n\n // Detach events\n swiper.detachEvents();\n\n // Destroy loop\n if (params.loop) {\n swiper.loopDestroy();\n }\n\n // Cleanup styles\n if (cleanStyles) {\n swiper.removeClasses();\n $el.removeAttr('style');\n $wrapperEl.removeAttr('style');\n if (slides && slides.length) {\n slides\n .removeClass([\n params.slideVisibleClass,\n params.slideActiveClass,\n params.slideNextClass,\n params.slidePrevClass ].join(' '))\n .removeAttr('style')\n .removeAttr('data-swiper-slide-index')\n .removeAttr('data-swiper-column')\n .removeAttr('data-swiper-row');\n }\n }\n\n swiper.emit('destroy');\n\n // Detach emitter events\n Object.keys(swiper.eventsListeners).forEach(function (eventName) {\n swiper.off(eventName);\n });\n\n if (deleteInstance !== false) {\n swiper.$el[0].swiper = null;\n swiper.$el.data('swiper', null);\n Utils.deleteProps(swiper);\n }\n swiper.destroyed = true;\n\n return null;\n };\n Swiper.extendDefaults = function extendDefaults (newDefaults) {\n Utils.extend(extendedDefaults, newDefaults);\n };\n staticAccessors.extendedDefaults.get = function () {\n return extendedDefaults;\n };\n staticAccessors.defaults.get = function () {\n return defaults;\n };\n staticAccessors.Class.get = function () {\n return SwiperClass$$1;\n };\n staticAccessors.$.get = function () {\n return $;\n };\n\n Object.defineProperties( Swiper, staticAccessors );\n\n return Swiper;\n }(SwiperClass));\n\n var Device$1 = {\n name: 'device',\n proto: {\n device: Device,\n },\n static: {\n device: Device,\n },\n };\n\n var Support$1 = {\n name: 'support',\n proto: {\n support: Support,\n },\n static: {\n support: Support,\n },\n };\n\n var Browser$1 = {\n name: 'browser',\n proto: {\n browser: Browser,\n },\n static: {\n browser: Browser,\n },\n };\n\n var Resize = {\n name: 'resize',\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n resize: {\n resizeHandler: function resizeHandler() {\n if (!swiper || swiper.destroyed || !swiper.initialized) { return; }\n swiper.emit('beforeResize');\n swiper.emit('resize');\n },\n orientationChangeHandler: function orientationChangeHandler() {\n if (!swiper || swiper.destroyed || !swiper.initialized) { return; }\n swiper.emit('orientationchange');\n },\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n // Emit resize\n win.addEventListener('resize', swiper.resize.resizeHandler);\n\n // Emit orientationchange\n win.addEventListener('orientationchange', swiper.resize.orientationChangeHandler);\n },\n destroy: function destroy() {\n var swiper = this;\n win.removeEventListener('resize', swiper.resize.resizeHandler);\n win.removeEventListener('orientationchange', swiper.resize.orientationChangeHandler);\n },\n },\n };\n\n var Observer = {\n func: win.MutationObserver || win.WebkitMutationObserver,\n attach: function attach(target, options) {\n if ( options === void 0 ) options = {};\n\n var swiper = this;\n\n var ObserverFunc = Observer.func;\n var observer = new ObserverFunc(function (mutations) {\n mutations.forEach(function (mutation) {\n swiper.emit('observerUpdate', mutation);\n });\n });\n\n observer.observe(target, {\n attributes: typeof options.attributes === 'undefined' ? true : options.attributes,\n childList: typeof options.childList === 'undefined' ? true : options.childList,\n characterData: typeof options.characterData === 'undefined' ? true : options.characterData,\n });\n\n swiper.observer.observers.push(observer);\n },\n init: function init() {\n var swiper = this;\n if (!Support.observer || !swiper.params.observer) { return; }\n if (swiper.params.observeParents) {\n var containerParents = swiper.$el.parents();\n for (var i = 0; i < containerParents.length; i += 1) {\n swiper.observer.attach(containerParents[i]);\n }\n }\n // Observe container\n swiper.observer.attach(swiper.$el[0], { childList: false });\n\n // Observe wrapper\n swiper.observer.attach(swiper.$wrapperEl[0], { attributes: false });\n },\n destroy: function destroy() {\n var swiper = this;\n swiper.observer.observers.forEach(function (observer) {\n observer.disconnect();\n });\n swiper.observer.observers = [];\n },\n };\n\n var Observer$1 = {\n name: 'observer',\n params: {\n observer: false,\n observeParents: false,\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n observer: {\n init: Observer.init.bind(swiper),\n attach: Observer.attach.bind(swiper),\n destroy: Observer.destroy.bind(swiper),\n observers: [],\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n swiper.observer.init();\n },\n destroy: function destroy() {\n var swiper = this;\n swiper.observer.destroy();\n },\n },\n };\n\n var Virtual = {\n update: function update(force) {\n var swiper = this;\n var ref = swiper.params;\n var slidesPerView = ref.slidesPerView;\n var slidesPerGroup = ref.slidesPerGroup;\n var centeredSlides = ref.centeredSlides;\n var ref$1 = swiper.virtual;\n var previousFrom = ref$1.from;\n var previousTo = ref$1.to;\n var slides = ref$1.slides;\n var previousSlidesGrid = ref$1.slidesGrid;\n var renderSlide = ref$1.renderSlide;\n var previousOffset = ref$1.offset;\n swiper.updateActiveIndex();\n var activeIndex = swiper.activeIndex || 0;\n\n var offsetProp;\n if (swiper.rtlTranslate) { offsetProp = 'right'; }\n else { offsetProp = swiper.isHorizontal() ? 'left' : 'top'; }\n\n var slidesAfter;\n var slidesBefore;\n if (centeredSlides) {\n slidesAfter = Math.floor(slidesPerView / 2) + slidesPerGroup;\n slidesBefore = Math.floor(slidesPerView / 2) + slidesPerGroup;\n } else {\n slidesAfter = slidesPerView + (slidesPerGroup - 1);\n slidesBefore = slidesPerGroup;\n }\n var from = Math.max((activeIndex || 0) - slidesBefore, 0);\n var to = Math.min((activeIndex || 0) + slidesAfter, slides.length - 1);\n var offset = (swiper.slidesGrid[from] || 0) - (swiper.slidesGrid[0] || 0);\n\n Utils.extend(swiper.virtual, {\n from: from,\n to: to,\n offset: offset,\n slidesGrid: swiper.slidesGrid,\n });\n\n function onRendered() {\n swiper.updateSlides();\n swiper.updateProgress();\n swiper.updateSlidesClasses();\n if (swiper.lazy && swiper.params.lazy.enabled) {\n swiper.lazy.load();\n }\n }\n\n if (previousFrom === from && previousTo === to && !force) {\n if (swiper.slidesGrid !== previousSlidesGrid && offset !== previousOffset) {\n swiper.slides.css(offsetProp, (offset + \"px\"));\n }\n swiper.updateProgress();\n return;\n }\n if (swiper.params.virtual.renderExternal) {\n swiper.params.virtual.renderExternal.call(swiper, {\n offset: offset,\n from: from,\n to: to,\n slides: (function getSlides() {\n var slidesToRender = [];\n for (var i = from; i <= to; i += 1) {\n slidesToRender.push(slides[i]);\n }\n return slidesToRender;\n }()),\n });\n onRendered();\n return;\n }\n var prependIndexes = [];\n var appendIndexes = [];\n if (force) {\n swiper.$wrapperEl.find((\".\" + (swiper.params.slideClass))).remove();\n } else {\n for (var i = previousFrom; i <= previousTo; i += 1) {\n if (i < from || i > to) {\n swiper.$wrapperEl.find((\".\" + (swiper.params.slideClass) + \"[data-swiper-slide-index=\\\"\" + i + \"\\\"]\")).remove();\n }\n }\n }\n for (var i$1 = 0; i$1 < slides.length; i$1 += 1) {\n if (i$1 >= from && i$1 <= to) {\n if (typeof previousTo === 'undefined' || force) {\n appendIndexes.push(i$1);\n } else {\n if (i$1 > previousTo) { appendIndexes.push(i$1); }\n if (i$1 < previousFrom) { prependIndexes.push(i$1); }\n }\n }\n }\n appendIndexes.forEach(function (index) {\n swiper.$wrapperEl.append(renderSlide(slides[index], index));\n });\n prependIndexes.sort(function (a, b) { return a < b; }).forEach(function (index) {\n swiper.$wrapperEl.prepend(renderSlide(slides[index], index));\n });\n swiper.$wrapperEl.children('.swiper-slide').css(offsetProp, (offset + \"px\"));\n onRendered();\n },\n renderSlide: function renderSlide(slide, index) {\n var swiper = this;\n var params = swiper.params.virtual;\n if (params.cache && swiper.virtual.cache[index]) {\n return swiper.virtual.cache[index];\n }\n var $slideEl = params.renderSlide\n ? $(params.renderSlide.call(swiper, slide, index))\n : $((\"
    \" + slide + \"
    \"));\n if (!$slideEl.attr('data-swiper-slide-index')) { $slideEl.attr('data-swiper-slide-index', index); }\n if (params.cache) { swiper.virtual.cache[index] = $slideEl; }\n return $slideEl;\n },\n appendSlide: function appendSlide(slide) {\n var swiper = this;\n swiper.virtual.slides.push(slide);\n swiper.virtual.update(true);\n },\n prependSlide: function prependSlide(slide) {\n var swiper = this;\n swiper.virtual.slides.unshift(slide);\n if (swiper.params.virtual.cache) {\n var cache = swiper.virtual.cache;\n var newCache = {};\n Object.keys(cache).forEach(function (cachedIndex) {\n newCache[cachedIndex + 1] = cache[cachedIndex];\n });\n swiper.virtual.cache = newCache;\n }\n swiper.virtual.update(true);\n swiper.slideNext(0);\n },\n };\n\n var Virtual$1 = {\n name: 'virtual',\n params: {\n virtual: {\n enabled: false,\n slides: [],\n cache: true,\n renderSlide: null,\n renderExternal: null,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n virtual: {\n update: Virtual.update.bind(swiper),\n appendSlide: Virtual.appendSlide.bind(swiper),\n prependSlide: Virtual.prependSlide.bind(swiper),\n renderSlide: Virtual.renderSlide.bind(swiper),\n slides: swiper.params.virtual.slides,\n cache: {},\n },\n });\n },\n on: {\n beforeInit: function beforeInit() {\n var swiper = this;\n if (!swiper.params.virtual.enabled) { return; }\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"virtual\"));\n var overwriteParams = {\n watchSlidesProgress: true,\n };\n Utils.extend(swiper.params, overwriteParams);\n Utils.extend(swiper.originalParams, overwriteParams);\n\n swiper.virtual.update();\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n if (!swiper.params.virtual.enabled) { return; }\n swiper.virtual.update();\n },\n },\n };\n\n var Keyboard = {\n handle: function handle(event) {\n var swiper = this;\n var rtl = swiper.rtlTranslate;\n var e = event;\n if (e.originalEvent) { e = e.originalEvent; } // jquery fix\n var kc = e.keyCode || e.charCode;\n // Directions locks\n if (!swiper.allowSlideNext && ((swiper.isHorizontal() && kc === 39) || (swiper.isVertical() && kc === 40))) {\n return false;\n }\n if (!swiper.allowSlidePrev && ((swiper.isHorizontal() && kc === 37) || (swiper.isVertical() && kc === 38))) {\n return false;\n }\n if (e.shiftKey || e.altKey || e.ctrlKey || e.metaKey) {\n return undefined;\n }\n if (doc.activeElement && doc.activeElement.nodeName && (doc.activeElement.nodeName.toLowerCase() === 'input' || doc.activeElement.nodeName.toLowerCase() === 'textarea')) {\n return undefined;\n }\n if (swiper.params.keyboard.onlyInViewport && (kc === 37 || kc === 39 || kc === 38 || kc === 40)) {\n var inView = false;\n // Check that swiper should be inside of visible area of window\n if (swiper.$el.parents((\".\" + (swiper.params.slideClass))).length > 0 && swiper.$el.parents((\".\" + (swiper.params.slideActiveClass))).length === 0) {\n return undefined;\n }\n var windowWidth = win.innerWidth;\n var windowHeight = win.innerHeight;\n var swiperOffset = swiper.$el.offset();\n if (rtl) { swiperOffset.left -= swiper.$el[0].scrollLeft; }\n var swiperCoord = [\n [swiperOffset.left, swiperOffset.top],\n [swiperOffset.left + swiper.width, swiperOffset.top],\n [swiperOffset.left, swiperOffset.top + swiper.height],\n [swiperOffset.left + swiper.width, swiperOffset.top + swiper.height] ];\n for (var i = 0; i < swiperCoord.length; i += 1) {\n var point = swiperCoord[i];\n if (\n point[0] >= 0 && point[0] <= windowWidth &&\n point[1] >= 0 && point[1] <= windowHeight\n ) {\n inView = true;\n }\n }\n if (!inView) { return undefined; }\n }\n if (swiper.isHorizontal()) {\n if (kc === 37 || kc === 39) {\n if (e.preventDefault) { e.preventDefault(); }\n else { e.returnValue = false; }\n }\n if ((kc === 39 && !rtl) || (kc === 37 && rtl)) { swiper.slideNext(); }\n if ((kc === 37 && !rtl) || (kc === 39 && rtl)) { swiper.slidePrev(); }\n } else {\n if (kc === 38 || kc === 40) {\n if (e.preventDefault) { e.preventDefault(); }\n else { e.returnValue = false; }\n }\n if (kc === 40) { swiper.slideNext(); }\n if (kc === 38) { swiper.slidePrev(); }\n }\n swiper.emit('keyPress', kc);\n return undefined;\n },\n enable: function enable() {\n var swiper = this;\n if (swiper.keyboard.enabled) { return; }\n $(doc).on('keydown', swiper.keyboard.handle);\n swiper.keyboard.enabled = true;\n },\n disable: function disable() {\n var swiper = this;\n if (!swiper.keyboard.enabled) { return; }\n $(doc).off('keydown', swiper.keyboard.handle);\n swiper.keyboard.enabled = false;\n },\n };\n\n var Keyboard$1 = {\n name: 'keyboard',\n params: {\n keyboard: {\n enabled: false,\n onlyInViewport: true,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n keyboard: {\n enabled: false,\n enable: Keyboard.enable.bind(swiper),\n disable: Keyboard.disable.bind(swiper),\n handle: Keyboard.handle.bind(swiper),\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n if (swiper.params.keyboard.enabled) {\n swiper.keyboard.enable();\n }\n },\n destroy: function destroy() {\n var swiper = this;\n if (swiper.keyboard.enabled) {\n swiper.keyboard.disable();\n }\n },\n },\n };\n\n function isEventSupported() {\n var eventName = 'onwheel';\n var isSupported = eventName in doc;\n\n if (!isSupported) {\n var element = doc.createElement('div');\n element.setAttribute(eventName, 'return;');\n isSupported = typeof element[eventName] === 'function';\n }\n\n if (!isSupported &&\n doc.implementation &&\n doc.implementation.hasFeature &&\n // always returns true in newer browsers as per the standard.\n // @see http://dom.spec.whatwg.org/#dom-domimplementation-hasfeature\n doc.implementation.hasFeature('', '') !== true\n ) {\n // This is the only way to test support for the `wheel` event in IE9+.\n isSupported = doc.implementation.hasFeature('Events.wheel', '3.0');\n }\n\n return isSupported;\n }\n var Mousewheel = {\n lastScrollTime: Utils.now(),\n event: (function getEvent() {\n if (win.navigator.userAgent.indexOf('firefox') > -1) { return 'DOMMouseScroll'; }\n return isEventSupported() ? 'wheel' : 'mousewheel';\n }()),\n normalize: function normalize(e) {\n // Reasonable defaults\n var PIXEL_STEP = 10;\n var LINE_HEIGHT = 40;\n var PAGE_HEIGHT = 800;\n\n var sX = 0;\n var sY = 0; // spinX, spinY\n var pX = 0;\n var pY = 0; // pixelX, pixelY\n\n // Legacy\n if ('detail' in e) {\n sY = e.detail;\n }\n if ('wheelDelta' in e) {\n sY = -e.wheelDelta / 120;\n }\n if ('wheelDeltaY' in e) {\n sY = -e.wheelDeltaY / 120;\n }\n if ('wheelDeltaX' in e) {\n sX = -e.wheelDeltaX / 120;\n }\n\n // side scrolling on FF with DOMMouseScroll\n if ('axis' in e && e.axis === e.HORIZONTAL_AXIS) {\n sX = sY;\n sY = 0;\n }\n\n pX = sX * PIXEL_STEP;\n pY = sY * PIXEL_STEP;\n\n if ('deltaY' in e) {\n pY = e.deltaY;\n }\n if ('deltaX' in e) {\n pX = e.deltaX;\n }\n\n if ((pX || pY) && e.deltaMode) {\n if (e.deltaMode === 1) { // delta in LINE units\n pX *= LINE_HEIGHT;\n pY *= LINE_HEIGHT;\n } else { // delta in PAGE units\n pX *= PAGE_HEIGHT;\n pY *= PAGE_HEIGHT;\n }\n }\n\n // Fall-back if spin cannot be determined\n if (pX && !sX) {\n sX = (pX < 1) ? -1 : 1;\n }\n if (pY && !sY) {\n sY = (pY < 1) ? -1 : 1;\n }\n\n return {\n spinX: sX,\n spinY: sY,\n pixelX: pX,\n pixelY: pY,\n };\n },\n handleMouseEnter: function handleMouseEnter() {\n var swiper = this;\n swiper.mouseEntered = true;\n },\n handleMouseLeave: function handleMouseLeave() {\n var swiper = this;\n swiper.mouseEntered = false;\n },\n handle: function handle(event) {\n var e = event;\n var swiper = this;\n var params = swiper.params.mousewheel;\n\n if (!swiper.mouseEntered && !params.releaseOnEdges) { return true; }\n\n if (e.originalEvent) { e = e.originalEvent; } // jquery fix\n var delta = 0;\n var rtlFactor = swiper.rtlTranslate ? -1 : 1;\n\n var data = Mousewheel.normalize(e);\n\n if (params.forceToAxis) {\n if (swiper.isHorizontal()) {\n if (Math.abs(data.pixelX) > Math.abs(data.pixelY)) { delta = data.pixelX * rtlFactor; }\n else { return true; }\n } else if (Math.abs(data.pixelY) > Math.abs(data.pixelX)) { delta = data.pixelY; }\n else { return true; }\n } else {\n delta = Math.abs(data.pixelX) > Math.abs(data.pixelY) ? -data.pixelX * rtlFactor : -data.pixelY;\n }\n\n if (delta === 0) { return true; }\n\n if (params.invert) { delta = -delta; }\n\n if (!swiper.params.freeMode) {\n if (Utils.now() - swiper.mousewheel.lastScrollTime > 60) {\n if (delta < 0) {\n if ((!swiper.isEnd || swiper.params.loop) && !swiper.animating) {\n swiper.slideNext();\n swiper.emit('scroll', e);\n } else if (params.releaseOnEdges) { return true; }\n } else if ((!swiper.isBeginning || swiper.params.loop) && !swiper.animating) {\n swiper.slidePrev();\n swiper.emit('scroll', e);\n } else if (params.releaseOnEdges) { return true; }\n }\n swiper.mousewheel.lastScrollTime = (new win.Date()).getTime();\n } else {\n // Freemode or scrollContainer:\n if (swiper.params.loop) {\n swiper.loopFix();\n }\n var position = swiper.getTranslate() + (delta * params.sensitivity);\n var wasBeginning = swiper.isBeginning;\n var wasEnd = swiper.isEnd;\n\n if (position >= swiper.minTranslate()) { position = swiper.minTranslate(); }\n if (position <= swiper.maxTranslate()) { position = swiper.maxTranslate(); }\n\n swiper.setTransition(0);\n swiper.setTranslate(position);\n swiper.updateProgress();\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n\n if ((!wasBeginning && swiper.isBeginning) || (!wasEnd && swiper.isEnd)) {\n swiper.updateSlidesClasses();\n }\n\n if (swiper.params.freeModeSticky) {\n clearTimeout(swiper.mousewheel.timeout);\n swiper.mousewheel.timeout = Utils.nextTick(function () {\n swiper.slideToClosest();\n }, 300);\n }\n // Emit event\n swiper.emit('scroll', e);\n\n // Stop autoplay\n if (swiper.params.autoplay && swiper.params.autoplayDisableOnInteraction) { swiper.stopAutoplay(); }\n // Return page scroll on edge positions\n if (position === swiper.minTranslate() || position === swiper.maxTranslate()) { return true; }\n }\n\n if (e.preventDefault) { e.preventDefault(); }\n else { e.returnValue = false; }\n return false;\n },\n enable: function enable() {\n var swiper = this;\n if (!Mousewheel.event) { return false; }\n if (swiper.mousewheel.enabled) { return false; }\n var target = swiper.$el;\n if (swiper.params.mousewheel.eventsTarged !== 'container') {\n target = $(swiper.params.mousewheel.eventsTarged);\n }\n target.on('mouseenter', swiper.mousewheel.handleMouseEnter);\n target.on('mouseleave', swiper.mousewheel.handleMouseLeave);\n target.on(Mousewheel.event, swiper.mousewheel.handle);\n swiper.mousewheel.enabled = true;\n return true;\n },\n disable: function disable() {\n var swiper = this;\n if (!Mousewheel.event) { return false; }\n if (!swiper.mousewheel.enabled) { return false; }\n var target = swiper.$el;\n if (swiper.params.mousewheel.eventsTarged !== 'container') {\n target = $(swiper.params.mousewheel.eventsTarged);\n }\n target.off(Mousewheel.event, swiper.mousewheel.handle);\n swiper.mousewheel.enabled = false;\n return true;\n },\n };\n\n var Mousewheel$1 = {\n name: 'mousewheel',\n params: {\n mousewheel: {\n enabled: false,\n releaseOnEdges: false,\n invert: false,\n forceToAxis: false,\n sensitivity: 1,\n eventsTarged: 'container',\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n mousewheel: {\n enabled: false,\n enable: Mousewheel.enable.bind(swiper),\n disable: Mousewheel.disable.bind(swiper),\n handle: Mousewheel.handle.bind(swiper),\n handleMouseEnter: Mousewheel.handleMouseEnter.bind(swiper),\n handleMouseLeave: Mousewheel.handleMouseLeave.bind(swiper),\n lastScrollTime: Utils.now(),\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n if (swiper.params.mousewheel.enabled) { swiper.mousewheel.enable(); }\n },\n destroy: function destroy() {\n var swiper = this;\n if (swiper.mousewheel.enabled) { swiper.mousewheel.disable(); }\n },\n },\n };\n\n var Navigation = {\n update: function update() {\n // Update Navigation Buttons\n var swiper = this;\n var params = swiper.params.navigation;\n\n if (swiper.params.loop) { return; }\n var ref = swiper.navigation;\n var $nextEl = ref.$nextEl;\n var $prevEl = ref.$prevEl;\n\n if ($prevEl && $prevEl.length > 0) {\n if (swiper.isBeginning) {\n $prevEl.addClass(params.disabledClass);\n } else {\n $prevEl.removeClass(params.disabledClass);\n }\n $prevEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass);\n }\n if ($nextEl && $nextEl.length > 0) {\n if (swiper.isEnd) {\n $nextEl.addClass(params.disabledClass);\n } else {\n $nextEl.removeClass(params.disabledClass);\n }\n $nextEl[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass);\n }\n },\n init: function init() {\n var swiper = this;\n var params = swiper.params.navigation;\n if (!(params.nextEl || params.prevEl)) { return; }\n\n var $nextEl;\n var $prevEl;\n if (params.nextEl) {\n $nextEl = $(params.nextEl);\n if (\n swiper.params.uniqueNavElements &&\n typeof params.nextEl === 'string' &&\n $nextEl.length > 1 &&\n swiper.$el.find(params.nextEl).length === 1\n ) {\n $nextEl = swiper.$el.find(params.nextEl);\n }\n }\n if (params.prevEl) {\n $prevEl = $(params.prevEl);\n if (\n swiper.params.uniqueNavElements &&\n typeof params.prevEl === 'string' &&\n $prevEl.length > 1 &&\n swiper.$el.find(params.prevEl).length === 1\n ) {\n $prevEl = swiper.$el.find(params.prevEl);\n }\n }\n\n if ($nextEl && $nextEl.length > 0) {\n $nextEl.on('click', function (e) {\n e.preventDefault();\n if (swiper.isEnd && !swiper.params.loop) { return; }\n swiper.slideNext();\n });\n }\n if ($prevEl && $prevEl.length > 0) {\n $prevEl.on('click', function (e) {\n e.preventDefault();\n if (swiper.isBeginning && !swiper.params.loop) { return; }\n swiper.slidePrev();\n });\n }\n\n Utils.extend(swiper.navigation, {\n $nextEl: $nextEl,\n nextEl: $nextEl && $nextEl[0],\n $prevEl: $prevEl,\n prevEl: $prevEl && $prevEl[0],\n });\n },\n destroy: function destroy() {\n var swiper = this;\n var ref = swiper.navigation;\n var $nextEl = ref.$nextEl;\n var $prevEl = ref.$prevEl;\n if ($nextEl && $nextEl.length) {\n $nextEl.off('click');\n $nextEl.removeClass(swiper.params.navigation.disabledClass);\n }\n if ($prevEl && $prevEl.length) {\n $prevEl.off('click');\n $prevEl.removeClass(swiper.params.navigation.disabledClass);\n }\n },\n };\n\n var Navigation$1 = {\n name: 'navigation',\n params: {\n navigation: {\n nextEl: null,\n prevEl: null,\n\n hideOnClick: false,\n disabledClass: 'swiper-button-disabled',\n hiddenClass: 'swiper-button-hidden',\n lockClass: 'swiper-button-lock',\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n navigation: {\n init: Navigation.init.bind(swiper),\n update: Navigation.update.bind(swiper),\n destroy: Navigation.destroy.bind(swiper),\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n swiper.navigation.init();\n swiper.navigation.update();\n },\n toEdge: function toEdge() {\n var swiper = this;\n swiper.navigation.update();\n },\n fromEdge: function fromEdge() {\n var swiper = this;\n swiper.navigation.update();\n },\n destroy: function destroy() {\n var swiper = this;\n swiper.navigation.destroy();\n },\n click: function click(e) {\n var swiper = this;\n var ref = swiper.navigation;\n var $nextEl = ref.$nextEl;\n var $prevEl = ref.$prevEl;\n if (\n swiper.params.navigation.hideOnClick &&\n !$(e.target).is($prevEl) &&\n !$(e.target).is($nextEl)\n ) {\n if ($nextEl) { $nextEl.toggleClass(swiper.params.navigation.hiddenClass); }\n if ($prevEl) { $prevEl.toggleClass(swiper.params.navigation.hiddenClass); }\n }\n },\n },\n };\n\n var Pagination = {\n update: function update() {\n // Render || Update Pagination bullets/items\n var swiper = this;\n var rtl = swiper.rtl;\n var params = swiper.params.pagination;\n if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) { return; }\n var slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length;\n var $el = swiper.pagination.$el;\n // Current/Total\n var current;\n var total = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length;\n if (swiper.params.loop) {\n current = Math.ceil((swiper.activeIndex - swiper.loopedSlides) / swiper.params.slidesPerGroup);\n if (current > slidesLength - 1 - (swiper.loopedSlides * 2)) {\n current -= (slidesLength - (swiper.loopedSlides * 2));\n }\n if (current > total - 1) { current -= total; }\n if (current < 0 && swiper.params.paginationType !== 'bullets') { current = total + current; }\n } else if (typeof swiper.snapIndex !== 'undefined') {\n current = swiper.snapIndex;\n } else {\n current = swiper.activeIndex || 0;\n }\n // Types\n if (params.type === 'bullets' && swiper.pagination.bullets && swiper.pagination.bullets.length > 0) {\n var bullets = swiper.pagination.bullets;\n var firstIndex;\n var lastIndex;\n var midIndex;\n if (params.dynamicBullets) {\n swiper.pagination.bulletSize = bullets.eq(0)[swiper.isHorizontal() ? 'outerWidth' : 'outerHeight'](true);\n $el.css(swiper.isHorizontal() ? 'width' : 'height', ((swiper.pagination.bulletSize * (params.dynamicMainBullets + 4)) + \"px\"));\n if (params.dynamicMainBullets > 1 && swiper.previousIndex !== undefined) {\n swiper.pagination.dynamicBulletIndex += (current - swiper.previousIndex);\n if (swiper.pagination.dynamicBulletIndex > (params.dynamicMainBullets - 1)) {\n swiper.pagination.dynamicBulletIndex = params.dynamicMainBullets - 1;\n } else if (swiper.pagination.dynamicBulletIndex < 0) {\n swiper.pagination.dynamicBulletIndex = 0;\n }\n }\n firstIndex = current - swiper.pagination.dynamicBulletIndex;\n lastIndex = firstIndex + (Math.min(bullets.length, params.dynamicMainBullets) - 1);\n midIndex = (lastIndex + firstIndex) / 2;\n }\n bullets.removeClass(((params.bulletActiveClass) + \" \" + (params.bulletActiveClass) + \"-next \" + (params.bulletActiveClass) + \"-next-next \" + (params.bulletActiveClass) + \"-prev \" + (params.bulletActiveClass) + \"-prev-prev \" + (params.bulletActiveClass) + \"-main\"));\n if ($el.length > 1) {\n bullets.each(function (index, bullet) {\n var $bullet = $(bullet);\n var bulletIndex = $bullet.index();\n if (bulletIndex === current) {\n $bullet.addClass(params.bulletActiveClass);\n }\n if (params.dynamicBullets) {\n if (bulletIndex >= firstIndex && bulletIndex <= lastIndex) {\n $bullet.addClass(((params.bulletActiveClass) + \"-main\"));\n }\n if (bulletIndex === firstIndex) {\n $bullet\n .prev()\n .addClass(((params.bulletActiveClass) + \"-prev\"))\n .prev()\n .addClass(((params.bulletActiveClass) + \"-prev-prev\"));\n }\n if (bulletIndex === lastIndex) {\n $bullet\n .next()\n .addClass(((params.bulletActiveClass) + \"-next\"))\n .next()\n .addClass(((params.bulletActiveClass) + \"-next-next\"));\n }\n }\n });\n } else {\n var $bullet = bullets.eq(current);\n $bullet.addClass(params.bulletActiveClass);\n if (params.dynamicBullets) {\n var $firstDisplayedBullet = bullets.eq(firstIndex);\n var $lastDisplayedBullet = bullets.eq(lastIndex);\n for (var i = firstIndex; i <= lastIndex; i += 1) {\n bullets.eq(i).addClass(((params.bulletActiveClass) + \"-main\"));\n }\n $firstDisplayedBullet\n .prev()\n .addClass(((params.bulletActiveClass) + \"-prev\"))\n .prev()\n .addClass(((params.bulletActiveClass) + \"-prev-prev\"));\n $lastDisplayedBullet\n .next()\n .addClass(((params.bulletActiveClass) + \"-next\"))\n .next()\n .addClass(((params.bulletActiveClass) + \"-next-next\"));\n }\n }\n if (params.dynamicBullets) {\n var dynamicBulletsLength = Math.min(bullets.length, params.dynamicMainBullets + 4);\n var bulletsOffset = (((swiper.pagination.bulletSize * dynamicBulletsLength) - (swiper.pagination.bulletSize)) / 2) - (midIndex * swiper.pagination.bulletSize);\n var offsetProp = rtl ? 'right' : 'left';\n bullets.css(swiper.isHorizontal() ? offsetProp : 'top', (bulletsOffset + \"px\"));\n }\n }\n if (params.type === 'fraction') {\n $el.find((\".\" + (params.currentClass))).text(current + 1);\n $el.find((\".\" + (params.totalClass))).text(total);\n }\n if (params.type === 'progressbar') {\n var progressbarDirection;\n if (params.progressbarOpposite) {\n progressbarDirection = swiper.isHorizontal() ? 'vertical' : 'horizontal';\n } else {\n progressbarDirection = swiper.isHorizontal() ? 'horizontal' : 'vertical';\n }\n var scale = (current + 1) / total;\n var scaleX = 1;\n var scaleY = 1;\n if (progressbarDirection === 'horizontal') {\n scaleX = scale;\n } else {\n scaleY = scale;\n }\n $el.find((\".\" + (params.progressbarFillClass))).transform((\"translate3d(0,0,0) scaleX(\" + scaleX + \") scaleY(\" + scaleY + \")\")).transition(swiper.params.speed);\n }\n if (params.type === 'custom' && params.renderCustom) {\n $el.html(params.renderCustom(swiper, current + 1, total));\n swiper.emit('paginationRender', swiper, $el[0]);\n } else {\n swiper.emit('paginationUpdate', swiper, $el[0]);\n }\n $el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](params.lockClass);\n },\n render: function render() {\n // Render Container\n var swiper = this;\n var params = swiper.params.pagination;\n if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) { return; }\n var slidesLength = swiper.virtual && swiper.params.virtual.enabled ? swiper.virtual.slides.length : swiper.slides.length;\n\n var $el = swiper.pagination.$el;\n var paginationHTML = '';\n if (params.type === 'bullets') {\n var numberOfBullets = swiper.params.loop ? Math.ceil((slidesLength - (swiper.loopedSlides * 2)) / swiper.params.slidesPerGroup) : swiper.snapGrid.length;\n for (var i = 0; i < numberOfBullets; i += 1) {\n if (params.renderBullet) {\n paginationHTML += params.renderBullet.call(swiper, i, params.bulletClass);\n } else {\n paginationHTML += \"<\" + (params.bulletElement) + \" class=\\\"\" + (params.bulletClass) + \"\\\">\";\n }\n }\n $el.html(paginationHTML);\n swiper.pagination.bullets = $el.find((\".\" + (params.bulletClass)));\n }\n if (params.type === 'fraction') {\n if (params.renderFraction) {\n paginationHTML = params.renderFraction.call(swiper, params.currentClass, params.totalClass);\n } else {\n paginationHTML =\n \"\" +\n ' / ' +\n \"\";\n }\n $el.html(paginationHTML);\n }\n if (params.type === 'progressbar') {\n if (params.renderProgressbar) {\n paginationHTML = params.renderProgressbar.call(swiper, params.progressbarFillClass);\n } else {\n paginationHTML = \"\";\n }\n $el.html(paginationHTML);\n }\n if (params.type !== 'custom') {\n swiper.emit('paginationRender', swiper.pagination.$el[0]);\n }\n },\n init: function init() {\n var swiper = this;\n var params = swiper.params.pagination;\n if (!params.el) { return; }\n\n var $el = $(params.el);\n if ($el.length === 0) { return; }\n\n if (\n swiper.params.uniqueNavElements &&\n typeof params.el === 'string' &&\n $el.length > 1 &&\n swiper.$el.find(params.el).length === 1\n ) {\n $el = swiper.$el.find(params.el);\n }\n\n if (params.type === 'bullets' && params.clickable) {\n $el.addClass(params.clickableClass);\n }\n\n $el.addClass(params.modifierClass + params.type);\n\n if (params.type === 'bullets' && params.dynamicBullets) {\n $el.addClass((\"\" + (params.modifierClass) + (params.type) + \"-dynamic\"));\n swiper.pagination.dynamicBulletIndex = 0;\n if (params.dynamicMainBullets < 1) {\n params.dynamicMainBullets = 1;\n }\n }\n if (params.type === 'progressbar' && params.progressbarOpposite) {\n $el.addClass(params.progressbarOppositeClass);\n }\n\n if (params.clickable) {\n $el.on('click', (\".\" + (params.bulletClass)), function onClick(e) {\n e.preventDefault();\n var index = $(this).index() * swiper.params.slidesPerGroup;\n if (swiper.params.loop) { index += swiper.loopedSlides; }\n swiper.slideTo(index);\n });\n }\n\n Utils.extend(swiper.pagination, {\n $el: $el,\n el: $el[0],\n });\n },\n destroy: function destroy() {\n var swiper = this;\n var params = swiper.params.pagination;\n if (!params.el || !swiper.pagination.el || !swiper.pagination.$el || swiper.pagination.$el.length === 0) { return; }\n var $el = swiper.pagination.$el;\n\n $el.removeClass(params.hiddenClass);\n $el.removeClass(params.modifierClass + params.type);\n if (swiper.pagination.bullets) { swiper.pagination.bullets.removeClass(params.bulletActiveClass); }\n if (params.clickable) {\n $el.off('click', (\".\" + (params.bulletClass)));\n }\n },\n };\n\n var Pagination$1 = {\n name: 'pagination',\n params: {\n pagination: {\n el: null,\n bulletElement: 'span',\n clickable: false,\n hideOnClick: false,\n renderBullet: null,\n renderProgressbar: null,\n renderFraction: null,\n renderCustom: null,\n progressbarOpposite: false,\n type: 'bullets', // 'bullets' or 'progressbar' or 'fraction' or 'custom'\n dynamicBullets: false,\n dynamicMainBullets: 1,\n bulletClass: 'swiper-pagination-bullet',\n bulletActiveClass: 'swiper-pagination-bullet-active',\n modifierClass: 'swiper-pagination-', // NEW\n currentClass: 'swiper-pagination-current',\n totalClass: 'swiper-pagination-total',\n hiddenClass: 'swiper-pagination-hidden',\n progressbarFillClass: 'swiper-pagination-progressbar-fill',\n progressbarOppositeClass: 'swiper-pagination-progressbar-opposite',\n clickableClass: 'swiper-pagination-clickable', // NEW\n lockClass: 'swiper-pagination-lock',\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n pagination: {\n init: Pagination.init.bind(swiper),\n render: Pagination.render.bind(swiper),\n update: Pagination.update.bind(swiper),\n destroy: Pagination.destroy.bind(swiper),\n dynamicBulletIndex: 0,\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n swiper.pagination.init();\n swiper.pagination.render();\n swiper.pagination.update();\n },\n activeIndexChange: function activeIndexChange() {\n var swiper = this;\n if (swiper.params.loop) {\n swiper.pagination.update();\n } else if (typeof swiper.snapIndex === 'undefined') {\n swiper.pagination.update();\n }\n },\n snapIndexChange: function snapIndexChange() {\n var swiper = this;\n if (!swiper.params.loop) {\n swiper.pagination.update();\n }\n },\n slidesLengthChange: function slidesLengthChange() {\n var swiper = this;\n if (swiper.params.loop) {\n swiper.pagination.render();\n swiper.pagination.update();\n }\n },\n snapGridLengthChange: function snapGridLengthChange() {\n var swiper = this;\n if (!swiper.params.loop) {\n swiper.pagination.render();\n swiper.pagination.update();\n }\n },\n destroy: function destroy() {\n var swiper = this;\n swiper.pagination.destroy();\n },\n click: function click(e) {\n var swiper = this;\n if (\n swiper.params.pagination.el &&\n swiper.params.pagination.hideOnClick &&\n swiper.pagination.$el.length > 0 &&\n !$(e.target).hasClass(swiper.params.pagination.bulletClass)\n ) {\n swiper.pagination.$el.toggleClass(swiper.params.pagination.hiddenClass);\n }\n },\n },\n };\n\n var Scrollbar = {\n setTranslate: function setTranslate() {\n var swiper = this;\n if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) { return; }\n var scrollbar = swiper.scrollbar;\n var rtl = swiper.rtlTranslate;\n var progress = swiper.progress;\n var dragSize = scrollbar.dragSize;\n var trackSize = scrollbar.trackSize;\n var $dragEl = scrollbar.$dragEl;\n var $el = scrollbar.$el;\n var params = swiper.params.scrollbar;\n\n var newSize = dragSize;\n var newPos = (trackSize - dragSize) * progress;\n if (rtl) {\n newPos = -newPos;\n if (newPos > 0) {\n newSize = dragSize - newPos;\n newPos = 0;\n } else if (-newPos + dragSize > trackSize) {\n newSize = trackSize + newPos;\n }\n } else if (newPos < 0) {\n newSize = dragSize + newPos;\n newPos = 0;\n } else if (newPos + dragSize > trackSize) {\n newSize = trackSize - newPos;\n }\n if (swiper.isHorizontal()) {\n if (Support.transforms3d) {\n $dragEl.transform((\"translate3d(\" + newPos + \"px, 0, 0)\"));\n } else {\n $dragEl.transform((\"translateX(\" + newPos + \"px)\"));\n }\n $dragEl[0].style.width = newSize + \"px\";\n } else {\n if (Support.transforms3d) {\n $dragEl.transform((\"translate3d(0px, \" + newPos + \"px, 0)\"));\n } else {\n $dragEl.transform((\"translateY(\" + newPos + \"px)\"));\n }\n $dragEl[0].style.height = newSize + \"px\";\n }\n if (params.hide) {\n clearTimeout(swiper.scrollbar.timeout);\n $el[0].style.opacity = 1;\n swiper.scrollbar.timeout = setTimeout(function () {\n $el[0].style.opacity = 0;\n $el.transition(400);\n }, 1000);\n }\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) { return; }\n swiper.scrollbar.$dragEl.transition(duration);\n },\n updateSize: function updateSize() {\n var swiper = this;\n if (!swiper.params.scrollbar.el || !swiper.scrollbar.el) { return; }\n\n var scrollbar = swiper.scrollbar;\n var $dragEl = scrollbar.$dragEl;\n var $el = scrollbar.$el;\n\n $dragEl[0].style.width = '';\n $dragEl[0].style.height = '';\n var trackSize = swiper.isHorizontal() ? $el[0].offsetWidth : $el[0].offsetHeight;\n\n var divider = swiper.size / swiper.virtualSize;\n var moveDivider = divider * (trackSize / swiper.size);\n var dragSize;\n if (swiper.params.scrollbar.dragSize === 'auto') {\n dragSize = trackSize * divider;\n } else {\n dragSize = parseInt(swiper.params.scrollbar.dragSize, 10);\n }\n\n if (swiper.isHorizontal()) {\n $dragEl[0].style.width = dragSize + \"px\";\n } else {\n $dragEl[0].style.height = dragSize + \"px\";\n }\n\n if (divider >= 1) {\n $el[0].style.display = 'none';\n } else {\n $el[0].style.display = '';\n }\n if (swiper.params.scrollbarHide) {\n $el[0].style.opacity = 0;\n }\n Utils.extend(scrollbar, {\n trackSize: trackSize,\n divider: divider,\n moveDivider: moveDivider,\n dragSize: dragSize,\n });\n scrollbar.$el[swiper.params.watchOverflow && swiper.isLocked ? 'addClass' : 'removeClass'](swiper.params.scrollbar.lockClass);\n },\n setDragPosition: function setDragPosition(e) {\n var swiper = this;\n var scrollbar = swiper.scrollbar;\n var rtl = swiper.rtlTranslate;\n var $el = scrollbar.$el;\n var dragSize = scrollbar.dragSize;\n var trackSize = scrollbar.trackSize;\n\n var pointerPosition;\n if (swiper.isHorizontal()) {\n pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageX : e.pageX || e.clientX);\n } else {\n pointerPosition = ((e.type === 'touchstart' || e.type === 'touchmove') ? e.targetTouches[0].pageY : e.pageY || e.clientY);\n }\n var positionRatio;\n positionRatio = ((pointerPosition) - $el.offset()[swiper.isHorizontal() ? 'left' : 'top'] - (dragSize / 2)) / (trackSize - dragSize);\n positionRatio = Math.max(Math.min(positionRatio, 1), 0);\n if (rtl) {\n positionRatio = 1 - positionRatio;\n }\n\n var position = swiper.minTranslate() + ((swiper.maxTranslate() - swiper.minTranslate()) * positionRatio);\n\n swiper.updateProgress(position);\n swiper.setTranslate(position);\n swiper.updateActiveIndex();\n swiper.updateSlidesClasses();\n },\n onDragStart: function onDragStart(e) {\n var swiper = this;\n var params = swiper.params.scrollbar;\n var scrollbar = swiper.scrollbar;\n var $wrapperEl = swiper.$wrapperEl;\n var $el = scrollbar.$el;\n var $dragEl = scrollbar.$dragEl;\n swiper.scrollbar.isTouched = true;\n e.preventDefault();\n e.stopPropagation();\n\n $wrapperEl.transition(100);\n $dragEl.transition(100);\n scrollbar.setDragPosition(e);\n\n clearTimeout(swiper.scrollbar.dragTimeout);\n\n $el.transition(0);\n if (params.hide) {\n $el.css('opacity', 1);\n }\n swiper.emit('scrollbarDragStart', e);\n },\n onDragMove: function onDragMove(e) {\n var swiper = this;\n var scrollbar = swiper.scrollbar;\n var $wrapperEl = swiper.$wrapperEl;\n var $el = scrollbar.$el;\n var $dragEl = scrollbar.$dragEl;\n\n if (!swiper.scrollbar.isTouched) { return; }\n if (e.preventDefault) { e.preventDefault(); }\n else { e.returnValue = false; }\n scrollbar.setDragPosition(e);\n $wrapperEl.transition(0);\n $el.transition(0);\n $dragEl.transition(0);\n swiper.emit('scrollbarDragMove', e);\n },\n onDragEnd: function onDragEnd(e) {\n var swiper = this;\n\n var params = swiper.params.scrollbar;\n var scrollbar = swiper.scrollbar;\n var $el = scrollbar.$el;\n\n if (!swiper.scrollbar.isTouched) { return; }\n swiper.scrollbar.isTouched = false;\n if (params.hide) {\n clearTimeout(swiper.scrollbar.dragTimeout);\n swiper.scrollbar.dragTimeout = Utils.nextTick(function () {\n $el.css('opacity', 0);\n $el.transition(400);\n }, 1000);\n }\n swiper.emit('scrollbarDragEnd', e);\n if (params.snapOnRelease) {\n swiper.slideToClosest();\n }\n },\n enableDraggable: function enableDraggable() {\n var swiper = this;\n if (!swiper.params.scrollbar.el) { return; }\n var scrollbar = swiper.scrollbar;\n var touchEvents = swiper.touchEvents;\n var touchEventsDesktop = swiper.touchEventsDesktop;\n var params = swiper.params;\n var $el = scrollbar.$el;\n var target = $el[0];\n var activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false;\n var passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false;\n if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) {\n target.addEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener);\n doc.addEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener);\n doc.addEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener);\n } else {\n if (Support.touch) {\n target.addEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener);\n target.addEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener);\n target.addEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener);\n }\n if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) {\n target.addEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener);\n doc.addEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener);\n doc.addEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener);\n }\n }\n },\n disableDraggable: function disableDraggable() {\n var swiper = this;\n if (!swiper.params.scrollbar.el) { return; }\n var scrollbar = swiper.scrollbar;\n var touchEvents = swiper.touchEvents;\n var touchEventsDesktop = swiper.touchEventsDesktop;\n var params = swiper.params;\n var $el = scrollbar.$el;\n var target = $el[0];\n var activeListener = Support.passiveListener && params.passiveListener ? { passive: false, capture: false } : false;\n var passiveListener = Support.passiveListener && params.passiveListener ? { passive: true, capture: false } : false;\n if (!Support.touch && (Support.pointerEvents || Support.prefixedPointerEvents)) {\n target.removeEventListener(touchEventsDesktop.start, swiper.scrollbar.onDragStart, activeListener);\n doc.removeEventListener(touchEventsDesktop.move, swiper.scrollbar.onDragMove, activeListener);\n doc.removeEventListener(touchEventsDesktop.end, swiper.scrollbar.onDragEnd, passiveListener);\n } else {\n if (Support.touch) {\n target.removeEventListener(touchEvents.start, swiper.scrollbar.onDragStart, activeListener);\n target.removeEventListener(touchEvents.move, swiper.scrollbar.onDragMove, activeListener);\n target.removeEventListener(touchEvents.end, swiper.scrollbar.onDragEnd, passiveListener);\n }\n if ((params.simulateTouch && !Device.ios && !Device.android) || (params.simulateTouch && !Support.touch && Device.ios)) {\n target.removeEventListener('mousedown', swiper.scrollbar.onDragStart, activeListener);\n doc.removeEventListener('mousemove', swiper.scrollbar.onDragMove, activeListener);\n doc.removeEventListener('mouseup', swiper.scrollbar.onDragEnd, passiveListener);\n }\n }\n },\n init: function init() {\n var swiper = this;\n if (!swiper.params.scrollbar.el) { return; }\n var scrollbar = swiper.scrollbar;\n var $swiperEl = swiper.$el;\n var params = swiper.params.scrollbar;\n\n var $el = $(params.el);\n if (swiper.params.uniqueNavElements && typeof params.el === 'string' && $el.length > 1 && $swiperEl.find(params.el).length === 1) {\n $el = $swiperEl.find(params.el);\n }\n\n var $dragEl = $el.find((\".\" + (swiper.params.scrollbar.dragClass)));\n if ($dragEl.length === 0) {\n $dragEl = $((\"
    \"));\n $el.append($dragEl);\n }\n\n Utils.extend(scrollbar, {\n $el: $el,\n el: $el[0],\n $dragEl: $dragEl,\n dragEl: $dragEl[0],\n });\n\n if (params.draggable) {\n scrollbar.enableDraggable();\n }\n },\n destroy: function destroy() {\n var swiper = this;\n swiper.scrollbar.disableDraggable();\n },\n };\n\n var Scrollbar$1 = {\n name: 'scrollbar',\n params: {\n scrollbar: {\n el: null,\n dragSize: 'auto',\n hide: false,\n draggable: false,\n snapOnRelease: true,\n lockClass: 'swiper-scrollbar-lock',\n dragClass: 'swiper-scrollbar-drag',\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n scrollbar: {\n init: Scrollbar.init.bind(swiper),\n destroy: Scrollbar.destroy.bind(swiper),\n updateSize: Scrollbar.updateSize.bind(swiper),\n setTranslate: Scrollbar.setTranslate.bind(swiper),\n setTransition: Scrollbar.setTransition.bind(swiper),\n enableDraggable: Scrollbar.enableDraggable.bind(swiper),\n disableDraggable: Scrollbar.disableDraggable.bind(swiper),\n setDragPosition: Scrollbar.setDragPosition.bind(swiper),\n onDragStart: Scrollbar.onDragStart.bind(swiper),\n onDragMove: Scrollbar.onDragMove.bind(swiper),\n onDragEnd: Scrollbar.onDragEnd.bind(swiper),\n isTouched: false,\n timeout: null,\n dragTimeout: null,\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n swiper.scrollbar.init();\n swiper.scrollbar.updateSize();\n swiper.scrollbar.setTranslate();\n },\n update: function update() {\n var swiper = this;\n swiper.scrollbar.updateSize();\n },\n resize: function resize() {\n var swiper = this;\n swiper.scrollbar.updateSize();\n },\n observerUpdate: function observerUpdate() {\n var swiper = this;\n swiper.scrollbar.updateSize();\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n swiper.scrollbar.setTranslate();\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n swiper.scrollbar.setTransition(duration);\n },\n destroy: function destroy() {\n var swiper = this;\n swiper.scrollbar.destroy();\n },\n },\n };\n\n var Parallax = {\n setTransform: function setTransform(el, progress) {\n var swiper = this;\n var rtl = swiper.rtl;\n\n var $el = $(el);\n var rtlFactor = rtl ? -1 : 1;\n\n var p = $el.attr('data-swiper-parallax') || '0';\n var x = $el.attr('data-swiper-parallax-x');\n var y = $el.attr('data-swiper-parallax-y');\n var scale = $el.attr('data-swiper-parallax-scale');\n var opacity = $el.attr('data-swiper-parallax-opacity');\n\n if (x || y) {\n x = x || '0';\n y = y || '0';\n } else if (swiper.isHorizontal()) {\n x = p;\n y = '0';\n } else {\n y = p;\n x = '0';\n }\n\n if ((x).indexOf('%') >= 0) {\n x = (parseInt(x, 10) * progress * rtlFactor) + \"%\";\n } else {\n x = (x * progress * rtlFactor) + \"px\";\n }\n if ((y).indexOf('%') >= 0) {\n y = (parseInt(y, 10) * progress) + \"%\";\n } else {\n y = (y * progress) + \"px\";\n }\n\n if (typeof opacity !== 'undefined' && opacity !== null) {\n var currentOpacity = opacity - ((opacity - 1) * (1 - Math.abs(progress)));\n $el[0].style.opacity = currentOpacity;\n }\n if (typeof scale === 'undefined' || scale === null) {\n $el.transform((\"translate3d(\" + x + \", \" + y + \", 0px)\"));\n } else {\n var currentScale = scale - ((scale - 1) * (1 - Math.abs(progress)));\n $el.transform((\"translate3d(\" + x + \", \" + y + \", 0px) scale(\" + currentScale + \")\"));\n }\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n var $el = swiper.$el;\n var slides = swiper.slides;\n var progress = swiper.progress;\n var snapGrid = swiper.snapGrid;\n $el.children('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]')\n .each(function (index, el) {\n swiper.parallax.setTransform(el, progress);\n });\n slides.each(function (slideIndex, slideEl) {\n var slideProgress = slideEl.progress;\n if (swiper.params.slidesPerGroup > 1 && swiper.params.slidesPerView !== 'auto') {\n slideProgress += Math.ceil(slideIndex / 2) - (progress * (snapGrid.length - 1));\n }\n slideProgress = Math.min(Math.max(slideProgress, -1), 1);\n $(slideEl).find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]')\n .each(function (index, el) {\n swiper.parallax.setTransform(el, slideProgress);\n });\n });\n },\n setTransition: function setTransition(duration) {\n if ( duration === void 0 ) duration = this.params.speed;\n\n var swiper = this;\n var $el = swiper.$el;\n $el.find('[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y]')\n .each(function (index, parallaxEl) {\n var $parallaxEl = $(parallaxEl);\n var parallaxDuration = parseInt($parallaxEl.attr('data-swiper-parallax-duration'), 10) || duration;\n if (duration === 0) { parallaxDuration = 0; }\n $parallaxEl.transition(parallaxDuration);\n });\n },\n };\n\n var Parallax$1 = {\n name: 'parallax',\n params: {\n parallax: {\n enabled: false,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n parallax: {\n setTransform: Parallax.setTransform.bind(swiper),\n setTranslate: Parallax.setTranslate.bind(swiper),\n setTransition: Parallax.setTransition.bind(swiper),\n },\n });\n },\n on: {\n beforeInit: function beforeInit() {\n var swiper = this;\n if (!swiper.params.parallax.enabled) { return; }\n swiper.params.watchSlidesProgress = true;\n },\n init: function init() {\n var swiper = this;\n if (!swiper.params.parallax) { return; }\n swiper.parallax.setTranslate();\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n if (!swiper.params.parallax) { return; }\n swiper.parallax.setTranslate();\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n if (!swiper.params.parallax) { return; }\n swiper.parallax.setTransition(duration);\n },\n },\n };\n\n var Zoom = {\n // Calc Scale From Multi-touches\n getDistanceBetweenTouches: function getDistanceBetweenTouches(e) {\n if (e.targetTouches.length < 2) { return 1; }\n var x1 = e.targetTouches[0].pageX;\n var y1 = e.targetTouches[0].pageY;\n var x2 = e.targetTouches[1].pageX;\n var y2 = e.targetTouches[1].pageY;\n var distance = Math.sqrt((Math.pow( (x2 - x1), 2 )) + (Math.pow( (y2 - y1), 2 )));\n return distance;\n },\n // Events\n onGestureStart: function onGestureStart(e) {\n var swiper = this;\n var params = swiper.params.zoom;\n var zoom = swiper.zoom;\n var gesture = zoom.gesture;\n zoom.fakeGestureTouched = false;\n zoom.fakeGestureMoved = false;\n if (!Support.gestures) {\n if (e.type !== 'touchstart' || (e.type === 'touchstart' && e.targetTouches.length < 2)) {\n return;\n }\n zoom.fakeGestureTouched = true;\n gesture.scaleStart = Zoom.getDistanceBetweenTouches(e);\n }\n if (!gesture.$slideEl || !gesture.$slideEl.length) {\n gesture.$slideEl = $(e.target).closest('.swiper-slide');\n if (gesture.$slideEl.length === 0) { gesture.$slideEl = swiper.slides.eq(swiper.activeIndex); }\n gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas');\n gesture.$imageWrapEl = gesture.$imageEl.parent((\".\" + (params.containerClass)));\n gesture.maxRatio = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio;\n if (gesture.$imageWrapEl.length === 0) {\n gesture.$imageEl = undefined;\n return;\n }\n }\n gesture.$imageEl.transition(0);\n swiper.zoom.isScaling = true;\n },\n onGestureChange: function onGestureChange(e) {\n var swiper = this;\n var params = swiper.params.zoom;\n var zoom = swiper.zoom;\n var gesture = zoom.gesture;\n if (!Support.gestures) {\n if (e.type !== 'touchmove' || (e.type === 'touchmove' && e.targetTouches.length < 2)) {\n return;\n }\n zoom.fakeGestureMoved = true;\n gesture.scaleMove = Zoom.getDistanceBetweenTouches(e);\n }\n if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; }\n if (Support.gestures) {\n swiper.zoom.scale = e.scale * zoom.currentScale;\n } else {\n zoom.scale = (gesture.scaleMove / gesture.scaleStart) * zoom.currentScale;\n }\n if (zoom.scale > gesture.maxRatio) {\n zoom.scale = (gesture.maxRatio - 1) + (Math.pow( ((zoom.scale - gesture.maxRatio) + 1), 0.5 ));\n }\n if (zoom.scale < params.minRatio) {\n zoom.scale = (params.minRatio + 1) - (Math.pow( ((params.minRatio - zoom.scale) + 1), 0.5 ));\n }\n gesture.$imageEl.transform((\"translate3d(0,0,0) scale(\" + (zoom.scale) + \")\"));\n },\n onGestureEnd: function onGestureEnd(e) {\n var swiper = this;\n var params = swiper.params.zoom;\n var zoom = swiper.zoom;\n var gesture = zoom.gesture;\n if (!Support.gestures) {\n if (!zoom.fakeGestureTouched || !zoom.fakeGestureMoved) {\n return;\n }\n if (e.type !== 'touchend' || (e.type === 'touchend' && e.changedTouches.length < 2 && !Device.android)) {\n return;\n }\n zoom.fakeGestureTouched = false;\n zoom.fakeGestureMoved = false;\n }\n if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; }\n zoom.scale = Math.max(Math.min(zoom.scale, gesture.maxRatio), params.minRatio);\n gesture.$imageEl.transition(swiper.params.speed).transform((\"translate3d(0,0,0) scale(\" + (zoom.scale) + \")\"));\n zoom.currentScale = zoom.scale;\n zoom.isScaling = false;\n if (zoom.scale === 1) { gesture.$slideEl = undefined; }\n },\n onTouchStart: function onTouchStart(e) {\n var swiper = this;\n var zoom = swiper.zoom;\n var gesture = zoom.gesture;\n var image = zoom.image;\n if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; }\n if (image.isTouched) { return; }\n if (Device.android) { e.preventDefault(); }\n image.isTouched = true;\n image.touchesStart.x = e.type === 'touchstart' ? e.targetTouches[0].pageX : e.pageX;\n image.touchesStart.y = e.type === 'touchstart' ? e.targetTouches[0].pageY : e.pageY;\n },\n onTouchMove: function onTouchMove(e) {\n var swiper = this;\n var zoom = swiper.zoom;\n var gesture = zoom.gesture;\n var image = zoom.image;\n var velocity = zoom.velocity;\n if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; }\n swiper.allowClick = false;\n if (!image.isTouched || !gesture.$slideEl) { return; }\n\n if (!image.isMoved) {\n image.width = gesture.$imageEl[0].offsetWidth;\n image.height = gesture.$imageEl[0].offsetHeight;\n image.startX = Utils.getTranslate(gesture.$imageWrapEl[0], 'x') || 0;\n image.startY = Utils.getTranslate(gesture.$imageWrapEl[0], 'y') || 0;\n gesture.slideWidth = gesture.$slideEl[0].offsetWidth;\n gesture.slideHeight = gesture.$slideEl[0].offsetHeight;\n gesture.$imageWrapEl.transition(0);\n if (swiper.rtl) {\n image.startX = -image.startX;\n image.startY = -image.startY;\n }\n }\n // Define if we need image drag\n var scaledWidth = image.width * zoom.scale;\n var scaledHeight = image.height * zoom.scale;\n\n if (scaledWidth < gesture.slideWidth && scaledHeight < gesture.slideHeight) { return; }\n\n image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0);\n image.maxX = -image.minX;\n image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0);\n image.maxY = -image.minY;\n\n image.touchesCurrent.x = e.type === 'touchmove' ? e.targetTouches[0].pageX : e.pageX;\n image.touchesCurrent.y = e.type === 'touchmove' ? e.targetTouches[0].pageY : e.pageY;\n\n if (!image.isMoved && !zoom.isScaling) {\n if (\n swiper.isHorizontal() &&\n (\n (Math.floor(image.minX) === Math.floor(image.startX) && image.touchesCurrent.x < image.touchesStart.x) ||\n (Math.floor(image.maxX) === Math.floor(image.startX) && image.touchesCurrent.x > image.touchesStart.x)\n )\n ) {\n image.isTouched = false;\n return;\n } else if (\n !swiper.isHorizontal() &&\n (\n (Math.floor(image.minY) === Math.floor(image.startY) && image.touchesCurrent.y < image.touchesStart.y) ||\n (Math.floor(image.maxY) === Math.floor(image.startY) && image.touchesCurrent.y > image.touchesStart.y)\n )\n ) {\n image.isTouched = false;\n return;\n }\n }\n e.preventDefault();\n e.stopPropagation();\n\n image.isMoved = true;\n image.currentX = (image.touchesCurrent.x - image.touchesStart.x) + image.startX;\n image.currentY = (image.touchesCurrent.y - image.touchesStart.y) + image.startY;\n\n if (image.currentX < image.minX) {\n image.currentX = (image.minX + 1) - (Math.pow( ((image.minX - image.currentX) + 1), 0.8 ));\n }\n if (image.currentX > image.maxX) {\n image.currentX = (image.maxX - 1) + (Math.pow( ((image.currentX - image.maxX) + 1), 0.8 ));\n }\n\n if (image.currentY < image.minY) {\n image.currentY = (image.minY + 1) - (Math.pow( ((image.minY - image.currentY) + 1), 0.8 ));\n }\n if (image.currentY > image.maxY) {\n image.currentY = (image.maxY - 1) + (Math.pow( ((image.currentY - image.maxY) + 1), 0.8 ));\n }\n\n // Velocity\n if (!velocity.prevPositionX) { velocity.prevPositionX = image.touchesCurrent.x; }\n if (!velocity.prevPositionY) { velocity.prevPositionY = image.touchesCurrent.y; }\n if (!velocity.prevTime) { velocity.prevTime = Date.now(); }\n velocity.x = (image.touchesCurrent.x - velocity.prevPositionX) / (Date.now() - velocity.prevTime) / 2;\n velocity.y = (image.touchesCurrent.y - velocity.prevPositionY) / (Date.now() - velocity.prevTime) / 2;\n if (Math.abs(image.touchesCurrent.x - velocity.prevPositionX) < 2) { velocity.x = 0; }\n if (Math.abs(image.touchesCurrent.y - velocity.prevPositionY) < 2) { velocity.y = 0; }\n velocity.prevPositionX = image.touchesCurrent.x;\n velocity.prevPositionY = image.touchesCurrent.y;\n velocity.prevTime = Date.now();\n\n gesture.$imageWrapEl.transform((\"translate3d(\" + (image.currentX) + \"px, \" + (image.currentY) + \"px,0)\"));\n },\n onTouchEnd: function onTouchEnd() {\n var swiper = this;\n var zoom = swiper.zoom;\n var gesture = zoom.gesture;\n var image = zoom.image;\n var velocity = zoom.velocity;\n if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; }\n if (!image.isTouched || !image.isMoved) {\n image.isTouched = false;\n image.isMoved = false;\n return;\n }\n image.isTouched = false;\n image.isMoved = false;\n var momentumDurationX = 300;\n var momentumDurationY = 300;\n var momentumDistanceX = velocity.x * momentumDurationX;\n var newPositionX = image.currentX + momentumDistanceX;\n var momentumDistanceY = velocity.y * momentumDurationY;\n var newPositionY = image.currentY + momentumDistanceY;\n\n // Fix duration\n if (velocity.x !== 0) { momentumDurationX = Math.abs((newPositionX - image.currentX) / velocity.x); }\n if (velocity.y !== 0) { momentumDurationY = Math.abs((newPositionY - image.currentY) / velocity.y); }\n var momentumDuration = Math.max(momentumDurationX, momentumDurationY);\n\n image.currentX = newPositionX;\n image.currentY = newPositionY;\n\n // Define if we need image drag\n var scaledWidth = image.width * zoom.scale;\n var scaledHeight = image.height * zoom.scale;\n image.minX = Math.min(((gesture.slideWidth / 2) - (scaledWidth / 2)), 0);\n image.maxX = -image.minX;\n image.minY = Math.min(((gesture.slideHeight / 2) - (scaledHeight / 2)), 0);\n image.maxY = -image.minY;\n image.currentX = Math.max(Math.min(image.currentX, image.maxX), image.minX);\n image.currentY = Math.max(Math.min(image.currentY, image.maxY), image.minY);\n\n gesture.$imageWrapEl.transition(momentumDuration).transform((\"translate3d(\" + (image.currentX) + \"px, \" + (image.currentY) + \"px,0)\"));\n },\n onTransitionEnd: function onTransitionEnd() {\n var swiper = this;\n var zoom = swiper.zoom;\n var gesture = zoom.gesture;\n if (gesture.$slideEl && swiper.previousIndex !== swiper.activeIndex) {\n gesture.$imageEl.transform('translate3d(0,0,0) scale(1)');\n gesture.$imageWrapEl.transform('translate3d(0,0,0)');\n gesture.$slideEl = undefined;\n gesture.$imageEl = undefined;\n gesture.$imageWrapEl = undefined;\n\n zoom.scale = 1;\n zoom.currentScale = 1;\n }\n },\n // Toggle Zoom\n toggle: function toggle(e) {\n var swiper = this;\n var zoom = swiper.zoom;\n\n if (zoom.scale && zoom.scale !== 1) {\n // Zoom Out\n zoom.out();\n } else {\n // Zoom In\n zoom.in(e);\n }\n },\n in: function in$1(e) {\n var swiper = this;\n\n var zoom = swiper.zoom;\n var params = swiper.params.zoom;\n var gesture = zoom.gesture;\n var image = zoom.image;\n\n if (!gesture.$slideEl) {\n gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex);\n gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas');\n gesture.$imageWrapEl = gesture.$imageEl.parent((\".\" + (params.containerClass)));\n }\n if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; }\n\n gesture.$slideEl.addClass((\"\" + (params.zoomedSlideClass)));\n\n var touchX;\n var touchY;\n var offsetX;\n var offsetY;\n var diffX;\n var diffY;\n var translateX;\n var translateY;\n var imageWidth;\n var imageHeight;\n var scaledWidth;\n var scaledHeight;\n var translateMinX;\n var translateMinY;\n var translateMaxX;\n var translateMaxY;\n var slideWidth;\n var slideHeight;\n\n if (typeof image.touchesStart.x === 'undefined' && e) {\n touchX = e.type === 'touchend' ? e.changedTouches[0].pageX : e.pageX;\n touchY = e.type === 'touchend' ? e.changedTouches[0].pageY : e.pageY;\n } else {\n touchX = image.touchesStart.x;\n touchY = image.touchesStart.y;\n }\n\n zoom.scale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio;\n zoom.currentScale = gesture.$imageWrapEl.attr('data-swiper-zoom') || params.maxRatio;\n if (e) {\n slideWidth = gesture.$slideEl[0].offsetWidth;\n slideHeight = gesture.$slideEl[0].offsetHeight;\n offsetX = gesture.$slideEl.offset().left;\n offsetY = gesture.$slideEl.offset().top;\n diffX = (offsetX + (slideWidth / 2)) - touchX;\n diffY = (offsetY + (slideHeight / 2)) - touchY;\n\n imageWidth = gesture.$imageEl[0].offsetWidth;\n imageHeight = gesture.$imageEl[0].offsetHeight;\n scaledWidth = imageWidth * zoom.scale;\n scaledHeight = imageHeight * zoom.scale;\n\n translateMinX = Math.min(((slideWidth / 2) - (scaledWidth / 2)), 0);\n translateMinY = Math.min(((slideHeight / 2) - (scaledHeight / 2)), 0);\n translateMaxX = -translateMinX;\n translateMaxY = -translateMinY;\n\n translateX = diffX * zoom.scale;\n translateY = diffY * zoom.scale;\n\n if (translateX < translateMinX) {\n translateX = translateMinX;\n }\n if (translateX > translateMaxX) {\n translateX = translateMaxX;\n }\n\n if (translateY < translateMinY) {\n translateY = translateMinY;\n }\n if (translateY > translateMaxY) {\n translateY = translateMaxY;\n }\n } else {\n translateX = 0;\n translateY = 0;\n }\n gesture.$imageWrapEl.transition(300).transform((\"translate3d(\" + translateX + \"px, \" + translateY + \"px,0)\"));\n gesture.$imageEl.transition(300).transform((\"translate3d(0,0,0) scale(\" + (zoom.scale) + \")\"));\n },\n out: function out() {\n var swiper = this;\n\n var zoom = swiper.zoom;\n var params = swiper.params.zoom;\n var gesture = zoom.gesture;\n\n if (!gesture.$slideEl) {\n gesture.$slideEl = swiper.clickedSlide ? $(swiper.clickedSlide) : swiper.slides.eq(swiper.activeIndex);\n gesture.$imageEl = gesture.$slideEl.find('img, svg, canvas');\n gesture.$imageWrapEl = gesture.$imageEl.parent((\".\" + (params.containerClass)));\n }\n if (!gesture.$imageEl || gesture.$imageEl.length === 0) { return; }\n\n zoom.scale = 1;\n zoom.currentScale = 1;\n gesture.$imageWrapEl.transition(300).transform('translate3d(0,0,0)');\n gesture.$imageEl.transition(300).transform('translate3d(0,0,0) scale(1)');\n gesture.$slideEl.removeClass((\"\" + (params.zoomedSlideClass)));\n gesture.$slideEl = undefined;\n },\n // Attach/Detach Events\n enable: function enable() {\n var swiper = this;\n var zoom = swiper.zoom;\n if (zoom.enabled) { return; }\n zoom.enabled = true;\n\n var passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false;\n\n // Scale image\n if (Support.gestures) {\n swiper.$wrapperEl.on('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener);\n swiper.$wrapperEl.on('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener);\n swiper.$wrapperEl.on('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener);\n } else if (swiper.touchEvents.start === 'touchstart') {\n swiper.$wrapperEl.on(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener);\n swiper.$wrapperEl.on(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener);\n swiper.$wrapperEl.on(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener);\n }\n\n // Move image\n swiper.$wrapperEl.on(swiper.touchEvents.move, (\".\" + (swiper.params.zoom.containerClass)), zoom.onTouchMove);\n },\n disable: function disable() {\n var swiper = this;\n var zoom = swiper.zoom;\n if (!zoom.enabled) { return; }\n\n swiper.zoom.enabled = false;\n\n var passiveListener = swiper.touchEvents.start === 'touchstart' && Support.passiveListener && swiper.params.passiveListeners ? { passive: true, capture: false } : false;\n\n // Scale image\n if (Support.gestures) {\n swiper.$wrapperEl.off('gesturestart', '.swiper-slide', zoom.onGestureStart, passiveListener);\n swiper.$wrapperEl.off('gesturechange', '.swiper-slide', zoom.onGestureChange, passiveListener);\n swiper.$wrapperEl.off('gestureend', '.swiper-slide', zoom.onGestureEnd, passiveListener);\n } else if (swiper.touchEvents.start === 'touchstart') {\n swiper.$wrapperEl.off(swiper.touchEvents.start, '.swiper-slide', zoom.onGestureStart, passiveListener);\n swiper.$wrapperEl.off(swiper.touchEvents.move, '.swiper-slide', zoom.onGestureChange, passiveListener);\n swiper.$wrapperEl.off(swiper.touchEvents.end, '.swiper-slide', zoom.onGestureEnd, passiveListener);\n }\n\n // Move image\n swiper.$wrapperEl.off(swiper.touchEvents.move, (\".\" + (swiper.params.zoom.containerClass)), zoom.onTouchMove);\n },\n };\n\n var Zoom$1 = {\n name: 'zoom',\n params: {\n zoom: {\n enabled: false,\n maxRatio: 3,\n minRatio: 1,\n toggle: true,\n containerClass: 'swiper-zoom-container',\n zoomedSlideClass: 'swiper-slide-zoomed',\n },\n },\n create: function create() {\n var swiper = this;\n var zoom = {\n enabled: false,\n scale: 1,\n currentScale: 1,\n isScaling: false,\n gesture: {\n $slideEl: undefined,\n slideWidth: undefined,\n slideHeight: undefined,\n $imageEl: undefined,\n $imageWrapEl: undefined,\n maxRatio: 3,\n },\n image: {\n isTouched: undefined,\n isMoved: undefined,\n currentX: undefined,\n currentY: undefined,\n minX: undefined,\n minY: undefined,\n maxX: undefined,\n maxY: undefined,\n width: undefined,\n height: undefined,\n startX: undefined,\n startY: undefined,\n touchesStart: {},\n touchesCurrent: {},\n },\n velocity: {\n x: undefined,\n y: undefined,\n prevPositionX: undefined,\n prevPositionY: undefined,\n prevTime: undefined,\n },\n };\n ('onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out').split(' ').forEach(function (methodName) {\n zoom[methodName] = Zoom[methodName].bind(swiper);\n });\n Utils.extend(swiper, {\n zoom: zoom,\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n if (swiper.params.zoom.enabled) {\n swiper.zoom.enable();\n }\n },\n destroy: function destroy() {\n var swiper = this;\n swiper.zoom.disable();\n },\n touchStart: function touchStart(e) {\n var swiper = this;\n if (!swiper.zoom.enabled) { return; }\n swiper.zoom.onTouchStart(e);\n },\n touchEnd: function touchEnd(e) {\n var swiper = this;\n if (!swiper.zoom.enabled) { return; }\n swiper.zoom.onTouchEnd(e);\n },\n doubleTap: function doubleTap(e) {\n var swiper = this;\n if (swiper.params.zoom.enabled && swiper.zoom.enabled && swiper.params.zoom.toggle) {\n swiper.zoom.toggle(e);\n }\n },\n transitionEnd: function transitionEnd() {\n var swiper = this;\n if (swiper.zoom.enabled && swiper.params.zoom.enabled) {\n swiper.zoom.onTransitionEnd();\n }\n },\n },\n };\n\n var Lazy = {\n loadInSlide: function loadInSlide(index, loadInDuplicate) {\n if ( loadInDuplicate === void 0 ) loadInDuplicate = true;\n\n var swiper = this;\n var params = swiper.params.lazy;\n if (typeof index === 'undefined') { return; }\n if (swiper.slides.length === 0) { return; }\n var isVirtual = swiper.virtual && swiper.params.virtual.enabled;\n\n var $slideEl = isVirtual\n ? swiper.$wrapperEl.children((\".\" + (swiper.params.slideClass) + \"[data-swiper-slide-index=\\\"\" + index + \"\\\"]\"))\n : swiper.slides.eq(index);\n\n var $images = $slideEl.find((\".\" + (params.elementClass) + \":not(.\" + (params.loadedClass) + \"):not(.\" + (params.loadingClass) + \")\"));\n if ($slideEl.hasClass(params.elementClass) && !$slideEl.hasClass(params.loadedClass) && !$slideEl.hasClass(params.loadingClass)) {\n $images = $images.add($slideEl[0]);\n }\n if ($images.length === 0) { return; }\n\n $images.each(function (imageIndex, imageEl) {\n var $imageEl = $(imageEl);\n $imageEl.addClass(params.loadingClass);\n\n var background = $imageEl.attr('data-background');\n var src = $imageEl.attr('data-src');\n var srcset = $imageEl.attr('data-srcset');\n var sizes = $imageEl.attr('data-sizes');\n\n swiper.loadImage($imageEl[0], (src || background), srcset, sizes, false, function () {\n if (typeof swiper === 'undefined' || swiper === null || !swiper || (swiper && !swiper.params) || swiper.destroyed) { return; }\n if (background) {\n $imageEl.css('background-image', (\"url(\\\"\" + background + \"\\\")\"));\n $imageEl.removeAttr('data-background');\n } else {\n if (srcset) {\n $imageEl.attr('srcset', srcset);\n $imageEl.removeAttr('data-srcset');\n }\n if (sizes) {\n $imageEl.attr('sizes', sizes);\n $imageEl.removeAttr('data-sizes');\n }\n if (src) {\n $imageEl.attr('src', src);\n $imageEl.removeAttr('data-src');\n }\n }\n\n $imageEl.addClass(params.loadedClass).removeClass(params.loadingClass);\n $slideEl.find((\".\" + (params.preloaderClass))).remove();\n if (swiper.params.loop && loadInDuplicate) {\n var slideOriginalIndex = $slideEl.attr('data-swiper-slide-index');\n if ($slideEl.hasClass(swiper.params.slideDuplicateClass)) {\n var originalSlide = swiper.$wrapperEl.children((\"[data-swiper-slide-index=\\\"\" + slideOriginalIndex + \"\\\"]:not(.\" + (swiper.params.slideDuplicateClass) + \")\"));\n swiper.lazy.loadInSlide(originalSlide.index(), false);\n } else {\n var duplicatedSlide = swiper.$wrapperEl.children((\".\" + (swiper.params.slideDuplicateClass) + \"[data-swiper-slide-index=\\\"\" + slideOriginalIndex + \"\\\"]\"));\n swiper.lazy.loadInSlide(duplicatedSlide.index(), false);\n }\n }\n swiper.emit('lazyImageReady', $slideEl[0], $imageEl[0]);\n });\n\n swiper.emit('lazyImageLoad', $slideEl[0], $imageEl[0]);\n });\n },\n load: function load() {\n var swiper = this;\n var $wrapperEl = swiper.$wrapperEl;\n var swiperParams = swiper.params;\n var slides = swiper.slides;\n var activeIndex = swiper.activeIndex;\n var isVirtual = swiper.virtual && swiperParams.virtual.enabled;\n var params = swiperParams.lazy;\n\n var slidesPerView = swiperParams.slidesPerView;\n if (slidesPerView === 'auto') {\n slidesPerView = 0;\n }\n\n function slideExist(index) {\n if (isVirtual) {\n if ($wrapperEl.children((\".\" + (swiperParams.slideClass) + \"[data-swiper-slide-index=\\\"\" + index + \"\\\"]\")).length) {\n return true;\n }\n } else if (slides[index]) { return true; }\n return false;\n }\n function slideIndex(slideEl) {\n if (isVirtual) {\n return $(slideEl).attr('data-swiper-slide-index');\n }\n return $(slideEl).index();\n }\n\n if (!swiper.lazy.initialImageLoaded) { swiper.lazy.initialImageLoaded = true; }\n if (swiper.params.watchSlidesVisibility) {\n $wrapperEl.children((\".\" + (swiperParams.slideVisibleClass))).each(function (elIndex, slideEl) {\n var index = isVirtual ? $(slideEl).attr('data-swiper-slide-index') : $(slideEl).index();\n swiper.lazy.loadInSlide(index);\n });\n } else if (slidesPerView > 1) {\n for (var i = activeIndex; i < activeIndex + slidesPerView; i += 1) {\n if (slideExist(i)) { swiper.lazy.loadInSlide(i); }\n }\n } else {\n swiper.lazy.loadInSlide(activeIndex);\n }\n if (params.loadPrevNext) {\n if (slidesPerView > 1 || (params.loadPrevNextAmount && params.loadPrevNextAmount > 1)) {\n var amount = params.loadPrevNextAmount;\n var spv = slidesPerView;\n var maxIndex = Math.min(activeIndex + spv + Math.max(amount, spv), slides.length);\n var minIndex = Math.max(activeIndex - Math.max(spv, amount), 0);\n // Next Slides\n for (var i$1 = activeIndex + slidesPerView; i$1 < maxIndex; i$1 += 1) {\n if (slideExist(i$1)) { swiper.lazy.loadInSlide(i$1); }\n }\n // Prev Slides\n for (var i$2 = minIndex; i$2 < activeIndex; i$2 += 1) {\n if (slideExist(i$2)) { swiper.lazy.loadInSlide(i$2); }\n }\n } else {\n var nextSlide = $wrapperEl.children((\".\" + (swiperParams.slideNextClass)));\n if (nextSlide.length > 0) { swiper.lazy.loadInSlide(slideIndex(nextSlide)); }\n\n var prevSlide = $wrapperEl.children((\".\" + (swiperParams.slidePrevClass)));\n if (prevSlide.length > 0) { swiper.lazy.loadInSlide(slideIndex(prevSlide)); }\n }\n }\n },\n };\n\n var Lazy$1 = {\n name: 'lazy',\n params: {\n lazy: {\n enabled: false,\n loadPrevNext: false,\n loadPrevNextAmount: 1,\n loadOnTransitionStart: false,\n\n elementClass: 'swiper-lazy',\n loadingClass: 'swiper-lazy-loading',\n loadedClass: 'swiper-lazy-loaded',\n preloaderClass: 'swiper-lazy-preloader',\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n lazy: {\n initialImageLoaded: false,\n load: Lazy.load.bind(swiper),\n loadInSlide: Lazy.loadInSlide.bind(swiper),\n },\n });\n },\n on: {\n beforeInit: function beforeInit() {\n var swiper = this;\n if (swiper.params.lazy.enabled && swiper.params.preloadImages) {\n swiper.params.preloadImages = false;\n }\n },\n init: function init() {\n var swiper = this;\n if (swiper.params.lazy.enabled && !swiper.params.loop && swiper.params.initialSlide === 0) {\n swiper.lazy.load();\n }\n },\n scroll: function scroll() {\n var swiper = this;\n if (swiper.params.freeMode && !swiper.params.freeModeSticky) {\n swiper.lazy.load();\n }\n },\n resize: function resize() {\n var swiper = this;\n if (swiper.params.lazy.enabled) {\n swiper.lazy.load();\n }\n },\n scrollbarDragMove: function scrollbarDragMove() {\n var swiper = this;\n if (swiper.params.lazy.enabled) {\n swiper.lazy.load();\n }\n },\n transitionStart: function transitionStart() {\n var swiper = this;\n if (swiper.params.lazy.enabled) {\n if (swiper.params.lazy.loadOnTransitionStart || (!swiper.params.lazy.loadOnTransitionStart && !swiper.lazy.initialImageLoaded)) {\n swiper.lazy.load();\n }\n }\n },\n transitionEnd: function transitionEnd() {\n var swiper = this;\n if (swiper.params.lazy.enabled && !swiper.params.lazy.loadOnTransitionStart) {\n swiper.lazy.load();\n }\n },\n },\n };\n\n /* eslint no-bitwise: [\"error\", { \"allow\": [\">>\"] }] */\n\n var Controller = {\n LinearSpline: function LinearSpline(x, y) {\n var binarySearch = (function search() {\n var maxIndex;\n var minIndex;\n var guess;\n return function (array, val) {\n minIndex = -1;\n maxIndex = array.length;\n while (maxIndex - minIndex > 1) {\n guess = maxIndex + minIndex >> 1;\n if (array[guess] <= val) {\n minIndex = guess;\n } else {\n maxIndex = guess;\n }\n }\n return maxIndex;\n };\n }());\n this.x = x;\n this.y = y;\n this.lastIndex = x.length - 1;\n // Given an x value (x2), return the expected y2 value:\n // (x1,y1) is the known point before given value,\n // (x3,y3) is the known point after given value.\n var i1;\n var i3;\n\n this.interpolate = function interpolate(x2) {\n if (!x2) { return 0; }\n\n // Get the indexes of x1 and x3 (the array indexes before and after given x2):\n i3 = binarySearch(this.x, x2);\n i1 = i3 - 1;\n\n // We have our indexes i1 & i3, so we can calculate already:\n // y2 := ((x2−x1) × (y3−y1)) ÷ (x3−x1) + y1\n return (((x2 - this.x[i1]) * (this.y[i3] - this.y[i1])) / (this.x[i3] - this.x[i1])) + this.y[i1];\n };\n return this;\n },\n // xxx: for now i will just save one spline function to to\n getInterpolateFunction: function getInterpolateFunction(c) {\n var swiper = this;\n if (!swiper.controller.spline) {\n swiper.controller.spline = swiper.params.loop ?\n new Controller.LinearSpline(swiper.slidesGrid, c.slidesGrid) :\n new Controller.LinearSpline(swiper.snapGrid, c.snapGrid);\n }\n },\n setTranslate: function setTranslate(setTranslate$1, byController) {\n var swiper = this;\n var controlled = swiper.controller.control;\n var multiplier;\n var controlledTranslate;\n function setControlledTranslate(c) {\n // this will create an Interpolate function based on the snapGrids\n // x is the Grid of the scrolled scroller and y will be the controlled scroller\n // it makes sense to create this only once and recall it for the interpolation\n // the function does a lot of value caching for performance\n var translate = swiper.rtlTranslate ? -swiper.translate : swiper.translate;\n if (swiper.params.controller.by === 'slide') {\n swiper.controller.getInterpolateFunction(c);\n // i am not sure why the values have to be multiplicated this way, tried to invert the snapGrid\n // but it did not work out\n controlledTranslate = -swiper.controller.spline.interpolate(-translate);\n }\n\n if (!controlledTranslate || swiper.params.controller.by === 'container') {\n multiplier = (c.maxTranslate() - c.minTranslate()) / (swiper.maxTranslate() - swiper.minTranslate());\n controlledTranslate = ((translate - swiper.minTranslate()) * multiplier) + c.minTranslate();\n }\n\n if (swiper.params.controller.inverse) {\n controlledTranslate = c.maxTranslate() - controlledTranslate;\n }\n c.updateProgress(controlledTranslate);\n c.setTranslate(controlledTranslate, swiper);\n c.updateActiveIndex();\n c.updateSlidesClasses();\n }\n if (Array.isArray(controlled)) {\n for (var i = 0; i < controlled.length; i += 1) {\n if (controlled[i] !== byController && controlled[i] instanceof Swiper) {\n setControlledTranslate(controlled[i]);\n }\n }\n } else if (controlled instanceof Swiper && byController !== controlled) {\n setControlledTranslate(controlled);\n }\n },\n setTransition: function setTransition(duration, byController) {\n var swiper = this;\n var controlled = swiper.controller.control;\n var i;\n function setControlledTransition(c) {\n c.setTransition(duration, swiper);\n if (duration !== 0) {\n c.transitionStart();\n c.$wrapperEl.transitionEnd(function () {\n if (!controlled) { return; }\n if (c.params.loop && swiper.params.controller.by === 'slide') {\n c.loopFix();\n }\n c.transitionEnd();\n });\n }\n }\n if (Array.isArray(controlled)) {\n for (i = 0; i < controlled.length; i += 1) {\n if (controlled[i] !== byController && controlled[i] instanceof Swiper) {\n setControlledTransition(controlled[i]);\n }\n }\n } else if (controlled instanceof Swiper && byController !== controlled) {\n setControlledTransition(controlled);\n }\n },\n };\n var Controller$1 = {\n name: 'controller',\n params: {\n controller: {\n control: undefined,\n inverse: false,\n by: 'slide', // or 'container'\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n controller: {\n control: swiper.params.controller.control,\n getInterpolateFunction: Controller.getInterpolateFunction.bind(swiper),\n setTranslate: Controller.setTranslate.bind(swiper),\n setTransition: Controller.setTransition.bind(swiper),\n },\n });\n },\n on: {\n update: function update() {\n var swiper = this;\n if (!swiper.controller.control) { return; }\n if (swiper.controller.spline) {\n swiper.controller.spline = undefined;\n delete swiper.controller.spline;\n }\n },\n resize: function resize() {\n var swiper = this;\n if (!swiper.controller.control) { return; }\n if (swiper.controller.spline) {\n swiper.controller.spline = undefined;\n delete swiper.controller.spline;\n }\n },\n observerUpdate: function observerUpdate() {\n var swiper = this;\n if (!swiper.controller.control) { return; }\n if (swiper.controller.spline) {\n swiper.controller.spline = undefined;\n delete swiper.controller.spline;\n }\n },\n setTranslate: function setTranslate(translate, byController) {\n var swiper = this;\n if (!swiper.controller.control) { return; }\n swiper.controller.setTranslate(translate, byController);\n },\n setTransition: function setTransition(duration, byController) {\n var swiper = this;\n if (!swiper.controller.control) { return; }\n swiper.controller.setTransition(duration, byController);\n },\n },\n };\n\n var a11y = {\n makeElFocusable: function makeElFocusable($el) {\n $el.attr('tabIndex', '0');\n return $el;\n },\n addElRole: function addElRole($el, role) {\n $el.attr('role', role);\n return $el;\n },\n addElLabel: function addElLabel($el, label) {\n $el.attr('aria-label', label);\n return $el;\n },\n disableEl: function disableEl($el) {\n $el.attr('aria-disabled', true);\n return $el;\n },\n enableEl: function enableEl($el) {\n $el.attr('aria-disabled', false);\n return $el;\n },\n onEnterKey: function onEnterKey(e) {\n var swiper = this;\n var params = swiper.params.a11y;\n if (e.keyCode !== 13) { return; }\n var $targetEl = $(e.target);\n if (swiper.navigation && swiper.navigation.$nextEl && $targetEl.is(swiper.navigation.$nextEl)) {\n if (!(swiper.isEnd && !swiper.params.loop)) {\n swiper.slideNext();\n }\n if (swiper.isEnd) {\n swiper.a11y.notify(params.lastSlideMessage);\n } else {\n swiper.a11y.notify(params.nextSlideMessage);\n }\n }\n if (swiper.navigation && swiper.navigation.$prevEl && $targetEl.is(swiper.navigation.$prevEl)) {\n if (!(swiper.isBeginning && !swiper.params.loop)) {\n swiper.slidePrev();\n }\n if (swiper.isBeginning) {\n swiper.a11y.notify(params.firstSlideMessage);\n } else {\n swiper.a11y.notify(params.prevSlideMessage);\n }\n }\n if (swiper.pagination && $targetEl.is((\".\" + (swiper.params.pagination.bulletClass)))) {\n $targetEl[0].click();\n }\n },\n notify: function notify(message) {\n var swiper = this;\n var notification = swiper.a11y.liveRegion;\n if (notification.length === 0) { return; }\n notification.html('');\n notification.html(message);\n },\n updateNavigation: function updateNavigation() {\n var swiper = this;\n\n if (swiper.params.loop) { return; }\n var ref = swiper.navigation;\n var $nextEl = ref.$nextEl;\n var $prevEl = ref.$prevEl;\n\n if ($prevEl && $prevEl.length > 0) {\n if (swiper.isBeginning) {\n swiper.a11y.disableEl($prevEl);\n } else {\n swiper.a11y.enableEl($prevEl);\n }\n }\n if ($nextEl && $nextEl.length > 0) {\n if (swiper.isEnd) {\n swiper.a11y.disableEl($nextEl);\n } else {\n swiper.a11y.enableEl($nextEl);\n }\n }\n },\n updatePagination: function updatePagination() {\n var swiper = this;\n var params = swiper.params.a11y;\n if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) {\n swiper.pagination.bullets.each(function (bulletIndex, bulletEl) {\n var $bulletEl = $(bulletEl);\n swiper.a11y.makeElFocusable($bulletEl);\n swiper.a11y.addElRole($bulletEl, 'button');\n swiper.a11y.addElLabel($bulletEl, params.paginationBulletMessage.replace(/{{index}}/, $bulletEl.index() + 1));\n });\n }\n },\n init: function init() {\n var swiper = this;\n\n swiper.$el.append(swiper.a11y.liveRegion);\n\n // Navigation\n var params = swiper.params.a11y;\n var $nextEl;\n var $prevEl;\n if (swiper.navigation && swiper.navigation.$nextEl) {\n $nextEl = swiper.navigation.$nextEl;\n }\n if (swiper.navigation && swiper.navigation.$prevEl) {\n $prevEl = swiper.navigation.$prevEl;\n }\n if ($nextEl) {\n swiper.a11y.makeElFocusable($nextEl);\n swiper.a11y.addElRole($nextEl, 'button');\n swiper.a11y.addElLabel($nextEl, params.nextSlideMessage);\n $nextEl.on('keydown', swiper.a11y.onEnterKey);\n }\n if ($prevEl) {\n swiper.a11y.makeElFocusable($prevEl);\n swiper.a11y.addElRole($prevEl, 'button');\n swiper.a11y.addElLabel($prevEl, params.prevSlideMessage);\n $prevEl.on('keydown', swiper.a11y.onEnterKey);\n }\n\n // Pagination\n if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) {\n swiper.pagination.$el.on('keydown', (\".\" + (swiper.params.pagination.bulletClass)), swiper.a11y.onEnterKey);\n }\n },\n destroy: function destroy() {\n var swiper = this;\n if (swiper.a11y.liveRegion && swiper.a11y.liveRegion.length > 0) { swiper.a11y.liveRegion.remove(); }\n\n var $nextEl;\n var $prevEl;\n if (swiper.navigation && swiper.navigation.$nextEl) {\n $nextEl = swiper.navigation.$nextEl;\n }\n if (swiper.navigation && swiper.navigation.$prevEl) {\n $prevEl = swiper.navigation.$prevEl;\n }\n if ($nextEl) {\n $nextEl.off('keydown', swiper.a11y.onEnterKey);\n }\n if ($prevEl) {\n $prevEl.off('keydown', swiper.a11y.onEnterKey);\n }\n\n // Pagination\n if (swiper.pagination && swiper.params.pagination.clickable && swiper.pagination.bullets && swiper.pagination.bullets.length) {\n swiper.pagination.$el.off('keydown', (\".\" + (swiper.params.pagination.bulletClass)), swiper.a11y.onEnterKey);\n }\n },\n };\n var A11y = {\n name: 'a11y',\n params: {\n a11y: {\n enabled: true,\n notificationClass: 'swiper-notification',\n prevSlideMessage: 'Previous slide',\n nextSlideMessage: 'Next slide',\n firstSlideMessage: 'This is the first slide',\n lastSlideMessage: 'This is the last slide',\n paginationBulletMessage: 'Go to slide {{index}}',\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n a11y: {\n liveRegion: $((\"\")),\n },\n });\n Object.keys(a11y).forEach(function (methodName) {\n swiper.a11y[methodName] = a11y[methodName].bind(swiper);\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n if (!swiper.params.a11y.enabled) { return; }\n swiper.a11y.init();\n swiper.a11y.updateNavigation();\n },\n toEdge: function toEdge() {\n var swiper = this;\n if (!swiper.params.a11y.enabled) { return; }\n swiper.a11y.updateNavigation();\n },\n fromEdge: function fromEdge() {\n var swiper = this;\n if (!swiper.params.a11y.enabled) { return; }\n swiper.a11y.updateNavigation();\n },\n paginationUpdate: function paginationUpdate() {\n var swiper = this;\n if (!swiper.params.a11y.enabled) { return; }\n swiper.a11y.updatePagination();\n },\n destroy: function destroy() {\n var swiper = this;\n if (!swiper.params.a11y.enabled) { return; }\n swiper.a11y.destroy();\n },\n },\n };\n\n var History = {\n init: function init() {\n var swiper = this;\n if (!swiper.params.history) { return; }\n if (!win.history || !win.history.pushState) {\n swiper.params.history.enabled = false;\n swiper.params.hashNavigation.enabled = true;\n return;\n }\n var history = swiper.history;\n history.initialized = true;\n history.paths = History.getPathValues();\n if (!history.paths.key && !history.paths.value) { return; }\n history.scrollToSlide(0, history.paths.value, swiper.params.runCallbacksOnInit);\n if (!swiper.params.history.replaceState) {\n win.addEventListener('popstate', swiper.history.setHistoryPopState);\n }\n },\n destroy: function destroy() {\n var swiper = this;\n if (!swiper.params.history.replaceState) {\n win.removeEventListener('popstate', swiper.history.setHistoryPopState);\n }\n },\n setHistoryPopState: function setHistoryPopState() {\n var swiper = this;\n swiper.history.paths = History.getPathValues();\n swiper.history.scrollToSlide(swiper.params.speed, swiper.history.paths.value, false);\n },\n getPathValues: function getPathValues() {\n var pathArray = win.location.pathname.slice(1).split('/').filter(function (part) { return part !== ''; });\n var total = pathArray.length;\n var key = pathArray[total - 2];\n var value = pathArray[total - 1];\n return { key: key, value: value };\n },\n setHistory: function setHistory(key, index) {\n var swiper = this;\n if (!swiper.history.initialized || !swiper.params.history.enabled) { return; }\n var slide = swiper.slides.eq(index);\n var value = History.slugify(slide.attr('data-history'));\n if (!win.location.pathname.includes(key)) {\n value = key + \"/\" + value;\n }\n var currentState = win.history.state;\n if (currentState && currentState.value === value) {\n return;\n }\n if (swiper.params.history.replaceState) {\n win.history.replaceState({ value: value }, null, value);\n } else {\n win.history.pushState({ value: value }, null, value);\n }\n },\n slugify: function slugify(text) {\n return text.toString().toLowerCase()\n .replace(/\\s+/g, '-')\n .replace(/[^\\w-]+/g, '')\n .replace(/--+/g, '-')\n .replace(/^-+/, '')\n .replace(/-+$/, '');\n },\n scrollToSlide: function scrollToSlide(speed, value, runCallbacks) {\n var swiper = this;\n if (value) {\n for (var i = 0, length = swiper.slides.length; i < length; i += 1) {\n var slide = swiper.slides.eq(i);\n var slideHistory = History.slugify(slide.attr('data-history'));\n if (slideHistory === value && !slide.hasClass(swiper.params.slideDuplicateClass)) {\n var index = slide.index();\n swiper.slideTo(index, speed, runCallbacks);\n }\n }\n } else {\n swiper.slideTo(0, speed, runCallbacks);\n }\n },\n };\n\n var History$1 = {\n name: 'history',\n params: {\n history: {\n enabled: false,\n replaceState: false,\n key: 'slides',\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n history: {\n init: History.init.bind(swiper),\n setHistory: History.setHistory.bind(swiper),\n setHistoryPopState: History.setHistoryPopState.bind(swiper),\n scrollToSlide: History.scrollToSlide.bind(swiper),\n destroy: History.destroy.bind(swiper),\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n if (swiper.params.history.enabled) {\n swiper.history.init();\n }\n },\n destroy: function destroy() {\n var swiper = this;\n if (swiper.params.history.enabled) {\n swiper.history.destroy();\n }\n },\n transitionEnd: function transitionEnd() {\n var swiper = this;\n if (swiper.history.initialized) {\n swiper.history.setHistory(swiper.params.history.key, swiper.activeIndex);\n }\n },\n },\n };\n\n var HashNavigation = {\n onHashCange: function onHashCange() {\n var swiper = this;\n var newHash = doc.location.hash.replace('#', '');\n var activeSlideHash = swiper.slides.eq(swiper.activeIndex).attr('data-hash');\n if (newHash !== activeSlideHash) {\n swiper.slideTo(swiper.$wrapperEl.children((\".\" + (swiper.params.slideClass) + \"[data-hash=\\\"\" + newHash + \"\\\"]\")).index());\n }\n },\n setHash: function setHash() {\n var swiper = this;\n if (!swiper.hashNavigation.initialized || !swiper.params.hashNavigation.enabled) { return; }\n if (swiper.params.hashNavigation.replaceState && win.history && win.history.replaceState) {\n win.history.replaceState(null, null, ((\"#\" + (swiper.slides.eq(swiper.activeIndex).attr('data-hash'))) || ''));\n } else {\n var slide = swiper.slides.eq(swiper.activeIndex);\n var hash = slide.attr('data-hash') || slide.attr('data-history');\n doc.location.hash = hash || '';\n }\n },\n init: function init() {\n var swiper = this;\n if (!swiper.params.hashNavigation.enabled || (swiper.params.history && swiper.params.history.enabled)) { return; }\n swiper.hashNavigation.initialized = true;\n var hash = doc.location.hash.replace('#', '');\n if (hash) {\n var speed = 0;\n for (var i = 0, length = swiper.slides.length; i < length; i += 1) {\n var slide = swiper.slides.eq(i);\n var slideHash = slide.attr('data-hash') || slide.attr('data-history');\n if (slideHash === hash && !slide.hasClass(swiper.params.slideDuplicateClass)) {\n var index = slide.index();\n swiper.slideTo(index, speed, swiper.params.runCallbacksOnInit, true);\n }\n }\n }\n if (swiper.params.hashNavigation.watchState) {\n $(win).on('hashchange', swiper.hashNavigation.onHashCange);\n }\n },\n destroy: function destroy() {\n var swiper = this;\n if (swiper.params.hashNavigation.watchState) {\n $(win).off('hashchange', swiper.hashNavigation.onHashCange);\n }\n },\n };\n var HashNavigation$1 = {\n name: 'hash-navigation',\n params: {\n hashNavigation: {\n enabled: false,\n replaceState: false,\n watchState: false,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n hashNavigation: {\n initialized: false,\n init: HashNavigation.init.bind(swiper),\n destroy: HashNavigation.destroy.bind(swiper),\n setHash: HashNavigation.setHash.bind(swiper),\n onHashCange: HashNavigation.onHashCange.bind(swiper),\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n if (swiper.params.hashNavigation.enabled) {\n swiper.hashNavigation.init();\n }\n },\n destroy: function destroy() {\n var swiper = this;\n if (swiper.params.hashNavigation.enabled) {\n swiper.hashNavigation.destroy();\n }\n },\n transitionEnd: function transitionEnd() {\n var swiper = this;\n if (swiper.hashNavigation.initialized) {\n swiper.hashNavigation.setHash();\n }\n },\n },\n };\n\n /* eslint no-underscore-dangle: \"off\" */\n\n var Autoplay = {\n run: function run() {\n var swiper = this;\n var $activeSlideEl = swiper.slides.eq(swiper.activeIndex);\n var delay = swiper.params.autoplay.delay;\n if ($activeSlideEl.attr('data-swiper-autoplay')) {\n delay = $activeSlideEl.attr('data-swiper-autoplay') || swiper.params.autoplay.delay;\n }\n swiper.autoplay.timeout = Utils.nextTick(function () {\n if (swiper.params.autoplay.reverseDirection) {\n if (swiper.params.loop) {\n swiper.loopFix();\n swiper.slidePrev(swiper.params.speed, true, true);\n swiper.emit('autoplay');\n } else if (!swiper.isBeginning) {\n swiper.slidePrev(swiper.params.speed, true, true);\n swiper.emit('autoplay');\n } else if (!swiper.params.autoplay.stopOnLastSlide) {\n swiper.slideTo(swiper.slides.length - 1, swiper.params.speed, true, true);\n swiper.emit('autoplay');\n } else {\n swiper.autoplay.stop();\n }\n } else if (swiper.params.loop) {\n swiper.loopFix();\n swiper.slideNext(swiper.params.speed, true, true);\n swiper.emit('autoplay');\n } else if (!swiper.isEnd) {\n swiper.slideNext(swiper.params.speed, true, true);\n swiper.emit('autoplay');\n } else if (!swiper.params.autoplay.stopOnLastSlide) {\n swiper.slideTo(0, swiper.params.speed, true, true);\n swiper.emit('autoplay');\n } else {\n swiper.autoplay.stop();\n }\n }, delay);\n },\n start: function start() {\n var swiper = this;\n if (typeof swiper.autoplay.timeout !== 'undefined') { return false; }\n if (swiper.autoplay.running) { return false; }\n swiper.autoplay.running = true;\n swiper.emit('autoplayStart');\n swiper.autoplay.run();\n return true;\n },\n stop: function stop() {\n var swiper = this;\n if (!swiper.autoplay.running) { return false; }\n if (typeof swiper.autoplay.timeout === 'undefined') { return false; }\n\n if (swiper.autoplay.timeout) {\n clearTimeout(swiper.autoplay.timeout);\n swiper.autoplay.timeout = undefined;\n }\n swiper.autoplay.running = false;\n swiper.emit('autoplayStop');\n return true;\n },\n pause: function pause(speed) {\n var swiper = this;\n if (!swiper.autoplay.running) { return; }\n if (swiper.autoplay.paused) { return; }\n if (swiper.autoplay.timeout) { clearTimeout(swiper.autoplay.timeout); }\n swiper.autoplay.paused = true;\n if (speed === 0 || !swiper.params.autoplay.waitForTransition) {\n swiper.autoplay.paused = false;\n swiper.autoplay.run();\n } else {\n swiper.$wrapperEl[0].addEventListener('transitionend', swiper.autoplay.onTransitionEnd);\n swiper.$wrapperEl[0].addEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd);\n }\n },\n };\n\n var Autoplay$1 = {\n name: 'autoplay',\n params: {\n autoplay: {\n enabled: false,\n delay: 3000,\n waitForTransition: true,\n disableOnInteraction: true,\n stopOnLastSlide: false,\n reverseDirection: false,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n autoplay: {\n running: false,\n paused: false,\n run: Autoplay.run.bind(swiper),\n start: Autoplay.start.bind(swiper),\n stop: Autoplay.stop.bind(swiper),\n pause: Autoplay.pause.bind(swiper),\n onTransitionEnd: function onTransitionEnd(e) {\n if (!swiper || swiper.destroyed || !swiper.$wrapperEl) { return; }\n if (e.target !== this) { return; }\n swiper.$wrapperEl[0].removeEventListener('transitionend', swiper.autoplay.onTransitionEnd);\n swiper.$wrapperEl[0].removeEventListener('webkitTransitionEnd', swiper.autoplay.onTransitionEnd);\n swiper.autoplay.paused = false;\n if (!swiper.autoplay.running) {\n swiper.autoplay.stop();\n } else {\n swiper.autoplay.run();\n }\n },\n },\n });\n },\n on: {\n init: function init() {\n var swiper = this;\n if (swiper.params.autoplay.enabled) {\n swiper.autoplay.start();\n }\n },\n beforeTransitionStart: function beforeTransitionStart(speed, internal) {\n var swiper = this;\n if (swiper.autoplay.running) {\n if (internal || !swiper.params.autoplay.disableOnInteraction) {\n swiper.autoplay.pause(speed);\n } else {\n swiper.autoplay.stop();\n }\n }\n },\n sliderFirstMove: function sliderFirstMove() {\n var swiper = this;\n if (swiper.autoplay.running) {\n if (swiper.params.autoplay.disableOnInteraction) {\n swiper.autoplay.stop();\n } else {\n swiper.autoplay.pause();\n }\n }\n },\n destroy: function destroy() {\n var swiper = this;\n if (swiper.autoplay.running) {\n swiper.autoplay.stop();\n }\n },\n },\n };\n\n var Fade = {\n setTranslate: function setTranslate() {\n var swiper = this;\n var slides = swiper.slides;\n for (var i = 0; i < slides.length; i += 1) {\n var $slideEl = swiper.slides.eq(i);\n var offset = $slideEl[0].swiperSlideOffset;\n var tx = -offset;\n if (!swiper.params.virtualTranslate) { tx -= swiper.translate; }\n var ty = 0;\n if (!swiper.isHorizontal()) {\n ty = tx;\n tx = 0;\n }\n var slideOpacity = swiper.params.fadeEffect.crossFade ?\n Math.max(1 - Math.abs($slideEl[0].progress), 0) :\n 1 + Math.min(Math.max($slideEl[0].progress, -1), 0);\n $slideEl\n .css({\n opacity: slideOpacity,\n })\n .transform((\"translate3d(\" + tx + \"px, \" + ty + \"px, 0px)\"));\n }\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n var slides = swiper.slides;\n var $wrapperEl = swiper.$wrapperEl;\n slides.transition(duration);\n if (swiper.params.virtualTranslate && duration !== 0) {\n var eventTriggered = false;\n slides.transitionEnd(function () {\n if (eventTriggered) { return; }\n if (!swiper || swiper.destroyed) { return; }\n eventTriggered = true;\n swiper.animating = false;\n var triggerEvents = ['webkitTransitionEnd', 'transitionend'];\n for (var i = 0; i < triggerEvents.length; i += 1) {\n $wrapperEl.trigger(triggerEvents[i]);\n }\n });\n }\n },\n };\n\n var EffectFade = {\n name: 'effect-fade',\n params: {\n fadeEffect: {\n crossFade: false,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n fadeEffect: {\n setTranslate: Fade.setTranslate.bind(swiper),\n setTransition: Fade.setTransition.bind(swiper),\n },\n });\n },\n on: {\n beforeInit: function beforeInit() {\n var swiper = this;\n if (swiper.params.effect !== 'fade') { return; }\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"fade\"));\n var overwriteParams = {\n slidesPerView: 1,\n slidesPerColumn: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n spaceBetween: 0,\n virtualTranslate: true,\n };\n Utils.extend(swiper.params, overwriteParams);\n Utils.extend(swiper.originalParams, overwriteParams);\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n if (swiper.params.effect !== 'fade') { return; }\n swiper.fadeEffect.setTranslate();\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n if (swiper.params.effect !== 'fade') { return; }\n swiper.fadeEffect.setTransition(duration);\n },\n },\n };\n\n var Cube = {\n setTranslate: function setTranslate() {\n var swiper = this;\n var $el = swiper.$el;\n var $wrapperEl = swiper.$wrapperEl;\n var slides = swiper.slides;\n var swiperWidth = swiper.width;\n var swiperHeight = swiper.height;\n var rtl = swiper.rtlTranslate;\n var swiperSize = swiper.size;\n var params = swiper.params.cubeEffect;\n var isHorizontal = swiper.isHorizontal();\n var isVirtual = swiper.virtual && swiper.params.virtual.enabled;\n var wrapperRotate = 0;\n var $cubeShadowEl;\n if (params.shadow) {\n if (isHorizontal) {\n $cubeShadowEl = $wrapperEl.find('.swiper-cube-shadow');\n if ($cubeShadowEl.length === 0) {\n $cubeShadowEl = $('
    ');\n $wrapperEl.append($cubeShadowEl);\n }\n $cubeShadowEl.css({ height: (swiperWidth + \"px\") });\n } else {\n $cubeShadowEl = $el.find('.swiper-cube-shadow');\n if ($cubeShadowEl.length === 0) {\n $cubeShadowEl = $('
    ');\n $el.append($cubeShadowEl);\n }\n }\n }\n for (var i = 0; i < slides.length; i += 1) {\n var $slideEl = slides.eq(i);\n var slideIndex = i;\n if (isVirtual) {\n slideIndex = parseInt($slideEl.attr('data-swiper-slide-index'), 10);\n }\n var slideAngle = slideIndex * 90;\n var round = Math.floor(slideAngle / 360);\n if (rtl) {\n slideAngle = -slideAngle;\n round = Math.floor(-slideAngle / 360);\n }\n var progress = Math.max(Math.min($slideEl[0].progress, 1), -1);\n var tx = 0;\n var ty = 0;\n var tz = 0;\n if (slideIndex % 4 === 0) {\n tx = -round * 4 * swiperSize;\n tz = 0;\n } else if ((slideIndex - 1) % 4 === 0) {\n tx = 0;\n tz = -round * 4 * swiperSize;\n } else if ((slideIndex - 2) % 4 === 0) {\n tx = swiperSize + (round * 4 * swiperSize);\n tz = swiperSize;\n } else if ((slideIndex - 3) % 4 === 0) {\n tx = -swiperSize;\n tz = (3 * swiperSize) + (swiperSize * 4 * round);\n }\n if (rtl) {\n tx = -tx;\n }\n\n if (!isHorizontal) {\n ty = tx;\n tx = 0;\n }\n\n var transform = \"rotateX(\" + (isHorizontal ? 0 : -slideAngle) + \"deg) rotateY(\" + (isHorizontal ? slideAngle : 0) + \"deg) translate3d(\" + tx + \"px, \" + ty + \"px, \" + tz + \"px)\";\n if (progress <= 1 && progress > -1) {\n wrapperRotate = (slideIndex * 90) + (progress * 90);\n if (rtl) { wrapperRotate = (-slideIndex * 90) - (progress * 90); }\n }\n $slideEl.transform(transform);\n if (params.slideShadows) {\n // Set shadows\n var shadowBefore = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top');\n var shadowAfter = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom');\n if (shadowBefore.length === 0) {\n shadowBefore = $((\"
    \"));\n $slideEl.append(shadowBefore);\n }\n if (shadowAfter.length === 0) {\n shadowAfter = $((\"
    \"));\n $slideEl.append(shadowAfter);\n }\n if (shadowBefore.length) { shadowBefore[0].style.opacity = Math.max(-progress, 0); }\n if (shadowAfter.length) { shadowAfter[0].style.opacity = Math.max(progress, 0); }\n }\n }\n $wrapperEl.css({\n '-webkit-transform-origin': (\"50% 50% -\" + (swiperSize / 2) + \"px\"),\n '-moz-transform-origin': (\"50% 50% -\" + (swiperSize / 2) + \"px\"),\n '-ms-transform-origin': (\"50% 50% -\" + (swiperSize / 2) + \"px\"),\n 'transform-origin': (\"50% 50% -\" + (swiperSize / 2) + \"px\"),\n });\n\n if (params.shadow) {\n if (isHorizontal) {\n $cubeShadowEl.transform((\"translate3d(0px, \" + ((swiperWidth / 2) + params.shadowOffset) + \"px, \" + (-swiperWidth / 2) + \"px) rotateX(90deg) rotateZ(0deg) scale(\" + (params.shadowScale) + \")\"));\n } else {\n var shadowAngle = Math.abs(wrapperRotate) - (Math.floor(Math.abs(wrapperRotate) / 90) * 90);\n var multiplier = 1.5 - (\n (Math.sin((shadowAngle * 2 * Math.PI) / 360) / 2) +\n (Math.cos((shadowAngle * 2 * Math.PI) / 360) / 2)\n );\n var scale1 = params.shadowScale;\n var scale2 = params.shadowScale / multiplier;\n var offset = params.shadowOffset;\n $cubeShadowEl.transform((\"scale3d(\" + scale1 + \", 1, \" + scale2 + \") translate3d(0px, \" + ((swiperHeight / 2) + offset) + \"px, \" + (-swiperHeight / 2 / scale2) + \"px) rotateX(-90deg)\"));\n }\n }\n var zFactor = (Browser.isSafari || Browser.isUiWebView) ? (-swiperSize / 2) : 0;\n $wrapperEl\n .transform((\"translate3d(0px,0,\" + zFactor + \"px) rotateX(\" + (swiper.isHorizontal() ? 0 : wrapperRotate) + \"deg) rotateY(\" + (swiper.isHorizontal() ? -wrapperRotate : 0) + \"deg)\"));\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n var $el = swiper.$el;\n var slides = swiper.slides;\n slides\n .transition(duration)\n .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .transition(duration);\n if (swiper.params.cubeEffect.shadow && !swiper.isHorizontal()) {\n $el.find('.swiper-cube-shadow').transition(duration);\n }\n },\n };\n\n var EffectCube = {\n name: 'effect-cube',\n params: {\n cubeEffect: {\n slideShadows: true,\n shadow: true,\n shadowOffset: 20,\n shadowScale: 0.94,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n cubeEffect: {\n setTranslate: Cube.setTranslate.bind(swiper),\n setTransition: Cube.setTransition.bind(swiper),\n },\n });\n },\n on: {\n beforeInit: function beforeInit() {\n var swiper = this;\n if (swiper.params.effect !== 'cube') { return; }\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"cube\"));\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"3d\"));\n var overwriteParams = {\n slidesPerView: 1,\n slidesPerColumn: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n resistanceRatio: 0,\n spaceBetween: 0,\n centeredSlides: false,\n virtualTranslate: true,\n };\n Utils.extend(swiper.params, overwriteParams);\n Utils.extend(swiper.originalParams, overwriteParams);\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n if (swiper.params.effect !== 'cube') { return; }\n swiper.cubeEffect.setTranslate();\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n if (swiper.params.effect !== 'cube') { return; }\n swiper.cubeEffect.setTransition(duration);\n },\n },\n };\n\n var Flip = {\n setTranslate: function setTranslate() {\n var swiper = this;\n var slides = swiper.slides;\n var rtl = swiper.rtlTranslate;\n for (var i = 0; i < slides.length; i += 1) {\n var $slideEl = slides.eq(i);\n var progress = $slideEl[0].progress;\n if (swiper.params.flipEffect.limitRotation) {\n progress = Math.max(Math.min($slideEl[0].progress, 1), -1);\n }\n var offset = $slideEl[0].swiperSlideOffset;\n var rotate = -180 * progress;\n var rotateY = rotate;\n var rotateX = 0;\n var tx = -offset;\n var ty = 0;\n if (!swiper.isHorizontal()) {\n ty = tx;\n tx = 0;\n rotateX = -rotateY;\n rotateY = 0;\n } else if (rtl) {\n rotateY = -rotateY;\n }\n\n $slideEl[0].style.zIndex = -Math.abs(Math.round(progress)) + slides.length;\n\n if (swiper.params.flipEffect.slideShadows) {\n // Set shadows\n var shadowBefore = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top');\n var shadowAfter = swiper.isHorizontal() ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom');\n if (shadowBefore.length === 0) {\n shadowBefore = $((\"
    \"));\n $slideEl.append(shadowBefore);\n }\n if (shadowAfter.length === 0) {\n shadowAfter = $((\"
    \"));\n $slideEl.append(shadowAfter);\n }\n if (shadowBefore.length) { shadowBefore[0].style.opacity = Math.max(-progress, 0); }\n if (shadowAfter.length) { shadowAfter[0].style.opacity = Math.max(progress, 0); }\n }\n $slideEl\n .transform((\"translate3d(\" + tx + \"px, \" + ty + \"px, 0px) rotateX(\" + rotateX + \"deg) rotateY(\" + rotateY + \"deg)\"));\n }\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n var slides = swiper.slides;\n var activeIndex = swiper.activeIndex;\n var $wrapperEl = swiper.$wrapperEl;\n slides\n .transition(duration)\n .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .transition(duration);\n if (swiper.params.virtualTranslate && duration !== 0) {\n var eventTriggered = false;\n // eslint-disable-next-line\n slides.eq(activeIndex).transitionEnd(function onTransitionEnd() {\n if (eventTriggered) { return; }\n if (!swiper || swiper.destroyed) { return; }\n // if (!$(this).hasClass(swiper.params.slideActiveClass)) return;\n eventTriggered = true;\n swiper.animating = false;\n var triggerEvents = ['webkitTransitionEnd', 'transitionend'];\n for (var i = 0; i < triggerEvents.length; i += 1) {\n $wrapperEl.trigger(triggerEvents[i]);\n }\n });\n }\n },\n };\n\n var EffectFlip = {\n name: 'effect-flip',\n params: {\n flipEffect: {\n slideShadows: true,\n limitRotation: true,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n flipEffect: {\n setTranslate: Flip.setTranslate.bind(swiper),\n setTransition: Flip.setTransition.bind(swiper),\n },\n });\n },\n on: {\n beforeInit: function beforeInit() {\n var swiper = this;\n if (swiper.params.effect !== 'flip') { return; }\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"flip\"));\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"3d\"));\n var overwriteParams = {\n slidesPerView: 1,\n slidesPerColumn: 1,\n slidesPerGroup: 1,\n watchSlidesProgress: true,\n spaceBetween: 0,\n virtualTranslate: true,\n };\n Utils.extend(swiper.params, overwriteParams);\n Utils.extend(swiper.originalParams, overwriteParams);\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n if (swiper.params.effect !== 'flip') { return; }\n swiper.flipEffect.setTranslate();\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n if (swiper.params.effect !== 'flip') { return; }\n swiper.flipEffect.setTransition(duration);\n },\n },\n };\n\n var Coverflow = {\n setTranslate: function setTranslate() {\n var swiper = this;\n var swiperWidth = swiper.width;\n var swiperHeight = swiper.height;\n var slides = swiper.slides;\n var $wrapperEl = swiper.$wrapperEl;\n var slidesSizesGrid = swiper.slidesSizesGrid;\n var params = swiper.params.coverflowEffect;\n var isHorizontal = swiper.isHorizontal();\n var transform = swiper.translate;\n var center = isHorizontal ? -transform + (swiperWidth / 2) : -transform + (swiperHeight / 2);\n var rotate = isHorizontal ? params.rotate : -params.rotate;\n var translate = params.depth;\n // Each slide offset from center\n for (var i = 0, length = slides.length; i < length; i += 1) {\n var $slideEl = slides.eq(i);\n var slideSize = slidesSizesGrid[i];\n var slideOffset = $slideEl[0].swiperSlideOffset;\n var offsetMultiplier = ((center - slideOffset - (slideSize / 2)) / slideSize) * params.modifier;\n\n var rotateY = isHorizontal ? rotate * offsetMultiplier : 0;\n var rotateX = isHorizontal ? 0 : rotate * offsetMultiplier;\n // var rotateZ = 0\n var translateZ = -translate * Math.abs(offsetMultiplier);\n\n var translateY = isHorizontal ? 0 : params.stretch * (offsetMultiplier);\n var translateX = isHorizontal ? params.stretch * (offsetMultiplier) : 0;\n\n // Fix for ultra small values\n if (Math.abs(translateX) < 0.001) { translateX = 0; }\n if (Math.abs(translateY) < 0.001) { translateY = 0; }\n if (Math.abs(translateZ) < 0.001) { translateZ = 0; }\n if (Math.abs(rotateY) < 0.001) { rotateY = 0; }\n if (Math.abs(rotateX) < 0.001) { rotateX = 0; }\n\n var slideTransform = \"translate3d(\" + translateX + \"px,\" + translateY + \"px,\" + translateZ + \"px) rotateX(\" + rotateX + \"deg) rotateY(\" + rotateY + \"deg)\";\n\n $slideEl.transform(slideTransform);\n $slideEl[0].style.zIndex = -Math.abs(Math.round(offsetMultiplier)) + 1;\n if (params.slideShadows) {\n // Set shadows\n var $shadowBeforeEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-left') : $slideEl.find('.swiper-slide-shadow-top');\n var $shadowAfterEl = isHorizontal ? $slideEl.find('.swiper-slide-shadow-right') : $slideEl.find('.swiper-slide-shadow-bottom');\n if ($shadowBeforeEl.length === 0) {\n $shadowBeforeEl = $((\"
    \"));\n $slideEl.append($shadowBeforeEl);\n }\n if ($shadowAfterEl.length === 0) {\n $shadowAfterEl = $((\"
    \"));\n $slideEl.append($shadowAfterEl);\n }\n if ($shadowBeforeEl.length) { $shadowBeforeEl[0].style.opacity = offsetMultiplier > 0 ? offsetMultiplier : 0; }\n if ($shadowAfterEl.length) { $shadowAfterEl[0].style.opacity = (-offsetMultiplier) > 0 ? -offsetMultiplier : 0; }\n }\n }\n\n // Set correct perspective for IE10\n if (Support.pointerEvents || Support.prefixedPointerEvents) {\n var ws = $wrapperEl[0].style;\n ws.perspectiveOrigin = center + \"px 50%\";\n }\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n swiper.slides\n .transition(duration)\n .find('.swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left')\n .transition(duration);\n },\n };\n\n var EffectCoverflow = {\n name: 'effect-coverflow',\n params: {\n coverflowEffect: {\n rotate: 50,\n stretch: 0,\n depth: 100,\n modifier: 1,\n slideShadows: true,\n },\n },\n create: function create() {\n var swiper = this;\n Utils.extend(swiper, {\n coverflowEffect: {\n setTranslate: Coverflow.setTranslate.bind(swiper),\n setTransition: Coverflow.setTransition.bind(swiper),\n },\n });\n },\n on: {\n beforeInit: function beforeInit() {\n var swiper = this;\n if (swiper.params.effect !== 'coverflow') { return; }\n\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"coverflow\"));\n swiper.classNames.push(((swiper.params.containerModifierClass) + \"3d\"));\n\n swiper.params.watchSlidesProgress = true;\n swiper.originalParams.watchSlidesProgress = true;\n },\n setTranslate: function setTranslate() {\n var swiper = this;\n if (swiper.params.effect !== 'coverflow') { return; }\n swiper.coverflowEffect.setTranslate();\n },\n setTransition: function setTransition(duration) {\n var swiper = this;\n if (swiper.params.effect !== 'coverflow') { return; }\n swiper.coverflowEffect.setTransition(duration);\n },\n },\n };\n\n // Swiper Class\n\n var components = [\n Device$1,\n Support$1,\n Browser$1,\n Resize,\n Observer$1,\n Virtual$1,\n Keyboard$1,\n Mousewheel$1,\n Navigation$1,\n Pagination$1,\n Scrollbar$1,\n Parallax$1,\n Zoom$1,\n Lazy$1,\n Controller$1,\n A11y,\n History$1,\n HashNavigation$1,\n Autoplay$1,\n EffectFade,\n EffectCube,\n EffectFlip,\n EffectCoverflow\n ];\n\n if (typeof Swiper.use === 'undefined') {\n Swiper.use = Swiper.Class.use;\n Swiper.installModule = Swiper.Class.installModule;\n }\n\n Swiper.use(components);\n\n return Swiper;\n\n})));\n"]} \ No newline at end of file diff --git a/user/config/config.php b/user/config/config.php index b69eb1c..aa5dc2f 100644 --- a/user/config/config.php +++ b/user/config/config.php @@ -1,5 +1,5 @@ 'function/profile,function/organization', + //'libfile'=>'function/profile,function/organization', 'default_mod'=>'space', ); \ No newline at end of file diff --git a/user/register/classes/regcommon.php b/user/register/classes/regcommon.php index d374c0a..b7c0dac 100644 --- a/user/register/classes/regcommon.php +++ b/user/register/classes/regcommon.php @@ -12,7 +12,7 @@ class Regcommon{ $type = isset($_GET['returnType']) ? $_GET['returnType']:''; //执行注册 - $result =C::t('user')->user_register($params,0); + $result =C::t('user')->user_register($params); //获取注册状态 $uid= is_array($result) ? $result['uid']:$result;
    checked="checked"value="1"> checked="checked"value="1"> - +      - +