diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index 4716b45..0000000 --- a/Dockerfile +++ /dev/null @@ -1,26 +0,0 @@ -FROM node:6.3.1 - -# -# RUN uname -a - -# Timezone Setting -# Ubuntu -RUN cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime -# CentOS -# RUN echo "Asia/shanghai" > /etc/timezone; - -RUN mkdir -p /usr/src/app -WORKDIR /usr/src/app -COPY package.json /usr/src/app/ - -RUN npm i -g supervisor -RUN npm i - -COPY . /usr/src/app - -ENV PORT 80 -EXPOSE 80 - -# ENTRYPOINT ["node", "app.js"] -# CMD forever start --minUptime 1000 --spinSleepTime 1000 app.js -CMD supervisor node ./bin/www \ No newline at end of file diff --git a/app.js b/app.js index 7776b02..4f07b54 100644 --- a/app.js +++ b/app.js @@ -7,7 +7,9 @@ var bodyParser = require('body-parser'); var session = require('express-session'); var request = require('superagent'); var index = require('./routes/index'); +var photo = require('./routes/photo'); var weibo = require('./routes/weibo'); +var ranking = require('./routes/ranking'); var v1 = require('./routes/v1'); // 定时器 @@ -19,6 +21,7 @@ var bingUtils = require('./utils/bingUtils'); var mailUtils = require('./utils/mailUtils'); var qiniuUtils = require('./utils/qiniuUtils'); var weiboUtils = require('./utils/weiboUtils'); +var config = require('./configs/config'); var app = express(); app.disable('x-powered-by'); @@ -48,34 +51,34 @@ app.use(logger('combined', { })); // 每天 00:00,00:10,00:20 检测bing数据 -schedule.scheduleJob('0 0,5,10,20,25,30 0 * * *', function() { - var date = new Date(); - var year = date.getFullYear(); - var month = date.getMonth() + 1; - var day = date.getDate(); - var now = year + '' + (month < 10 ? '0' + month : month) + '' + (day < 10 ? '0' + day : day); - // 查询是否已经抓取并插入数据库,如果已插入就不重复抓取 - dbUtils.get('bing', { - body: { - enddate: now - } - }, function(rows) { - if (rows.length === 0) { - bingUtils.fetchPicture({}, function(data) { - dbUtils.set('bing', data, function(rows) { - data.id = rows.insertId || 0; - mailUtils.send({ - message: '从Bing抓取成功', - title: '从Bing抓取成功', - stack: JSON.stringify(data, '', 4) - }); - }) - }); - } - }); -}); +// schedule.scheduleJob('0 0,5,10,20,25,30 0 * * *', function() { +// var date = new Date(); +// var year = date.getFullYear(); +// var month = date.getMonth() + 1; +// var day = date.getDate(); +// var now = year + '' + (month < 10 ? '0' + month : month) + '' + (day < 10 ? '0' + day : day); +// // 查询是否已经抓取并插入数据库,如果已插入就不重复抓取 +// dbUtils.get('bing', { +// body: { +// enddate: now +// } +// }, function(rows) { +// if (rows.length === 0) { +// bingUtils.fetchPicture({}, function(data) { +// dbUtils.set('bing', data, function(rows) { +// data.id = rows.insertId || 0; +// mailUtils.send({ +// message: '从Bing抓取成功', +// title: '从Bing抓取成功', +// stack: JSON.stringify(data, '', 4) +// }); +// }) +// }); +// } +// }); +// }); // 每天 08:30,12:30,15:30,18:30,21:30 定时发送微博 -schedule.scheduleJob('0 30 8,12,15,18,21 * * *', function() { +schedule.scheduleJob('*/30 8-21 * * *', function() { weiboUtils.update(function(data) { if (data && data.id) { mailUtils.send({ @@ -94,47 +97,74 @@ schedule.scheduleJob('0 30 8,12,15,18,21 * * *', function() { }); // 每隔五分钟检查数据库中是否存在未上传到骑牛的图片,如果存在则上传图片到骑牛 -schedule.scheduleJob('0 1,6,11,16,21,26,31 0 * * *', function() { - dbUtils.get('bing', 'ISNULL(qiniu_url) || qiniu_url=""', function(rows) { - if (rows.length > 0) { - var data = rows[0]; - var url = data.url; - qiniuUtils.fetchToQiniu(url, function() { - var _temp = url.substr(url.lastIndexOf('/') + 1, url.length); - var qiniu_url = _temp.substr(0, _temp.lastIndexOf('_')); - dbUtils.update('bing', { - body: { - qiniu_url: qiniu_url - }, - condition: { - id: data.id - } - }, function(rs) { - // nsole.log(rs); - }); - }); - } - }); -}) +// schedule.scheduleJob('*/1 * * * *', function() { +// dbUtils.get('bing', 'ISNULL(qiniu_url) || qiniu_url=""', function(rows) { +// if (rows.length > 0) { +// var data = rows[0]; +// var url = data.url; +// qiniuUtils.fetchToQiniu(url, function() { +// var _temp = url.substr(url.lastIndexOf('/') + 1, url.length); +// var qiniu_url = _temp.substr(0, _temp.lastIndexOf('_')); +// dbUtils.update('bing', { +// body: { +// qiniu_url: qiniu_url +// }, +// condition: { +// id: data.id +// } +// }, function(rs) { +// // nsole.log(rs); +// }); +// }); +// } +// }); +// }) /** * 处理OPTIONS请求 */ app.use(function(req, res, next) { + console.log('-----------------------------') + console.log(req.headers['host']) + console.log(req.headers['referer']) + console.log('-----------------------------') + if (config.disabled.indexOf(req.headers['host']) > -1) { + res.sendStatus(400) + } // if (req.method === 'OPTIONS') { res.sendStatus(200); } else next(); }); +// var images = [ +// 'MangroveRoots_ZH-CN10720576635', +// 'IzmirFaceWall_ZH-CN8661261728', +// 'CapeSebastian_ZH-CN9469145123', +// 'FireEscapes_ZH-CN9251582421', +// 'LaurelMoss_ZH-CN9578543974' +// ]; + +// var resolutions = require('./configs/config').resolutions; +// for (var i in images) { +// var name = images[i]; +// var link = `http://images.ioliu.cn/bing/${name}_1920x1080.jpg`; +// qiniuUtils.specialFetchToQiniu(link); +// } + app.use('/', index); +app.use('/photo', photo); app.use('/weibo', weibo); +app.use('/ranking', ranking); app.use('/v1', v1); +app.get('/about.html', function(req, res, next) { + res.render('about'); +}); /** * Robots.txt */ -app.use('/robots.txt', function(req, res, next) { +app.get('/robots.txt', function(req, res, next) { res.header('content-type', 'text/plain'); res.send('User-Agent: * \nAllow: /'); }); @@ -153,9 +183,11 @@ app.get('/test', function(req, res, next) { // catch 404 and forward to error handler app.use(function(req, res, next) { - var err = new Error('啊( ⊙ o ⊙ ),你发现了新大陆 ∑(っ °Д °;)っ'); - err.status = 404; - next(err); + // var err = new Error('啊( ⊙ o ⊙ ),你发现了新大陆 ∑(っ °Д °;)っ'); + // err.status = 404; + // next(err); + + res.redirect('/'); }); // error handlers // development error handler diff --git a/bin/www b/bin/www index 4174cd5..7bf22e7 100644 --- a/bin/www +++ b/bin/www @@ -15,7 +15,7 @@ var http = require('http'); * Get port from environment and store in Express. */ -var port = normalizePort(process.env.PORT || '1001'); +var port = normalizePort(process.env.PORT || '999'); app.set('port', port); /** diff --git a/configs/config.js b/configs/config.js index 0ae2465..0a4cdd0 100644 --- a/configs/config.js +++ b/configs/config.js @@ -9,15 +9,16 @@ module.exports = { }, mysql_dev: { host: process.env.mysql_host, + database: process.env.mysql_database, user: process.env.mysql_user, password: process.env.mysql_password, port: '3306', - database: process.env.mysql_database, connectionLimit: 10, supportBigNumbers: true, multipleStatements: true, insecureAuth: true }, + disabled: [process.env.disabled.split(',')], /** * 已知分辨率 */ @@ -26,17 +27,33 @@ module.exports = { '1920x1080', '1366x768', '1280x768', + '1080x1920', '1024x768', '800x600', '800x480', + '768x1366', '768x1280', + '768x1024', '720x1280', '640x480', + '640x360', '480x800', '400x240', '320x240', - '240x320' - ] + '320x180', + '240x400', + '240x320', + '240x240', + '200x200', + '150x150' + ], + + global_link: function() { + return Math.random() > 0.5 ? 'https://static.ioliu.cn' : 'https://bing-images.bitmoe.cn'; + }, + global_http: function() { + return Math.random() > 0.5 ? 'http://static.ioliu.cn' : 'http://bing-images.bitmoe.cn'; + } } \ No newline at end of file diff --git a/db/bing.sql b/db/bing.sql new file mode 100644 index 0000000..d364a6b --- /dev/null +++ b/db/bing.sql @@ -0,0 +1,35 @@ +SET FOREIGN_KEY_CHECKS=0; + +-- ---------------------------- +-- Table structure for bing +-- ---------------------------- +DROP TABLE IF EXISTS `bing`; +CREATE TABLE `bing` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `title` varchar(100) DEFAULT NULL, + `attribute` varchar(100) DEFAULT NULL, + `description` varchar(500) DEFAULT NULL, + `copyright` varchar(500) NOT NULL DEFAULT '0', + `copyrightlink` varchar(500) NOT NULL DEFAULT '0', + `startdate` varchar(50) NOT NULL DEFAULT '0', + `enddate` varchar(50) NOT NULL DEFAULT '0', + `fullstartdate` varchar(50) NOT NULL DEFAULT '0', + `url` varchar(500) NOT NULL DEFAULT '0', + `urlbase` varchar(500) NOT NULL DEFAULT '0', + `hsh` varchar(500) NOT NULL DEFAULT '0', + `qiniu_url` varchar(100) DEFAULT NULL, + `longitude` varchar(500) DEFAULT NULL COMMENT '经度', + `latitude` varchar(500) DEFAULT NULL COMMENT '纬度', + `city` varchar(500) DEFAULT NULL COMMENT '城市', + `country` varchar(255) DEFAULT NULL COMMENT '国家', + `continent` varchar(255) DEFAULT NULL COMMENT '洲/大陆', + `thumbnail_pic` varchar(255) DEFAULT NULL COMMENT '缩略图', + `bmiddle_pic` varchar(255) DEFAULT NULL COMMENT '中等大小图', + `original_pic` varchar(255) CHARACTER SET utf8 COLLATE utf8_bin DEFAULT NULL COMMENT '原图', + `weibo` int(1) unsigned zerofill NOT NULL DEFAULT '0' COMMENT '是否发送微博,默认0', + `likes` int(11) unsigned DEFAULT '0' COMMENT '喜欢量', + `views` int(11) unsigned DEFAULT '0' COMMENT '展现量', + `downloads` int(11) unsigned DEFAULT '0' COMMENT '下载量', + PRIMARY KEY (`id`), + KEY `id-title-attribute-qiniu_url` (`id`,`title`,`attribute`,`qiniu_url`) USING BTREE +) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; diff --git a/db/bing_session.sql b/db/bing_session.sql new file mode 100644 index 0000000..2307801 --- /dev/null +++ b/db/bing_session.sql @@ -0,0 +1,15 @@ + +SET FOREIGN_KEY_CHECKS=0; + +-- ---------------------------- +-- Table structure for bing_session +-- ---------------------------- +DROP TABLE IF EXISTS `bing_session`; +CREATE TABLE `bing_session` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `token` varchar(255) NOT NULL, + `expires_in` int(200) NOT NULL COMMENT '过期时间', + `insertdate` int(200) NOT NULL COMMENT '插入时间', + `uid` varchar(200) NOT NULL, + PRIMARY KEY (`id`) +) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; diff --git a/package.json b/package.json index 0bb3517..466e620 100644 --- a/package.json +++ b/package.json @@ -1,46 +1,46 @@ -{ - "name": "bing", - "version": "1.0.0", - "private": true, - "scripts": { - "start": "supervisor node ./bin/www" - }, - "author": { - "name": "xCss", - "mail": "xioveliu@gmail.com" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/xCss/bing.git" - }, - "keywords": [ - "Bing", - "BingPicture API", - "必应图片", - "必应壁纸接口" - ], - "bugs": { - "url": "https://github.com/xCss/bing/issues" - }, - "readme": "./readme.md", - "homepage": "https://github.com/xCss/bing#readme", - "dependencies": { - "bluebird": "^3.4.6", - "body-parser": "~1.15.1", - "cookie-parser": "~1.4.3", - "debug": "~2.2.0", - "express": "~4.13.4", - "express-flash": "0.0.2", - "express-session": "^1.14.1", - "helmet": "^2.3.0", - "morgan": "~1.7.0", - "mysql": "^2.11.1", - "node-schedule": "^1.2.0", - "nodemailer": "^0.7.1", - "object-assign": "^4.1.0", - "pug": "^2.0.0-beta6", - "qiniu": "^6.1.13", - "serve-favicon": "~2.3.0", - "superagent": "^2.3.0" - } -} \ No newline at end of file +{ + "name": "bing", + "version": "1.0.0", + "private": true, + "scripts": { + "start": "supervisor node ./bin/www" + }, + "author": { + "name": "xCss", + "mail": "xioveliu@gmail.com" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/xCss/bing.git" + }, + "keywords": [ + "Bing", + "BingPicture API", + "必应图片", + "必应壁纸接口" + ], + "bugs": { + "url": "https://github.com/xCss/bing/issues" + }, + "readme": "./readme.md", + "homepage": "https://github.com/xCss/bing#readme", + "dependencies": { + "body-parser": "~1.15.1", + "cookie-parser": "~1.4.3", + "debug": "~2.2.0", + "express": "~4.13.4", + "express-flash": "0.0.2", + "express-session": "^1.14.1", + "helmet": "^2.3.0", + "moment": "^2.18.1", + "morgan": "~1.7.0", + "mysql": "^2.11.1", + "node-schedule": "^1.2.0", + "nodemailer": "^0.7.1", + "object-assign": "^4.1.0", + "pug": "^2.0.0-beta6", + "qiniu": "^6.1.13", + "serve-favicon": "~2.3.0", + "superagent": "^2.3.0" + } +} diff --git a/robots.txt b/robots.txt new file mode 100644 index 0000000..301e448 --- /dev/null +++ b/robots.txt @@ -0,0 +1,2 @@ +User-Agent: * +Allow: / \ No newline at end of file diff --git a/routes/index.js b/routes/index.js index c0c38dc..2618e17 100644 --- a/routes/index.js +++ b/routes/index.js @@ -1,55 +1,78 @@ var express = require('express'); var dbUtils = require('../utils/dbUtils'); var qiniuUtils = require('../utils/qiniuUtils'); +var config = require('../configs/config'); var router = express.Router(); /* GET home page. */ router.get('/', function(req, res, next) { - var no = req.query.p; - var id = req.query.id; - no = !!no && Number(no) > 0 ? Number(no) : 1; - var params = { - body: '!ISNULL(qiniu_url) || qiniu_url<>""', - page: { - no: no, - size: 10 - } - }; - if (!!id && Number(id) > 0) { - params['body'] = 'id<=' + id; - dbUtils.get('bing', params, function(rows) { + var isAjax = !!req.headers['x-requested-with']; + var pageNo = req.query.p; + pageNo = !!pageNo && Number(pageNo) > 0 ? Number(pageNo) : 1; + var pageSize = 12; // pageSize + dbUtils.commonQuery(`select count(0) as sum from bing where (!ISNULL(qiniu_url) || qiniu_url<>"") and mkt like '%zh-cn%'`, function(rows) { + var count = rows[0]['sum'] || 0; + if (count > 0) { var page = { - prev: 1, - next: 2, - curr: rows.length > 0 && rows[0]['title'] || '首页', - desc: rows.length > 0 && rows[0]['description'] || '' - }; - common(req, res, next, page, rows); - }); - } else { - dbUtils.getCount('bing', params.body, function(r) { - var sum = r[0]['sum'] || 0; - var size = params.page.size; - if (sum > 0) { - var page = { - size: size, - no: no > Math.ceil(sum / size) ? Math.ceil(sum / size) : no, - sum: sum, - next: no + 1 > Math.ceil(sum / size) ? Math.ceil(sum / size) : no + 1, - prev: no - 1 >= 0 ? ((no - 1) > Math.ceil(sum / size) ? Math.ceil(sum / size) - 1 : no - 1) : 1, - curr: no <= 1 ? '首页' : '第 ' + no + ' 页' - }; - params['page'] = page; - dbUtils.get('bing', params, function(rows) { - common(req, res, next, page, rows); - }); - } else { - var err = new Error('啊( ⊙ o ⊙ ),你发现了新大陆 ∑(っ °Д °;)っ'); - err.status = 404; - next(err); + size: pageSize, + count: count, + pageCount: Math.ceil(count / pageSize), + next: pageNo + 1 > Math.ceil(count / pageSize) ? Math.ceil(count / pageSize) : pageNo + 1, + prev: pageNo - 1 > 0 ? pageNo - 1 : 1, + curr: pageNo > Math.ceil(count / pageSize) ? Math.ceil(count / pageSize) : pageNo, + currText: pageNo === 1 ? '' : '第' + pageNo + '页', + currPage: 'home' } - }); - } - + if (pageNo > page.curr && !isAjax) { + res.redirect(`/?p=${page.curr}`); + } + var sql = `select id,title,attribute,description,copyright,qiniu_url as photo,city,country,continent,DATE_FORMAT(enddate, '%Y-%m-%d') as dt,likes,views,downloads,thumbnail_pic,original_pic from bing + where (!ISNULL(qiniu_url) || qiniu_url<>"") and mkt like '%zh-cn%' + order by id desc + limit ${(page.curr-1)*page.size},${page.size}`; + dbUtils.commonQuery(sql, function(rs) { + if (rs.length > 0) { + var data = []; + for (var i in rs) { + var temp = rs[i]; + /** + * 1024x576 + * 120x67 + */ + var thumbnail = temp['original_pic'] ? temp['original_pic'].replace('http', 'https') : `${config.global_link()}/bing/${temp['photo']}_1920x1080.jpg?imageView2/1/w/1024/h/576/q/100`; + var smallpic = temp['thumbnail_pic'] ? temp['thumbnail_pic'].replace('http', 'https') : `${config.global_link()}/bing/${temp['photo']}_1920x1080.jpg?imageView2/1/w/120/h/67/q/100`; + data.push({ + id: temp['id'], + title: temp['title'], + attribute: temp['attribute'], + description: temp['description'], + copyright: temp['copyright'], + photo: temp['photo'], + city: temp['city'], + country: temp['country'], + continent: temp['continent'], + thumbnail: thumbnail, + smallpic: smallpic, + dt: temp['dt'], + likes: temp['likes'], + views: temp['views'], + downloads: temp['downloads'] + }); + } + if (isAjax) { + res.json({ + doc: data, + page: page + }); + } else { + res.render('index', { + doc: data, + page: page + }); + } + } + }); + } + }); }); var common = function(req, res, next, page, rows) { @@ -66,32 +89,21 @@ var common = function(req, res, next, page, rows) { title: rows[i]['title'], attribute: rows[i]['attribute'], description: rows[i]['description'], - startdate: rows[i]['startdate'], - enddate: rows[i]['enddate'], - fullstartdate: rows[i]['fullstartdate'], - url: rows[i]['url'], - urlbase: rows[i]['urlbase'], copyright: rows[i]['copyright'], - copyrightlink: rows[i]['copyrightlink'], - hsh: rows[i]['hsh'], - qiniu_url: rows[i]['qiniu_url'], - longitude: rows[i]['longitude'], - latitude: rows[i]['latitude'], + photo: rows[i]['qiniu_url'], city: rows[i]['city'], country: rows[i]['country'], continent: rows[i]['continent'], - thumbnail: qiniuUtils.imageView(rows[i]['qiniu_url'], 30, 15), - smallpic: qiniuUtils.imageView(rows[i]['qiniu_url'], 300, 150), - //bmiddle_pic: rows[i]['bmiddle_pic'], - //original_pic: rows[i]['original_pic'], - //weibo: rows[i]['weibo'], - date: full + thumbnail: `${config.global_link()}/bing/${rows[i]['qiniu_url']}_800x600.jpg`, + smallpic: `${config.global_link()}/small/${rows[i]['qiniu_url']}_800x600.jpg`, + date: full, + likes: rows[i]['likes'], + views: rows[i]['views'], + downloads: rows[i]['downloads'] }); } res.render('index', { data: data, - title: '必应壁纸', - description: 'Bing 每日壁纸', page: page }); } else { diff --git a/routes/photo.js b/routes/photo.js new file mode 100644 index 0000000..43a06cd --- /dev/null +++ b/routes/photo.js @@ -0,0 +1,98 @@ +var express = require('express'); +var router = express.Router(); +var request = require('superagent'); +var db = require('../utils/dbUtils'); +var config = require('../configs/config'); + +/* GET photo listing. */ +router.get('/:photo', function(req, res, next) { + var force = req.query.force || ''; + var photo = req.params.photo; + var isAjax = !!req.headers['x-requested-with']; + switch (force) { + case 'like': + if (isAjax) { + var ck = req.cookies['likes'] || ''; + ck = ck.split('_'); + if (ck.indexOf(photo) > -1) { + res.json({ + msg: '', + code: 200 + }); + return; + } + var sql = `update bing as a join (select likes,id from bing WHERE id='${photo}') as b on a.id=b.id set a.likes=(b.likes+1)`; + db.commonQuery(sql, function(rows) { + var ret = { + msg: '', + code: 200 + }; + if (rows.affectedRows == 0) { + ret.msg = 'something happend.' + } + res.json(ret); + }); + } else {} + return; + break; + case 'download': + var ua = req.get('User-Agent'); + if (!isAjax && !/(spider|bot)/ig.test(ua)) { + var sql = `update bing as a join (select downloads,id from bing WHERE qiniu_url='${photo}') as b on a.id=b.id set a.downloads=(b.downloads+1)`; + db.commonQuery(sql, function(rows) {}); + res.set({ + 'Content-Type': 'application/octet-stream', + 'Content-Disposition': 'attachment; filename=' + encodeURI(`${photo}_1920x1080.jpg`) + }); + // request.get(`https://bing-images.bitmoe.cn/bing/${photo}_1920x1080.jpg`) + request.get(`${config.global_link()}/bing/${photo}_1920x1080.jpg`) + .set({ + 'User-Agent': ua, + referer: 'https://bing.ioliu.cn' + }).pipe(res); + } else { + res.json({ + code: 200, + msg: 'bad request' + }) + } + return; + break; + } + + var sql = `select id,title,attribute,description,copyright,qiniu_url as photo,city,country,continent,DATE_FORMAT(enddate, '%Y-%m-%d') as dt,likes,views,downloads,thumbnail_pic from bing + where qiniu_url='${photo}'`; + if (isAjax) { + res.send({ + code: 200, + msg: 'bad request' + }); + } else { + // 修改展示量 + db.commonQuery(`update bing as a join (select views,id from bing WHERE qiniu_url='${photo}') as b on a.id=b.id set a.views=(b.views+1)`, function(rows) {}); + // 返回数据 + db.commonQuery(sql, function(rows) { + if (rows.length > 0) { + var doc = rows[0]; + doc['thumbnail'] = doc['thumbnail_pic'] ? doc['thumbnail_pic'].replace('http', 'https') : `${config.global_link()}/bing/${photo}_800x480.jpg`; + if (force.indexOf('_') > -1) { + var rt = force.split('_'); + doc['back_url'] = rt[0] === 'ranking' ? '/ranking?p=' + rt[1] : '/?p=' + rt[1]; + } else { + doc['back_url'] = '/'; + } + res.render('detail', { doc: doc }); + } else { + res.redirect(`/`); + } + }); + } +}); +/** + * 如果没有参数,则跳转到首页 + */ +router.get('/', function(req, res, next) { + res.redirect('/'); +}); + +module.exports = router; \ No newline at end of file diff --git a/routes/ranking.js b/routes/ranking.js new file mode 100644 index 0000000..a0e02f5 --- /dev/null +++ b/routes/ranking.js @@ -0,0 +1,85 @@ +var express = require('express'); +var router = express.Router(); +var request = require('superagent'); +var dbUtils = require('../utils/dbUtils'); +var config = require('../configs/config'); + +/* GET ranking listing. */ +router.get('/', function(req, res, next) { + var isAjax = !!req.headers['x-requested-with']; + var pageNo = req.query.p; + pageNo = !!pageNo && Number(pageNo) > 0 ? Number(pageNo) : 1; + var pageSize = 12; // pageSize + dbUtils.commonQuery(`select count(0) as sum from bing where (!ISNULL(qiniu_url) || qiniu_url<>"") and mkt like '%zh-cn%'`, function(rows) { + var count = rows[0]['sum'] || 0; + if (count > 0) { + var page = { + size: pageSize, + count: count, + pageCount: Math.ceil(count / pageSize), + next: pageNo + 1 > Math.ceil(count / pageSize) ? Math.ceil(count / pageSize) : pageNo + 1, + prev: pageNo - 1 > 0 ? pageNo - 1 : 1, + curr: pageNo > Math.ceil(count / pageSize) ? Math.ceil(count / pageSize) : pageNo, + currText: pageNo === 1 ? '下载榜' : '第' + pageNo + '页', + currPage: 'ranking' + } + if (pageNo > page.curr && !isAjax) { + res.redirect(`/?p=${page.curr}`); + } + var sql = `select id,title,attribute,description,copyright,qiniu_url as photo,city,country,continent,DATE_FORMAT(enddate, '%Y-%m-%d') as dt,likes,views,downloads,thumbnail_pic,original_pic from bing + where (!ISNULL(qiniu_url) || qiniu_url<>"") and mkt like '%zh-cn%' + order by downloads desc + limit ${(page.curr-1)*page.size},${page.size}`; + dbUtils.commonQuery(sql, function(rs) { + if (rs.length > 0) { + var data = []; + for (var i in rs) { + var temp = rs[i]; + /** + * 1024x576 + * 120x67 + */ + var thumbnail = temp['original_pic'] ? temp['original_pic'].replace('http', 'https') : `${config.global_link()}/bing/${temp['photo']}_1920x1080.jpg?imageView2/1/w/1024/h/576/q/100`; + var smallpic = temp['thumbnail_pic'] ? temp['thumbnail_pic'].replace('http', 'https') : `${config.global_link()}/bing/${temp['photo']}_1920x1080.jpg?imageView2/1/w/120/h/67/q/100`; + data.push({ + id: temp['id'], + title: temp['title'], + attribute: temp['attribute'], + description: temp['description'], + copyright: temp['copyright'], + photo: temp['photo'], + city: temp['city'], + country: temp['country'], + continent: temp['continent'], + thumbnail: thumbnail, + smallpic: smallpic, + dt: temp['dt'], + likes: temp['likes'], + views: temp['views'], + downloads: temp['downloads'] + }); + } + if (isAjax) { + res.json({ + doc: data, + page: page + }); + } else { + res.render('index', { + doc: data, + page: page + }); + } + } + }); + } + }); +}); +/** + * 如果没有参数,则跳转到首页 + */ +router.get('/', function(req, res, next) { + res.redirect('/'); +}); + +module.exports = router; \ No newline at end of file diff --git a/routes/v1.js b/routes/v1.js index d0db1ab..9efd0e1 100644 --- a/routes/v1.js +++ b/routes/v1.js @@ -2,7 +2,7 @@ var express = require('express'); var request = require('superagent'); var dbUtils = require('../utils/dbUtils'); var qiniuUtils = require('../utils/qiniuUtils'); -var resolutions = require('../configs/config').resolutions; +var config = require('../configs/config'); var cookie = { 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36' }; var router = express.Router(); @@ -19,12 +19,11 @@ router.post('/', function(req, res, next) { var v1 = function(req, res, next) { var d = req.query.d || req.body.d; - var w = req.query.w || req.body.w; - var h = req.query.h || req.body.h; - var p = req.query.p || req.body.p; - var num = req.query.size || req.body.size; + var w = req.query.w || req.body.w || '1366'; + var h = req.query.h || req.body.h || '768'; var t = req.query.type || req.body.type; var size = w + 'x' + h; + var cb = req.query.callback; var enddate = 0; if (!isNaN(d)) { var date = new Date().getTime() - parseInt(d) * 1000 * 60 * 60 * 24; @@ -39,51 +38,52 @@ var v1 = function(req, res, next) { body: {} }; if (!!enddate) { - params.body = { + params['body'] = { enddate: enddate } } - if (!!p && !isNaN(p)) { - p = +p < 1 ? 1 : p; - params.page = { - no: p, - size: 10 - } - if (!!num && !isNaN(num)) { - num = +num < 1 ? 1 : num; - params.page.size = num; - } - } dbUtils.get('bing', params, function(rows) { if (rows.length > 0) { var data = rows[0]; - if (!!w || !!h) { - if (resolutions.indexOf(size) > -1) { - data['url'] = 'http://static.ioliu.cn/bing/' + data.qiniu_url + '_' + size + '.jpg'; - } - var qiniu_url = /static\.ioliu\.cn/.test(data.url) ? data.url : qiniuUtils.imageView(data.qiniu_url, w, h); - request.get(qiniu_url) - .set(cookie) - .end(function(err, response) { - res.header('content-type', 'image/jpg'); - res.send(response.body); - }); - } else { - if (+num > 0) { - data = rows; - } + if (t === 'json' || !!cb) { var output = { - data: data, + data: { + enddate: data.enddate, + url: data.url, + bmiddle_pic: data.bmiddle_pic, + original_pic: data.original_pic, + thumbnail_pic: data.thumbnail_pic, + }, status: { code: 200, message: '' } }; - if (req.method === 'GET' && req.query.callback) { + if (cb) { res.jsonp(output); } else { res.json(output); } + } else { + + if (config.resolutions.indexOf(size) === -1) { + data['url'] = qiniuUtils.imageView(data.qiniu_url, w, h); + } else { + data['url'] = config.global_http() + '/bing/' + data.qiniu_url + '_' + size + '.jpg'; + } + request.get(data['url']) + .set({ + 'user-agent': req.headers['user-agent'], + 'referer': req.headers['host'] + }) + .end(function(err, response) { + if (err) { + res.send(err) + } else { + res.header('content-type', 'image/jpeg'); + res.send(response.body); + } + }); } } else { res.json({ @@ -109,8 +109,8 @@ router.post('/rand', function(req, res, next) { var random = function(req, res, next) { var t = req.query.type || req.body.type; - var w = req.query.w || req.body.w || '1920'; - var h = req.query.h || req.body.h || '1080'; + var w = req.query.w || req.body.w || '1366'; + var h = req.query.h || req.body.h || '768'; var size = w + 'x' + h; var callback = req.query.callback || req.body.callback; dbUtils.getCount('bing', {}, function(rows) { @@ -122,13 +122,15 @@ var random = function(req, res, next) { }, function(rs) { if (rs.length > 0) { var data = rs[0]; - if (resolutions.indexOf(size) > -1) { - data['url'] = 'https://static.ioliu.cn/bing/' + data.qiniu_url + '_' + size + '.jpg'; - } if (t === 'json' || !!callback) { - //console.log(callback); var output = { - data: data, + data: { + enddate: data.enddate, + url: data.url, + bmiddle_pic: data.bmiddle_pic, + original_pic: data.original_pic, + thumbnail_pic: data.thumbnail_pic, + }, status: { code: 200, message: '' @@ -140,12 +142,24 @@ var random = function(req, res, next) { res.json(output); } } else { - var qiniu_url = /static\.ioliu\.cn/.test(data.url) ? data.url : qiniuUtils.imageView(data.qiniu_url, w, h); - request.get(qiniu_url) - .set(cookie) + var data = rs[0]; + if (config.resolutions.indexOf(size) === -1) { + data['url'] = qiniuUtils.imageView(data.qiniu_url, w, h); + } else { + data['url'] = config.global_http() + '/bing/' + data.qiniu_url + '_' + size + '.jpg'; + } + request.get(data['url']) + .set({ + 'user-agent': req.headers['user-agent'], + 'referer': req.headers['host'] + }) .end(function(err, response) { - res.header('content-type', 'image/jpg'); - res.send(response.body); + if (err) { + res.send(err) + } else { + res.header('content-type', 'image/jpeg'); + res.send(response.body); + } }); } } else { @@ -153,7 +167,7 @@ var random = function(req, res, next) { params += !!t ? '&t=' + t : ''; params += !!w ? '&w=' + w : ''; params += !!h ? '&h=' + h : ''; - params += !!callback ? '&&callback=' + callback : ''; + params += !!callback ? '&callback=' + callback : ''; res.redirect('/v1/rand' + params); } }); @@ -162,7 +176,7 @@ var random = function(req, res, next) { params += !!t ? '&t=' + t : ''; params += !!w ? '&w=' + w : ''; params += !!h ? '&h=' + h : ''; - params += !!callback ? '&&callback=' + callback : ''; + params += !!callback ? '&callback=' + callback : ''; res.redirect('/v1/rand' + params); } }); @@ -181,8 +195,8 @@ router.post('/blur', function(req, res, next) { var blur = function(req, res, next) { var d = req.query.d || req.body.d; - var w = req.query.w || req.body.w; - var h = req.query.h || req.body.h; + var w = req.query.w || req.body.w || 1366; + var h = req.query.h || req.body.h || 768; var r = req.query.r || req.body.r; r = isNaN(r) ? 10 : parseInt(r) > 50 ? 50 : parseInt(r) <= 0 ? 1 : r; var size = w + 'x' + h; @@ -207,17 +221,24 @@ var blur = function(req, res, next) { dbUtils.get('bing', params, function(rows) { if (rows.length > 0) { var data = rows[0]; - var base = 'https://static.ioliu.cn/bing/'; - if (resolutions.indexOf(size) > -1) { + var base = config.global_http() + '/bing/'; + if (config.resolutions.indexOf(size) > -1) { data['url'] = base + data.qiniu_url + '_' + size + '.jpg'; } - var qiniu_url = /static\.ioliu\.cn/.test(data.url) ? data.url : base + data.qiniu_url + '_1920x1080.jpg'; + var qiniu_url = /^(http|https)/.test(data.url) ? data.url : base + data.qiniu_url + '_1920x1080.jpg'; qiniu_url += '?imageMogr2/blur/' + r + 'x50' request.get(qiniu_url) - .set(cookie) + .set({ + 'user-agent': req.headers['user-agent'], + 'referer': req.headers['host'] + }) .end(function(err, response) { - res.header('content-type', 'image/jpg'); - res.send(response.body); + if (err) { + res.send(err) + } else { + res.header('content-type', 'image/jpg'); + res.send(response.body); + } }); } else { res.json({ diff --git a/static/about.html b/static/about.html index 12f0a5a..291b9e6 100644 --- a/static/about.html +++ b/static/about.html @@ -1,189 +1,191 @@ - - - - - - 关于 - 必应壁纸 - - - - - - - - - - - - - - -
-


-

Bing 每日壁纸,你值得拥有

-
- - -
- -

最开始做 Bing 壁纸的目的很纯粹,就是看到必应搜索 cn.bing.com 官网的壁纸很赞,但是想找到之前的壁纸就有点困难,然后就自己用PHP语言开发了一个,每天同步cn.bing.com 官网的壁纸,同步抓取每日故事,存在自己的数据库里。源代码可以在GitHub上找到。当时主机是用的 - 阿里云送的免费两年的云主机,可能大部分人都没见过。整体布局如下:

- -

由于我不是专业的 PHP工程师(前端攻城狮一枚),PHP版本 到后期维护就越来越困难,每次花费在改问题的时间越来越长,于是后面干脆就用Node.js 重写了Bing 壁纸,将版本号升级到了2.0版本(哈哈,自己定义的,无需在意),图片存储采用的七牛云存储,毕竟早期的流量小,免费额度还是撑得住的。程序部署在DaoCloud上,有兴趣的可以去看看Dockerfile。并且将域名由 - api.ioliu.cn 换成了 bing.ioliu.cn,这个版本可能大家就更熟悉一些,应该是上线时间最长的版本了吧。 -

-

后面由于 道客(DocCloud) 访问速度慢,最后干脆咬牙买了阿里云主机(ECS)1核/2G,并更新了SSL证书,相信现在的你一定发现了本站的访问速度简直是超级快(哈哈,自我陶醉下)。

- -

截止到 2017-03-05,Bing 壁纸 项目已经稳步运行了一年,相信在未来的日子里,Bing 壁纸 会越来越好,功能越来越完善。现在,Bing壁纸 开通了留言功能,大家有什么想说的可以在下面留言咯\(^o^)/YES!

-

为了把壁纸的美好带给大家,攻城狮小哥花费了很多个人时间和精力进行开发,甚至自己掏钱购买服务器,看攻城狮小哥这么可怜,快来打赏杯咖啡吧。≡ω≡

-
-
- 云淡风轻 WeChat Pay -

微信打赏

-
-
- 云淡风轻 Alipay -

支付宝打赏

-
-
-
- - -
- - - Fork me on GitHub - - - + + + + + + 关于 | 必应每日高清壁纸 - 精彩,从这里开始 + + + + + + + + + + + + + + +
+


+

Bing 每日壁纸,你值得拥有

+
+ + +
+ +

最开始做 Bing 壁纸的目的很纯粹,就是看到必应搜索 cn.bing.com 官网的壁纸很赞,但是想找到之前的壁纸就有点困难,然后就自己用PHP语言开发了一个,每天同步cn.bing.com 官网的壁纸,同步抓取每日故事,存在自己的数据库里。源代码可以在GitHub上找到。当时主机是用的 + 阿里云送的免费两年的云主机,可能大部分人都没见过。整体布局如下:

+ +

由于我不是专业的 PHP工程师(前端攻城狮一枚),PHP版本 到后期维护就越来越困难,每次花费在改问题的时间越来越长,于是后面干脆就用Node.js 重写了Bing 壁纸,将版本号升级到了2.0版本(哈哈,自己定义的,无需在意),图片存储采用的七牛云存储,毕竟早期的流量小,免费额度还是撑得住的。程序部署在DaoCloud上,有兴趣的可以去看看Dockerfile。并且将域名由 + api.ioliu.cn 换成了 bing.ioliu.cn,这个版本可能大家就更熟悉一些,应该是上线时间最长的版本了吧。 +

+

后面由于 道客(DocCloud) 访问速度慢,最后干脆咬牙买了阿里云主机(ECS)1核/2G,并更新了SSL证书,相信现在的你一定发现了本站的访问速度简直是超级快(哈哈,自我陶醉下)。

+ +

截止到 2017-03-05,Bing 壁纸 项目已经稳步运行了一年,相信在未来的日子里,Bing 壁纸 会越来越好,功能越来越完善。现在,Bing壁纸 开通了留言功能,大家有什么想说的可以在下面留言咯\(^o^)/YES!

+

为了把壁纸的美好带给大家,攻城狮小哥花费了很多个人时间和精力进行开发,甚至自己掏钱购买服务器,看攻城狮小哥这么可怜,快来打赏杯咖啡吧。≡ω≡

+
+
+ 云淡风轻 WeChat Pay +

微信打赏

+
+
+ 云淡风轻 Alipay +

支付宝打赏

+
+
+
+ + +
+ + + Fork me on GitHub + + + + + \ No newline at end of file diff --git a/static/css/about.css b/static/css/about.css new file mode 100644 index 0000000..8591a34 --- /dev/null +++ b/static/css/about.css @@ -0,0 +1,112 @@ +code { + color: #1abc9c; +} + +html { + background: #eee; +} + +body { + width: 95%; + max-width: 960px; + background: #fff; + margin: 2em auto 0; + padding-top: 1em; + border: 1px solid #ddd; + border-width: 0 1px; +} + +pre { + white-space: pre-wrap; +} + +i.serif { + text-transform: lowercase; + color: #1abc9c; +} + + :-moz-any(h1, h2, h3, h4, h5, h5) i.serif { + text-transform: capitalize; +} + +i.serif:hover { + color: inherit; +} + +#wrapper { + padding: 2% 2%; + position: relative; +} + +#tagline { + color: #999; + font-size: 1em; + margin: -2em 0 2em; + padding-bottom: 2em; + border-bottom: 3px double #eee; +} + +#fork { + position: fixed; + top: 0; + right: 0; + _position: absolute; +} + +#table { + margin-bottom: 2em; + color: #888; +} + +#github { + position: absolute; + top: 1em; +} + +#github iframe { + display: inline; + margin-right: 1em; +} + +@media only screen and (max-width: 640px) { + body { + width: 100%; + border: none; + } + table { + word-break: break-all; + word-wrap: break-word; + font-size: 12px; + } + .typo table th, + .typo table td, + .typo-table th, + .typo-table td .typo table caption { + padding: 0.5em; + } + #fork { + display: none; + } +} + +.icon { + font-size: 1em; +} + +#QR { + font-size: 0; +} + +#wechat, +#alipay { + font-size: 14px; + width: 50%; + box-sizing: border-box; + text-align: center; +} + +#wechat_qr, +#alipay_qr { + display: inline-block; + max-width: 150px; +} \ No newline at end of file diff --git a/static/css/common.css b/static/css/common.css new file mode 100644 index 0000000..a9ade56 --- /dev/null +++ b/static/css/common.css @@ -0,0 +1,257 @@ +* { + margin: 0; + padding: 0; + -webkit-box-sizing: border-box; + box-sizing: border-box; +} + +body { + margin: 0; + line-height: 1.5; + font-size: .16rem; + position: relative; + background-color: #FFF; + -webkit-text-size-adjust: 100%; + -ms-text-size-adjust: 100%; + text-size-adjust: 100%; + -webkit-overflow-scrolling: touch; + -webkit-font-smoothing: antialiased; + color: #0C8484; + font-family: "Source Han Sans SC", "Noto Sans CJK SC", "Source Han Sans CN", "Noto Sans SC", "Source Han Sans TC", "Noto Sans CJK TC", "PingFang SC", "Hiragino Sans GB", "Neue Haas Grotesk Text Pro", "Microsoft YaHei", "Microsoft JhengHei", sans-serif; +} + +.clearfix::before { + display: table; + content: ""; +} + +.clearfix::after { + display: table; + clear: both; + content: ""; +} + +.float-right { + float: right !important; +} + +.float-left { + float: left !important; +} + +.float-none { + float: none !important; +} + +a { + text-decoration: none; + -webkit-transition: color .15s linear; + transition: color .15s linear; + color: #0C8484; +} + +a:hover { + color: #888; +} + +ul, +li { + list-style: none; + padding: 0; + margin: 0; + display: inline-block; + vertical-align: middle; +} + +header { + padding: .1rem 0; + display: block; + background: rgba(255, 255, 255, 0.93); + height: .7rem; + width: 100%; + z-index: 99; +} + +header .container { + padding: 0 .5rem; +} + +header .logo { + display: inline-block; + height: 100%; + font-size: .3rem; + color: #0C8484; +} + +header .logo i { + font-size: .4rem; +} + +header nav { + float: right; +} + +header nav .menu { + height: .6rem; + display: block; + -webkit-transition: all .3s ease; + transition: all .3s ease; +} + +header nav .menu li { + font-size: .14rem; + display: inline-block; + height: 100%; + vertical-align: middle; + overflow: hidden; +} + +header nav .menu li.active a { + color: #f15151; +} + +header nav .menu li a { + display: block; + height: 100%; + padding: 0 .25rem; + text-align: center; + line-height: .55rem; +} + +header nav .menu li a .icon { + font-size: .25rem; + display: none; +} + +header nav .menu li .search { + height: 100%; + position: relative; + display: block; +} + +header nav .menu li .search input { + font-size: .12rem; + border: 1px solid #dedede; + -webkit-border-radius: 5px; + border-radius: 5px; + height: .4rem; + margin: .1rem 0; + padding: 0 .1rem; + outline: none; + width: 1.68rem; + -webkit-transition: all .2s ease; + transition: all .2s ease; +} + +header nav .menu li .search input:focus { + margin-left: 0; + opacity: 1; + border: 1px solid #a7afef; +} + +header nav .menu li .search input:focus+.search-btn .icon { + color: #a7afef; +} + +header nav .menu li .search .search-btn { + border: none; + position: absolute; + right: .05rem; + top: -0.04rem; + padding: .05rem; + background: transparent; + outline: none; + cursor: pointer; +} + +header nav .menu li .search .search-btn .icon { + display: block; + color: #dedede; + -webkit-transition: all .2s ease; + transition: all .2s ease; +} + +html { + font-size: 100px; +} + +@media only screen and (max-width: 768px) { + html { + font-size: 115px; + } + html .holder { + height: .65rem; + } + html header { + text-align: center; + } + html header .container { + padding: 0 !important; + } + html nav { + float: none; + } + html nav .menu { + position: absolute; + top: .65rem; + left: 0; + width: 100%; + display: none !important; + transition: all .5s ease; + } + html nav .menu { + display: block !important; + z-index: 2; + } + html nav .menu li { + background: rgba(255, 255, 255, 0.9); + width: 33.33%; + } + html nav .menu li .text { + display: none; + } + html nav .menu li .icon { + display: inline-block !important; + } + html nav .menu li.search-wrap { + width: 100%; + padding: 0 .1rem; + } + html nav .menu li.search-wrap input { + width: 100%; + } + html .item { + padding: .06rem !important; + } +} + +@media only screen and (max-width: 640px) { + html { + font-size: 110px; + } + html .item { + padding: .05rem 0 !important; + margin-bottom: .15rem; + width: 100% !important; + } + html .item .card .mark, + html .item .card .description, + html .item .card .options { + opacity: 1 !important; + } + html .sub { + display: none; + } +} + +@media only screen and (max-width: 480px) { + html { + font-size: 100px; + } +} + +@media only screen and (max-width: 320px) { + html { + font-size: 85px; + } +} \ No newline at end of file diff --git a/static/css/error.css b/static/css/error.css deleted file mode 100644 index 0792d13..0000000 --- a/static/css/error.css +++ /dev/null @@ -1,327 +0,0 @@ -@import './reset.css'; -body { - color: #fff; - font-size: 100%; - background-color: #141724; - margin: 0px auto; - font-family: sans-serif; - font-family: CamingoCode, 'Lantinghei SC', 'HanHei SC', 'PingFang SC', arial, 'Microsoft Yahei', georgia, verdana, helvetica, sans-serif; -} - -h1 { - font-size: 4.25em; - font-weight: 700; -} - -#help { - position: absolute; - color: white; - z-index: 1; - margin-left: 50px; - margin-top: 50px; -} - -#stars { - width: 100%; - height: 80vh; - overflow: hidden; - position: absolute; - background: linear-gradient(rgba(0, 0, 0, 0.69) 0%, rgba(0, 0, 0, 0.69) 50%, #141724 100%); -} - -.star { - width: 10px; - height: 10px; - background-color: rgba(255, 255, 255, 0.62); - border-radius: 10px; - box-shadow: 0 0 5px white; - position: absolute; - animation: twinkle 5s infinite; -} - -#land { - height: 100vh; - width: 100%; - overflow: hidden; - position: absolute; - bottom: 0px; -} - -#land img { - position: absolute; - bottom: 0px; -} - -@keyframes twinkle { - 0% { - opacity: 1 - } - 50% { - opacity: 0.2 - } - 100% { - opacity: 1 - } -} - -#fire { - position: absolute; - height: 100px; - width: 100px; - bottom: -20px; - right: 50%; - margin-right: -50px; -} - -#logOne { - width: 100px; - height: 20px; - border-radius: 5px; - background-color: #917654; - position: absolute; - transform: rotate(25deg); - bottom: 0px; - margin-bottom: 50px; - z-index: 2; -} - -#logTwo { - width: 100px; - height: 20px; - border-radius: 5px; - background-color: #745c3d; - position: absolute; - transform: rotate(-25deg); - bottom: 0px; - margin-bottom: 50px; - z-index: 2; -} - -.flame { - width: 0px; - height: 0px; - background-color: darkorange; - border-radius: 5px; - bottom: 0px; - transform: rotate(45deg); - margin-left: 25px; - margin-bottom: 75px; - position: absolute; - animation: fire 1s infinite; - animation-timing-function: linear; -} - -.flame:nth-child(1) { - animation: fire 2s infinite; - animation-timing-function: linear; - animation-delay: 0; -} - -.flame:nth-child(2) { - animation: fire 2s infinite; - animation-timing-function: linear; - animation-delay: 0.5s; -} - -.flame:nth-child(3) { - animation: fire 2s infinite; - animation-timing-function: linear; - animation-delay: 1s; -} - -.flame:nth-child(4) { - animation: fire 2s infinite; - animation-timing-function: linear; - animation-delay: 1.5s; -} - -.flame:nth-child(5) { - animation: fire 2s infinite; - animation-timing-function: linear; - animation-delay: 2s; -} - -#flicker { - width: 10px; - height: 10px; - background-color: rgba(255, 140, 0, 0.1); - border-radius: 40px; - position: absolute; - bottom: 0px; - margin-left: 50px; - margin-bottom: 50px; - z-index: 1; - box-shadow: 0 0 100px darkorange; - animation: flick 3s infinite; - animation-timing-function: ease-in-out; -} - -#ground { - width: 130%; - height: 25vh; - background-color: #121628; - position: absolute; - bottom: 0px; - border-radius: 100%; - margin-left: -15%; - margin-bottom: -10vh; - box-shadow: 0 0 100px rgb(39, 48, 64); -} - -@keyframes fire { - 0% { - width: 0; - height: 0; - margin-left: 50px; - background-color: #ffce00; - z-index: 1000; - } - 50% { - width: 50px; - height: 50px; - margin-bottom: 75px; - margin-left: 25px; - background-color: darkorange; - } - 75% { - z-index: 1; - } - 100% { - width: 0px; - height: 0px; - margin-bottom: 200px; - margin-left: 50px; - background-color: #ff0000; - z-index: 1; - } -} - -@keyframes flick { - 0% { - opacity: 0.4; - } - 50% { - opacity: 0.8; - } - 100% { - opacity: 0.4; - } -} - - -/* Button */ - -input[type="submit"], -input[type="reset"], -input[type="button"], -button, -.button { - -moz-appearance: none; - -webkit-appearance: none; - -ms-appearance: none; - appearance: none; - -webkit-transition: background-color 0.25s ease-in-out, border-color 0.25s ease-in-out, color 0.25s ease-in-out; - transition: background-color 0.25s ease-in-out, border-color 0.25s ease-in-out, color 0.25s ease-in-out; - background-color: transparent; - border: solid 1px #ccc; - color: #555; - cursor: pointer; - display: inline-block; - line-height: 1; - padding: 0.75em 1.5em; - text-align: center; - text-decoration: none; - white-space: nowrap; - margin-top: 15px; -} - -.button+.button { - margin-left: 5px; -} - -.caption input[type="submit"], -.caption input[type="reset"], -.caption input[type="button"], -.caption button, -.caption .button { - background-color: transparent; - border-color: #ffffff; - color: #ffffff; -} - -input[type="submit"]:hover, -input[type="reset"]:hover, -input[type="button"]:hover, -button:hover, -.button:hover { - border-color: #00D3B7; - color: #00D3B7; - text-decoration: none; -} - -input[type="submit"]:hover:active, -input[type="reset"]:hover:active, -input[type="button"]:hover:active, -button:hover:active, -.button:hover:active { - background-color: rgba(0, 211, 183, 0.15); -} - -input[type="submit"].icon, -input[type="reset"].icon, -input[type="button"].icon, -button.icon, -.button.icon { - padding-left: 1.35em; -} - -input[type="submit"].icon:before, -input[type="reset"].icon:before, -input[type="button"].icon:before, -button.icon:before, -.button.icon:before { - margin-right: 0.5em; -} - -input[type="submit"].fit, -input[type="reset"].fit, -input[type="button"].fit, -button.fit, -.button.fit { - display: block; - margin: 0 0 0.625em 0; - width: 100%; -} - -input[type="submit"].small, -input[type="reset"].small, -input[type="button"].small, -button.small, -.button.small { - font-size: 0.8em; -} - -input[type="submit"].big, -input[type="reset"].big, -input[type="button"].big, -button.big, -.button.big { - font-size: 1.35em; -} - -input[type="submit"].disabled, -input[type="submit"]:disabled, -input[type="reset"].disabled, -input[type="reset"]:disabled, -input[type="button"].disabled, -input[type="button"]:disabled, -button.disabled, -button:disabled, -.button.disabled, -.button:disabled { - -moz-pointer-events: none; - -webkit-pointer-events: none; - -ms-pointer-events: none; - pointer-events: none; - opacity: 0.25; -} \ No newline at end of file diff --git a/static/css/font-awesome.min.css b/static/css/font-awesome.min.css deleted file mode 100644 index 540440c..0000000 --- a/static/css/font-awesome.min.css +++ /dev/null @@ -1,4 +0,0 @@ -/*! - * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome - * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) - */@font-face{font-family:'FontAwesome';src:url('../fonts/fontawesome-webfont.eot?v=4.7.0');src:url('../fonts/fontawesome-webfont.eot?#iefix&v=4.7.0') format('embedded-opentype'),url('../fonts/fontawesome-webfont.woff2?v=4.7.0') format('woff2'),url('../fonts/fontawesome-webfont.woff?v=4.7.0') format('woff'),url('../fonts/fontawesome-webfont.ttf?v=4.7.0') format('truetype'),url('../fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular') format('svg');font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571429em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em;text-align:center}.fa-li.fa-lg{left:-1.85714286em}.fa-border{padding:.2em .25em .15em;border:solid .08em #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left{margin-right:.3em}.fa.fa-pull-right{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);-ms-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);-ms-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:"\f000"}.fa-music:before{content:"\f001"}.fa-search:before{content:"\f002"}.fa-envelope-o:before{content:"\f003"}.fa-heart:before{content:"\f004"}.fa-star:before{content:"\f005"}.fa-star-o:before{content:"\f006"}.fa-user:before{content:"\f007"}.fa-film:before{content:"\f008"}.fa-th-large:before{content:"\f009"}.fa-th:before{content:"\f00a"}.fa-th-list:before{content:"\f00b"}.fa-check:before{content:"\f00c"}.fa-remove:before,.fa-close:before,.fa-times:before{content:"\f00d"}.fa-search-plus:before{content:"\f00e"}.fa-search-minus:before{content:"\f010"}.fa-power-off:before{content:"\f011"}.fa-signal:before{content:"\f012"}.fa-gear:before,.fa-cog:before{content:"\f013"}.fa-trash-o:before{content:"\f014"}.fa-home:before{content:"\f015"}.fa-file-o:before{content:"\f016"}.fa-clock-o:before{content:"\f017"}.fa-road:before{content:"\f018"}.fa-download:before{content:"\f019"}.fa-arrow-circle-o-down:before{content:"\f01a"}.fa-arrow-circle-o-up:before{content:"\f01b"}.fa-inbox:before{content:"\f01c"}.fa-play-circle-o:before{content:"\f01d"}.fa-rotate-right:before,.fa-repeat:before{content:"\f01e"}.fa-refresh:before{content:"\f021"}.fa-list-alt:before{content:"\f022"}.fa-lock:before{content:"\f023"}.fa-flag:before{content:"\f024"}.fa-headphones:before{content:"\f025"}.fa-volume-off:before{content:"\f026"}.fa-volume-down:before{content:"\f027"}.fa-volume-up:before{content:"\f028"}.fa-qrcode:before{content:"\f029"}.fa-barcode:before{content:"\f02a"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-book:before{content:"\f02d"}.fa-bookmark:before{content:"\f02e"}.fa-print:before{content:"\f02f"}.fa-camera:before{content:"\f030"}.fa-font:before{content:"\f031"}.fa-bold:before{content:"\f032"}.fa-italic:before{content:"\f033"}.fa-text-height:before{content:"\f034"}.fa-text-width:before{content:"\f035"}.fa-align-left:before{content:"\f036"}.fa-align-center:before{content:"\f037"}.fa-align-right:before{content:"\f038"}.fa-align-justify:before{content:"\f039"}.fa-list:before{content:"\f03a"}.fa-dedent:before,.fa-outdent:before{content:"\f03b"}.fa-indent:before{content:"\f03c"}.fa-video-camera:before{content:"\f03d"}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:"\f03e"}.fa-pencil:before{content:"\f040"}.fa-map-marker:before{content:"\f041"}.fa-adjust:before{content:"\f042"}.fa-tint:before{content:"\f043"}.fa-edit:before,.fa-pencil-square-o:before{content:"\f044"}.fa-share-square-o:before{content:"\f045"}.fa-check-square-o:before{content:"\f046"}.fa-arrows:before{content:"\f047"}.fa-step-backward:before{content:"\f048"}.fa-fast-backward:before{content:"\f049"}.fa-backward:before{content:"\f04a"}.fa-play:before{content:"\f04b"}.fa-pause:before{content:"\f04c"}.fa-stop:before{content:"\f04d"}.fa-forward:before{content:"\f04e"}.fa-fast-forward:before{content:"\f050"}.fa-step-forward:before{content:"\f051"}.fa-eject:before{content:"\f052"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-plus-circle:before{content:"\f055"}.fa-minus-circle:before{content:"\f056"}.fa-times-circle:before{content:"\f057"}.fa-check-circle:before{content:"\f058"}.fa-question-circle:before{content:"\f059"}.fa-info-circle:before{content:"\f05a"}.fa-crosshairs:before{content:"\f05b"}.fa-times-circle-o:before{content:"\f05c"}.fa-check-circle-o:before{content:"\f05d"}.fa-ban:before{content:"\f05e"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-up:before{content:"\f062"}.fa-arrow-down:before{content:"\f063"}.fa-mail-forward:before,.fa-share:before{content:"\f064"}.fa-expand:before{content:"\f065"}.fa-compress:before{content:"\f066"}.fa-plus:before{content:"\f067"}.fa-minus:before{content:"\f068"}.fa-asterisk:before{content:"\f069"}.fa-exclamation-circle:before{content:"\f06a"}.fa-gift:before{content:"\f06b"}.fa-leaf:before{content:"\f06c"}.fa-fire:before{content:"\f06d"}.fa-eye:before{content:"\f06e"}.fa-eye-slash:before{content:"\f070"}.fa-warning:before,.fa-exclamation-triangle:before{content:"\f071"}.fa-plane:before{content:"\f072"}.fa-calendar:before{content:"\f073"}.fa-random:before{content:"\f074"}.fa-comment:before{content:"\f075"}.fa-magnet:before{content:"\f076"}.fa-chevron-up:before{content:"\f077"}.fa-chevron-down:before{content:"\f078"}.fa-retweet:before{content:"\f079"}.fa-shopping-cart:before{content:"\f07a"}.fa-folder:before{content:"\f07b"}.fa-folder-open:before{content:"\f07c"}.fa-arrows-v:before{content:"\f07d"}.fa-arrows-h:before{content:"\f07e"}.fa-bar-chart-o:before,.fa-bar-chart:before{content:"\f080"}.fa-twitter-square:before{content:"\f081"}.fa-facebook-square:before{content:"\f082"}.fa-camera-retro:before{content:"\f083"}.fa-key:before{content:"\f084"}.fa-gears:before,.fa-cogs:before{content:"\f085"}.fa-comments:before{content:"\f086"}.fa-thumbs-o-up:before{content:"\f087"}.fa-thumbs-o-down:before{content:"\f088"}.fa-star-half:before{content:"\f089"}.fa-heart-o:before{content:"\f08a"}.fa-sign-out:before{content:"\f08b"}.fa-linkedin-square:before{content:"\f08c"}.fa-thumb-tack:before{content:"\f08d"}.fa-external-link:before{content:"\f08e"}.fa-sign-in:before{content:"\f090"}.fa-trophy:before{content:"\f091"}.fa-github-square:before{content:"\f092"}.fa-upload:before{content:"\f093"}.fa-lemon-o:before{content:"\f094"}.fa-phone:before{content:"\f095"}.fa-square-o:before{content:"\f096"}.fa-bookmark-o:before{content:"\f097"}.fa-phone-square:before{content:"\f098"}.fa-twitter:before{content:"\f099"}.fa-facebook-f:before,.fa-facebook:before{content:"\f09a"}.fa-github:before{content:"\f09b"}.fa-unlock:before{content:"\f09c"}.fa-credit-card:before{content:"\f09d"}.fa-feed:before,.fa-rss:before{content:"\f09e"}.fa-hdd-o:before{content:"\f0a0"}.fa-bullhorn:before{content:"\f0a1"}.fa-bell:before{content:"\f0f3"}.fa-certificate:before{content:"\f0a3"}.fa-hand-o-right:before{content:"\f0a4"}.fa-hand-o-left:before{content:"\f0a5"}.fa-hand-o-up:before{content:"\f0a6"}.fa-hand-o-down:before{content:"\f0a7"}.fa-arrow-circle-left:before{content:"\f0a8"}.fa-arrow-circle-right:before{content:"\f0a9"}.fa-arrow-circle-up:before{content:"\f0aa"}.fa-arrow-circle-down:before{content:"\f0ab"}.fa-globe:before{content:"\f0ac"}.fa-wrench:before{content:"\f0ad"}.fa-tasks:before{content:"\f0ae"}.fa-filter:before{content:"\f0b0"}.fa-briefcase:before{content:"\f0b1"}.fa-arrows-alt:before{content:"\f0b2"}.fa-group:before,.fa-users:before{content:"\f0c0"}.fa-chain:before,.fa-link:before{content:"\f0c1"}.fa-cloud:before{content:"\f0c2"}.fa-flask:before{content:"\f0c3"}.fa-cut:before,.fa-scissors:before{content:"\f0c4"}.fa-copy:before,.fa-files-o:before{content:"\f0c5"}.fa-paperclip:before{content:"\f0c6"}.fa-save:before,.fa-floppy-o:before{content:"\f0c7"}.fa-square:before{content:"\f0c8"}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:"\f0c9"}.fa-list-ul:before{content:"\f0ca"}.fa-list-ol:before{content:"\f0cb"}.fa-strikethrough:before{content:"\f0cc"}.fa-underline:before{content:"\f0cd"}.fa-table:before{content:"\f0ce"}.fa-magic:before{content:"\f0d0"}.fa-truck:before{content:"\f0d1"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-square:before{content:"\f0d3"}.fa-google-plus-square:before{content:"\f0d4"}.fa-google-plus:before{content:"\f0d5"}.fa-money:before{content:"\f0d6"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-up:before{content:"\f0d8"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-columns:before{content:"\f0db"}.fa-unsorted:before,.fa-sort:before{content:"\f0dc"}.fa-sort-down:before,.fa-sort-desc:before{content:"\f0dd"}.fa-sort-up:before,.fa-sort-asc:before{content:"\f0de"}.fa-envelope:before{content:"\f0e0"}.fa-linkedin:before{content:"\f0e1"}.fa-rotate-left:before,.fa-undo:before{content:"\f0e2"}.fa-legal:before,.fa-gavel:before{content:"\f0e3"}.fa-dashboard:before,.fa-tachometer:before{content:"\f0e4"}.fa-comment-o:before{content:"\f0e5"}.fa-comments-o:before{content:"\f0e6"}.fa-flash:before,.fa-bolt:before{content:"\f0e7"}.fa-sitemap:before{content:"\f0e8"}.fa-umbrella:before{content:"\f0e9"}.fa-paste:before,.fa-clipboard:before{content:"\f0ea"}.fa-lightbulb-o:before{content:"\f0eb"}.fa-exchange:before{content:"\f0ec"}.fa-cloud-download:before{content:"\f0ed"}.fa-cloud-upload:before{content:"\f0ee"}.fa-user-md:before{content:"\f0f0"}.fa-stethoscope:before{content:"\f0f1"}.fa-suitcase:before{content:"\f0f2"}.fa-bell-o:before{content:"\f0a2"}.fa-coffee:before{content:"\f0f4"}.fa-cutlery:before{content:"\f0f5"}.fa-file-text-o:before{content:"\f0f6"}.fa-building-o:before{content:"\f0f7"}.fa-hospital-o:before{content:"\f0f8"}.fa-ambulance:before{content:"\f0f9"}.fa-medkit:before{content:"\f0fa"}.fa-fighter-jet:before{content:"\f0fb"}.fa-beer:before{content:"\f0fc"}.fa-h-square:before{content:"\f0fd"}.fa-plus-square:before{content:"\f0fe"}.fa-angle-double-left:before{content:"\f100"}.fa-angle-double-right:before{content:"\f101"}.fa-angle-double-up:before{content:"\f102"}.fa-angle-double-down:before{content:"\f103"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angle-down:before{content:"\f107"}.fa-desktop:before{content:"\f108"}.fa-laptop:before{content:"\f109"}.fa-tablet:before{content:"\f10a"}.fa-mobile-phone:before,.fa-mobile:before{content:"\f10b"}.fa-circle-o:before{content:"\f10c"}.fa-quote-left:before{content:"\f10d"}.fa-quote-right:before{content:"\f10e"}.fa-spinner:before{content:"\f110"}.fa-circle:before{content:"\f111"}.fa-mail-reply:before,.fa-reply:before{content:"\f112"}.fa-github-alt:before{content:"\f113"}.fa-folder-o:before{content:"\f114"}.fa-folder-open-o:before{content:"\f115"}.fa-smile-o:before{content:"\f118"}.fa-frown-o:before{content:"\f119"}.fa-meh-o:before{content:"\f11a"}.fa-gamepad:before{content:"\f11b"}.fa-keyboard-o:before{content:"\f11c"}.fa-flag-o:before{content:"\f11d"}.fa-flag-checkered:before{content:"\f11e"}.fa-terminal:before{content:"\f120"}.fa-code:before{content:"\f121"}.fa-mail-reply-all:before,.fa-reply-all:before{content:"\f122"}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:"\f123"}.fa-location-arrow:before{content:"\f124"}.fa-crop:before{content:"\f125"}.fa-code-fork:before{content:"\f126"}.fa-unlink:before,.fa-chain-broken:before{content:"\f127"}.fa-question:before{content:"\f128"}.fa-info:before{content:"\f129"}.fa-exclamation:before{content:"\f12a"}.fa-superscript:before{content:"\f12b"}.fa-subscript:before{content:"\f12c"}.fa-eraser:before{content:"\f12d"}.fa-puzzle-piece:before{content:"\f12e"}.fa-microphone:before{content:"\f130"}.fa-microphone-slash:before{content:"\f131"}.fa-shield:before{content:"\f132"}.fa-calendar-o:before{content:"\f133"}.fa-fire-extinguisher:before{content:"\f134"}.fa-rocket:before{content:"\f135"}.fa-maxcdn:before{content:"\f136"}.fa-chevron-circle-left:before{content:"\f137"}.fa-chevron-circle-right:before{content:"\f138"}.fa-chevron-circle-up:before{content:"\f139"}.fa-chevron-circle-down:before{content:"\f13a"}.fa-html5:before{content:"\f13b"}.fa-css3:before{content:"\f13c"}.fa-anchor:before{content:"\f13d"}.fa-unlock-alt:before{content:"\f13e"}.fa-bullseye:before{content:"\f140"}.fa-ellipsis-h:before{content:"\f141"}.fa-ellipsis-v:before{content:"\f142"}.fa-rss-square:before{content:"\f143"}.fa-play-circle:before{content:"\f144"}.fa-ticket:before{content:"\f145"}.fa-minus-square:before{content:"\f146"}.fa-minus-square-o:before{content:"\f147"}.fa-level-up:before{content:"\f148"}.fa-level-down:before{content:"\f149"}.fa-check-square:before{content:"\f14a"}.fa-pencil-square:before{content:"\f14b"}.fa-external-link-square:before{content:"\f14c"}.fa-share-square:before{content:"\f14d"}.fa-compass:before{content:"\f14e"}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:"\f150"}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:"\f151"}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:"\f152"}.fa-euro:before,.fa-eur:before{content:"\f153"}.fa-gbp:before{content:"\f154"}.fa-dollar:before,.fa-usd:before{content:"\f155"}.fa-rupee:before,.fa-inr:before{content:"\f156"}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:"\f157"}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:"\f158"}.fa-won:before,.fa-krw:before{content:"\f159"}.fa-bitcoin:before,.fa-btc:before{content:"\f15a"}.fa-file:before{content:"\f15b"}.fa-file-text:before{content:"\f15c"}.fa-sort-alpha-asc:before{content:"\f15d"}.fa-sort-alpha-desc:before{content:"\f15e"}.fa-sort-amount-asc:before{content:"\f160"}.fa-sort-amount-desc:before{content:"\f161"}.fa-sort-numeric-asc:before{content:"\f162"}.fa-sort-numeric-desc:before{content:"\f163"}.fa-thumbs-up:before{content:"\f164"}.fa-thumbs-down:before{content:"\f165"}.fa-youtube-square:before{content:"\f166"}.fa-youtube:before{content:"\f167"}.fa-xing:before{content:"\f168"}.fa-xing-square:before{content:"\f169"}.fa-youtube-play:before{content:"\f16a"}.fa-dropbox:before{content:"\f16b"}.fa-stack-overflow:before{content:"\f16c"}.fa-instagram:before{content:"\f16d"}.fa-flickr:before{content:"\f16e"}.fa-adn:before{content:"\f170"}.fa-bitbucket:before{content:"\f171"}.fa-bitbucket-square:before{content:"\f172"}.fa-tumblr:before{content:"\f173"}.fa-tumblr-square:before{content:"\f174"}.fa-long-arrow-down:before{content:"\f175"}.fa-long-arrow-up:before{content:"\f176"}.fa-long-arrow-left:before{content:"\f177"}.fa-long-arrow-right:before{content:"\f178"}.fa-apple:before{content:"\f179"}.fa-windows:before{content:"\f17a"}.fa-android:before{content:"\f17b"}.fa-linux:before{content:"\f17c"}.fa-dribbble:before{content:"\f17d"}.fa-skype:before{content:"\f17e"}.fa-foursquare:before{content:"\f180"}.fa-trello:before{content:"\f181"}.fa-female:before{content:"\f182"}.fa-male:before{content:"\f183"}.fa-gittip:before,.fa-gratipay:before{content:"\f184"}.fa-sun-o:before{content:"\f185"}.fa-moon-o:before{content:"\f186"}.fa-archive:before{content:"\f187"}.fa-bug:before{content:"\f188"}.fa-vk:before{content:"\f189"}.fa-weibo:before{content:"\f18a"}.fa-renren:before{content:"\f18b"}.fa-pagelines:before{content:"\f18c"}.fa-stack-exchange:before{content:"\f18d"}.fa-arrow-circle-o-right:before{content:"\f18e"}.fa-arrow-circle-o-left:before{content:"\f190"}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:"\f191"}.fa-dot-circle-o:before{content:"\f192"}.fa-wheelchair:before{content:"\f193"}.fa-vimeo-square:before{content:"\f194"}.fa-turkish-lira:before,.fa-try:before{content:"\f195"}.fa-plus-square-o:before{content:"\f196"}.fa-space-shuttle:before{content:"\f197"}.fa-slack:before{content:"\f198"}.fa-envelope-square:before{content:"\f199"}.fa-wordpress:before{content:"\f19a"}.fa-openid:before{content:"\f19b"}.fa-institution:before,.fa-bank:before,.fa-university:before{content:"\f19c"}.fa-mortar-board:before,.fa-graduation-cap:before{content:"\f19d"}.fa-yahoo:before{content:"\f19e"}.fa-google:before{content:"\f1a0"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-square:before{content:"\f1a2"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-stumbleupon:before{content:"\f1a4"}.fa-delicious:before{content:"\f1a5"}.fa-digg:before{content:"\f1a6"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-drupal:before{content:"\f1a9"}.fa-joomla:before{content:"\f1aa"}.fa-language:before{content:"\f1ab"}.fa-fax:before{content:"\f1ac"}.fa-building:before{content:"\f1ad"}.fa-child:before{content:"\f1ae"}.fa-paw:before{content:"\f1b0"}.fa-spoon:before{content:"\f1b1"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-behance:before{content:"\f1b4"}.fa-behance-square:before{content:"\f1b5"}.fa-steam:before{content:"\f1b6"}.fa-steam-square:before{content:"\f1b7"}.fa-recycle:before{content:"\f1b8"}.fa-automobile:before,.fa-car:before{content:"\f1b9"}.fa-cab:before,.fa-taxi:before{content:"\f1ba"}.fa-tree:before{content:"\f1bb"}.fa-spotify:before{content:"\f1bc"}.fa-deviantart:before{content:"\f1bd"}.fa-soundcloud:before{content:"\f1be"}.fa-database:before{content:"\f1c0"}.fa-file-pdf-o:before{content:"\f1c1"}.fa-file-word-o:before{content:"\f1c2"}.fa-file-excel-o:before{content:"\f1c3"}.fa-file-powerpoint-o:before{content:"\f1c4"}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:"\f1c5"}.fa-file-zip-o:before,.fa-file-archive-o:before{content:"\f1c6"}.fa-file-sound-o:before,.fa-file-audio-o:before{content:"\f1c7"}.fa-file-movie-o:before,.fa-file-video-o:before{content:"\f1c8"}.fa-file-code-o:before{content:"\f1c9"}.fa-vine:before{content:"\f1ca"}.fa-codepen:before{content:"\f1cb"}.fa-jsfiddle:before{content:"\f1cc"}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:"\f1cd"}.fa-circle-o-notch:before{content:"\f1ce"}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:"\f1d0"}.fa-ge:before,.fa-empire:before{content:"\f1d1"}.fa-git-square:before{content:"\f1d2"}.fa-git:before{content:"\f1d3"}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:"\f1d4"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-qq:before{content:"\f1d6"}.fa-wechat:before,.fa-weixin:before{content:"\f1d7"}.fa-send:before,.fa-paper-plane:before{content:"\f1d8"}.fa-send-o:before,.fa-paper-plane-o:before{content:"\f1d9"}.fa-history:before{content:"\f1da"}.fa-circle-thin:before{content:"\f1db"}.fa-header:before{content:"\f1dc"}.fa-paragraph:before{content:"\f1dd"}.fa-sliders:before{content:"\f1de"}.fa-share-alt:before{content:"\f1e0"}.fa-share-alt-square:before{content:"\f1e1"}.fa-bomb:before{content:"\f1e2"}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:"\f1e3"}.fa-tty:before{content:"\f1e4"}.fa-binoculars:before{content:"\f1e5"}.fa-plug:before{content:"\f1e6"}.fa-slideshare:before{content:"\f1e7"}.fa-twitch:before{content:"\f1e8"}.fa-yelp:before{content:"\f1e9"}.fa-newspaper-o:before{content:"\f1ea"}.fa-wifi:before{content:"\f1eb"}.fa-calculator:before{content:"\f1ec"}.fa-paypal:before{content:"\f1ed"}.fa-google-wallet:before{content:"\f1ee"}.fa-cc-visa:before{content:"\f1f0"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-bell-slash:before{content:"\f1f6"}.fa-bell-slash-o:before{content:"\f1f7"}.fa-trash:before{content:"\f1f8"}.fa-copyright:before{content:"\f1f9"}.fa-at:before{content:"\f1fa"}.fa-eyedropper:before{content:"\f1fb"}.fa-paint-brush:before{content:"\f1fc"}.fa-birthday-cake:before{content:"\f1fd"}.fa-area-chart:before{content:"\f1fe"}.fa-pie-chart:before{content:"\f200"}.fa-line-chart:before{content:"\f201"}.fa-lastfm:before{content:"\f202"}.fa-lastfm-square:before{content:"\f203"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-bicycle:before{content:"\f206"}.fa-bus:before{content:"\f207"}.fa-ioxhost:before{content:"\f208"}.fa-angellist:before{content:"\f209"}.fa-cc:before{content:"\f20a"}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:"\f20b"}.fa-meanpath:before{content:"\f20c"}.fa-buysellads:before{content:"\f20d"}.fa-connectdevelop:before{content:"\f20e"}.fa-dashcube:before{content:"\f210"}.fa-forumbee:before{content:"\f211"}.fa-leanpub:before{content:"\f212"}.fa-sellsy:before{content:"\f213"}.fa-shirtsinbulk:before{content:"\f214"}.fa-simplybuilt:before{content:"\f215"}.fa-skyatlas:before{content:"\f216"}.fa-cart-plus:before{content:"\f217"}.fa-cart-arrow-down:before{content:"\f218"}.fa-diamond:before{content:"\f219"}.fa-ship:before{content:"\f21a"}.fa-user-secret:before{content:"\f21b"}.fa-motorcycle:before{content:"\f21c"}.fa-street-view:before{content:"\f21d"}.fa-heartbeat:before{content:"\f21e"}.fa-venus:before{content:"\f221"}.fa-mars:before{content:"\f222"}.fa-mercury:before{content:"\f223"}.fa-intersex:before,.fa-transgender:before{content:"\f224"}.fa-transgender-alt:before{content:"\f225"}.fa-venus-double:before{content:"\f226"}.fa-mars-double:before{content:"\f227"}.fa-venus-mars:before{content:"\f228"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-v:before{content:"\f22a"}.fa-mars-stroke-h:before{content:"\f22b"}.fa-neuter:before{content:"\f22c"}.fa-genderless:before{content:"\f22d"}.fa-facebook-official:before{content:"\f230"}.fa-pinterest-p:before{content:"\f231"}.fa-whatsapp:before{content:"\f232"}.fa-server:before{content:"\f233"}.fa-user-plus:before{content:"\f234"}.fa-user-times:before{content:"\f235"}.fa-hotel:before,.fa-bed:before{content:"\f236"}.fa-viacoin:before{content:"\f237"}.fa-train:before{content:"\f238"}.fa-subway:before{content:"\f239"}.fa-medium:before{content:"\f23a"}.fa-yc:before,.fa-y-combinator:before{content:"\f23b"}.fa-optin-monster:before{content:"\f23c"}.fa-opencart:before{content:"\f23d"}.fa-expeditedssl:before{content:"\f23e"}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:"\f240"}.fa-battery-3:before,.fa-battery-three-quarters:before{content:"\f241"}.fa-battery-2:before,.fa-battery-half:before{content:"\f242"}.fa-battery-1:before,.fa-battery-quarter:before{content:"\f243"}.fa-battery-0:before,.fa-battery-empty:before{content:"\f244"}.fa-mouse-pointer:before{content:"\f245"}.fa-i-cursor:before{content:"\f246"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-sticky-note:before{content:"\f249"}.fa-sticky-note-o:before{content:"\f24a"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-diners-club:before{content:"\f24c"}.fa-clone:before{content:"\f24d"}.fa-balance-scale:before{content:"\f24e"}.fa-hourglass-o:before{content:"\f250"}.fa-hourglass-1:before,.fa-hourglass-start:before{content:"\f251"}.fa-hourglass-2:before,.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-3:before,.fa-hourglass-end:before{content:"\f253"}.fa-hourglass:before{content:"\f254"}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:"\f255"}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:"\f256"}.fa-hand-scissors-o:before{content:"\f257"}.fa-hand-lizard-o:before{content:"\f258"}.fa-hand-spock-o:before{content:"\f259"}.fa-hand-pointer-o:before{content:"\f25a"}.fa-hand-peace-o:before{content:"\f25b"}.fa-trademark:before{content:"\f25c"}.fa-registered:before{content:"\f25d"}.fa-creative-commons:before{content:"\f25e"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-tripadvisor:before{content:"\f262"}.fa-odnoklassniki:before{content:"\f263"}.fa-odnoklassniki-square:before{content:"\f264"}.fa-get-pocket:before{content:"\f265"}.fa-wikipedia-w:before{content:"\f266"}.fa-safari:before{content:"\f267"}.fa-chrome:before{content:"\f268"}.fa-firefox:before{content:"\f269"}.fa-opera:before{content:"\f26a"}.fa-internet-explorer:before{content:"\f26b"}.fa-tv:before,.fa-television:before{content:"\f26c"}.fa-contao:before{content:"\f26d"}.fa-500px:before{content:"\f26e"}.fa-amazon:before{content:"\f270"}.fa-calendar-plus-o:before{content:"\f271"}.fa-calendar-minus-o:before{content:"\f272"}.fa-calendar-times-o:before{content:"\f273"}.fa-calendar-check-o:before{content:"\f274"}.fa-industry:before{content:"\f275"}.fa-map-pin:before{content:"\f276"}.fa-map-signs:before{content:"\f277"}.fa-map-o:before{content:"\f278"}.fa-map:before{content:"\f279"}.fa-commenting:before{content:"\f27a"}.fa-commenting-o:before{content:"\f27b"}.fa-houzz:before{content:"\f27c"}.fa-vimeo:before{content:"\f27d"}.fa-black-tie:before{content:"\f27e"}.fa-fonticons:before{content:"\f280"}.fa-reddit-alien:before{content:"\f281"}.fa-edge:before{content:"\f282"}.fa-credit-card-alt:before{content:"\f283"}.fa-codiepie:before{content:"\f284"}.fa-modx:before{content:"\f285"}.fa-fort-awesome:before{content:"\f286"}.fa-usb:before{content:"\f287"}.fa-product-hunt:before{content:"\f288"}.fa-mixcloud:before{content:"\f289"}.fa-scribd:before{content:"\f28a"}.fa-pause-circle:before{content:"\f28b"}.fa-pause-circle-o:before{content:"\f28c"}.fa-stop-circle:before{content:"\f28d"}.fa-stop-circle-o:before{content:"\f28e"}.fa-shopping-bag:before{content:"\f290"}.fa-shopping-basket:before{content:"\f291"}.fa-hashtag:before{content:"\f292"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-percent:before{content:"\f295"}.fa-gitlab:before{content:"\f296"}.fa-wpbeginner:before{content:"\f297"}.fa-wpforms:before{content:"\f298"}.fa-envira:before{content:"\f299"}.fa-universal-access:before{content:"\f29a"}.fa-wheelchair-alt:before{content:"\f29b"}.fa-question-circle-o:before{content:"\f29c"}.fa-blind:before{content:"\f29d"}.fa-audio-description:before{content:"\f29e"}.fa-volume-control-phone:before{content:"\f2a0"}.fa-braille:before{content:"\f2a1"}.fa-assistive-listening-systems:before{content:"\f2a2"}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:"\f2a3"}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:"\f2a4"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-signing:before,.fa-sign-language:before{content:"\f2a7"}.fa-low-vision:before{content:"\f2a8"}.fa-viadeo:before{content:"\f2a9"}.fa-viadeo-square:before{content:"\f2aa"}.fa-snapchat:before{content:"\f2ab"}.fa-snapchat-ghost:before{content:"\f2ac"}.fa-snapchat-square:before{content:"\f2ad"}.fa-pied-piper:before{content:"\f2ae"}.fa-first-order:before{content:"\f2b0"}.fa-yoast:before{content:"\f2b1"}.fa-themeisle:before{content:"\f2b2"}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:"\f2b3"}.fa-fa:before,.fa-font-awesome:before{content:"\f2b4"}.fa-handshake-o:before{content:"\f2b5"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-open-o:before{content:"\f2b7"}.fa-linode:before{content:"\f2b8"}.fa-address-book:before{content:"\f2b9"}.fa-address-book-o:before{content:"\f2ba"}.fa-vcard:before,.fa-address-card:before{content:"\f2bb"}.fa-vcard-o:before,.fa-address-card-o:before{content:"\f2bc"}.fa-user-circle:before{content:"\f2bd"}.fa-user-circle-o:before{content:"\f2be"}.fa-user-o:before{content:"\f2c0"}.fa-id-badge:before{content:"\f2c1"}.fa-drivers-license:before,.fa-id-card:before{content:"\f2c2"}.fa-drivers-license-o:before,.fa-id-card-o:before{content:"\f2c3"}.fa-quora:before{content:"\f2c4"}.fa-free-code-camp:before{content:"\f2c5"}.fa-telegram:before{content:"\f2c6"}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:"\f2c7"}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-thermometer-2:before,.fa-thermometer-half:before{content:"\f2c9"}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:"\f2ca"}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:"\f2cb"}.fa-shower:before{content:"\f2cc"}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:"\f2cd"}.fa-podcast:before{content:"\f2ce"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-times-rectangle:before,.fa-window-close:before{content:"\f2d3"}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:"\f2d4"}.fa-bandcamp:before{content:"\f2d5"}.fa-grav:before{content:"\f2d6"}.fa-etsy:before{content:"\f2d7"}.fa-imdb:before{content:"\f2d8"}.fa-ravelry:before{content:"\f2d9"}.fa-eercast:before{content:"\f2da"}.fa-microchip:before{content:"\f2db"}.fa-snowflake-o:before{content:"\f2dc"}.fa-superpowers:before{content:"\f2dd"}.fa-wpexplorer:before{content:"\f2de"}.fa-meetup:before{content:"\f2e0"}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto} diff --git a/static/css/main.css b/static/css/main.css new file mode 100644 index 0000000..aacfa32 --- /dev/null +++ b/static/css/main.css @@ -0,0 +1,303 @@ +.container { + font-size: 0; + max-width: 12rem; + margin: 0 auto; + position: relative; +} + +.container .item { + display: inline-block; + width: 33.33%; + height: auto; + padding: .1rem; + position: relative; + border: none; +} + +.container .item .card { + display: block; + height: 100%; + background: #dedede; + position: relative; + cursor: -webkit-zoom-in; + cursor: zoom-in; +} + +.container .item .card img { + width: 100%; + border: 0; +} + +.container .item .card .mark { + width: 100%; + height: 100%; + position: absolute; + top: 0; + left: 0; + opacity: 0; + background: -webkit-gradient(linear, left top, left bottom, color-stop(0, rgba(0, 0, 0, 0.4)), color-stop(40%, transparent), color-stop(60%, transparent), color-stop(60%, rgba(0, 0, 0, 0.6))); + background: -webkit-linear-gradient(top, rgba(0, 0, 0, 0.4) 0, transparent 40%, transparent 60%, rgba(0, 0, 0, 0.6)); + background: linear-gradient(180deg, rgba(0, 0, 0, 0.4) 0, transparent 40%, transparent 60%, rgba(0, 0, 0, 0.6)); + -webkit-filter: blur(15px); + filter: blur(15px); + z-index: 1; + -webkit-transition: all .5s ease; + transition: all .5s ease; +} + +.container .item .card .options { + font-size: .12rem; + position: absolute; + right: .05rem; + bottom: .05rem; + padding: .05rem; + display: block; + text-align: right; + -webkit-transition: all .5s ease; + transition: all .5s ease; + opacity: 0; + z-index: 3; +} + +.container .item .card .ctrl { + display: inline-block; + height: .32rem; + line-height: .31rem; + background-color: rgba(255, 255, 255, 0.8); + border: 1px solid transparent; + cursor: pointer; + -webkit-border-radius: .06rem; + border-radius: .06rem; + -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); + text-align: center; + padding: 0 .1rem; +} + +.container .item .card .ctrl+.ctrl { + margin-left: .05rem; +} + +.container .item .card .ctrl.heart .icon { + color: #f15151 !important; +} + +.container .item .card .ctrl:hover { + background: #fff; +} + +.container .item .card .t { + margin-left: .05rem; + font-style: normal; +} + +.container .item .card .description { + position: absolute; + width: 100%; + left: 0; + top: 0; + padding: .05rem; + display: block; + color: #fff; + opacity: 0; + -webkit-transition: all .5s ease; + transition: all .5s ease; + z-index: 1; + pointer-events: none; +} + +.container .item .card .description h3 { + font-size: .14rem; + letter-spacing: .01rem; + font-weight: 400; + color: #fff; + padding: .02rem; +} + +.container .item .card .description p { + font-size: .12rem; +} + +.container .item .card .description p .icon { + color: #dedede; +} + +.container .item .card .description p .t { + color: #dedede; +} + +.container .item:hover .mark { + opacity: 1; +} + +.container .item:hover .options { + opacity: 1; +} + +.container .item:hover .description { + opacity: 1; +} + +.mobile .mark, +.mobile .options, +.mobile .description { + opacity: 1 !important; +} + +.ctrl.hide { + display: none; +} + +@media only screen and (max-width: 980px) { + .item { + padding: .08rem !important; + width: 50% !important; + } +} + +.page { + text-align: center; + padding: .3rem; +} + +.page a { + display: inline-block; + height: .32rem; + line-height: .31rem; + background-color: rgba(255, 255, 255, 0.8); + border: 1px solid #dedede; + cursor: pointer; + -webkit-border-radius: .06rem; + border-radius: .06rem; + -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); + text-align: center; + padding: 0 .1rem; +} + +.page span { + display: inline-block; + padding: 0 .1rem; +} + +.copyright { + padding-bottom: .3rem; + text-align: center; +} + + +/**********************Detail.css***********************/ + +.detail { + height: 100vh; + position: relative; + background: rgba(1, 1, 1, .5); +} + +.detail .mark { + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + z-index: -1; + background-size: cover; + background-position: center; + -webkit-transition: all .5s ease; + transition: all .5s ease; + -webkit-filter: blur(30px); + filter: blur(20px); +} + +.detail .preview img { + width: 0; + height: 0; + border: 0; +} + +.detail .preview .progressive { + background: transparent; +} + +.detail .preview .options { + font-size: .12rem; + padding: .1rem; + width: 100%; + display: block; + text-align: right; + -webkit-transition: all .5s ease; + transition: all .5s ease; + position: absolute; + right: 0; + top: 0; +} + +.detail .preview .ctrl { + display: inline-block; + height: .32rem; + line-height: .31rem; + background-color: rgba(255, 255, 255, 0.8); + border: 1px solid transparent; + cursor: pointer; + -webkit-border-radius: .06rem; + border-radius: .06rem; + -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); + text-align: center; + padding: 0 .1rem; +} + +.detail .preview .ctrl+.ctrl { + margin-left: .05rem; +} + +.detail .preview .ctrl.heart .icon { + color: #f15151 !important; +} + +.detail .preview .ctrl.left { + left: .15rem; + top: .1rem; + position: absolute; +} + +.detail .preview .ctrl:hover { + background: #fff; +} + +.detail .preview .ctrl .t { + font-style: normal; + margin-left: .05rem; + display: inline-block; + vertical-align: top; +} + +.detail .preview .description { + position: absolute; + left: 0; + bottom: 0; + padding: .1rem; + display: block; + width: 100%; + color: #fff; + background: rgba(1, 1, 1, 0.5); +} + +.detail .preview .description .title { + font-size: .2rem; +} + +.detail .preview .description .sub { + color: #c6cccc; +} + +.detail .preview .description .t { + font-style: normal; + margin-left: .05rem; + display: inline-block; + vertical-align: top; +} + +.detail .preview .description .show+.show { + margin-left: .3rem; +} \ No newline at end of file diff --git a/static/css/progressively.css b/static/css/progressively.css new file mode 100644 index 0000000..5dfa437 --- /dev/null +++ b/static/css/progressively.css @@ -0,0 +1,37 @@ +/* + * progressively 1.1.2 + * https://github.com/thinker3197/progressively + * @license MIT licensed + * + * Copyright (C) 2016-17 Ashish + */ + +.progressive { + overflow: hidden; + position: relative; + background: #efefef; +} + +.progressive__img { + width: 100%; + height: 100%; + transform: translateZ(0); +} + +.progressive--not-loaded { + filter: blur(30px); +} + +.progressive--is-loaded { + filter: blur(20px); + animation: sharpen 0.5s both; +} + +@keyframes sharpen { + from { + filter: blur(20px); + } + to { + filter: blur(0px); + } +} diff --git a/static/css/progressively.min.css b/static/css/progressively.min.css deleted file mode 100644 index fab4086..0000000 --- a/static/css/progressively.min.css +++ /dev/null @@ -1 +0,0 @@ -.progressive{overflow:hidden;position:relative;background:#efefef}.progressive__img{width:100%;height:100%;transform:translateZ(0)}.progressive--not-loaded{filter:blur(30px)}.progressive--is-loaded{filter:blur(20px);animation:a .5s both}@keyframes a{0%{filter:blur(20px)}to{filter:blur(0)}} \ No newline at end of file diff --git a/static/css/reset.css b/static/css/reset.css deleted file mode 100644 index 0522b0f..0000000 --- a/static/css/reset.css +++ /dev/null @@ -1 +0,0 @@ -*, :after, :before{box-sizing: border-box;}html{color:#000}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,textarea,p,blockquote,th,td{margin:0;padding:0}body{font:12px/1.5 'Lantinghei SC','HanHei SC','PingFang SC',arial,'Microsoft Yahei',georgia,verdana,helvetica,sans-serif;color:#000}ul,ol,menu{list-style:none}fieldset,img{border:none}img,object,select,input,textarea,button{outline:0;vertical-align:middle}button{border:none;cursor:pointer;padding:0}table{border-collapse:collapse;border-spacing:0}article,aside,footer,header,section,nav,menu,figure,figcaption,hgroup,details{display:block}address,caption,cite,code,dfn,em,strong,th,var,i,b,small,abbr{font-style:normal;font-weight:400}caption,th{text-align:left}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:400}abbr,acronym{border:0;font-variant:normal}sup{vertical-align:text-top}sub{vertical-align:text-bottom}input,textarea,select{font-family:inherit;font-size:inherit;font-weight:inherit}legend{color:#000}a{text-decoration:none}::selection{background-color:#39f;color:#fff}::-moz-selection{background-color:#39f;color:#fff}q:before,q:after{content:''}a:hover{text-decoration:underline} \ No newline at end of file diff --git a/static/css/skin/ie8.css b/static/css/skin/ie8.css deleted file mode 100644 index f3589d7..0000000 --- a/static/css/skin/ie8.css +++ /dev/null @@ -1,5 +0,0 @@ -/* Viewer */ - -#viewer { - width: 100%; -} \ No newline at end of file diff --git a/static/css/skin/ie9.css b/static/css/skin/ie9.css deleted file mode 100644 index 323c30f..0000000 --- a/static/css/skin/ie9.css +++ /dev/null @@ -1,26 +0,0 @@ -/* Thumbnails */ - -#thumbnails:after { - content: ''; - display: block; - clear: both; -} - -#thumbnails article { - float: left; -} - - -/* Viewer */ - -#viewer .inner { - box-shadow: inset 0 0 9em 2em rgba(16, 16, 16, 0.2); -} - -#viewer .inner:before { - display: none; -} - -#viewer .slide .caption { - background-color: rgba(16, 16, 16, 0.5); -} \ No newline at end of file diff --git a/static/css/skin/images/arrow-small.svg b/static/css/skin/images/arrow-small.svg deleted file mode 100644 index 9b7b156..0000000 --- a/static/css/skin/images/arrow-small.svg +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/static/css/skin/images/arrow.svg b/static/css/skin/images/arrow.svg deleted file mode 100644 index 06f32b3..0000000 --- a/static/css/skin/images/arrow.svg +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/static/css/skin/images/close-small-alt.svg b/static/css/skin/images/close-small-alt.svg deleted file mode 100644 index 2da146b..0000000 --- a/static/css/skin/images/close-small-alt.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - \ No newline at end of file diff --git a/static/css/skin/images/close-small.svg b/static/css/skin/images/close-small.svg deleted file mode 100644 index 27cc12a..0000000 --- a/static/css/skin/images/close-small.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - \ No newline at end of file diff --git a/static/css/skin/images/close.svg b/static/css/skin/images/close.svg deleted file mode 100644 index 8401a83..0000000 --- a/static/css/skin/images/close.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - \ No newline at end of file diff --git a/static/css/skin/images/open-small.svg b/static/css/skin/images/open-small.svg deleted file mode 100644 index f1cabee..0000000 --- a/static/css/skin/images/open-small.svg +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/static/css/skin/images/open.svg b/static/css/skin/images/open.svg deleted file mode 100644 index c0043ca..0000000 --- a/static/css/skin/images/open.svg +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - \ No newline at end of file diff --git a/static/css/skin/images/spinner.svg b/static/css/skin/images/spinner.svg deleted file mode 100644 index 8c15bed..0000000 --- a/static/css/skin/images/spinner.svg +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/static/css/skin/lens.css b/static/css/skin/lens.css deleted file mode 100644 index 419cf3c..0000000 --- a/static/css/skin/lens.css +++ /dev/null @@ -1,1278 +0,0 @@ -@import url(../font-awesome.min.css); -@import '../reset.css'; - -/* Reset */ - -html, -body, -div, -span, -applet, -object, -iframe, -h1, -h2, -h3, -h4, -h5, -h6, -p, -blockquote, -pre, -a, -abbr, -acronym, -address, -big, -cite, -code, -del, -dfn, -em, -img, -ins, -kbd, -q, -s, -samp, -small, -strike, -strong, -sub, -sup, -tt, -var, -b, -u, -i, -center, -dl, -dt, -dd, -ol, -ul, -li, -fieldset, -form, -label, -legend, -table, -caption, -tbody, -tfoot, -thead, -tr, -th, -td, -article, -aside, -canvas, -details, -embed, -figure, -figcaption, -footer, -header, -hgroup, -menu, -nav, -output, -ruby, -section, -summary, -time, -mark, -audio, -video { - margin: 0; - padding: 0; - border: 0; - font-size: 100%; - font: inherit; - vertical-align: baseline; -} - -article, -aside, -details, -figcaption, -figure, -footer, -header, -hgroup, -menu, -nav, -section { - display: block; -} - -body { - line-height: 1; -} - -ol, -ul { - list-style: none; -} - -blockquote, -q { - quotes: none; -} - -blockquote:before, -blockquote:after, -q:before, -q:after { - content: ''; - content: none; -} - -table { - border-collapse: collapse; - border-spacing: 0; -} - -body { - -webkit-text-size-adjust: none; -} - - -/* Box Model */ - -*, -*:before, -*:after { - box-sizing: border-box; -} - - -/* Basic */ - - -/* - @-ms-viewport { - width: device-width; - } - - */ - -@media screen and (max-width: 480px) { - html, - body { - min-width: 320px; - } -} - -body.is-loading-0 *, -body.is-loading-0 *:before, -body.is-loading-0 *:after { - -webkit-animation: none !important; - animation: none !important; - -webkit-transition: none !important; - transition: none !important; -} - -html, -body { - background-color: #3a3838; - overflow: hidden; -} - - -/* Type */ - -html { - font-size: 16pt; -} - -@media screen and (max-width: 1680px) { - html { - font-size: 12pt; - } -} - -@media screen and (max-width: 1280px) { - html { - font-size: 11pt; - } -} - -body { - background-color: #141724; - color: #aaa; -} - -body, -input, -select, -textarea { - font-family: CamingoCode, 'Lantinghei SC', 'HanHei SC', 'PingFang SC', arial, 'Microsoft Yahei', georgia, verdana, helvetica, sans-serif; - font-weight: 400; - line-height: 1.65; - font-size: 1em; - color: #aaa; -} - -a { - -webkit-transition: color 0.25s ease, border-bottom-color 0.25s ease; - transition: color 0.25s ease, border-bottom-color 0.25s ease; - border-bottom: dotted 1px; - color: inherit; - text-decoration: none; -} - -a:hover { - border-bottom-color: transparent; - color: #00D3B7; - text-decoration: none; -} - -strong, -b { - font-weight: 400; - color: #555; -} - -em, -i { - font-style: italic; -} - -p { - margin: 0; -} - -h1, -h2, -h3, -h4, -h5, -h6 { - font-weight: 400; - line-height: 1.25; - margin: 0 0 0.5em 0; - color: #555; -} - -h1 a, -h2 a, -h3 a, -h4 a, -h5 a, -h6 a { - color: inherit; - text-decoration: none; -} - -h2 { - font-size: 1.25em; -} - -h3 { - font-size: 1em; -} - -h4 { - font-size: 0.9em; -} - -h5 { - font-size: 0.8em; -} - -h6 { - font-size: 0.7em; -} - -sub { - font-size: 0.8em; - position: relative; - top: 0.5em; -} - -sup { - font-size: 0.8em; - position: relative; - top: -0.5em; -} - -blockquote { - border-left: solid 4px #ccc; - font-style: italic; - margin: 0 0 1.25em 0; - padding: 0.3125em 0 0.3125em 1.25em; -} - -code { - border: solid 1px; - font-family: "Courier New", monospace; - font-size: 0.9em; - margin: 0 0.25em; - padding: 0.25em 0.65em; - border-color: #ccc; -} - -pre { - -webkit-overflow-scrolling: touch; - font-family: "Courier New", monospace; - font-size: 0.9em; - margin: 0 0 1.25em 0; -} - -pre code { - display: block; - padding: 1em 1.5em; - overflow-x: auto; -} - -hr { - border: 0; - border-bottom: solid 1px #ccc; - margin: 1.25em 0; -} - -hr.major { - margin: 1.875em 0; -} - -.align-left { - text-align: left; -} - -.align-center { - text-align: center; -} - -.align-right { - text-align: right; -} - - -/* Button */ - -input[type="submit"], -input[type="reset"], -input[type="button"], -button, -.button { - -moz-appearance: none; - -webkit-appearance: none; - -ms-appearance: none; - appearance: none; - -webkit-transition: background-color 0.25s ease-in-out, border-color 0.25s ease-in-out, color 0.25s ease-in-out; - transition: background-color 0.25s ease-in-out, border-color 0.25s ease-in-out, color 0.25s ease-in-out; - background-color: transparent; - border: solid 1px #ccc; - color: #555; - cursor: pointer; - display: inline-block; - line-height: 1; - padding: 0.75em 1.5em; - text-align: center; - text-decoration: none; - white-space: nowrap; -} - -.button+.button { - margin-left: 5px; -} - -.caption input[type="submit"], -.caption input[type="reset"], -.caption input[type="button"], -.caption button, -.caption .button { - background-color: transparent; - border-color: #ffffff; - color: #ffffff; -} - -input[type="submit"]:hover, -input[type="reset"]:hover, -input[type="button"]:hover, -button:hover, -.button:hover { - border-color: #00D3B7; - color: #00D3B7; - text-decoration: none; -} - -input[type="submit"]:hover:active, -input[type="reset"]:hover:active, -input[type="button"]:hover:active, -button:hover:active, -.button:hover:active { - background-color: rgba(0, 211, 183, 0.15); -} - -input[type="submit"].icon, -input[type="reset"].icon, -input[type="button"].icon, -button.icon, -.button.icon { - padding-left: 1.35em; -} - -input[type="submit"].icon:before, -input[type="reset"].icon:before, -input[type="button"].icon:before, -button.icon:before, -.button.icon:before { - margin-right: 0.5em; -} - -input[type="submit"].fit, -input[type="reset"].fit, -input[type="button"].fit, -button.fit, -.button.fit { - display: block; - margin: 0 0 0.625em 0; - width: 100%; -} - -input[type="submit"].small, -input[type="reset"].small, -input[type="button"].small, -button.small, -.button.small { - font-size: 0.8em; -} - -input[type="submit"].big, -input[type="reset"].big, -input[type="button"].big, -button.big, -.button.big { - font-size: 1.35em; -} - -input[type="submit"].disabled, -input[type="submit"]:disabled, -input[type="reset"].disabled, -input[type="reset"]:disabled, -input[type="button"].disabled, -input[type="button"]:disabled, -button.disabled, -button:disabled, -.button.disabled, -.button:disabled { - -moz-pointer-events: none; - -webkit-pointer-events: none; - -ms-pointer-events: none; - pointer-events: none; - opacity: 0.25; -} - - -/* Form */ - -form { - margin: 0 0 1.25em 0; -} - -label { - color: #555; - display: block; - font-size: 0.9em; - font-weight: 400; - margin: 0 0 0.625em 0; -} - -input[type="text"], -input[type="password"], -input[type="email"], -select, -textarea { - -moz-appearance: none; - -webkit-appearance: none; - -ms-appearance: none; - appearance: none; - background-color: transparent; - border: solid 1px #ccc; - color: inherit; - display: block; - outline: 0; - padding: 0 0.75em; - text-decoration: none; - width: 100%; -} - -input[type="text"]:invalid, -input[type="password"]:invalid, -input[type="email"]:invalid, -select:invalid, -textarea:invalid { - box-shadow: none; -} - -input[type="text"]:focus, -input[type="password"]:focus, -input[type="email"]:focus, -select:focus, -textarea:focus { - border-color: #00D3B7; -} - -.select-wrapper { - text-decoration: none; - display: block; - position: relative; -} - -.select-wrapper:before { - -moz-osx-font-smoothing: grayscale; - -webkit-font-smoothing: antialiased; - font-family: FontAwesome; - font-style: normal; - font-weight: normal; - text-transform: none !important; -} - -.select-wrapper:before { - color: #ccc; - content: '\f107'; - display: block; - height: 2.75em; - line-height: 2.75em; - pointer-events: none; - position: absolute; - right: 0; - text-align: center; - top: 0; - width: 2.75em; -} - -.select-wrapper select::-ms-expand { - display: none; -} - -input[type="text"], -input[type="password"], -input[type="email"], -select { - height: 2.75em; -} - -textarea { - padding: 0.75em 1em; -} - -input[type="checkbox"], -input[type="radio"] { - -moz-appearance: none; - -webkit-appearance: none; - -ms-appearance: none; - appearance: none; - display: block; - float: left; - margin-right: -2em; - opacity: 0; - width: 1em; - z-index: -1; -} - -input[type="checkbox"]+label, -input[type="radio"]+label { - text-decoration: none; - color: #aaa; - cursor: pointer; - display: inline-block; - font-size: 1em; - font-weight: 400; - margin: 0; - padding-left: 2.4em; - padding-right: 0.75em; - position: relative; -} - -input[type="checkbox"]+label:before, -input[type="radio"]+label:before { - -moz-osx-font-smoothing: grayscale; - -webkit-font-smoothing: antialiased; - font-family: FontAwesome; - font-style: normal; - font-weight: normal; - text-transform: none !important; -} - -input[type="checkbox"]+label:before, -input[type="radio"]+label:before { - background: transparent; - border: solid 1px #ccc; - content: ''; - display: inline-block; - height: 1.65em; - left: 0; - line-height: 1.58125em; - position: absolute; - text-align: center; - top: 0; - width: 1.65em; -} - -input[type="checkbox"]:checked+label:before, -input[type="radio"]:checked+label:before { - background-color: #555; - border-color: #555; - color: #fff; - content: '\f00c'; -} - -input[type="checkbox"]:focus+label:before, -input[type="radio"]:focus+label:before { - border-color: #00D3B7; -} - -input[type="checkbox"]+label:before {} - -input[type="radio"]+label:before { - border-radius: 100%; -} - -::-webkit-input-placeholder { - opacity: 1.0; - color: #ccc !important; -} - -:-moz-placeholder { - opacity: 1.0; - color: #ccc !important; -} - -::-moz-placeholder { - opacity: 1.0; - color: #ccc !important; -} - -:-ms-input-placeholder { - opacity: 1.0; - color: #ccc !important; -} - -.formerize-placeholder { - opacity: 1.0; - color: #ccc !important; -} - -.field { - margin: 0 0 1.25em 0; -} - - -/* Icon */ - -.icon { - text-decoration: none; - border-bottom: none; - position: relative; -} - -.icon:before { - -moz-osx-font-smoothing: grayscale; - -webkit-font-smoothing: antialiased; - font-family: FontAwesome; - font-style: normal; - font-weight: normal; - text-transform: none !important; -} - -.icon>.label { - display: none; -} - -.icon.fa-github:hover { - color: #333333; -} - -.icon.fa-weibo:hover { - color: #E32428; -} - -.icon.fa-envelope:hover { - color: #627DFE; -} - - -/* List */ - -ol { - list-style: decimal; - margin: 0 0 1.25em 0; - padding-left: 1.25em; -} - -ol li { - padding-left: 0.25em; -} - -ul { - list-style: disc; - margin: 0 0 1.25em 0; - padding-left: 1em; -} - -ul li { - padding-left: 0.5em; -} - -ul.alt { - list-style: none; - padding-left: 0; -} - -ul.alt li { - border-top: solid 1px #ccc; - padding: 0.5em 0; -} - -ul.alt li:first-child { - border-top: 0; - padding-top: 0; -} - -ul.icons { - cursor: default; - list-style: none; - padding-left: 0; -} - -ul.icons li { - display: inline-block; - padding: 0 1em 0 0; -} - -ul.icons li:last-child { - padding-right: 0; -} - -ul.icons li .icon:before { - font-size: 1.5rem; -} - -ul.actions { - cursor: default; - list-style: none; - padding-left: 0; - padding-top: 15px; -} - -ul.actions li { - display: inline-block; - padding: 0 0.625em 0 0; - vertical-align: middle; -} - -ul.actions li:last-child { - padding-right: 0; -} - -ul.actions.small li { - padding: 0 0.3125em 0 0; -} - -ul.actions.vertical li { - display: block; - padding: 0.625em 0 0 0; -} - -ul.actions.vertical li:first-child { - padding-top: 0; -} - -ul.actions.vertical li>* { - margin-bottom: 0; -} - -ul.actions.vertical.small li { - padding: 0.3125em 0 0 0; -} - -ul.actions.vertical.small li:first-child { - padding-top: 0; -} - -ul.actions.fit { - display: table; - margin-left: -0.625em; - padding: 0; - table-layout: fixed; - width: calc(100% + 0.625em); -} - -ul.actions.fit li { - display: table-cell; - padding: 0 0 0 0.625em; -} - -ul.actions.fit li>* { - margin-bottom: 0; -} - -ul.actions.fit.small { - margin-left: -0.3125em; - width: calc(100% + 0.3125em); -} - -ul.actions.fit.small li { - padding: 0 0 0 0.3125em; -} - -dl { - margin: 0 0 1.25em 0; -} - -dl dt { - display: block; - font-weight: 400; - margin: 0 0 0.625em 0; -} - -dl dd { - margin-left: 1.25em; -} - - -/* Main */ - -#main { - -webkit-transition: opacity 0.75s ease, right 0.75s ease, left 0.75s ease, visibility 0.75s; - transition: opacity 0.75s ease, right 0.75s ease, left 0.75s ease, visibility 0.75s; - -webkit-overflow-scrolling: touch; - position: fixed; - top: 0; - width: 22.5em; - height: 100%; - background: #fff; - outline: 0; - overflow-x: hidden; - overflow-y: auto; - text-align: right; - visibility: visible; - z-index: 10000; - right: 0; -} - -#main .toggle { - -webkit-tap-highlight-color: transparent; - position: absolute; - top: 0; - width: 4em; - height: 4em; - background-image: url("images/close-small-alt.svg"); - background-repeat: no-repeat; - background-size: 32px 32px; - cursor: pointer; - display: none; - z-index: 1; - background-position: 0.5em 0.5em; - left: 0; -} - -body.fullscreen #main { - visibility: hidden; - right: -22.5em; -} - -body.is-loading-1 #main { - opacity: 0; - right: -2em; -} - -@media screen and (max-width: 1280px) { - #main { - width: 19em; - } - body.fullscreen #main { - right: -19em; - } -} - -@media screen and (max-width: 980px) { - #main { - background: rgba(255, 255, 255, 0.925); - } - #main .toggle { - display: block; - } -} - -@media screen and (max-width: 480px) { - #main { - -webkit-transition: opacity 0.5s ease, visibility 0.5s; - transition: opacity 0.5s ease, visibility 0.5s; - width: 100%; - background: #fff; - text-align: center; - } - body.is-loading-1 #main { - left: auto !important; - right: auto !important; - } - body.fullscreen #main { - left: auto !important; - right: auto !important; - opacity: 0; - } - #main .toggle { - display: none; - } -} - - -/* Header */ - -#header { - padding: 1.75em 2.25em; -} - -#header h1 { - font-size: 2.25em; - font-weight: 700; -} - - -/* Footer */ - -#footer { - padding: 0 1.25em; -} - -#footer .copyright { - list-style: none; - padding: 0; -} - -#footer .copyright li { - display: inline-block; - font-size: 0.8em; - margin-left: 0.35em; - padding: 0; -} - -#footer .copyright li:first-child { - margin-left: 0; -} - - -/* Thumbnails */ - -#thumbnails { - display: -moz-flex; - display: -ms-flex; - display: -webkit-box; - display: -ms-flexbox; - display: flex; - -ms-flex-wrap: wrap; - flex-wrap: wrap; - padding: 0 0.75em; -} - -#thumbnails article { - position: relative; - width: 50%; - background: #101010; - outline: 0; -} - -#thumbnails article .thumbnail { - -webkit-tap-highlight-color: transparent; - display: block; - position: relative; - border: 0; - outline: 0; -} - -#thumbnails article .thumbnail img { - display: block; - width: 100%; -} - -#thumbnails article .thumbnail:before { - -moz-pointer-events: none; - -webkit-pointer-events: none; - -ms-pointer-events: none; - pointer-events: none; - -webkit-transition: opacity 0.25s ease; - transition: opacity 0.25s ease; - content: ''; - position: absolute; - left: 0; - top: 0; - width: 100%; - height: 100%; - box-shadow: inset 0 0 0 2px #00D3B7, inset 0 0 0px 3px rgba(0, 0, 0, 0.15); - opacity: 0; - z-index: 1; -} - -#thumbnails article .thumbnail:focus:before { - opacity: 0.5; -} - -#thumbnails article h2, -#thumbnails article p { - display: none; -} - -#thumbnails article.active .thumbnail:before { - opacity: 1; -} - -@media screen and (max-width: 480px) { - #thumbnails article .thumbnail:before { - display: none; - } -} - - -/* Viewer */ - -@-webkit-keyframes spinner { - 0% { - -webkit-transform: rotate(0deg); - transform: rotate(0deg); - } - 100% { - -webkit-transform: rotate(360deg); - transform: rotate(360deg); - } -} - -@keyframes spinner { - 0% { - -webkit-transform: rotate(0deg); - transform: rotate(0deg); - } - 100% { - -webkit-transform: rotate(360deg); - transform: rotate(360deg); - } -} - -#viewer { - -webkit-transition: opacity 0.75s ease, width 0.75s ease; - transition: opacity 0.75s ease, width 0.75s ease; - position: absolute; - top: 0; - width: calc(100% - 22.5em); - height: 100%; - left: 0; -} - -#viewer .inner { - -moz-pointer-events: none; - -webkit-pointer-events: none; - -ms-pointer-events: none; - pointer-events: none; - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - z-index: 2; -} - -#viewer .inner>* { - -moz-pointer-events: auto; - -webkit-pointer-events: auto; - -ms-pointer-events: auto; - pointer-events: auto; -} - -#viewer .inner:before { - background-image: -webkit-linear-gradient(left, rgba(16, 16, 16, 0.2), rgba(16, 16, 16, 0) 10em, rgba(16, 16, 16, 0)), -webkit-linear-gradient(right, rgba(16, 16, 16, 0.2), rgba(16, 16, 16, 0) 10em, rgba(16, 16, 16, 0)); - background-image: linear-gradient(left, rgba(16, 16, 16, 0.2), rgba(16, 16, 16, 0) 10em, rgba(16, 16, 16, 0)), linear-gradient(right, rgba(16, 16, 16, 0.2), rgba(16, 16, 16, 0) 10em, rgba(16, 16, 16, 0)); - content: ''; - display: block; - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; -} - -#viewer .inner .toggle { - -webkit-tap-highlight-color: transparent; - position: absolute; - top: 0; - width: 4em; - height: 4em; - background-image: url("images/close.svg"); - background-repeat: no-repeat; - background-size: 64px 64px; - cursor: pointer; - z-index: 1; - right: 0; - background-position: calc(100% - 0.75em) 0.75em; -} - -#viewer .inner .nav-next, -#viewer .inner .nav-previous { - -webkit-tap-highlight-color: transparent; - position: absolute; - top: 50%; - width: 6em; - height: 6em; - margin-top: -3em; - background-image: url("images/arrow.svg"); - background-position: center; - background-repeat: no-repeat; - background-size: contain; - cursor: pointer; -} - -#viewer .inner .nav-previous { - -webkit-transform: scaleX(-1); - transform: scaleX(-1); - left: 0; -} - -#viewer .inner .nav-next { - right: 0; -} - -#viewer .slide { - -webkit-transition: opacity 0.5s ease-in-out; - transition: opacity 0.5s ease-in-out; - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - opacity: 1; - z-index: 1; -} - -#viewer .slide .caption { - background-image: -webkit-linear-gradient(bottom, rgba(16, 16, 16, 0.75), rgba(16, 16, 16, 0.25) 80%, rgba(16, 16, 16, 0)); - background-image: linear-gradient(bottom, rgba(16, 16, 16, 0.75), rgba(16, 16, 16, 0.25) 80%, rgba(16, 16, 16, 0)); - padding: 2em 2em 0.75em 2em; - position: absolute; - bottom: 0; - left: 0; - width: 100%; - color: rgba(255, 255, 255, 0.5); - z-index: 1; -} - -#viewer .slide .caption h2, -#viewer .slide .caption h3, -#viewer .slide .caption h4, -#viewer .slide .caption h5, -#viewer .slide .caption h6 { - color: #fff; -} - -#viewer .slide .image { - -webkit-transition: opacity 0.5s ease-in-out; - transition: opacity 0.5s ease-in-out; - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - background-repeat: no-repeat; - background-size: cover; - opacity: 0; -} - -#viewer .slide:before { - -webkit-animation: spinner 1s linear infinite; - animation: spinner 1s linear infinite; - -webkit-transition: opacity 0.5s ease-in-out; - transition: opacity 0.5s ease-in-out; - content: ''; - display: block; - position: absolute; - top: 50%; - left: 50%; - width: 3em; - height: 3em; - background-image: url("images/spinner.svg"); - background-position: center; - background-repeat: no-repeat; - background-size: contain; - margin: -1.5em 0 0 -1.5em; - opacity: 0; -} - -#viewer .slide.loading:before { - opacity: 1; -} - -#viewer .slide.active .image { - opacity: 1; -} - -body.fullscreen #viewer { - width: 100%; -} - -body.fullscreen #viewer .inner .toggle { - background-image: url("images/open.svg"); -} - -body.is-loading-1 #viewer { - opacity: 0; -} - -body.is-loading-2 #viewer .slide { - opacity: 0; -} - -@media screen and (max-width: 1280px) { - #viewer { - width: calc(100% - 19em); - } -} - -@media screen and (max-width: 980px) { - #viewer { - width: 100%; - } - #viewer .inner .toggle { - -webkit-transition: opacity 0.75s ease; - transition: opacity 0.75s ease; - background-image: url("images/open.svg"); - opacity: 0; - right: 0; - } - body.fullscreen #viewer .inner .toggle { - opacity: 1; - } -} - -@media screen and (max-width: 736px) { - #viewer .inner .toggle { - background-size: 32px 32px; - } - #viewer .inner .nav-next, - #viewer .inner .nav-previous { - background-image: url("images/arrow-small.svg"); - background-size: 32px 32px; - } - body.fullscreen #viewer .inner .toggle { - background-image: url("images/open-small.svg"); - } -} - -@media screen and (max-width: 480px) { - #viewer { - -webkit-transition: opacity 0.5s ease; - transition: opacity 0.5s ease; - -webkit-transition-delay: 0s; - transition-delay: 0s; - opacity: 0; - } - #viewer .inner .toggle { - background-image: url("images/close-small.svg") !important; - background-size: 32px 32px; - } - body.fullscreen #viewer { - -webkit-transition-delay: 0.5s; - transition-delay: 0.5s; - opacity: 1; - } -} \ No newline at end of file diff --git a/static/css/skin/noscript.css b/static/css/skin/noscript.css deleted file mode 100644 index 5988f30..0000000 --- a/static/css/skin/noscript.css +++ /dev/null @@ -1,23 +0,0 @@ -/* Main */ - -#main { - opacity: 1 !important; - right: 0 !important; -} - -body:before { - content: 'Javascript is disabled :('; - display: block; - position: absolute; - top: 50%; - width: calc(100% - 22.5em * 0.333333333); - height: 4em; - margin-top: -2em; - color: #272727; - cursor: default; - font-size: 3em; - line-height: 4em; - text-align: center; - white-space: nowrap; - left: 0; -} \ No newline at end of file diff --git a/static/fonts/FontAwesome.otf b/static/fonts/FontAwesome.otf deleted file mode 100644 index 401ec0f..0000000 Binary files a/static/fonts/FontAwesome.otf and /dev/null differ diff --git a/static/fonts/fontawesome-webfont.eot b/static/fonts/fontawesome-webfont.eot deleted file mode 100644 index e9f60ca..0000000 Binary files a/static/fonts/fontawesome-webfont.eot and /dev/null differ diff --git a/static/fonts/fontawesome-webfont.svg b/static/fonts/fontawesome-webfont.svg deleted file mode 100644 index 855c845..0000000 --- a/static/fonts/fontawesome-webfont.svg +++ /dev/null @@ -1,2671 +0,0 @@ - - - - -Created by FontForge 20120731 at Mon Oct 24 17:37:40 2016 - By ,,, -Copyright Dave Gandy 2016. All rights reserved. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/static/fonts/fontawesome-webfont.ttf b/static/fonts/fontawesome-webfont.ttf deleted file mode 100644 index 35acda2..0000000 Binary files a/static/fonts/fontawesome-webfont.ttf and /dev/null differ diff --git a/static/fonts/fontawesome-webfont.woff b/static/fonts/fontawesome-webfont.woff deleted file mode 100644 index 400014a..0000000 Binary files a/static/fonts/fontawesome-webfont.woff and /dev/null differ diff --git a/static/fonts/fontawesome-webfont.woff2 b/static/fonts/fontawesome-webfont.woff2 deleted file mode 100644 index 4d13fc6..0000000 Binary files a/static/fonts/fontawesome-webfont.woff2 and /dev/null differ diff --git a/static/js/baidu-analysis.js b/static/js/baidu-analysis.js new file mode 100644 index 0000000..1003922 --- /dev/null +++ b/static/js/baidu-analysis.js @@ -0,0 +1,18 @@ +if (!/^http:\/\/localhost/.test(location.href)) { + var _hmt = _hmt || []; + var hm = document.createElement("script"); + hm.src = "//hm.baidu.com/hm.js?667639aad0d4654c92786a241a486361"; + var s = document.getElementsByTagName("script")[0]; + s.parentNode.insertBefore(hm, s); + + var bp = document.createElement('script'); + var curProtocol = window.location.protocol.split(':')[0]; + if (curProtocol === 'https') { + bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; + } + else { + bp.src = 'http://push.zhanzhang.baidu.com/push.js'; + } + var s = document.getElementsByTagName("script")[0]; + s.parentNode.insertBefore(bp, s); +} diff --git a/static/js/device.js b/static/js/device.js new file mode 100644 index 0000000..a5261d5 --- /dev/null +++ b/static/js/device.js @@ -0,0 +1,78 @@ +//***************************************************** +//获取浏览器或设备名称 以及版本号 +//***************************************************** +//输出结果: +//--------------------------------------------------------- +//DEVICE.isIpad @return:Boolean 是否是:ipad +//DEVICE.isIphone @return:Boolean 是否是:ipbone +//DEVICE.isAndroid @return:Boolean 是否是:android +//DEVICE.isIe @return:Boolean 是否是:ie +//DEVICE.isFirefox @return:Boolean 是否是:firefox +//DEVICE.isChrome @return:Boolean 是否是:chrome +//DEVICE.isOpera @return:Boolean 是否是:opera +//DEVICE.isSafari @return:Boolean 是否是:safari + +//DEVICE.isPc @return:Boolean 是否是:pc +//DEVICE.isMac @return:Boolean 是否是:mac +//DEVICE.isLinux @return:Boolean 是否是:linux +//DEVICE.isMobile @return:Boolean 是否是:移动设备,非pc + +//DEVICE.ver @return:Number 浏览器版本或 ipad/iphone/android系统版本 +//--------------------------------------------------------- +(function() { + var DEVICE = {}; + var Sys = {}; + var ua = navigator.userAgent.toLowerCase(); + var s; + (s = ua.match(/ipad; cpu os ([\d_]+)/)) ? Sys.ipad = s[1].replace(/_/g, "."): + (s = ua.match(/iphone os ([\d_]+)/)) ? Sys.iphone = s[1].replace(/_/g, ".") : + (s = ua.match(/android[ \/]([\d.]+)/)) ? Sys.android = s[1] : + (s = ua.match(/rv:([\d.]+)\) like gecko/)) ? Sys.ie = s[1] : + (s = ua.match(/msie ([\d.]+)/)) ? Sys.ie = s[1] : + (s = ua.match(/firefox\/([\d.]+)/)) ? Sys.firefox = s[1] : + (s = ua.match(/chrome\/([\d.]+)/)) ? Sys.chrome = s[1] : + (s = ua.match(/opera.([\d.]+)/)) ? Sys.opera = s[1] : + (s = ua.match(/version\/([\d.]+).*safari/)) ? Sys.safari = s[1] : Sys._ = 0; + + DEVICE.isIpad = (Sys.hasOwnProperty("ipad")); + DEVICE.isIphone = (Sys.hasOwnProperty("iphone")); + DEVICE.isAndroid = (Sys.hasOwnProperty("android")); + DEVICE.isIe = (Sys.hasOwnProperty("ie")); + DEVICE.isFirefox = (Sys.hasOwnProperty("firefox")); + DEVICE.isChrome = (Sys.hasOwnProperty("chrome")); + DEVICE.isOpera = (Sys.hasOwnProperty("opera")); + DEVICE.isSafari = (Sys.hasOwnProperty("safari")); + + DEVICE.ver = 0; + var ver; + for (var key in Sys) { + if (Sys.hasOwnProperty(key)) { + ver = Sys[key]; + } + } + ver = ver.split("."); + var _ver = []; + for (var i = 0, l = ver.length; i < l; i++) { + if (i >= 2) { + break; + } + _ver.push(ver[i]); + } + _ver = _ver.join("."); + DEVICE.ver = _ver; + + DEVICE.isMobile = (DEVICE.isAndroid || DEVICE.isIpad || DEVICE.isIphone); + + var p = navigator.platform; + var win = p.indexOf("Win") === 0; + var mac = p.indexOf("Mac") === 0; + var x11 = (p == "X11") || (p.indexOf("Linux") === 0); + + DEVICE.isPc = (win || mac || x11); + DEVICE.isMobile = !(win || mac || x11); + DEVICE.isMac = mac; + DEVICE.isWin = win; + DEVICE.isLinux = x11; + + window.DEVICE = DEVICE; +})(); \ No newline at end of file diff --git a/static/js/error.js b/static/js/error.js deleted file mode 100644 index c94d7bb..0000000 --- a/static/js/error.js +++ /dev/null @@ -1,16 +0,0 @@ -function generateStars() { - for (var i = 0; i < 200; i++) { - document.getElementById('stars').innerHTML += '
'; - } - - var stars = document.getElementsByClassName('star'); - for (var t = 0; t < stars.length; t++) { - stars[t].style.left = (Math.random() * 110) + "%"; - stars[t].style.top = (Math.random() * 90) + "%"; - var size = Math.random() * 4; - stars[t].style.height = size + "px"; - stars[t].style.width = size + "px"; - var animationTime = (Math.random() * 2) + 1; - stars[t].style.animation = "twinkle " + animationTime + "s infinite"; - } -} \ No newline at end of file diff --git a/static/js/html5shiv.js b/static/js/html5shiv.js index de8b840..dcf351c 100644 --- a/static/js/html5shiv.js +++ b/static/js/html5shiv.js @@ -1,86 +1,8 @@ -/** - * @preserve HTML5 Shiv 3.7.3 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed - */ -! function (a, b) { - function c(a, b) { - var c = a.createElement("p") - , d = a.getElementsByTagName("head")[0] || a.documentElement; - return c.innerHTML = "x", d.insertBefore(c.lastChild, d.firstChild) - } - - function d() { - var a = t.elements; - return "string" == typeof a ? a.split(" ") : a - } - - function e(a, b) { - var c = t.elements; - "string" != typeof c && (c = c.join(" ")), "string" != typeof a && (a = a.join(" ")), t.elements = c + " " + a, j(b) - } - - function f(a) { - var b = s[a[q]]; - return b || (b = {}, r++, a[q] = r, s[r] = b), b - } - - function g(a, c, d) { - if (c || (c = b), l) return c.createElement(a); - d || (d = f(c)); - var e; - return e = d.cache[a] ? d.cache[a].cloneNode() : p.test(a) ? (d.cache[a] = d.createElem(a)).cloneNode() : d.createElem(a), !e.canHaveChildren || o.test(a) || e.tagUrn ? e : d.frag.appendChild(e) - } - - function h(a, c) { - if (a || (a = b), l) return a.createDocumentFragment(); - c = c || f(a); - for (var e = c.frag.cloneNode(), g = 0, h = d(), i = h.length; i > g; g++) e.createElement(h[g]); - return e - } - - function i(a, b) { - b.cache || (b.cache = {}, b.createElem = a.createElement, b.createFrag = a.createDocumentFragment, b.frag = b.createFrag()), a.createElement = function (c) { - return t.shivMethods ? g(c, a, b) : b.createElem(c) - }, a.createDocumentFragment = Function("h,f", "return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&(" + d().join().replace(/[\w\-:]+/g, function (a) { - return b.createElem(a), b.frag.createElement(a), 'c("' + a + '")' - }) + ");return n}")(t, b.frag) - } - - function j(a) { - a || (a = b); - var d = f(a); - return !t.shivCSS || k || d.hasCSS || (d.hasCSS = !!c(a, "article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")), l || i(a, d), a - } - var k, l, m = "3.7.3" - , n = a.html5 || {} - , o = /^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i - , p = /^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i - , q = "_html5shiv" - , r = 0 - , s = {}; - ! function () { - try { - var a = b.createElement("a"); - a.innerHTML = "", k = "hidden" in a, l = 1 == a.childNodes.length || function () { - b.createElement("a"); - var a = b.createDocumentFragment(); - return "undefined" == typeof a.cloneNode || "undefined" == typeof a.createDocumentFragment || "undefined" == typeof a.createElement - }() - } - catch (c) { - k = !0, l = !0 - } - }(); - var t = { - elements: n.elements || "abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output picture progress section summary template time video" - , version: m - , shivCSS: n.shivCSS !== !1 - , supportsUnknownElements: l - , shivMethods: n.shivMethods !== !1 - , type: "default" - , shivDocument: j - , createElement: g - , createDocumentFragment: h - , addElements: e - }; - a.html5 = t, j(b), "object" == typeof module && module.exports && (module.exports = t) -}("undefined" != typeof window ? window : this, document); \ No newline at end of file +/* + HTML5 Shiv v3.6.2 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed +*/ +(function(l,f){function m(){var a=e.elements;return"string"==typeof a?a.split(" "):a}function i(a){var b=n[a[o]];b||(b={},h++,a[o]=h,n[h]=b);return b}function p(a,b,c){b||(b=f);if(g)return b.createElement(a);c||(c=i(b));b=c.cache[a]?c.cache[a].cloneNode():r.test(a)?(c.cache[a]=c.createElem(a)).cloneNode():c.createElem(a);return b.canHaveChildren&&!s.test(a)?c.frag.appendChild(b):b}function t(a,b){if(!b.cache)b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag(); +a.createElement=function(c){return!e.shivMethods?b.createElem(c):p(c,a,b)};a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+m().join().replace(/\w+/g,function(a){b.createElem(a);b.frag.createElement(a);return'c("'+a+'")'})+");return n}")(e,b.frag)}function q(a){a||(a=f);var b=i(a);if(e.shivCSS&&!j&&!b.hasCSS){var c,d=a;c=d.createElement("p");d=d.getElementsByTagName("head")[0]||d.documentElement;c.innerHTML="x"; +c=d.insertBefore(c.lastChild,d.firstChild);b.hasCSS=!!c}g||t(a,b);return a}var k=l.html5||{},s=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,r=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,j,o="_html5shiv",h=0,n={},g;(function(){try{var a=f.createElement("a");a.innerHTML="";j="hidden"in a;var b;if(!(b=1==a.childNodes.length)){f.createElement("a");var c=f.createDocumentFragment();b="undefined"==typeof c.cloneNode|| +"undefined"==typeof c.createDocumentFragment||"undefined"==typeof c.createElement}g=b}catch(d){g=j=!0}})();var e={elements:k.elements||"abbr article aside audio bdi canvas data datalist details figcaption figure footer header hgroup main mark meter nav output progress section summary time video",version:"3.6.2",shivCSS:!1!==k.shivCSS,supportsUnknownElements:g,shivMethods:!1!==k.shivMethods,type:"default",shivDocument:q,createElement:p,createDocumentFragment:function(a,b){a||(a=f);if(g)return a.createDocumentFragment(); +for(var b=b||i(a),c=b.frag.cloneNode(),d=0,e=m(),h=e.length;db?a:a.substr(0,b)}function z(a){for(;a&&"A"!=a.nodeName;)a=a.parentNode;return a}function A(a){var b=e.protocol+"//"+e.host;if(!(b=a.target||a.hasAttribute("download")||0!=a.href.indexOf(b+"/")||-1+new Date-500||(a=z(a.target))&&A(a)&&x(a.href)}function N(a){G>+new Date-500||(a=z(a.target))&&A(a)&&(a.addEventListener("mouseout",T),H?(O=a.href,l=setTimeout(x,H)):x(a.href))}function U(a){G=+new Date;(a=z(a.target))&&A(a)&&(D?a.removeEventListener("mousedown", +M):a.removeEventListener("mouseover",N),x(a.href))}function V(a){var b=z(a.target);!b||!A(b)||1p.readyState)&&0!=p.status){q.ready=+new Date-q.start;if(p.getResponseHeader("Content-Type").match(/\/(x|ht|xht)ml/)){var a=d.implementation.createHTMLDocument("");a.documentElement.innerHTML=p.responseText.replace(//gi,"");y=a.title; +u=a.body;var b=t("receive",r,u,y);b&&("body"in b&&(u=b.body),"title"in b&&(y=b.title));b=w(r);h[b]={body:u,title:y,scrollY:b in h?h[b].scrollY:0};for(var a=a.head.children,b=0,c,g=a.length-1;0<=g;g--)if(c=a[g],c.hasAttribute("data-instant-track")){c=c.getAttribute("href")||c.getAttribute("src")||c.innerHTML;for(var e=E.length-1;0<=e;e--)E[e]==c&&b++}b!=E.length&&(F=!0)}else F=!0;m&&(m=!1,P(r))}}function L(a){d.body.addEventListener("touchstart",U,!0);D?d.body.addEventListener("mousedown",M,!0):d.body.addEventListener("mouseover", +N,!0);d.body.addEventListener("click",V,!0);if(!a){a=d.body.getElementsByTagName("script");var b,c,g,e;i=0;for(j=a.length;i+new Date-(q.start+q.display)||(l&&(clearTimeout(l),l=!1),a||(a=O),v&&(a==r||m))||(v=!0,m=!1,r=a,F=u=!1,q={start:+new Date},t("fetch"), +p.open("GET",a),p.send())}function P(a){"display"in q||(q.display=+new Date-q.start);l||!v?l&&r&&r!=a?e.href=a:(x(a),C.start(0,!0),t("wait"),m=!0):m?e.href=a:F?e.href=r:u?(h[k].scrollY=pageYOffset,m=v=!1,K(y,u,r)):(C.start(0,!0),t("wait"),m=!0)}var I=navigator.userAgent,S=-1b;b++)a[b]+"Transform"in h.style&&(k=a[b]+"Transform");var c="transition";if(!(c in h.style))for(b=0;3>b;b++)a[b]+"Transition"in +h.style&&(c="-"+a[b].toLowerCase()+"-"+c);a=d.createElement("style");a.innerHTML="#instantclick{position:"+(Q?"absolute":"fixed")+";top:0;left:0;width:100%;pointer-events:none;z-index:2147483647;"+c+":opacity .25s .1s}.instantclick-bar{background:#29d;width:100%;margin-left:-100%;height:2px;"+c+":all .25s}";d.head.appendChild(a);Q&&(m(),addEventListener("resize",m),addEventListener("scroll",m))},start:a,done:e}}(),R="pushState"in history&&(!I.match("Android")||I.match("Chrome/"))&&"file:"!=e.protocol; +return{supported:R,init:function(){if(!k)if(R){for(var a=arguments.length-1;0<=a;a--){var b=arguments[a];!0===b?J=!0:"mousedown"==b?D=!0:"number"==typeof b&&(H=b)}k=w(e.href);h[k]={body:d.body,title:d.title,scrollY:pageYOffset};for(var b=d.head.children,c,a=b.length-1;0<=a;a--)c=b[a],c.hasAttribute("data-instant-track")&&(c=c.getAttribute("href")||c.getAttribute("src")||c.innerHTML,E.push(c));p=new XMLHttpRequest;p.addEventListener("readystatechange",W);L(!0);C.init();t("change",!0);addEventListener("popstate", +function(){var a=w(e.href);a!=k&&(a in h?(h[k].scrollY=pageYOffset,k=a,K(h[a].title,h[a].body,!1,h[a].scrollY)):e.href=e.href)})}else t("change",!0)},on:function(a,b){B[a].push(b)}}}(document,location); diff --git a/static/js/jquery-1.12.4.min.js b/static/js/jquery-1.12.4.min.js new file mode 100644 index 0000000..e836475 --- /dev/null +++ b/static/js/jquery-1.12.4.min.js @@ -0,0 +1,5 @@ +/*! jQuery v1.12.4 | (c) jQuery Foundation | jquery.org/license */ +!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=a.document,e=c.slice,f=c.concat,g=c.push,h=c.indexOf,i={},j=i.toString,k=i.hasOwnProperty,l={},m="1.12.4",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return e.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:e.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a){return n.each(this,a)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(e.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor()},push:g,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(e=arguments[h]))for(d in e)a=g[d],c=e[d],g!==c&&(j&&c&&(n.isPlainObject(c)||(b=n.isArray(c)))?(b?(b=!1,f=a&&n.isArray(a)?a:[]):f=a&&n.isPlainObject(a)?a:{},g[d]=n.extend(j,f,c)):void 0!==c&&(g[d]=c));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray||function(a){return"array"===n.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){var b=a&&a.toString();return!n.isArray(a)&&b-parseFloat(b)+1>=0},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},isPlainObject:function(a){var b;if(!a||"object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;try{if(a.constructor&&!k.call(a,"constructor")&&!k.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}if(!l.ownFirst)for(b in a)return k.call(a,b);for(b in a);return void 0===b||k.call(a,b)},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?i[j.call(a)]||"object":typeof a},globalEval:function(b){b&&n.trim(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b){var c,d=0;if(s(a)){for(c=a.length;c>d;d++)if(b.call(a[d],d,a[d])===!1)break}else for(d in a)if(b.call(a[d],d,a[d])===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):g.call(c,a)),c},inArray:function(a,b,c){var d;if(b){if(h)return h.call(b,a,c);for(d=b.length,c=c?0>c?Math.max(0,d+c):c:0;d>c;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,b){var c=+b.length,d=0,e=a.length;while(c>d)a[e++]=b[d++];if(c!==c)while(void 0!==b[d])a[e++]=b[d++];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,e,g=0,h=[];if(s(a))for(d=a.length;d>g;g++)e=b(a[g],g,c),null!=e&&h.push(e);else for(g in a)e=b(a[g],g,c),null!=e&&h.push(e);return f.apply([],h)},guid:1,proxy:function(a,b){var c,d,f;return"string"==typeof b&&(f=a[b],b=a,a=f),n.isFunction(a)?(c=e.call(arguments,2),d=function(){return a.apply(b||this,c.concat(e.call(arguments)))},d.guid=a.guid=a.guid||n.guid++,d):void 0},now:function(){return+new Date},support:l}),"function"==typeof Symbol&&(n.fn[Symbol.iterator]=c[Symbol.iterator]),n.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(a,b){i["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=!!a&&"length"in a&&a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ga(),z=ga(),A=ga(),B=function(a,b){return a===b&&(l=!0),0},C=1<<31,D={}.hasOwnProperty,E=[],F=E.pop,G=E.push,H=E.push,I=E.slice,J=function(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return c;return-1},K="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",N="\\["+L+"*("+M+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+M+"))|)"+L+"*\\]",O=":("+M+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+N+")*)|.*)\\)|)",P=new RegExp(L+"+","g"),Q=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),R=new RegExp("^"+L+"*,"+L+"*"),S=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),T=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),U=new RegExp(O),V=new RegExp("^"+M+"$"),W={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M+"|[*])"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},X=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,$=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_=/[+~]/,aa=/'|\\/g,ba=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),ca=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},da=function(){m()};try{H.apply(E=I.call(v.childNodes),v.childNodes),E[v.childNodes.length].nodeType}catch(ea){H={apply:E.length?function(a,b){G.apply(a,I.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fa(a,b,d,e){var f,h,j,k,l,o,r,s,w=b&&b.ownerDocument,x=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==x&&9!==x&&11!==x)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==x&&(o=$.exec(a)))if(f=o[1]){if(9===x){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(w&&(j=w.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(o[2])return H.apply(d,b.getElementsByTagName(a)),d;if((f=o[3])&&c.getElementsByClassName&&b.getElementsByClassName)return H.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==x)w=b,s=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(aa,"\\$&"):b.setAttribute("id",k=u),r=g(a),h=r.length,l=V.test(k)?"#"+k:"[id='"+k+"']";while(h--)r[h]=l+" "+qa(r[h]);s=r.join(","),w=_.test(a)&&oa(b.parentNode)||b}if(s)try{return H.apply(d,w.querySelectorAll(s)),d}catch(y){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(Q,"$1"),b,d,e)}function ga(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ha(a){return a[u]=!0,a}function ia(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ja(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function ka(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||C)-(~a.sourceIndex||C);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function la(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function na(a){return ha(function(b){return b=+b,ha(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function oa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=fa.support={},f=fa.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fa.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ia(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ia(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Z.test(n.getElementsByClassName),c.getById=ia(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return"undefined"!=typeof b.getElementsByClassName&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=Z.test(n.querySelectorAll))&&(ia(function(a){o.appendChild(a).innerHTML="",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+L+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+L+"*(?:value|"+K+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ia(function(a){var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+L+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Z.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ia(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",O)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Z.test(o.compareDocumentPosition),t=b||Z.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?J(k,a)-J(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?J(k,a)-J(k,b):0;if(e===f)return ka(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?ka(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},fa.matches=function(a,b){return fa(a,null,null,b)},fa.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(T,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fa(b,n,null,[a]).length>0},fa.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fa.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&D.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fa.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fa.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fa.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fa.selectors={cacheLength:50,createPseudo:ha,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ba,ca),a[3]=(a[3]||a[4]||a[5]||"").replace(ba,ca),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fa.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fa.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return W.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&U.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ba,ca).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+L+")"+a+"("+L+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fa.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(P," ")+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),t===!1)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return t-=e,t===d||t%d===0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fa.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ha(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=J(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ha(function(a){var b=[],c=[],d=h(a.replace(Q,"$1"));return d[u]?ha(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ha(function(a){return function(b){return fa(a,b).length>0}}),contains:ha(function(a){return a=a.replace(ba,ca),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ha(function(a){return V.test(a||"")||fa.error("unsupported lang: "+a),a=a.replace(ba,ca).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Y.test(a.nodeName)},input:function(a){return X.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:na(function(){return[0]}),last:na(function(a,b){return[b-1]}),eq:na(function(a,b,c){return[0>c?c+b:c]}),even:na(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:na(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:na(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:na(function(a,b,c){for(var d=0>c?c+b:c;++db;b++)d+=a[b].value;return d}function ra(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j,k=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(j=b[u]||(b[u]={}),i=j[b.uniqueID]||(j[b.uniqueID]={}),(h=i[d])&&h[0]===w&&h[1]===f)return k[2]=h[2];if(i[d]=k,k[2]=a(b,c,g))return!0}}}function sa(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function ta(a,b,c){for(var d=0,e=b.length;e>d;d++)fa(a,b[d],c);return c}function ua(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(c&&!c(f,d,e)||(g.push(f),j&&b.push(h)));return g}function va(a,b,c,d,e,f){return d&&!d[u]&&(d=va(d)),e&&!e[u]&&(e=va(e,f)),ha(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||ta(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ua(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ua(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?J(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ua(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):H.apply(g,r)})}function wa(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=ra(function(a){return a===b},h,!0),l=ra(function(a){return J(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];f>i;i++)if(c=d.relative[a[i].type])m=[ra(sa(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return va(i>1&&sa(m),i>1&&qa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(Q,"$1"),c,e>i&&wa(a.slice(i,e)),f>e&&wa(a=a.slice(e)),f>e&&qa(a))}m.push(c)}return sa(m)}function xa(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=F.call(i));u=ua(u)}H.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&fa.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ha(f):f}return h=fa.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wa(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xa(e,d)),f.selector=a}return f},i=fa.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(ba,ca),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=W.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(ba,ca),_.test(j[0].type)&&oa(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qa(j),!a)return H.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,!b||_.test(a)&&oa(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ia(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ia(function(a){return a.innerHTML="","#"===a.firstChild.getAttribute("href")})||ja("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ia(function(a){return a.innerHTML="",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ja("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ia(function(a){return null==a.getAttribute("disabled")})||ja(K,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fa}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.uniqueSort=n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},v=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},w=n.expr.match.needsContext,x=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,y=/^.[^:#\[\.,]*$/;function z(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(y.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return n.inArray(a,b)>-1!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=[],d=this,e=d.length;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;e>b;b++)if(n.contains(d[b],this))return!0}));for(b=0;e>b;b++)n.find(a,d[b],c);return c=this.pushStack(e>1?n.unique(c):c),c.selector=this.selector?this.selector+" "+a:a,c},filter:function(a){return this.pushStack(z(this,a||[],!1))},not:function(a){return this.pushStack(z(this,a||[],!0))},is:function(a){return!!z(this,"string"==typeof a&&w.test(a)?n(a):a||[],!1).length}});var A,B=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,C=n.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||A,"string"==typeof a){if(e="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:B.exec(a),!e||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),x.test(e[1])&&n.isPlainObject(b))for(e in b)n.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}if(f=d.getElementById(e[2]),f&&f.parentNode){if(f.id!==e[2])return A.find(a);this.length=1,this[0]=f}return this.context=d,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?"undefined"!=typeof c.ready?c.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};C.prototype=n.fn,A=n(d);var D=/^(?:parents|prev(?:Until|All))/,E={children:!0,contents:!0,next:!0,prev:!0};n.fn.extend({has:function(a){var b,c=n(a,this),d=c.length;return this.filter(function(){for(b=0;d>b;b++)if(n.contains(this,c[b]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=w.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?n.inArray(this[0],n(a)):n.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.uniqueSort(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function F(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return u(a,"parentNode")},parentsUntil:function(a,b,c){return u(a,"parentNode",c)},next:function(a){return F(a,"nextSibling")},prev:function(a){return F(a,"previousSibling")},nextAll:function(a){return u(a,"nextSibling")},prevAll:function(a){return u(a,"previousSibling")},nextUntil:function(a,b,c){return u(a,"nextSibling",c)},prevUntil:function(a,b,c){return u(a,"previousSibling",c)},siblings:function(a){return v((a.parentNode||{}).firstChild,a)},children:function(a){return v(a.firstChild)},contents:function(a){return n.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(E[a]||(e=n.uniqueSort(e)),D.test(a)&&(e=e.reverse())),this.pushStack(e)}});var G=/\S+/g;function H(a){var b={};return n.each(a.match(G)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?H(a):n.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h-1)f.splice(c,1),h>=c&&h--}),this},has:function(a){return a?n.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=!0,c||j.disable(),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().progress(c.notify).done(c.resolve).fail(c.reject):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=e.call(arguments),d=c.length,f=1!==d||a&&n.isFunction(a.promise)?d:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?e.call(arguments):d,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(d>1)for(i=new Array(d),j=new Array(d),k=new Array(d);d>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().progress(h(b,j,i)).done(h(b,k,c)).fail(g.reject):--f;return f||g.resolveWith(k,c),g.promise()}});var I;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(I.resolveWith(d,[n]),n.fn.triggerHandler&&(n(d).triggerHandler("ready"),n(d).off("ready"))))}});function J(){d.addEventListener?(d.removeEventListener("DOMContentLoaded",K),a.removeEventListener("load",K)):(d.detachEvent("onreadystatechange",K),a.detachEvent("onload",K))}function K(){(d.addEventListener||"load"===a.event.type||"complete"===d.readyState)&&(J(),n.ready())}n.ready.promise=function(b){if(!I)if(I=n.Deferred(),"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll)a.setTimeout(n.ready);else if(d.addEventListener)d.addEventListener("DOMContentLoaded",K),a.addEventListener("load",K);else{d.attachEvent("onreadystatechange",K),a.attachEvent("onload",K);var c=!1;try{c=null==a.frameElement&&d.documentElement}catch(e){}c&&c.doScroll&&!function f(){if(!n.isReady){try{c.doScroll("left")}catch(b){return a.setTimeout(f,50)}J(),n.ready()}}()}return I.promise(b)},n.ready.promise();var L;for(L in n(l))break;l.ownFirst="0"===L,l.inlineBlockNeedsLayout=!1,n(function(){var a,b,c,e;c=d.getElementsByTagName("body")[0],c&&c.style&&(b=d.createElement("div"),e=d.createElement("div"),e.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",c.appendChild(e).appendChild(b),"undefined"!=typeof b.style.zoom&&(b.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",l.inlineBlockNeedsLayout=a=3===b.offsetWidth,a&&(c.style.zoom=1)),c.removeChild(e))}),function(){var a=d.createElement("div");l.deleteExpando=!0;try{delete a.test}catch(b){l.deleteExpando=!1}a=null}();var M=function(a){var b=n.noData[(a.nodeName+" ").toLowerCase()],c=+a.nodeType||1;return 1!==c&&9!==c?!1:!b||b!==!0&&a.getAttribute("classid")===b},N=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,O=/([A-Z])/g;function P(a,b,c){if(void 0===c&&1===a.nodeType){var d="data-"+b.replace(O,"-$1").toLowerCase();if(c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:N.test(c)?n.parseJSON(c):c}catch(e){}n.data(a,b,c)}else c=void 0; +}return c}function Q(a){var b;for(b in a)if(("data"!==b||!n.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function R(a,b,d,e){if(M(a)){var f,g,h=n.expando,i=a.nodeType,j=i?n.cache:a,k=i?a[h]:a[h]&&h;if(k&&j[k]&&(e||j[k].data)||void 0!==d||"string"!=typeof b)return k||(k=i?a[h]=c.pop()||n.guid++:h),j[k]||(j[k]=i?{}:{toJSON:n.noop}),"object"!=typeof b&&"function"!=typeof b||(e?j[k]=n.extend(j[k],b):j[k].data=n.extend(j[k].data,b)),g=j[k],e||(g.data||(g.data={}),g=g.data),void 0!==d&&(g[n.camelCase(b)]=d),"string"==typeof b?(f=g[b],null==f&&(f=g[n.camelCase(b)])):f=g,f}}function S(a,b,c){if(M(a)){var d,e,f=a.nodeType,g=f?n.cache:a,h=f?a[n.expando]:n.expando;if(g[h]){if(b&&(d=c?g[h]:g[h].data)){n.isArray(b)?b=b.concat(n.map(b,n.camelCase)):b in d?b=[b]:(b=n.camelCase(b),b=b in d?[b]:b.split(" ")),e=b.length;while(e--)delete d[b[e]];if(c?!Q(d):!n.isEmptyObject(d))return}(c||(delete g[h].data,Q(g[h])))&&(f?n.cleanData([a],!0):l.deleteExpando||g!=g.window?delete g[h]:g[h]=void 0)}}}n.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(a){return a=a.nodeType?n.cache[a[n.expando]]:a[n.expando],!!a&&!Q(a)},data:function(a,b,c){return R(a,b,c)},removeData:function(a,b){return S(a,b)},_data:function(a,b,c){return R(a,b,c,!0)},_removeData:function(a,b){return S(a,b,!0)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=n.data(f),1===f.nodeType&&!n._data(f,"parsedAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),P(f,d,e[d])));n._data(f,"parsedAttrs",!0)}return e}return"object"==typeof a?this.each(function(){n.data(this,a)}):arguments.length>1?this.each(function(){n.data(this,a,b)}):f?P(f,a,n.data(f,a)):void 0},removeData:function(a){return this.each(function(){n.removeData(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=n._data(a,b),c&&(!d||n.isArray(c)?d=n._data(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return n._data(a,c)||n._data(a,c,{empty:n.Callbacks("once memory").add(function(){n._removeData(a,b+"queue"),n._removeData(a,c)})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.lengthh;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},Z=/^(?:checkbox|radio)$/i,$=/<([\w:-]+)/,_=/^$|\/(?:java|ecma)script/i,aa=/^\s+/,ba="abbr|article|aside|audio|bdi|canvas|data|datalist|details|dialog|figcaption|figure|footer|header|hgroup|main|mark|meter|nav|output|picture|progress|section|summary|template|time|video";function ca(a){var b=ba.split("|"),c=a.createDocumentFragment();if(c.createElement)while(b.length)c.createElement(b.pop());return c}!function(){var a=d.createElement("div"),b=d.createDocumentFragment(),c=d.createElement("input");a.innerHTML="
a",l.leadingWhitespace=3===a.firstChild.nodeType,l.tbody=!a.getElementsByTagName("tbody").length,l.htmlSerialize=!!a.getElementsByTagName("link").length,l.html5Clone="<:nav>"!==d.createElement("nav").cloneNode(!0).outerHTML,c.type="checkbox",c.checked=!0,b.appendChild(c),l.appendChecked=c.checked,a.innerHTML="",l.noCloneChecked=!!a.cloneNode(!0).lastChild.defaultValue,b.appendChild(a),c=d.createElement("input"),c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),a.appendChild(c),l.checkClone=a.cloneNode(!0).cloneNode(!0).lastChild.checked,l.noCloneEvent=!!a.addEventListener,a[n.expando]=1,l.attributes=!a.getAttribute(n.expando)}();var da={option:[1,""],legend:[1,"
","
"],area:[1,"",""],param:[1,"",""],thead:[1,"","
"],tr:[2,"","
"],col:[2,"","
"],td:[3,"","
"],_default:l.htmlSerialize?[0,"",""]:[1,"X
","
"]};da.optgroup=da.option,da.tbody=da.tfoot=da.colgroup=da.caption=da.thead,da.th=da.td;function ea(a,b){var c,d,e=0,f="undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName(b||"*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll(b||"*"):void 0;if(!f)for(f=[],c=a.childNodes||a;null!=(d=c[e]);e++)!b||n.nodeName(d,b)?f.push(d):n.merge(f,ea(d,b));return void 0===b||b&&n.nodeName(a,b)?n.merge([a],f):f}function fa(a,b){for(var c,d=0;null!=(c=a[d]);d++)n._data(c,"globalEval",!b||n._data(b[d],"globalEval"))}var ga=/<|&#?\w+;/,ha=/r;r++)if(g=a[r],g||0===g)if("object"===n.type(g))n.merge(q,g.nodeType?[g]:g);else if(ga.test(g)){i=i||p.appendChild(b.createElement("div")),j=($.exec(g)||["",""])[1].toLowerCase(),m=da[j]||da._default,i.innerHTML=m[1]+n.htmlPrefilter(g)+m[2],f=m[0];while(f--)i=i.lastChild;if(!l.leadingWhitespace&&aa.test(g)&&q.push(b.createTextNode(aa.exec(g)[0])),!l.tbody){g="table"!==j||ha.test(g)?""!==m[1]||ha.test(g)?0:i:i.firstChild,f=g&&g.childNodes.length;while(f--)n.nodeName(k=g.childNodes[f],"tbody")&&!k.childNodes.length&&g.removeChild(k)}n.merge(q,i.childNodes),i.textContent="";while(i.firstChild)i.removeChild(i.firstChild);i=p.lastChild}else q.push(b.createTextNode(g));i&&p.removeChild(i),l.appendChecked||n.grep(ea(q,"input"),ia),r=0;while(g=q[r++])if(d&&n.inArray(g,d)>-1)e&&e.push(g);else if(h=n.contains(g.ownerDocument,g),i=ea(p.appendChild(g),"script"),h&&fa(i),c){f=0;while(g=i[f++])_.test(g.type||"")&&c.push(g)}return i=null,p}!function(){var b,c,e=d.createElement("div");for(b in{submit:!0,change:!0,focusin:!0})c="on"+b,(l[b]=c in a)||(e.setAttribute(c,"t"),l[b]=e.attributes[c].expando===!1);e=null}();var ka=/^(?:input|select|textarea)$/i,la=/^key/,ma=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,na=/^(?:focusinfocus|focusoutblur)$/,oa=/^([^.]*)(?:\.(.+)|)/;function pa(){return!0}function qa(){return!1}function ra(){try{return d.activeElement}catch(a){}}function sa(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)sa(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),e===!1)e=qa;else if(!e)return a;return 1===f&&(g=e,e=function(a){return n().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=n.guid++)),a.each(function(){n.event.add(this,b,e,d,c)})}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n._data(a);if(r){c.handler&&(i=c,c=i.handler,e=i.selector),c.guid||(c.guid=n.guid++),(g=r.events)||(g=r.events={}),(k=r.handle)||(k=r.handle=function(a){return"undefined"==typeof n||a&&n.event.triggered===a.type?void 0:n.event.dispatch.apply(k.elem,arguments)},k.elem=a),b=(b||"").match(G)||[""],h=b.length;while(h--)f=oa.exec(b[h])||[],o=q=f[1],p=(f[2]||"").split(".").sort(),o&&(j=n.event.special[o]||{},o=(e?j.delegateType:j.bindType)||o,j=n.event.special[o]||{},l=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},i),(m=g[o])||(m=g[o]=[],m.delegateCount=0,j.setup&&j.setup.call(a,d,p,k)!==!1||(a.addEventListener?a.addEventListener(o,k,!1):a.attachEvent&&a.attachEvent("on"+o,k))),j.add&&(j.add.call(a,l),l.handler.guid||(l.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,l):m.push(l),n.event.global[o]=!0);a=null}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=n.hasData(a)&&n._data(a);if(r&&(k=r.events)){b=(b||"").match(G)||[""],j=b.length;while(j--)if(h=oa.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=k[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),i=f=m.length;while(f--)g=m[f],!e&&q!==g.origType||c&&c.guid!==g.guid||h&&!h.test(g.namespace)||d&&d!==g.selector&&("**"!==d||!g.selector)||(m.splice(f,1),g.selector&&m.delegateCount--,l.remove&&l.remove.call(a,g));i&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete k[o])}else for(o in k)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(k)&&(delete r.handle,n._removeData(a,"events"))}},trigger:function(b,c,e,f){var g,h,i,j,l,m,o,p=[e||d],q=k.call(b,"type")?b.type:b,r=k.call(b,"namespace")?b.namespace.split("."):[];if(i=m=e=e||d,3!==e.nodeType&&8!==e.nodeType&&!na.test(q+n.event.triggered)&&(q.indexOf(".")>-1&&(r=q.split("."),q=r.shift(),r.sort()),h=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=f?2:3,b.namespace=r.join("."),b.rnamespace=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=e),c=null==c?[b]:n.makeArray(c,[b]),l=n.event.special[q]||{},f||!l.trigger||l.trigger.apply(e,c)!==!1)){if(!f&&!l.noBubble&&!n.isWindow(e)){for(j=l.delegateType||q,na.test(j+q)||(i=i.parentNode);i;i=i.parentNode)p.push(i),m=i;m===(e.ownerDocument||d)&&p.push(m.defaultView||m.parentWindow||a)}o=0;while((i=p[o++])&&!b.isPropagationStopped())b.type=o>1?j:l.bindType||q,g=(n._data(i,"events")||{})[b.type]&&n._data(i,"handle"),g&&g.apply(i,c),g=h&&i[h],g&&g.apply&&M(i)&&(b.result=g.apply(i,c),b.result===!1&&b.preventDefault());if(b.type=q,!f&&!b.isDefaultPrevented()&&(!l._default||l._default.apply(p.pop(),c)===!1)&&M(e)&&h&&e[q]&&!n.isWindow(e)){m=e[h],m&&(e[h]=null),n.event.triggered=q;try{e[q]()}catch(s){}n.event.triggered=void 0,m&&(e[h]=m)}return b.result}},dispatch:function(a){a=n.event.fix(a);var b,c,d,f,g,h=[],i=e.call(arguments),j=(n._data(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())a.rnamespace&&!a.rnamespace.test(g.namespace)||(a.handleObj=g,a.data=g.data,d=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==d&&(a.result=d)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&("click"!==a.type||isNaN(a.button)||a.button<1))for(;i!=this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>-1:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h]","i"),va=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,wa=/\s*$/g,Aa=ca(d),Ba=Aa.appendChild(d.createElement("div"));function Ca(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function Da(a){return a.type=(null!==n.find.attr(a,"type"))+"/"+a.type,a}function Ea(a){var b=ya.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function Fa(a,b){if(1===b.nodeType&&n.hasData(a)){var c,d,e,f=n._data(a),g=n._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)n.event.add(b,c,h[c][d])}g.data&&(g.data=n.extend({},g.data))}}function Ga(a,b){var c,d,e;if(1===b.nodeType){if(c=b.nodeName.toLowerCase(),!l.noCloneEvent&&b[n.expando]){e=n._data(b);for(d in e.events)n.removeEvent(b,d,e.handle);b.removeAttribute(n.expando)}"script"===c&&b.text!==a.text?(Da(b).text=a.text,Ea(b)):"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),l.html5Clone&&a.innerHTML&&!n.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&Z.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.defaultSelected=b.selected=a.defaultSelected:"input"!==c&&"textarea"!==c||(b.defaultValue=a.defaultValue)}}function Ha(a,b,c,d){b=f.apply([],b);var e,g,h,i,j,k,m=0,o=a.length,p=o-1,q=b[0],r=n.isFunction(q);if(r||o>1&&"string"==typeof q&&!l.checkClone&&xa.test(q))return a.each(function(e){var f=a.eq(e);r&&(b[0]=q.call(this,e,f.html())),Ha(f,b,c,d)});if(o&&(k=ja(b,a[0].ownerDocument,!1,a,d),e=k.firstChild,1===k.childNodes.length&&(k=e),e||d)){for(i=n.map(ea(k,"script"),Da),h=i.length;o>m;m++)g=k,m!==p&&(g=n.clone(g,!0,!0),h&&n.merge(i,ea(g,"script"))),c.call(a[m],g,m);if(h)for(j=i[i.length-1].ownerDocument,n.map(i,Ea),m=0;h>m;m++)g=i[m],_.test(g.type||"")&&!n._data(g,"globalEval")&&n.contains(j,g)&&(g.src?n._evalUrl&&n._evalUrl(g.src):n.globalEval((g.text||g.textContent||g.innerHTML||"").replace(za,"")));k=e=null}return a}function Ia(a,b,c){for(var d,e=b?n.filter(b,a):a,f=0;null!=(d=e[f]);f++)c||1!==d.nodeType||n.cleanData(ea(d)),d.parentNode&&(c&&n.contains(d.ownerDocument,d)&&fa(ea(d,"script")),d.parentNode.removeChild(d));return a}n.extend({htmlPrefilter:function(a){return a.replace(va,"<$1>")},clone:function(a,b,c){var d,e,f,g,h,i=n.contains(a.ownerDocument,a);if(l.html5Clone||n.isXMLDoc(a)||!ua.test("<"+a.nodeName+">")?f=a.cloneNode(!0):(Ba.innerHTML=a.outerHTML,Ba.removeChild(f=Ba.firstChild)),!(l.noCloneEvent&&l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(d=ea(f),h=ea(a),g=0;null!=(e=h[g]);++g)d[g]&&Ga(e,d[g]);if(b)if(c)for(h=h||ea(a),d=d||ea(f),g=0;null!=(e=h[g]);g++)Fa(e,d[g]);else Fa(a,f);return d=ea(f,"script"),d.length>0&&fa(d,!i&&ea(a,"script")),d=h=e=null,f},cleanData:function(a,b){for(var d,e,f,g,h=0,i=n.expando,j=n.cache,k=l.attributes,m=n.event.special;null!=(d=a[h]);h++)if((b||M(d))&&(f=d[i],g=f&&j[f])){if(g.events)for(e in g.events)m[e]?n.event.remove(d,e):n.removeEvent(d,e,g.handle);j[f]&&(delete j[f],k||"undefined"==typeof d.removeAttribute?d[i]=void 0:d.removeAttribute(i),c.push(f))}}}),n.fn.extend({domManip:Ha,detach:function(a){return Ia(this,a,!0)},remove:function(a){return Ia(this,a)},text:function(a){return Y(this,function(a){return void 0===a?n.text(this):this.empty().append((this[0]&&this[0].ownerDocument||d).createTextNode(a))},null,a,arguments.length)},append:function(){return Ha(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ca(this,a);b.appendChild(a)}})},prepend:function(){return Ha(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=Ca(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return Ha(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return Ha(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++){1===a.nodeType&&n.cleanData(ea(a,!1));while(a.firstChild)a.removeChild(a.firstChild);a.options&&n.nodeName(a,"select")&&(a.options.length=0)}return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return Y(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a)return 1===b.nodeType?b.innerHTML.replace(ta,""):void 0;if("string"==typeof a&&!wa.test(a)&&(l.htmlSerialize||!ua.test(a))&&(l.leadingWhitespace||!aa.test(a))&&!da[($.exec(a)||["",""])[1].toLowerCase()]){a=n.htmlPrefilter(a);try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(ea(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=[];return Ha(this,arguments,function(b){var c=this.parentNode;n.inArray(this,a)<0&&(n.cleanData(ea(this)),c&&c.replaceChild(b,this))},a)}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=0,e=[],f=n(a),h=f.length-1;h>=d;d++)c=d===h?this:this.clone(!0),n(f[d])[b](c),g.apply(e,c.get());return this.pushStack(e)}});var Ja,Ka={HTML:"block",BODY:"block"};function La(a,b){var c=n(b.createElement(a)).appendTo(b.body),d=n.css(c[0],"display");return c.detach(),d}function Ma(a){var b=d,c=Ka[a];return c||(c=La(a,b),"none"!==c&&c||(Ja=(Ja||n(" + + + +

最开始做 Bing 壁纸的目的很纯粹,就是看到必应搜索 cn.bing.com 官网的壁纸很赞,但是想找到之前的壁纸就有点困难,然后就自己用PHP语言开发了一个,每天同步cn.bing.com 官网的壁纸,同步抓取每日故事,存在自己的数据库里。源代码可以在GitHub上找到。当时主机是用的 + 阿里云送的免费两年的云主机,可能大部分人都没见过。整体布局如下:

+ +

由于我不是专业的 PHP工程师(前端攻城狮一枚),PHP版本 到后期维护就越来越困难,每次花费在改问题的时间越来越长,于是后面干脆就用Node.js 重写了Bing 壁纸,将版本号升级到了2.0版本(哈哈,自己定义的,无需在意),图片存储采用的七牛云存储,毕竟早期的流量小,免费额度还是撑得住的。程序部署在DaoCloud上,有兴趣的可以去看看Dockerfile。并且将域名由 + api.ioliu.cn 换成了 bing.ioliu.cn,这个版本可能大家就更熟悉一些,应该是上线时间最长的版本了吧。 +

+

后面由于 道客(DocCloud) 访问速度慢,最后干脆咬牙买了阿里云主机(ECS)1核/2G,并更新了SSL证书,相信现在的你一定发现了本站的访问速度简直是超级快(哈哈,自我陶醉下)。

+ +

截止到 2017-03-05,Bing 壁纸 项目已经稳步运行了一年,相信在未来的日子里,Bing 壁纸 会越来越好,功能越来越完善。现在,Bing壁纸 开通了留言功能,大家有什么想说的可以在下面留言咯\(^o^)/YES!

+

为了把壁纸的美好带给大家,攻城狮小哥花费了很多个人时间和精力进行开发,甚至自己掏钱购买服务器,看攻城狮小哥这么可怜,快来打赏杯咖啡吧。≡ω≡

+
+
+ 云淡风轻 WeChat Pay +

微信打赏

+
+
+ 云淡风轻 Alipay +

支付宝打赏

+
+
+

云淡风轻
2017-03-28

+
+ script. + var cloudTieConfig = { + url: document.location.href, + sourceId: "", + productKey: "86c5aa95f7b240b5ae7e4f97bc08d5ff", + target: "cloud-tie-wrapper" + }; + script(src="https://img1.cache.netease.com/f2e/tie/yun/sdk/loader.js") + + + + img(src='https://ws1.sinaimg.cn/large/006qRazegy1fe4s9xlfauj3045045jrb.jpg') + + + script(src='/static/js/baidu-analysis.js') + \ No newline at end of file diff --git a/views/common_headers.pug b/views/common_headers.pug new file mode 100644 index 0000000..cdde3d5 --- /dev/null +++ b/views/common_headers.pug @@ -0,0 +1,21 @@ +// + BingPictrues by xCss + https://github.com/xCss/bing | xioveliu@gamil.com +meta(charset="UTF-8") +meta(name="author",content="xCss") +meta(name="mobile-web-app-capable",content="yes") +meta(name="apple-mobile-web-app-capable",content="yes") +meta(name="apple-mobile-web-app-status-bar-style",content="black") +meta(content="telephone=no,email=no",name="format-detection") +meta(http-equiv="X-UA-Compatible",content="IE=Edge,Chrome=1") +meta(name="renderer",content="webkit") +meta(property="wb:webmaster",content="4513019856d2091e") +meta(name="google-site-verification",content="fto43W1-4i099gqlMImLOannS1KjzlC5A-a1dnT0iVs") +meta(name="viewport",content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no") +link(rel="stylesheet" type="text/css" href="/static/css/iconfont.css") +link(rel="icon",href="/static/images/bing.ico",sizes="32x32") +script(src='/static/js/js.cookie.js') + \ No newline at end of file diff --git a/views/detail.pug b/views/detail.pug new file mode 100644 index 0000000..09a7678 --- /dev/null +++ b/views/detail.pug @@ -0,0 +1,80 @@ +doctype html +html(lang="en") + head + include common_headers.pug + - var tt = doc.title ? doc.title+' - '+doc.copyright+' | 必应每日高清壁纸 - 精彩,从这里开始' : doc.copyright+' | 必应每日高清壁纸 - 精彩,从这里开始'; + title #{tt} + - var location = (doc.country && doc.city) ? doc.country + ', ' + doc.city : false; + - location = doc.continent ? (location ? doc.continent + ', ' + location : doc.continent) : location; + meta(name="keywords",content=`${doc.copyright}, ${doc.title}, ${location}, ${doc.dt}`) + meta(name="description",content=`${doc.description}`) + meta(name="author",content=`${doc.copyright}`) + link(rel='stylesheet',href="/static/css/progressively.css") + link(rel='stylesheet', href='/static/css/common.css') + link(rel='stylesheet', href='/static/css/main.css') + + + body.detail + div.preview + - var small = doc.photo; + div.progressive + - var link = Math.random() < 0.5 ? 'https://static.ioliu.cn' : 'https://bing-images.bitmoe.cn'; + img.target.progressive__img.progressive--not-loaded(src=doc.thumbnail,data-progressive=`${link}/bing/${small}_1920x1080.jpg`) + div.mark + div.options + a.ctrl.left(href=`${doc.back_url}`) + i.icon.icon-left + em.t BACK + span.ctrl.eye + i.icon.icon-eye + em.t #{doc.views} + span.ctrl.heart(photo=doc.id,likes=doc.likes) + i.icon.icon-heart + em.t #{doc.likes} + a.ctrl.download(href=`/photo/${doc.photo}?force=download`,target="_blank") + i.icon.icon-download + em.t #{doc.downloads} + div.description + p.title #{doc.copyright} + p.sub #{doc.description} + p.calendari.icon.icon-calendar + em.t #{doc.dt} + if location + p.location + i.icon.icon-location + em.t #{location} + + script(src='/static/js/jquery-1.12.4.min.js') + script(src='/static/js/progressively.js') + script(src='/static/js/baidu-analysis.js') + script(src='/static/js/like.js') + //- script(data-no-instant,src="/static/js/instantclick.min.js") + //- script(data-no-instant,src="/static/js/mine-instantclick.js") + script. + $(function() { + var i=0; + var img = $('.target'); + var mini = img.attr('src'); + var mark = $('.mark'); + mark.css({ + 'background-image': 'url('+mini+')' + }); + progressively.init({ + delay: 20, + throttle: 300, + onLoad: function(elem) { + }, + onLoadComplete: function() { + i++; + if(i>=2){ + var big = img.attr('src'); + mark.css({ + backgroundImage: 'url('+big+')', + filter: 'blur(0)' + }); + img.remove(); + } + } + }); + + }); \ No newline at end of file diff --git a/views/error.pug b/views/error.pug index a4b4f19..0e088c6 100644 --- a/views/error.pug +++ b/views/error.pug @@ -1,25 +1,17 @@ -extends error_layout +doctype html +html(lang="en") + head + include common_headers.pug + title 404 | 必应壁纸,必应每日壁纸,必应高清壁纸 + meta(name="keywords",content="必应壁纸,必应高清壁纸打包下载,必应壁纸合集,必应每日壁纸下载,必应壁纸接口,必应壁纸官方下载,Bing壁纸,微软bing每日壁纸,必应每日壁纸下载,Bing壁纸api,高清壁纸分享,bing壁纸官方下载,必应高清壁纸,必应壁纸打包下载") + link(rel='stylesheet', href='/static/css/common.css') + link(rel='stylesheet', href='/static/css/main.css') +body -block content - div#help - h1=error.status - h2=message - a.button(href='/') 带我回家 - div#stars - div#land - div#fire - div.flame - div.flame - div.flame - div.flame - div.flame - div#logs - div#logOne - div#logTwo - div#flicker - div#ground - //h1= error.status - //p= message - //a.button(href='/') Home - - //pre #{error.stack} \ No newline at end of file + script(src="/static/js/elm.js") + script. + Elm.Main.fullscreen({ + randomSeed: Date.now(), + imagesUrl: 'img', + devicePixelRatio: window.devicePixelRatio + }); \ No newline at end of file diff --git a/views/index.bakx.pug b/views/index.bakx.pug deleted file mode 100644 index 05f69df..0000000 --- a/views/index.bakx.pug +++ /dev/null @@ -1,3 +0,0 @@ -extends layout - -block content \ No newline at end of file diff --git a/views/index.pug b/views/index.pug index 8684de5..f9c573a 100644 --- a/views/index.pug +++ b/views/index.pug @@ -1,51 +1,100 @@ -extends layout - -block content - div#main - header#header - a(href='/') - h1 #{title} - p #{description} - h2(style="color:red;font-weight:bold;") - i.icon.fa-bullhorn - a(href='/static/about.html',target="_blank") 号外!留言上线啦 - section#thumbnails - each val in data - - var original = 'https://static.ioliu.cn/bing/'+val.qiniu_url+'_1920x1080.jpg'; - - var download = 'https://static.ioliu.cn/bing/'+val.qiniu_url+'_1920x1080.jpg'; - article(rid=val.id) - a.thumbnail.progressive(href= original) - img.progressive__img.progressive--not-loaded(data-progressive=val.smallpic,src=val.thumbnail ) - h2 ##{val.date}# #{val.copyright} - p #{val.description} - - var url = 'http://service.weibo.com/share/share.php?url='+encodeURIComponent('http://bing.ioliu.cn?id='+val.id)+'&title='+encodeURIComponent('#必应壁纸# '+ val.date + ' / '+ val.description) + '&appkey=1833831541'; - ul.actions +doctype html +html(lang="en") + head + include common_headers.pug + - var title = page.currText ? page.currText + ' | 必应每日高清壁纸 - 精彩,从这里开始' : '必应每日高清壁纸 - 精彩,从这里开始' + title #{title} + meta(name="keywords",content="必应壁纸,必应美图,必应每日壁纸,必应每日美图,必应壁纸下载,必应每日壁纸下载,必应每日壁纸接口,必应每日壁纸官方下载,Bing壁纸,微软bing每日壁纸") + link(rel='stylesheet',href="/static/css/progressively.css") + link(rel='stylesheet', href='/static/css/common.css') + link(rel='stylesheet', href='/static/css/main.css') + body + header + div.container + a.logo(href="/") + i.icon.icon-bing + span 必应壁纸 + nav + ul.menu + li(class=`${page.currPage === 'home' ? 'active' : ''}`) + a(href="/") + i.icon.icon-home + p.text 首页 + li(class=`${page.currPage === 'ranking' ? 'active' : ''}`) + a(href="/ranking") + i.icon.icon-ranking + p.text 下载榜 li - a.button.small(href=url,target="_blank",rel="nofollow") 分享 - li - a.button.small(href=val.copyrightlink,target="_blank",rel="nofollow") 搜索 - li - a.button.small(href=download,target="_blank") 下载 + a(data-no-instant,href="/static/about.html") + i.icon.icon-about + p.text 关于 + + //-
  • + //- + //-
  • + + div.holder + div.mask + div.container + each val in doc + - var location = (val.country && val.city) ? val.country + ', ' + val.city : false; + - location = val.continent ? (location ? val.continent + ', ' + location : val.continent) : location; + div.item + div.card.progressive + img.progressive__img.progressive--not-loaded(data-progressive=val.thumbnail,src=val.smallpic ) + a.mark(href=`/photo/${val.photo}?force=${page.currPage}_${page.curr}`) + div.description + h3 #{val.copyright} + p.calendar + i.icon.icon-calendar + em.t #{val.dt} + if location + p.location + i.icon.icon-location + em.t #{location} + div.options + span.ctrl.eye + i.icon.icon-eye + em.t #{val.views} + span.ctrl.heart(photo=val.id,likes=val.likes) + i.icon.icon-heart + em.t #{val.likes} + + a.ctrl.download(href=`/photo/${val.photo}?force=download`,target="_blank",rel="nofollow") + i.icon.icon-download + em.t #{val.downloads} + div.page + - var url = page.currPage === 'home' ? '/' : `/${page.currPage}` + - var prev = page.prev === 1 ? `${url}` : `${url}?p=${page.prev}`; + - var next = `${url}?p=${page.next}`; + a(href=prev) + i.icon.icon-prev 上一页 + span #{page.curr} / #{page.pageCount} + a(href=next) 下一页 + i.icon.icon-next + div.copyright + p 本站所有图片均来自必应搜索 + p Copyright © 2016 - 2017 云淡风轻 - - var prev = page.prev<=1?'/':'/?p='+page.prev; - - var next = '/?p='+page.next; - ul.actions.align-center - li - a.button.small(href=prev) << 上页 - a.button.small(href=next) 下页 >> - footer#footer - ul.icons - li - a.icon.fa-github(href='https://github.com/xCss/bing',target="_blank",rel="nofollow") - span.label Github - li - a.icon.fa-weibo(href='http://weibo.com/BingPictures',target="_blank",rel="nofollow") - span.label Weibo - li - a.icon.fa-envelope(href='mail:xioveliu@gmail.com',target="_blank") - span.label Mail - ul.copyright - li - span.copy 2016 - 2017 - b © - a(href='/') Bing Pictures. + script(src="/static/js/jquery-1.12.4.min.js") + script(src="/static/js/progressively.js") + script(src="/static/js/device.js") + script(src="/static/js/baidu-analysis.js") + script(src="/static/js/like.js") + //- script(data-no-instant,src="/static/js/instantclick.min.js") + //- script(data-no-instant,src="/static/js/mine-instantclick.js") + script. + $(function() { + var i = 0; + var timer = setInterval(function(){ + progressively.init(); + if(i++ === 5) clearInterval(timer); + },1000/4); + var click = 'ontouchstart' in window ? 'touchstart' : 'click'; + if (DEVICE.isMobile) { + $(document.body).addClass('mobile'); + } + }); \ No newline at end of file diff --git a/views/layout.pug b/views/layout.pug index e3bee7c..70076a6 100644 --- a/views/layout.pug +++ b/views/layout.pug @@ -1,62 +1,16 @@ doctype html html head - // - BingPictrues by xCss - https://github.com/xCss/bing | xioveliu@gamil.com - + include common_headers.pug - var desc = page.desc || '必应每日壁纸:风景, 这边独好。'; title #{page.curr} - #{title} - meta('charset'="utf-8") - meta(name="google-site-verification",content="fto43W1-4i099gqlMImLOannS1KjzlC5A-a1dnT0iVs") meta(name="keywords",content="必应壁纸,必应高清壁纸打包下载,必应壁纸合集,必应每日壁纸下载,必应壁纸接口,必应壁纸官方下载,Bing壁纸,微软bing每日壁纸,必应每日壁纸下载,Bing壁纸api,高清壁纸分享,bing壁纸官方下载,必应高清壁纸,必应壁纸打包下载") meta(name="description",content=desc) - meta(name="viewport",content="width=device-width,user-scalable=no,initial-scale=1,minimum-scale=1,maximum-scale=1") - meta(name="author",content="xCss") - meta(http-equiv="X-UA-Compatible",content="IE=edge,chrome=1") - meta(name="renderer",content="webkit") - meta(property="wb:webmaster",content="4513019856d2091e") - - - - noscript - link(rel="stylesheet",href="/static/css/skin/noscript.css") - link(rel='stylesheet', href='/static/css/skin/lens.css') - link(rel="icon",href="/static/images/bing.ico",sizes="32x32") + link(rel='stylesheet', href='/static/css/common.min.css') + link(rel='stylesheet', href='/static/css/main.min.css') link(rel='stylesheet',href="/static/css/progressively.min.css") - body.is-loading-0.is-loading-1.is-loading-2 + body block content - script(src="/static/js/jquery.min.js") - script(src="/static/js/skel.min.js") - script(src="/static/js/progressively.min.js") - - script(src="/static/js/main.js") - script. - $(function() { - progressively.init(); - - if (skel.vars.os == 'ios' && window.self !== window.top) { - var $body = $('html,body'), $window = $(window.top); - $body.css('-webkit-overflow-scrolling', 'touch'); - $window.on('resize orientationchange', function() { - $body - .css('width', $window.width()) - .css('height', $window.height()); - }).trigger('resize'); - } - if(!/^http:\/\/localhost/.test(location.href)){ - var _hmt = _hmt || []; - var hm = document.createElement("script"); - hm.src = "//hm.baidu.com/hm.js?667639aad0d4654c92786a241a486361"; - var s = document.getElementsByTagName("script")[0]; - s.parentNode.insertBefore(hm, s); - } - }); +