├── .gitignore ├── README.md ├── assets ├── postman.png └── status.png ├── config ├── dev.js ├── index.js ├── prod.js └── test.js ├── index.js ├── lib ├── db.js ├── log.js ├── redisUtils.js └── utils.js ├── models └── moklrModel.js ├── package.json ├── public ├── css │ ├── 1.woff2 │ ├── 2.woff2 │ ├── 3.woff2 │ ├── 4.woff2 │ ├── bootstrap-3.3.5.journal.min.css │ ├── bootstrap-3.3.5.min.css │ ├── font.css │ ├── highlight-8.4-github.min.css │ ├── icheck-skins │ │ ├── all.css │ │ ├── flat │ │ │ ├── _all.css │ │ │ ├── aero.css │ │ │ ├── aero.png │ │ │ ├── aero@2x.png │ │ │ ├── blue.css │ │ │ ├── blue.png │ │ │ ├── blue@2x.png │ │ │ ├── flat.css │ │ │ ├── flat.png │ │ │ ├── flat@2x.png │ │ │ ├── green.css │ │ │ ├── green.png │ │ │ ├── green@2x.png │ │ │ ├── grey.css │ │ │ ├── grey.png │ │ │ ├── grey@2x.png │ │ │ ├── orange.css │ │ │ ├── orange.png │ │ │ ├── orange@2x.png │ │ │ ├── pink.css │ │ │ ├── pink.png │ │ │ ├── pink@2x.png │ │ │ ├── purple.css │ │ │ ├── purple.png │ │ │ ├── purple@2x.png │ │ │ ├── red.css │ │ │ ├── red.png │ │ │ ├── red@2x.png │ │ │ ├── yellow.css │ │ │ ├── yellow.png │ │ │ └── yellow@2x.png │ │ ├── futurico │ │ │ ├── futurico.css │ │ │ ├── futurico.png │ │ │ └── futurico@2x.png │ │ ├── line │ │ │ ├── _all.css │ │ │ ├── aero.css │ │ │ ├── blue.css │ │ │ ├── green.css │ │ │ ├── grey.css │ │ │ ├── line.css │ │ │ ├── line.png │ │ │ ├── line@2x.png │ │ │ ├── orange.css │ │ │ ├── pink.css │ │ │ ├── purple.css │ │ │ ├── red.css │ │ │ └── yellow.css │ │ ├── minimal │ │ │ ├── _all.css │ │ │ ├── aero.css │ │ │ ├── aero.png │ │ │ ├── aero@2x.png │ │ │ ├── blue.css │ │ │ ├── blue.png │ │ │ ├── blue@2x.png │ │ │ ├── green.css │ │ │ ├── green.png │ │ │ ├── green@2x.png │ │ │ ├── grey.css │ │ │ ├── grey.png │ │ │ ├── grey@2x.png │ │ │ ├── minimal.css │ │ │ ├── minimal.png │ │ │ ├── minimal@2x.png │ │ │ ├── orange.css │ │ │ ├── orange.png │ │ │ ├── orange@2x.png │ │ │ ├── pink.css │ │ │ ├── pink.png │ │ │ ├── pink@2x.png │ │ │ ├── purple.css │ │ │ ├── purple.png │ │ │ ├── purple@2x.png │ │ │ ├── red.css │ │ │ ├── red.png │ │ │ ├── red@2x.png │ │ │ ├── yellow.css │ │ │ ├── yellow.png │ │ │ └── yellow@2x.png │ │ ├── polaris │ │ │ ├── polaris.css │ │ │ ├── polaris.png │ │ │ └── polaris@2x.png │ │ └── square │ │ │ ├── _all.css │ │ │ ├── aero.css │ │ │ ├── aero.png │ │ │ ├── aero@2x.png │ │ │ ├── blue.css │ │ │ ├── blue.png │ │ │ ├── blue@2x.png │ │ │ ├── green.css │ │ │ ├── green.png │ │ │ ├── green@2x.png │ │ │ ├── grey.css │ │ │ ├── grey.png │ │ │ ├── grey@2x.png │ │ │ ├── orange.css │ │ │ ├── orange.png │ │ │ ├── orange@2x.png │ │ │ ├── pink.css │ │ │ ├── pink.png │ │ │ ├── pink@2x.png │ │ │ ├── purple.css │ │ │ ├── purple.png │ │ │ ├── purple@2x.png │ │ │ ├── red.css │ │ │ ├── red.png │ │ │ ├── red@2x.png │ │ │ ├── square.css │ │ │ ├── square.png │ │ │ ├── square@2x.png │ │ │ ├── yellow.css │ │ │ ├── yellow.png │ │ │ └── yellow@2x.png │ ├── main.css │ ├── profile.css │ ├── status.css │ └── ui-dialog.css ├── fonts │ ├── glyphicons-halflings-regular.eot │ ├── glyphicons-halflings-regular.svg │ ├── glyphicons-halflings-regular.ttf │ ├── glyphicons-halflings-regular.woff │ └── glyphicons-halflings-regular.woff2 ├── img │ └── moklr.png └── js │ ├── FileSaver.min.js │ ├── bootstrap-3.3.5.min.js │ ├── common.js │ ├── create.js │ ├── dialog-min.js │ ├── highlight-8.4.min.js │ ├── icheck.min.js │ ├── jquery-2.1.4.min.js │ ├── juicer.js │ ├── moment-2.10.6.js │ ├── postman.js │ └── status.js ├── roadmap.md ├── route.js ├── routes ├── auth.js ├── mock.js ├── postman.js ├── run.js └── status.js ├── test ├── moklrModel.test.js ├── mongo.test.js ├── mongoose.test.js ├── redis.test.js └── user.test.js └── views ├── create.ejs ├── error.ejs ├── footer.ejs ├── har.ejs ├── header.ejs ├── help.ejs ├── index.ejs ├── login.ejs ├── meta.ejs ├── postman-modal-tpl.ejs ├── postman-tpl.ejs ├── postman.ejs ├── status-tpl.ejs └── status.ejs /.gitignore: -------------------------------------------------------------------------------- 1 | *.log 2 | .idea 3 | node_modules 4 | config/heroku.js -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## Moklr 2 | 3 | moklr定位于http请求代码生成,自动化测试,API status服务等test/development辅助功能,此外还可能集成文档服务,目前仍在持续开发中。 4 | 5 | 6 | ### Demo 7 | 8 | [heroku moklr](https://still-peak-9538.herokuapp.com), 账号:test/123456 9 | 10 | ### Features 11 | 12 | - [X] postman替代品,支持postaman数据(collection级别)直接导入 13 | - [X] http请求代码生成,支持常见的多种语言(js/java/go/python/shell/ruby等等) 14 | - [X] API status检查(需[runbot](https://github.com/sumory/runbot)支持) 15 | - [ ] 批量测试case 16 | - [ ] 测试文档和API文档生成 17 | 18 | 19 | ### Usage 20 | 21 | 1. 依赖于mongodb,需提前安装 22 | 2. 运行 23 | 24 | ``` 25 | git clone https://github.com/sumory/moklr.git 26 | cd moklr 27 | npm install . 28 | 29 | #根据具体情况修改config配置,配置位于config目录下 30 | 31 | #选择config目录下的test.js这个配置启动 32 | NODE_ENV=test node index.js 33 | 34 | #访问http://localhost:8001 35 | ``` 36 | 37 | ### Screenshots 38 | 39 | ![](assets/postman.png) 40 | ![](assets/status.png) 41 | 42 | -------------------------------------------------------------------------------- /assets/postman.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/assets/postman.png -------------------------------------------------------------------------------- /assets/status.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/assets/status.png -------------------------------------------------------------------------------- /config/dev.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | 3 | module.exports = { 4 | port: 8001, 5 | viewEngine: 'ejs', 6 | sessionSecret: 'session_secret_random_seed', 7 | 8 | views: 'views', 9 | staticPath: 'public',//静态资源目录 10 | uploadDir: 'public/uploads',//注意:要首先建立该文件夹,并做好权限 11 | 12 | env: 'dev', 13 | 14 | log:{ 15 | persist: false,//是否开启日志的持久化,即记录到日志文件 16 | logfile: path.join(__dirname, '../logs/app.log')//persist为true时有效 17 | }, 18 | 19 | 20 | 21 | //mysql config 22 | //mysql: { 23 | // host: "192.168.100.182", 24 | // user: "dmdevelop", 25 | // password: "develop@dm.com", 26 | // db: "relation" 27 | //}, 28 | 29 | //redis config 30 | //"redis": {"address": "192.168.100.185", "port": "6379", "passwd": ""}, 31 | 32 | mongodb: { 33 | address: "mongodb://192.168.100.186:20301/moklr" 34 | }, 35 | 36 | //moklr的status服务需要runbot来做指定http api的定期check,若不需要status服务可不开启此功能 37 | //runbot服务需单独部署,详见https://github.com/sumory/runbot 38 | runbot: { 39 | on: true,//是否开启runbot支持 40 | address:"http://localhost:8002"//若on为true,即开启runbot服务,这里配置runbot服务的http地址 41 | } 42 | 43 | }; 44 | -------------------------------------------------------------------------------- /config/index.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | 3 | // 通过NODE_ENV设置环境变量,默认为dev环境 4 | if(process.env.NODE_ENV && process.env.NODE_ENV=="development"){ 5 | process.env.NODE_ENV = 'dev'; 6 | } 7 | var env = process.env.NODE_ENV || 'dev'; 8 | env = env.toLowerCase(); 9 | 10 | var file = path.resolve(__dirname, env); 11 | try { 12 | var config = module.exports = require(file); 13 | console.log('Load config: [%s] %s', env, file); 14 | } catch (err) { 15 | console.error('Error when load config: [%s] %s', env, file); 16 | throw err; 17 | } -------------------------------------------------------------------------------- /config/prod.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/config/prod.js -------------------------------------------------------------------------------- /config/test.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | 3 | module.exports = { 4 | port: 8001, 5 | viewEngine: 'ejs', 6 | sessionSecret: 'session_secret_random_seed_for_test', 7 | 8 | views: 'views', 9 | staticPath: 'public',//静态资源目录 10 | uploadDir: 'public/uploads',//注意:要首先建立该文件夹,并做好权限 11 | 12 | env: 'test', 13 | 14 | log:{ 15 | persist: true,//是否开启日志的持久化,即记录到日志文件 16 | logfile: '/dmdata/logs/moklr.log'//persist为true时有效 17 | }, 18 | 19 | 20 | 21 | //mysql config 22 | //mysql: { 23 | // host: "192.168.100.182", 24 | // user: "dmdevelop", 25 | // password: "develop@dm.com", 26 | // db: "relation" 27 | //}, 28 | 29 | //redis config 30 | //"redis": {"address": "192.168.100.185", "port": "6379", "passwd": ""}, 31 | 32 | mongodb: { 33 | address: "mongodb://192.168.100.186:20301/moklr_online" 34 | }, 35 | 36 | //moklr的status服务需要runbot来做指定http api的定期check,若不需要status服务可不开启此功能 37 | //runbot服务需单独部署,详见https://github.com/sumory/runbot 38 | runbot: { 39 | on: true,//是否开启runbot支持 40 | address:"http://192.168.100.122:8002"//若on为true,即开启runbot服务,这里配置runbot服务的http地址 41 | } 42 | 43 | }; 44 | -------------------------------------------------------------------------------- /index.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var methodOverride = require('method-override'); 3 | var bodyParser = require('body-parser'); 4 | var expressSession = require('express-session'); 5 | var multiparty = require('multiparty'); 6 | var log4js = require('log4js'); 7 | 8 | var logger = require('./lib/log.js').logger('app'); 9 | var route = require('./route.js'); 10 | var config = require('./config'); 11 | 12 | var app = express(); 13 | app.set('env', config.env); 14 | app.set('port', process.env.PORT||config.port); 15 | app.set('views', config.views); 16 | app.set('view engine', config.viewEngine); 17 | app.use(expressSession({ 18 | secret: config.sessionSecret, 19 | name: 'expressId', //种到cookies里的标识 20 | resave: false, 21 | saveUninitialized: true 22 | 23 | })); 24 | app.use(express.static(config.staticPath)); 25 | app.use(log4js.connectLogger(logger, { 26 | level: "auto" 27 | })); 28 | app.use(bodyParser.urlencoded({extended: true})); 29 | app.use(bodyParser.json()); 30 | app.use(methodOverride()); 31 | 32 | app.use(function (req, res, next) { 33 | if(req && req.session && req.session.user){ 34 | res.locals.isLogin = true; 35 | res.locals.loginUserId = req.session.user.userId; 36 | res.locals.loginUsername = req.session.user.username; 37 | } 38 | 39 | next(); 40 | }); 41 | 42 | 43 | route(app); //加载routes 44 | 45 | //404错,即无匹配请求地址 46 | app.use(function (req, res, next) { 47 | res.status(404); 48 | res.json({ 49 | success: false, 50 | status: 404, 51 | msg: '404错误,找不到访问的资源(url)' 52 | }); 53 | }); 54 | 55 | //处理错误,返回响应 56 | app.use(function (err, req, res, next) { 57 | var status = err.status || 500; 58 | logger.error('【error】', err.message || '', err.stack || ''); 59 | res.status(status); 60 | res.json({ 61 | success: false, 62 | status: status, 63 | msg: "服务端发生异常" 64 | }); 65 | }); 66 | 67 | 68 | var server = require('http').Server(app); 69 | server.listen(app.get('port'), function () { 70 | console.log('Server listening on port ' + server.address().port, ', env is ' + app.get('env')); 71 | }); 72 | 73 | process.on('uncaughtException', function (err) { 74 | console.log('Holy shit!!!!! Fatal Errors!!!!!!! ' + err); 75 | }); -------------------------------------------------------------------------------- /lib/db.js: -------------------------------------------------------------------------------- 1 | var mysql = require("mysql"); 2 | var config = require("../config"); 3 | var logger = require('./log.js').logger('db'); 4 | var commonUtils = require("./utils.js"); 5 | var utils = require("util"); 6 | 7 | var pool;//mysql connection pool 8 | 9 | 10 | exports.init = function(){ 11 | if(!pool){ 12 | pool = mysql.createPool({ 13 | connectionLimit: 50, 14 | host: config.mysql.host, 15 | user: config.mysql.user, 16 | password: config.mysql.password, 17 | database: "", 18 | supportBigNumbers: true, //dealing with big numbers as a string 19 | acquireTimeout: 6000, 20 | waitForConnections: false //发现连接不可用,立刻回调错误 21 | //debug: true 22 | }); 23 | 24 | pool.on('connection', function (connection) { 25 | logger.info("新的数据库连接被创建", connection.threadId); 26 | }); 27 | } 28 | }; 29 | 30 | 31 | 32 | /** 33 | * 获取连接 34 | * 35 | * @param callback 36 | */ 37 | exports.getConnection = function (callback) { 38 | pool.getConnection(callback);//无论任何情况必选保证connection调用release 39 | }; 40 | 41 | /** 42 | * 执行sql查询 43 | * 要确保严格有三个参数,最后一个为callback,中间params不能省略 44 | * 45 | * @param sql 46 | * @param params 47 | * @param callback 48 | */ 49 | exports.query = function (sql, params, callback) { 50 | var trackId = commonUtils.rd();//生成一个追踪id,用于排查问题 51 | logger.info(trackId, "进入query:", sql, params); 52 | if (!utils.isArray(params)) { 53 | logger.error(trackId, "query参数不是数组,退出sql执行"); 54 | callback && callback(new Error("请确保query参数必须是数组"), null); 55 | return; 56 | } 57 | 58 | pool.getConnection(function (err, connection) { 59 | logger.info(trackId, "尝试拿到连接", err == null ? "成功" : "失败"); 60 | if (err) { 61 | try { 62 | if (connection) 63 | connection.release(); 64 | } catch (e) { 65 | logger.error(trackId, "拿连接出错,尝试释放出错", err, connection); 66 | } 67 | callback && callback(err, null); 68 | } else { 69 | logger.info(trackId, '连接id为' + connection.threadId); 70 | connection.query(sql, params, function (err, data) { 71 | logger.info(trackId, '连接将被释放 ', connection.threadId); 72 | connection.release(); 73 | logger.info(trackId, '连接已释放'); 74 | if (err) { 75 | logger.error(trackId, err); 76 | } 77 | callback && callback(err, data); 78 | }); 79 | } 80 | }); 81 | }; 82 | 83 | -------------------------------------------------------------------------------- /lib/log.js: -------------------------------------------------------------------------------- 1 | var log4js = require('log4js'); 2 | var logConfig = require('../config').log; 3 | 4 | if (logConfig.persist) { 5 | log4js.configure({ 6 | appenders: [{//控制台输出 7 | type: 'console' 8 | }, { 9 | type: 'file', //文件输出 10 | filename: logConfig.logfile, 11 | //maxLogSize: 20480, //当超过maxLogSize大小时,会自动生成一个新文件 12 | //backups: 3 13 | pattern: "-yyyy-MM-dd", 14 | alwaysIncludePattern: true 15 | }], 16 | replaceConsole: true //增加replaceConsole配置,让所有console输出到日志中,以[INFO] console代替console默认样式。 17 | }); 18 | } else { 19 | log4js.configure({ 20 | appenders: [{//控制台输出 21 | type: 'console' 22 | }], 23 | replaceConsole: true //增加replaceConsole配置,让所有console输出到日志中,以[INFO] console代替console默认样式。 24 | }); 25 | } 26 | 27 | 28 | exports.logger = function (name, level) { 29 | var logger = log4js.getLogger(name); 30 | logger.setLevel(level || 'INFO'); 31 | return logger; 32 | }; -------------------------------------------------------------------------------- /lib/redisUtils.js: -------------------------------------------------------------------------------- 1 | var Redis = require("ioredis"); 2 | var config = require("../config"); 3 | 4 | 5 | 6 | var redis; 7 | 8 | exports.init= function(){ 9 | if(!redis){ 10 | redis = new Redis({ 11 | port:config.redis.port, 12 | host:config.redis.address, 13 | family:4, 14 | password:"", 15 | db:0 16 | }); 17 | } 18 | }; 19 | 20 | 21 | exports.set = function(k, v, callback){ 22 | console.log(k,v); 23 | redis.set(k,v,callback); 24 | }; 25 | 26 | exports.get = function(k, callback){ 27 | redis.get(k, callback); 28 | }; 29 | 30 | /** 31 | * hset 32 | * 如果 field 是哈希表中的一个新建域,并且值设置成功,返回 1 33 | * 如果哈希表中域 field 已经存在且旧值已被新值覆盖,返回 0 34 | * 35 | * @param k key 36 | * @param f field 37 | * @param v value 38 | * @param callback 39 | */ 40 | exports.hset = function(k,f, v, callback){ 41 | redis.hset(k,f,v,callback); 42 | }; 43 | 44 | exports.hget = function(k, f, callback){ 45 | redis.hget(k,f,callback); 46 | }; 47 | 48 | /** 49 | * hmset 50 | * 同时将多个 field-value (域-值)对设置到哈希表 key 中 51 | * 52 | * @param k 53 | * @param fvs object {field1: value1, field2: value2} 54 | * @param callback 55 | */ 56 | exports.hmset = function(k,fvs,callback){ 57 | redis.hmset(k, fvs, callback); 58 | }; 59 | 60 | 61 | /** 62 | * hgetall 63 | * 64 | * { k1: 'v1', 'k2': 'v2' } 65 | * 66 | * @param k 67 | * @param callback 68 | */ 69 | exports.hgetall = function(k, callback){ 70 | redis.hgetall(k, callback); 71 | }; -------------------------------------------------------------------------------- /lib/utils.js: -------------------------------------------------------------------------------- 1 | var crypto = require('crypto'); 2 | var uuid = require('node-uuid'); 3 | 4 | exports.checkLogin = function (req, res, next) { 5 | if (req && req.session && req.session.user) { 6 | next(); 7 | } else { 8 | res.render('error', { 9 | msg: 'You have not login Moklr!', 10 | nologin: true 11 | }); 12 | return; 13 | } 14 | }; 15 | 16 | exports.checkLoginAjax = function (req, res, next) { 17 | if (req && req.session && req.session.user) { 18 | next(); 19 | } else { 20 | return res.json({ 21 | success: false, 22 | msg: 'You have not login Moklr!' 23 | }); 24 | } 25 | }; 26 | 27 | exports.md5 = function (str, salt) { 28 | var md5sum = crypto.createHash("md5"); 29 | if (salt) 30 | md5sum.update(str + salt, "utf-8");//记得添加‘utf-8’ 31 | else 32 | md5sum.update(str, "utf-8"); 33 | str = md5sum.digest("hex"); 34 | return str; 35 | }; 36 | 37 | exports.getUUID = function () { 38 | return uuid.v4(); 39 | }; 40 | 41 | exports.rd = function () { 42 | return Math.floor(Math.random() * 100000 + 1); 43 | } 44 | 45 | //console.log(exports.md5("123456","-abc")); 46 | //console.log(exports.getUUID()); 47 | 48 | -------------------------------------------------------------------------------- /models/moklrModel.js: -------------------------------------------------------------------------------- 1 | var mongoose = require('mongoose'); 2 | var config = require('../config'); 3 | var uuid = require('node-uuid'); 4 | var logger = require('../lib/log.js').logger('moklrModel'); 5 | 6 | mongoose.connect(config.mongodb.address); 7 | var Schema = mongoose.Schema; 8 | 9 | var UserSchema = new Schema({ 10 | userId: {type: String, index: true}, 11 | username: {type: String, index: true, unique: true}, 12 | pwd: String, 13 | date: {type: Date, default: Date.now} 14 | }); 15 | //建立唯一性索引 16 | // db.user.ensureIndex({username:1},{unique:true}) 17 | 18 | UserSchema.statics.findbyUsername = function (username, callback) { 19 | return this.model('User').find({username: username}, callback); 20 | }; 21 | 22 | var CollectionSchema = new Schema({ 23 | collectionId: {type: String, index: true}, 24 | userId: {type: String, index: true}, 25 | name: String, 26 | date: {type: Date, default: Date.now} 27 | }); 28 | 29 | CollectionSchema.statics.findAllByUserId = function (userId, callback) { 30 | return this.model('Collection').find({userId: userId}, callback); 31 | }; 32 | 33 | var HarSchema = new Schema({ 34 | harId: {type: String, index: true}, 35 | userId: {type: String, index: true}, 36 | collectionId: {type: String, index: true}, 37 | type: String,//"GET" or "POST" or...与content里的method字段相同 38 | name: String, 39 | content: {}, 40 | date: {type: Date, default: Date.now} 41 | }); 42 | 43 | var StatusAPISchema = new Schema({ 44 | monitor: {type: Boolean, index: true}, 45 | cron: {type: String}, 46 | id: {type: String, index: true}, 47 | userId: {type: String, index: true}, 48 | type: String,//"GET" or "POST" or...与content里的method字段相同 49 | name: String, 50 | content: {}, 51 | date: {type: Date, default: Date.now} 52 | }); 53 | 54 | //status api 请求响应日志 55 | var StatusAPILogSchema = new Schema({ 56 | statusAPIId: {type: String, index: true}, 57 | userId: {type: String, index: true}, 58 | statusCode: Number, 59 | spent: Number,//耗时 60 | response: String, 61 | date: {type: Date, default: Date.now} 62 | }); 63 | 64 | 65 | var User = mongoose.model('User', UserSchema, "user"); 66 | var Collection = mongoose.model('Collection', CollectionSchema, "collection"); 67 | var Har = mongoose.model('Har', HarSchema, "har"); 68 | var StatusAPI = mongoose.model('StatusAPI', StatusAPISchema, "status_api"); 69 | var StatusAPILog = mongoose.model('StatusAPILog', StatusAPILogSchema, "status_api_log"); 70 | 71 | 72 | function genId() { 73 | return uuid.v4(); 74 | } 75 | 76 | //生成id 77 | exports.genId = genId; 78 | 79 | 80 | //~========== methods create================= 81 | 82 | 83 | //创建用户,同时创建一个默认的集合 84 | exports.createUser = function (user, callback) { 85 | var userId = genId(); 86 | user.userId = userId; 87 | var u = new User(user); 88 | u.save(function (err, u) { 89 | if (err) { 90 | logger.error("创建用户失败", err, u); 91 | return callback(new Error("创建用户失败")); 92 | } 93 | 94 | if (u) 95 | exports.createCollection(userId, "Default", callback); 96 | else 97 | callback(new Error("无法保存用户")); 98 | }) 99 | 100 | }; 101 | 102 | //创建集合 103 | exports.createCollection = function (uid, name, callback) { 104 | var collectionId = genId(); 105 | var collection = new Collection({ 106 | collectionId: collectionId, 107 | userId: uid, 108 | name: name 109 | }); 110 | collection.save(callback); 111 | }; 112 | 113 | //创建一个har,它属于一个集合 114 | exports.createHar = function (uid, collectionId, name, har, callback) { 115 | if (!uid || !collectionId) { 116 | callback && callback(new Error("必须指定uid和collectionId")); 117 | return; 118 | } 119 | var harId = genId(); 120 | var har = new Har({ 121 | harId: harId, 122 | userId: uid, 123 | collectionId: collectionId, 124 | name: name, 125 | type: har && (har.method || ""), 126 | content: har 127 | }); 128 | 129 | Collection.findOne({collectionId: collectionId}, function (err, c) { 130 | if (err || !c) { 131 | return callback(new Error("无法找到collection")); 132 | } 133 | 134 | har.save(callback); 135 | }); 136 | }; 137 | 138 | //创建一个status_api 139 | exports.createStatusAPI = function (uid, name, monitor, cron, har, callback) { 140 | if (!uid) { 141 | callback && callback(new Error("必须指定uid")); 142 | return; 143 | } 144 | var statusAPIID = genId(); 145 | var statusAPI = new StatusAPI({ 146 | monitor: monitor, 147 | cron: cron, 148 | id: statusAPIID, 149 | userId: uid, 150 | type: har && (har.method || ""), 151 | name: name, 152 | content: har 153 | }); 154 | statusAPI.save(callback); 155 | }; 156 | 157 | 158 | 159 | //~========== methods find================= 160 | 161 | //查找用户 162 | exports.findUser = function (username, pwd, callback) { 163 | User.findOne({username: username, pwd: pwd}, callback); 164 | }; 165 | 166 | //查找某用户的所有collection 167 | exports.findCollections = function (uid, callback) { 168 | Collection.find({userId: uid}).sort({'_id': -1}).exec(callback); 169 | }; 170 | 171 | //查询一个collection下的所有har 172 | exports.findHarsOfCollection = function (cid, callback) { 173 | Har.find({collectionId: cid}).sort({'_id': -1}).exec(callback); 174 | }; 175 | 176 | //查询一个用户下的所有har 177 | exports.findHarsOfUser = function (uid, callback) { 178 | Har.find({userId: uid}).sort({'_id': -1}).exec(callback); 179 | }; 180 | 181 | exports.findHar = function (hid, callback) { 182 | Har.findOne({harId: hid}).exec(callback); 183 | }; 184 | 185 | //查询一个用户的所有status api 186 | exports.findStatusAPIs = function (uid, callback) { 187 | StatusAPI.find({userId: uid}).sort({'_id': -1}).exec(callback); 188 | }; 189 | 190 | //查找属于某个用户的某个status api 191 | exports.findStatusAPI = function (uid, statusAPIId, callback) { 192 | StatusAPI.findOne({id: statusAPIId, userId: uid}).exec(callback); 193 | }; 194 | 195 | //查询某个status api的请求响应日志 196 | exports.findStatusAPILogs = function (apiId, callback) { 197 | StatusAPILog.find({statusAPIId: apiId}).sort({'_id': -1}).exec(callback); 198 | }; 199 | 200 | //查询某个status api的请求响应日志 201 | exports.findStatusAPILogs = function (apiId,limit, callback) { 202 | StatusAPILog.find({statusAPIId: apiId}).sort({'_id': -1}).limit(limit).exec(callback); 203 | }; 204 | 205 | 206 | //依据时间间隔查询log 207 | exports.findStatusAPILogsByTime = function (apiId, startTime, stopTime, callback) { 208 | StatusAPILog.find({statusAPIId: apiId, date: {"$gte": startTime, "$lte": stopTime}}).sort({'_id': -1}).exec(callback); 209 | }; 210 | 211 | 212 | //~========== methods delete================= 213 | 214 | 215 | //删除collection 216 | exports.deleteCollection = function (uid, cid, callback) { 217 | Collection.remove({userId: uid, collectionId: cid}, function (err, result) { 218 | if (err) { 219 | return callback(new Error("删除collection失败")); 220 | } 221 | Har.remove({userId: uid, collectionId: cid}, function (err, result) { 222 | callback(err); 223 | }); 224 | }); 225 | }; 226 | 227 | //删除har 228 | exports.deleteHar = function (uid, hid, callback) { 229 | Har.remove({userId: uid, harId: hid}, callback); 230 | }; 231 | 232 | //删除status api 233 | exports.deleteStatusAPI = function (uid, statusAPIId, callback) { 234 | StatusAPI.remove({userId: uid, id: statusAPIId}, callback); 235 | }; 236 | 237 | //删除status api logs 238 | exports.deleteStatusAPILogs = function (uid, statusAPIId, callback) { 239 | StatusAPILog.remove({userId: uid, statusAPIId: statusAPIId}, callback); 240 | }; 241 | 242 | 243 | 244 | 245 | 246 | //~========== methods update================= 247 | 248 | 249 | //更新har 250 | exports.updateHar = function (userId, harId, harName, harContent, callback) { 251 | var conditions = {harId: harId, userId: userId}; 252 | var update = { 253 | $set: { 254 | content: harContent, 255 | name: harName, 256 | type: harContent && (harContent.method || ""), 257 | date: Date.now() 258 | } 259 | }; 260 | var options = {upsert: false}; 261 | Har.update(conditions, update, options, callback); 262 | }; 263 | 264 | 265 | //更collection name 266 | exports.updateCollection = function (userId, collectionId, newName, callback) { 267 | var conditions = {collectionId: collectionId, userId: userId}; 268 | var update = {$set: {name: newName, date: Date.now()}}; 269 | var options = {upsert: false}; 270 | Collection.update(conditions, update, options, callback); 271 | }; 272 | 273 | //更新status api 274 | exports.modifyStatusAPI = function (uid, statusAPIId, name, monitor, cron, callback) { 275 | var conditions = {id: statusAPIId, userId: uid}; 276 | var update = {$set: {name: name, monitor: monitor, cron: cron, date: Date.now()}}; 277 | var options = {upsert: false}; 278 | StatusAPI.update(conditions, update, options, callback); 279 | }; 280 | 281 | 282 | function Callback(err, result) { 283 | console.log(err, result); 284 | } 285 | 286 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "moklr", 3 | "version": "0.6.0", 4 | "author": "sumory.wu", 5 | "private": true, 6 | "scripts": { 7 | "start": "node index.js" 8 | }, 9 | "dependencies": { 10 | "express": "4.13.3", 11 | "express-session": "1.11.3", 12 | "body-parser": "1.13.3", 13 | "ejs": "2.3.1", 14 | "method-override": "1.0.2", 15 | "multiparty": "3.2.4", 16 | "ioredis": "1.7.5", 17 | "async": "0.9.0", 18 | "mysql": "2.6.0", 19 | "log4js": "0.6.16", 20 | "utility":"1.2.1", 21 | "request":"2.53.0", 22 | "node-uuid":"1.4.3", 23 | "httpsnippet": "1.16.3", 24 | "mongoose":"4.1.3" 25 | } 26 | } 27 | 28 | -------------------------------------------------------------------------------- /public/css/1.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/1.woff2 -------------------------------------------------------------------------------- /public/css/2.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/2.woff2 -------------------------------------------------------------------------------- /public/css/3.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/3.woff2 -------------------------------------------------------------------------------- /public/css/4.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/4.woff2 -------------------------------------------------------------------------------- /public/css/font.css: -------------------------------------------------------------------------------- 1 | /* latin-ext */ 2 | @font-face { 3 | font-family: 'News Cycle'; 4 | font-style: normal; 5 | font-weight: 400; 6 | src: local('News Cycle'), local('NewsCycle'), url(1.woff2) format('woff2'); 7 | unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; 8 | } 9 | /* latin */ 10 | @font-face { 11 | font-family: 'News Cycle'; 12 | font-style: normal; 13 | font-weight: 400; 14 | src: local('News Cycle'), local('NewsCycle'), url(4.woff2) format('woff2'); 15 | unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000; 16 | } 17 | /* latin-ext */ 18 | @font-face { 19 | font-family: 'News Cycle'; 20 | font-style: normal; 21 | font-weight: 700; 22 | src: local('News Cycle Bold'), local('NewsCycle-Bold'), url(2.woff2) format('woff2'); 23 | unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; 24 | } 25 | /* latin */ 26 | @font-face { 27 | font-family: 'News Cycle'; 28 | font-style: normal; 29 | font-weight: 700; 30 | src: local('News Cycle Bold'), local('NewsCycle-Bold'), url(3.woff2) format('woff2'); 31 | unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000; 32 | } -------------------------------------------------------------------------------- /public/css/highlight-8.4-github.min.css: -------------------------------------------------------------------------------- 1 | .hljs{display:block;overflow-x:auto;padding:0.5em;color:#333;background:#f8f8f8;-webkit-text-size-adjust:none}.hljs-comment,.diff .hljs-header,.hljs-javadoc{color:#998;font-style:italic}.hljs-keyword,.css .rule .hljs-keyword,.hljs-winutils,.nginx .hljs-title,.hljs-subst,.hljs-request,.hljs-status{color:#333;font-weight:bold}.hljs-number,.hljs-hexcolor,.ruby .hljs-constant{color:#008080}.hljs-string,.hljs-tag .hljs-value,.hljs-phpdoc,.hljs-dartdoc,.tex .hljs-formula{color:#d14}.hljs-title,.hljs-id,.scss .hljs-preprocessor{color:#900;font-weight:bold}.hljs-list .hljs-keyword,.hljs-subst{font-weight:normal}.hljs-class .hljs-title,.hljs-type,.vhdl .hljs-literal,.tex .hljs-command{color:#458;font-weight:bold}.hljs-tag,.hljs-tag .hljs-title,.hljs-rules .hljs-property,.django .hljs-tag .hljs-keyword{color:#000080;font-weight:normal}.hljs-attribute,.hljs-variable,.lisp .hljs-body{color:#008080}.hljs-regexp{color:#009926}.hljs-symbol,.ruby .hljs-symbol .hljs-string,.lisp .hljs-keyword,.clojure .hljs-keyword,.scheme .hljs-keyword,.tex .hljs-special,.hljs-prompt{color:#990073}.hljs-built_in{color:#0086b3}.hljs-preprocessor,.hljs-pragma,.hljs-pi,.hljs-doctype,.hljs-shebang,.hljs-cdata{color:#999;font-weight:bold}.hljs-deletion{background:#fdd}.hljs-addition{background:#dfd}.diff .hljs-change{background:#0086b3}.hljs-chunk{color:#aaa} 2 | -------------------------------------------------------------------------------- /public/css/icheck-skins/all.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin skins 2 | ----------------------------------- */ 3 | @import url("minimal/_all.css"); 4 | /* 5 | @import url("minimal/minimal.css"); 6 | @import url("minimal/red.css"); 7 | @import url("minimal/green.css"); 8 | @import url("minimal/blue.css"); 9 | @import url("minimal/aero.css"); 10 | @import url("minimal/grey.css"); 11 | @import url("minimal/orange.css"); 12 | @import url("minimal/yellow.css"); 13 | @import url("minimal/pink.css"); 14 | @import url("minimal/purple.css"); 15 | */ 16 | 17 | @import url("square/_all.css"); 18 | /* 19 | @import url("square/square.css"); 20 | @import url("square/red.css"); 21 | @import url("square/green.css"); 22 | @import url("square/blue.css"); 23 | @import url("square/aero.css"); 24 | @import url("square/grey.css"); 25 | @import url("square/orange.css"); 26 | @import url("square/yellow.css"); 27 | @import url("square/pink.css"); 28 | @import url("square/purple.css"); 29 | */ 30 | 31 | @import url("flat/_all.css"); 32 | /* 33 | @import url("flat/flat.css"); 34 | @import url("flat/red.css"); 35 | @import url("flat/green.css"); 36 | @import url("flat/blue.css"); 37 | @import url("flat/aero.css"); 38 | @import url("flat/grey.css"); 39 | @import url("flat/orange.css"); 40 | @import url("flat/yellow.css"); 41 | @import url("flat/pink.css"); 42 | @import url("flat/purple.css"); 43 | */ 44 | 45 | @import url("line/_all.css"); 46 | /* 47 | @import url("line/line.css"); 48 | @import url("line/red.css"); 49 | @import url("line/green.css"); 50 | @import url("line/blue.css"); 51 | @import url("line/aero.css"); 52 | @import url("line/grey.css"); 53 | @import url("line/orange.css"); 54 | @import url("line/yellow.css"); 55 | @import url("line/pink.css"); 56 | @import url("line/purple.css"); 57 | */ 58 | 59 | @import url("polaris/polaris.css"); 60 | 61 | @import url("futurico/futurico.css"); -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/aero.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, aero 2 | ----------------------------------- */ 3 | .icheckbox_flat-aero, 4 | .iradio_flat-aero { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(aero.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-aero { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-aero.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-aero.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-aero.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-aero { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-aero.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-aero.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-aero.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-aero, 48 | .iradio_flat-aero { 49 | background-image: url(aero@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/aero.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/aero.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/aero@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/aero@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/blue.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, blue 2 | ----------------------------------- */ 3 | .icheckbox_flat-blue, 4 | .iradio_flat-blue { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(blue.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-blue { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-blue.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-blue.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-blue.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-blue { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-blue.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-blue.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-blue.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-blue, 48 | .iradio_flat-blue { 49 | background-image: url(blue@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/blue.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/blue@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/blue@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/flat.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin flat skin, black 2 | ----------------------------------- */ 3 | .icheckbox_flat, 4 | .iradio_flat { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(flat.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat, 48 | .iradio_flat { 49 | background-image: url(flat@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/flat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/flat.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/flat@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/flat@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/green.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, green 2 | ----------------------------------- */ 3 | .icheckbox_flat-green, 4 | .iradio_flat-green { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(green.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-green { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-green.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-green.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-green.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-green { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-green.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-green.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-green.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-green, 48 | .iradio_flat-green { 49 | background-image: url(green@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/green.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/green@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/green@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/grey.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, grey 2 | ----------------------------------- */ 3 | .icheckbox_flat-grey, 4 | .iradio_flat-grey { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(grey.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-grey { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-grey.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-grey.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-grey.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-grey { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-grey.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-grey.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-grey.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-grey, 48 | .iradio_flat-grey { 49 | background-image: url(grey@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/grey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/grey.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/grey@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/grey@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/orange.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, orange 2 | ----------------------------------- */ 3 | .icheckbox_flat-orange, 4 | .iradio_flat-orange { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(orange.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-orange { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-orange.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-orange.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-orange.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-orange { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-orange.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-orange.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-orange.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-orange, 48 | .iradio_flat-orange { 49 | background-image: url(orange@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/orange.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/orange@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/orange@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/pink.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, pink 2 | ----------------------------------- */ 3 | .icheckbox_flat-pink, 4 | .iradio_flat-pink { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(pink.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-pink { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-pink.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-pink.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-pink.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-pink { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-pink.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-pink.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-pink.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-pink, 48 | .iradio_flat-pink { 49 | background-image: url(pink@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/pink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/pink.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/pink@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/pink@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/purple.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, purple 2 | ----------------------------------- */ 3 | .icheckbox_flat-purple, 4 | .iradio_flat-purple { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(purple.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-purple { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-purple.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-purple.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-purple.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-purple { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-purple.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-purple.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-purple.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-purple, 48 | .iradio_flat-purple { 49 | background-image: url(purple@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/purple.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/purple.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/purple@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/purple@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/red.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, red 2 | ----------------------------------- */ 3 | .icheckbox_flat-red, 4 | .iradio_flat-red { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(red.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-red { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-red.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-red.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-red.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-red { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-red.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-red.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-red.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-red, 48 | .iradio_flat-red { 49 | background-image: url(red@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/red.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/red@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/red@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/yellow.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Flat skin, yellow 2 | ----------------------------------- */ 3 | .icheckbox_flat-yellow, 4 | .iradio_flat-yellow { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 20px; 11 | height: 20px; 12 | background: url(yellow.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_flat-yellow { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_flat-yellow.checked { 21 | background-position: -22px 0; 22 | } 23 | .icheckbox_flat-yellow.disabled { 24 | background-position: -44px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_flat-yellow.checked.disabled { 28 | background-position: -66px 0; 29 | } 30 | 31 | .iradio_flat-yellow { 32 | background-position: -88px 0; 33 | } 34 | .iradio_flat-yellow.checked { 35 | background-position: -110px 0; 36 | } 37 | .iradio_flat-yellow.disabled { 38 | background-position: -132px 0; 39 | cursor: default; 40 | } 41 | .iradio_flat-yellow.checked.disabled { 42 | background-position: -154px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_flat-yellow, 48 | .iradio_flat-yellow { 49 | background-image: url(yellow@2x.png); 50 | -webkit-background-size: 176px 22px; 51 | background-size: 176px 22px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/yellow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/yellow.png -------------------------------------------------------------------------------- /public/css/icheck-skins/flat/yellow@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/flat/yellow@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/futurico/futurico.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Futurico skin 2 | ----------------------------------- */ 3 | .icheckbox_futurico, 4 | .iradio_futurico { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 16px; 11 | height: 17px; 12 | background: url(futurico.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_futurico { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_futurico.checked { 21 | background-position: -18px 0; 22 | } 23 | .icheckbox_futurico.disabled { 24 | background-position: -36px 0; 25 | cursor: default; 26 | } 27 | .icheckbox_futurico.checked.disabled { 28 | background-position: -54px 0; 29 | } 30 | 31 | .iradio_futurico { 32 | background-position: -72px 0; 33 | } 34 | .iradio_futurico.checked { 35 | background-position: -90px 0; 36 | } 37 | .iradio_futurico.disabled { 38 | background-position: -108px 0; 39 | cursor: default; 40 | } 41 | .iradio_futurico.checked.disabled { 42 | background-position: -126px 0; 43 | } 44 | 45 | /* HiDPI support */ 46 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 47 | .icheckbox_futurico, 48 | .iradio_futurico { 49 | background-image: url(futurico@2x.png); 50 | -webkit-background-size: 144px 19px; 51 | background-size: 144px 19px; 52 | } 53 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/futurico/futurico.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/futurico/futurico.png -------------------------------------------------------------------------------- /public/css/icheck-skins/futurico/futurico@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/futurico/futurico@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/line/aero.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, aero 2 | ----------------------------------- */ 3 | .icheckbox_line-aero, 4 | .iradio_line-aero { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #9cc2cb; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-aero .icheck_line-icon, 20 | .iradio_line-aero .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-aero.hover, 33 | .icheckbox_line-aero.checked.hover, 34 | .iradio_line-aero.hover { 35 | background: #B5D1D8; 36 | } 37 | .icheckbox_line-aero.checked, 38 | .iradio_line-aero.checked { 39 | background: #9cc2cb; 40 | } 41 | .icheckbox_line-aero.checked .icheck_line-icon, 42 | .iradio_line-aero.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-aero.disabled, 46 | .iradio_line-aero.disabled { 47 | background: #D2E4E8; 48 | cursor: default; 49 | } 50 | .icheckbox_line-aero.disabled .icheck_line-icon, 51 | .iradio_line-aero.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-aero.checked.disabled, 55 | .iradio_line-aero.checked.disabled { 56 | background: #D2E4E8; 57 | } 58 | .icheckbox_line-aero.checked.disabled .icheck_line-icon, 59 | .iradio_line-aero.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-aero .icheck_line-icon, 66 | .iradio_line-aero .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/blue.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, blue 2 | ----------------------------------- */ 3 | .icheckbox_line-blue, 4 | .iradio_line-blue { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #2489c5; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-blue .icheck_line-icon, 20 | .iradio_line-blue .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-blue.hover, 33 | .icheckbox_line-blue.checked.hover, 34 | .iradio_line-blue.hover { 35 | background: #3DA0DB; 36 | } 37 | .icheckbox_line-blue.checked, 38 | .iradio_line-blue.checked { 39 | background: #2489c5; 40 | } 41 | .icheckbox_line-blue.checked .icheck_line-icon, 42 | .iradio_line-blue.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-blue.disabled, 46 | .iradio_line-blue.disabled { 47 | background: #ADD7F0; 48 | cursor: default; 49 | } 50 | .icheckbox_line-blue.disabled .icheck_line-icon, 51 | .iradio_line-blue.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-blue.checked.disabled, 55 | .iradio_line-blue.checked.disabled { 56 | background: #ADD7F0; 57 | } 58 | .icheckbox_line-blue.checked.disabled .icheck_line-icon, 59 | .iradio_line-blue.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-blue .icheck_line-icon, 66 | .iradio_line-blue .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/green.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, green 2 | ----------------------------------- */ 3 | .icheckbox_line-green, 4 | .iradio_line-green { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #1b7e5a; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-green .icheck_line-icon, 20 | .iradio_line-green .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-green.hover, 33 | .icheckbox_line-green.checked.hover, 34 | .iradio_line-green.hover { 35 | background: #24AA7A; 36 | } 37 | .icheckbox_line-green.checked, 38 | .iradio_line-green.checked { 39 | background: #1b7e5a; 40 | } 41 | .icheckbox_line-green.checked .icheck_line-icon, 42 | .iradio_line-green.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-green.disabled, 46 | .iradio_line-green.disabled { 47 | background: #89E6C4; 48 | cursor: default; 49 | } 50 | .icheckbox_line-green.disabled .icheck_line-icon, 51 | .iradio_line-green.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-green.checked.disabled, 55 | .iradio_line-green.checked.disabled { 56 | background: #89E6C4; 57 | } 58 | .icheckbox_line-green.checked.disabled .icheck_line-icon, 59 | .iradio_line-green.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-green .icheck_line-icon, 66 | .iradio_line-green .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/grey.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, grey 2 | ----------------------------------- */ 3 | .icheckbox_line-grey, 4 | .iradio_line-grey { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #73716e; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-grey .icheck_line-icon, 20 | .iradio_line-grey .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-grey.hover, 33 | .icheckbox_line-grey.checked.hover, 34 | .iradio_line-grey.hover { 35 | background: #8B8986; 36 | } 37 | .icheckbox_line-grey.checked, 38 | .iradio_line-grey.checked { 39 | background: #73716e; 40 | } 41 | .icheckbox_line-grey.checked .icheck_line-icon, 42 | .iradio_line-grey.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-grey.disabled, 46 | .iradio_line-grey.disabled { 47 | background: #D5D4D3; 48 | cursor: default; 49 | } 50 | .icheckbox_line-grey.disabled .icheck_line-icon, 51 | .iradio_line-grey.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-grey.checked.disabled, 55 | .iradio_line-grey.checked.disabled { 56 | background: #D5D4D3; 57 | } 58 | .icheckbox_line-grey.checked.disabled .icheck_line-icon, 59 | .iradio_line-grey.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-grey .icheck_line-icon, 66 | .iradio_line-grey .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/line.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, black 2 | ----------------------------------- */ 3 | .icheckbox_line, 4 | .iradio_line { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #000; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line .icheck_line-icon, 20 | .iradio_line .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line.hover, 33 | .icheckbox_line.checked.hover, 34 | .iradio_line.hover { 35 | background: #444; 36 | } 37 | .icheckbox_line.checked, 38 | .iradio_line.checked { 39 | background: #000; 40 | } 41 | .icheckbox_line.checked .icheck_line-icon, 42 | .iradio_line.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line.disabled, 46 | .iradio_line.disabled { 47 | background: #ccc; 48 | cursor: default; 49 | } 50 | .icheckbox_line.disabled .icheck_line-icon, 51 | .iradio_line.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line.checked.disabled, 55 | .iradio_line.checked.disabled { 56 | background: #ccc; 57 | } 58 | .icheckbox_line.checked.disabled .icheck_line-icon, 59 | .iradio_line.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line .icheck_line-icon, 66 | .iradio_line .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/line.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/line/line.png -------------------------------------------------------------------------------- /public/css/icheck-skins/line/line@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/line/line@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/line/orange.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, orange 2 | ----------------------------------- */ 3 | .icheckbox_line-orange, 4 | .iradio_line-orange { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #f70; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-orange .icheck_line-icon, 20 | .iradio_line-orange .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-orange.hover, 33 | .icheckbox_line-orange.checked.hover, 34 | .iradio_line-orange.hover { 35 | background: #FF9233; 36 | } 37 | .icheckbox_line-orange.checked, 38 | .iradio_line-orange.checked { 39 | background: #f70; 40 | } 41 | .icheckbox_line-orange.checked .icheck_line-icon, 42 | .iradio_line-orange.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-orange.disabled, 46 | .iradio_line-orange.disabled { 47 | background: #FFD6B3; 48 | cursor: default; 49 | } 50 | .icheckbox_line-orange.disabled .icheck_line-icon, 51 | .iradio_line-orange.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-orange.checked.disabled, 55 | .iradio_line-orange.checked.disabled { 56 | background: #FFD6B3; 57 | } 58 | .icheckbox_line-orange.checked.disabled .icheck_line-icon, 59 | .iradio_line-orange.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-orange .icheck_line-icon, 66 | .iradio_line-orange .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/pink.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, pink 2 | ----------------------------------- */ 3 | .icheckbox_line-pink, 4 | .iradio_line-pink { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #a77a94; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-pink .icheck_line-icon, 20 | .iradio_line-pink .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-pink.hover, 33 | .icheckbox_line-pink.checked.hover, 34 | .iradio_line-pink.hover { 35 | background: #B995A9; 36 | } 37 | .icheckbox_line-pink.checked, 38 | .iradio_line-pink.checked { 39 | background: #a77a94; 40 | } 41 | .icheckbox_line-pink.checked .icheck_line-icon, 42 | .iradio_line-pink.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-pink.disabled, 46 | .iradio_line-pink.disabled { 47 | background: #E0D0DA; 48 | cursor: default; 49 | } 50 | .icheckbox_line-pink.disabled .icheck_line-icon, 51 | .iradio_line-pink.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-pink.checked.disabled, 55 | .iradio_line-pink.checked.disabled { 56 | background: #E0D0DA; 57 | } 58 | .icheckbox_line-pink.checked.disabled .icheck_line-icon, 59 | .iradio_line-pink.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-pink .icheck_line-icon, 66 | .iradio_line-pink .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/purple.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, purple 2 | ----------------------------------- */ 3 | .icheckbox_line-purple, 4 | .iradio_line-purple { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #6a5a8c; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-purple .icheck_line-icon, 20 | .iradio_line-purple .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-purple.hover, 33 | .icheckbox_line-purple.checked.hover, 34 | .iradio_line-purple.hover { 35 | background: #8677A7; 36 | } 37 | .icheckbox_line-purple.checked, 38 | .iradio_line-purple.checked { 39 | background: #6a5a8c; 40 | } 41 | .icheckbox_line-purple.checked .icheck_line-icon, 42 | .iradio_line-purple.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-purple.disabled, 46 | .iradio_line-purple.disabled { 47 | background: #D2CCDE; 48 | cursor: default; 49 | } 50 | .icheckbox_line-purple.disabled .icheck_line-icon, 51 | .iradio_line-purple.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-purple.checked.disabled, 55 | .iradio_line-purple.checked.disabled { 56 | background: #D2CCDE; 57 | } 58 | .icheckbox_line-purple.checked.disabled .icheck_line-icon, 59 | .iradio_line-purple.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-purple .icheck_line-icon, 66 | .iradio_line-purple .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/red.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, red 2 | ----------------------------------- */ 3 | .icheckbox_line-red, 4 | .iradio_line-red { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #e56c69; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-red .icheck_line-icon, 20 | .iradio_line-red .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-red.hover, 33 | .icheckbox_line-red.checked.hover, 34 | .iradio_line-red.hover { 35 | background: #E98582; 36 | } 37 | .icheckbox_line-red.checked, 38 | .iradio_line-red.checked { 39 | background: #e56c69; 40 | } 41 | .icheckbox_line-red.checked .icheck_line-icon, 42 | .iradio_line-red.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-red.disabled, 46 | .iradio_line-red.disabled { 47 | background: #F7D3D2; 48 | cursor: default; 49 | } 50 | .icheckbox_line-red.disabled .icheck_line-icon, 51 | .iradio_line-red.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-red.checked.disabled, 55 | .iradio_line-red.checked.disabled { 56 | background: #F7D3D2; 57 | } 58 | .icheckbox_line-red.checked.disabled .icheck_line-icon, 59 | .iradio_line-red.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-red .icheck_line-icon, 66 | .iradio_line-red .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/line/yellow.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Line skin, yellow 2 | ----------------------------------- */ 3 | .icheckbox_line-yellow, 4 | .iradio_line-yellow { 5 | position: relative; 6 | display: block; 7 | margin: 0; 8 | padding: 5px 15px 5px 38px; 9 | font-size: 13px; 10 | line-height: 17px; 11 | color: #fff; 12 | background: #FFC414; 13 | border: none; 14 | -webkit-border-radius: 3px; 15 | -moz-border-radius: 3px; 16 | border-radius: 3px; 17 | cursor: pointer; 18 | } 19 | .icheckbox_line-yellow .icheck_line-icon, 20 | .iradio_line-yellow .icheck_line-icon { 21 | position: absolute; 22 | top: 50%; 23 | left: 13px; 24 | width: 13px; 25 | height: 11px; 26 | margin: -5px 0 0 0; 27 | padding: 0; 28 | overflow: hidden; 29 | background: url(line.png) no-repeat; 30 | border: none; 31 | } 32 | .icheckbox_line-yellow.hover, 33 | .icheckbox_line-yellow.checked.hover, 34 | .iradio_line-yellow.hover { 35 | background: #FFD34F; 36 | } 37 | .icheckbox_line-yellow.checked, 38 | .iradio_line-yellow.checked { 39 | background: #FFC414; 40 | } 41 | .icheckbox_line-yellow.checked .icheck_line-icon, 42 | .iradio_line-yellow.checked .icheck_line-icon { 43 | background-position: -15px 0; 44 | } 45 | .icheckbox_line-yellow.disabled, 46 | .iradio_line-yellow.disabled { 47 | background: #FFE495; 48 | cursor: default; 49 | } 50 | .icheckbox_line-yellow.disabled .icheck_line-icon, 51 | .iradio_line-yellow.disabled .icheck_line-icon { 52 | background-position: -30px 0; 53 | } 54 | .icheckbox_line-yellow.checked.disabled, 55 | .iradio_line-yellow.checked.disabled { 56 | background: #FFE495; 57 | } 58 | .icheckbox_line-yellow.checked.disabled .icheck_line-icon, 59 | .iradio_line-yellow.checked.disabled .icheck_line-icon { 60 | background-position: -45px 0; 61 | } 62 | 63 | /* HiDPI support */ 64 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 65 | .icheckbox_line-yellow .icheck_line-icon, 66 | .iradio_line-yellow .icheck_line-icon { 67 | background-image: url(line@2x.png); 68 | -webkit-background-size: 60px 13px; 69 | background-size: 60px 13px; 70 | } 71 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/aero.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, aero 2 | ----------------------------------- */ 3 | .icheckbox_minimal-aero, 4 | .iradio_minimal-aero { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(aero.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-aero { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-aero.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-aero.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-aero.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-aero.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-aero { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-aero.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-aero.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-aero.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-aero.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-aero, 54 | .iradio_minimal-aero { 55 | background-image: url(aero@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/aero.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/aero.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/aero@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/aero@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/blue.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, blue 2 | ----------------------------------- */ 3 | .icheckbox_minimal-blue, 4 | .iradio_minimal-blue { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(blue.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-blue { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-blue.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-blue.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-blue.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-blue.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-blue { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-blue.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-blue.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-blue.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-blue.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-blue, 54 | .iradio_minimal-blue { 55 | background-image: url(blue@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/blue.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/blue@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/blue@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/green.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, green 2 | ----------------------------------- */ 3 | .icheckbox_minimal-green, 4 | .iradio_minimal-green { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(green.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-green { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-green.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-green.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-green.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-green.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-green { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-green.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-green.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-green.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-green.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-green, 54 | .iradio_minimal-green { 55 | background-image: url(green@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/green.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/green@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/green@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/grey.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, grey 2 | ----------------------------------- */ 3 | .icheckbox_minimal-grey, 4 | .iradio_minimal-grey { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(grey.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-grey { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-grey.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-grey.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-grey.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-grey.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-grey { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-grey.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-grey.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-grey.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-grey.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-grey, 54 | .iradio_minimal-grey { 55 | background-image: url(grey@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/grey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/grey.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/grey@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/grey@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/minimal.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, black 2 | ----------------------------------- */ 3 | .icheckbox_minimal, 4 | .iradio_minimal { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(minimal.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal, 54 | .iradio_minimal { 55 | background-image: url(minimal@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/minimal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/minimal.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/minimal@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/minimal@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/orange.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, orange 2 | ----------------------------------- */ 3 | .icheckbox_minimal-orange, 4 | .iradio_minimal-orange { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(orange.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-orange { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-orange.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-orange.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-orange.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-orange.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-orange { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-orange.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-orange.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-orange.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-orange.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-orange, 54 | .iradio_minimal-orange { 55 | background-image: url(orange@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/orange.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/orange@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/orange@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/pink.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, pink 2 | ----------------------------------- */ 3 | .icheckbox_minimal-pink, 4 | .iradio_minimal-pink { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(pink.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-pink { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-pink.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-pink.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-pink.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-pink.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-pink { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-pink.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-pink.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-pink.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-pink.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-pink, 54 | .iradio_minimal-pink { 55 | background-image: url(pink@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/pink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/pink.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/pink@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/pink@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/purple.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, purple 2 | ----------------------------------- */ 3 | .icheckbox_minimal-purple, 4 | .iradio_minimal-purple { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(purple.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-purple { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-purple.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-purple.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-purple.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-purple.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-purple { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-purple.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-purple.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-purple.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-purple.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-purple, 54 | .iradio_minimal-purple { 55 | background-image: url(purple@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/purple.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/purple.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/purple@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/purple@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/red.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, red 2 | ----------------------------------- */ 3 | .icheckbox_minimal-red, 4 | .iradio_minimal-red { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(red.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-red { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-red.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-red.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-red.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-red.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-red { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-red.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-red.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-red.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-red.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-red, 54 | .iradio_minimal-red { 55 | background-image: url(red@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/red.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/red@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/red@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/yellow.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Minimal skin, yellow 2 | ----------------------------------- */ 3 | .icheckbox_minimal-yellow, 4 | .iradio_minimal-yellow { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 18px; 11 | height: 18px; 12 | background: url(yellow.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_minimal-yellow { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_minimal-yellow.hover { 21 | background-position: -20px 0; 22 | } 23 | .icheckbox_minimal-yellow.checked { 24 | background-position: -40px 0; 25 | } 26 | .icheckbox_minimal-yellow.disabled { 27 | background-position: -60px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_minimal-yellow.checked.disabled { 31 | background-position: -80px 0; 32 | } 33 | 34 | .iradio_minimal-yellow { 35 | background-position: -100px 0; 36 | } 37 | .iradio_minimal-yellow.hover { 38 | background-position: -120px 0; 39 | } 40 | .iradio_minimal-yellow.checked { 41 | background-position: -140px 0; 42 | } 43 | .iradio_minimal-yellow.disabled { 44 | background-position: -160px 0; 45 | cursor: default; 46 | } 47 | .iradio_minimal-yellow.checked.disabled { 48 | background-position: -180px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_minimal-yellow, 54 | .iradio_minimal-yellow { 55 | background-image: url(yellow@2x.png); 56 | -webkit-background-size: 200px 20px; 57 | background-size: 200px 20px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/yellow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/yellow.png -------------------------------------------------------------------------------- /public/css/icheck-skins/minimal/yellow@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/minimal/yellow@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/polaris/polaris.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Polaris skin 2 | ----------------------------------- */ 3 | .icheckbox_polaris, 4 | .iradio_polaris { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 29px; 11 | height: 29px; 12 | background: url(polaris.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_polaris { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_polaris.hover { 21 | background-position: -31px 0; 22 | } 23 | .icheckbox_polaris.checked { 24 | background-position: -62px 0; 25 | } 26 | .icheckbox_polaris.disabled { 27 | background-position: -93px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_polaris.checked.disabled { 31 | background-position: -124px 0; 32 | } 33 | 34 | .iradio_polaris { 35 | background-position: -155px 0; 36 | } 37 | .iradio_polaris.hover { 38 | background-position: -186px 0; 39 | } 40 | .iradio_polaris.checked { 41 | background-position: -217px 0; 42 | } 43 | .iradio_polaris.disabled { 44 | background-position: -248px 0; 45 | cursor: default; 46 | } 47 | .iradio_polaris.checked.disabled { 48 | background-position: -279px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_polaris, 54 | .iradio_polaris { 55 | background-image: url(polaris@2x.png); 56 | -webkit-background-size: 310px 31px; 57 | background-size: 310px 31px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/polaris/polaris.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/polaris/polaris.png -------------------------------------------------------------------------------- /public/css/icheck-skins/polaris/polaris@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/polaris/polaris@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/aero.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, aero 2 | ----------------------------------- */ 3 | .icheckbox_square-aero, 4 | .iradio_square-aero { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(aero.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-aero { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-aero.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-aero.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-aero.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-aero.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-aero { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-aero.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-aero.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-aero.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-aero.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-aero, 54 | .iradio_square-aero { 55 | background-image: url(aero@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/aero.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/aero.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/aero@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/aero@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/blue.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, blue 2 | ----------------------------------- */ 3 | .icheckbox_square-blue, 4 | .iradio_square-blue { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(blue.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-blue { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-blue.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-blue.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-blue.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-blue.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-blue { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-blue.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-blue.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-blue.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-blue.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-blue, 54 | .iradio_square-blue { 55 | background-image: url(blue@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/blue.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/blue@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/blue@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/green.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, green 2 | ----------------------------------- */ 3 | .icheckbox_square-green, 4 | .iradio_square-green { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(green.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-green { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-green.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-green.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-green.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-green.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-green { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-green.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-green.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-green.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-green.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-green, 54 | .iradio_square-green { 55 | background-image: url(green@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/green.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/green@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/green@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/grey.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, grey 2 | ----------------------------------- */ 3 | .icheckbox_square-grey, 4 | .iradio_square-grey { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(grey.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-grey { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-grey.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-grey.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-grey.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-grey.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-grey { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-grey.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-grey.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-grey.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-grey.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-grey, 54 | .iradio_square-grey { 55 | background-image: url(grey@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/grey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/grey.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/grey@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/grey@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/orange.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, orange 2 | ----------------------------------- */ 3 | .icheckbox_square-orange, 4 | .iradio_square-orange { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(orange.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-orange { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-orange.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-orange.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-orange.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-orange.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-orange { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-orange.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-orange.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-orange.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-orange.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-orange, 54 | .iradio_square-orange { 55 | background-image: url(orange@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/orange.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/orange@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/orange@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/pink.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, pink 2 | ----------------------------------- */ 3 | .icheckbox_square-pink, 4 | .iradio_square-pink { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(pink.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-pink { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-pink.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-pink.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-pink.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-pink.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-pink { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-pink.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-pink.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-pink.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-pink.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-pink, 54 | .iradio_square-pink { 55 | background-image: url(pink@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/pink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/pink.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/pink@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/pink@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/purple.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, purple 2 | ----------------------------------- */ 3 | .icheckbox_square-purple, 4 | .iradio_square-purple { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(purple.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-purple { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-purple.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-purple.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-purple.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-purple.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-purple { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-purple.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-purple.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-purple.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-purple.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-purple, 54 | .iradio_square-purple { 55 | background-image: url(purple@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/purple.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/purple.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/purple@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/purple@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/red.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, red 2 | ----------------------------------- */ 3 | .icheckbox_square-red, 4 | .iradio_square-red { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(red.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-red { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-red.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-red.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-red.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-red.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-red { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-red.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-red.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-red.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-red.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-red, 54 | .iradio_square-red { 55 | background-image: url(red@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/red.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/red@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/red@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/square.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, black 2 | ----------------------------------- */ 3 | .icheckbox_square, 4 | .iradio_square { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(square.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square, 54 | .iradio_square { 55 | background-image: url(square@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/square.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/square.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/square@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/square@2x.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/yellow.css: -------------------------------------------------------------------------------- 1 | /* iCheck plugin Square skin, yellow 2 | ----------------------------------- */ 3 | .icheckbox_square-yellow, 4 | .iradio_square-yellow { 5 | display: inline-block; 6 | *display: inline; 7 | vertical-align: middle; 8 | margin: 0; 9 | padding: 0; 10 | width: 22px; 11 | height: 22px; 12 | background: url(yellow.png) no-repeat; 13 | border: none; 14 | cursor: pointer; 15 | } 16 | 17 | .icheckbox_square-yellow { 18 | background-position: 0 0; 19 | } 20 | .icheckbox_square-yellow.hover { 21 | background-position: -24px 0; 22 | } 23 | .icheckbox_square-yellow.checked { 24 | background-position: -48px 0; 25 | } 26 | .icheckbox_square-yellow.disabled { 27 | background-position: -72px 0; 28 | cursor: default; 29 | } 30 | .icheckbox_square-yellow.checked.disabled { 31 | background-position: -96px 0; 32 | } 33 | 34 | .iradio_square-yellow { 35 | background-position: -120px 0; 36 | } 37 | .iradio_square-yellow.hover { 38 | background-position: -144px 0; 39 | } 40 | .iradio_square-yellow.checked { 41 | background-position: -168px 0; 42 | } 43 | .iradio_square-yellow.disabled { 44 | background-position: -192px 0; 45 | cursor: default; 46 | } 47 | .iradio_square-yellow.checked.disabled { 48 | background-position: -216px 0; 49 | } 50 | 51 | /* HiDPI support */ 52 | @media (-o-min-device-pixel-ratio: 5/4), (-webkit-min-device-pixel-ratio: 1.25), (min-resolution: 120dpi), (min-resolution: 1.25dppx) { 53 | .icheckbox_square-yellow, 54 | .iradio_square-yellow { 55 | background-image: url(yellow@2x.png); 56 | -webkit-background-size: 240px 24px; 57 | background-size: 240px 24px; 58 | } 59 | } -------------------------------------------------------------------------------- /public/css/icheck-skins/square/yellow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/yellow.png -------------------------------------------------------------------------------- /public/css/icheck-skins/square/yellow@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/css/icheck-skins/square/yellow@2x.png -------------------------------------------------------------------------------- /public/css/main.css: -------------------------------------------------------------------------------- 1 | * { 2 | -webkit-font-smoothing: antialiased; 3 | -moz-osx-font-smoothing: grayscale; 4 | } 5 | 6 | body { 7 | color: #36434C; 8 | font-family: 'Open Sans', helvetica, sans-serif; 9 | } 10 | 11 | code, kbd, pre, samp { 12 | background-color: #FFFFFF; 13 | font-family: 'Source Code Pro', Menlo, Monaco, Consolas, 'Courier New', monospace; 14 | } 15 | 16 | 17 | div[data-page="moklr"] .form-inline .form-group { 18 | margin-bottom: 15px; 19 | } 20 | 21 | div[data-page="moklr"] .input-group.multi > .form-control { 22 | width: 49%; 23 | } 24 | 25 | div[data-page="moklr"] .input-group.multi > .form-control:last-of-type { 26 | margin-left: -1px; 27 | } 28 | 29 | div[data-page="moklr"] .pair:last-of-type .btn-danger { 30 | display: none; 31 | } 32 | 33 | div[data-page="moklr"] .pair .btn-success { 34 | border-radius: 0px; 35 | } 36 | 37 | div[data-page="moklr"] .pair .btn-danger { 38 | border-radius: 0px; 39 | } 40 | 41 | #harform .btn-success i { 42 | top: 0px; 43 | } 44 | 45 | #harform .btn-danger i { 46 | top: 0px; 47 | } 48 | 49 | div[data-page="moklr"] .pair:not(:last-of-type) .btn-success { 50 | display: none; 51 | } 52 | 53 | div[data-page="moklr"] code { 54 | min-height: 400px; 55 | } 56 | 57 | .table { 58 | table-layout: fixed; 59 | white-space: nowrap; 60 | } 61 | 62 | .table td { 63 | white-space: nowrap; 64 | overflow: hidden; 65 | text-overflow: ellipsis; 66 | } 67 | 68 | .badge { 69 | padding-bottom: 2px; 70 | padding-top: 4px; 71 | vertical-align: 2px; 72 | font-size: 10px; 73 | } 74 | 75 | /**/ 76 | .logo a { 77 | font-size: 24px; 78 | } 79 | 80 | .container { 81 | padding-left: 0px; 82 | padding-right: 0px; 83 | } 84 | 85 | span.input-group-btn button.btn { 86 | height: 30px; 87 | } 88 | 89 | #preview_code { 90 | margin-top: 20px; 91 | max-height:600px; 92 | } 93 | 94 | #codeArea { 95 | display: none; 96 | } 97 | 98 | #execArea { 99 | display: none; 100 | } 101 | 102 | form[name=postData-params] { 103 | display: none; 104 | } 105 | 106 | .btn-default { 107 | color: #333; 108 | background-color: #fff; 109 | border-color: #ccc; 110 | } 111 | 112 | .btn-default.focus, .btn-default:focus { 113 | color: #333; 114 | background-color: #e6e6e6; 115 | border-color: #8c8c8c 116 | } 117 | 118 | .btn-default:hover { 119 | color: #333; 120 | background-color: #e6e6e6; 121 | border-color: #adadad 122 | } 123 | 124 | .btn-default.active, .btn-default:active { 125 | color: #333; 126 | background-color: #e6e6e6; 127 | border-color: #adadad 128 | } 129 | 130 | .btn-default.active.focus, .btn-default.active:focus, .btn-default.active:hover, .btn-default:active.focus, .btn-default:active:focus, .btn-default:active:hover { 131 | color: #333; 132 | background-color: #d4d4d4; 133 | border-color: #8c8c8c 134 | } 135 | 136 | .btn-default.active, .btn-default:active, .open > .dropdown-toggle.btn-default { 137 | background-image: none 138 | } 139 | 140 | .btn-default.disabled, .btn-default.disabled.active, .btn-default.disabled.focus, .btn-default.disabled:active, .btn-default.disabled:focus, .btn-default.disabled:hover, .btn-default[disabled], .btn-default[disabled].active, .btn-default[disabled].focus, .btn-default[disabled]:active, .btn-default[disabled]:focus, .btn-default[disabled]:hover, fieldset[disabled] .btn-default, fieldset[disabled] .btn-default.active, fieldset[disabled] .btn-default.focus, fieldset[disabled] .btn-default:active, fieldset[disabled] .btn-default:focus, fieldset[disabled] .btn-default:hover { 141 | background-color: #fff; 142 | border-color: #ccc 143 | } 144 | 145 | .btn-default .badge { 146 | color: #fff; 147 | background-color: #333 148 | } 149 | 150 | .col-md-12 { 151 | padding-left: 0px; 152 | } 153 | 154 | .control-label { 155 | font-size: 14px; 156 | } 157 | 158 | .navbar-default { 159 | background-color: #F4F4F4; 160 | border-color: #eeeeee; 161 | border-radius: 0px; 162 | } 163 | 164 | .form-control[disabled], .form-control[readonly], fieldset[disabled] .form-control { 165 | background-color: #F9F9F9; 166 | opacity: 1; 167 | } 168 | 169 | .form-control{ 170 | font-size:14px; 171 | } 172 | .btn{ 173 | font-size:14px; 174 | } 175 | 176 | #main-content .dropdown-menu{ 177 | font-size:12px; 178 | min-width:50px; 179 | } 180 | 181 | .logo{ 182 | padding-top:10px; 183 | } 184 | .logo .logo-a{ 185 | line-height: 40px; 186 | height: 40px; 187 | color: #272636; 188 | } 189 | .logo .logo-a img{ 190 | height: 40px; 191 | vertical-align: top; 192 | } -------------------------------------------------------------------------------- /public/css/profile.css: -------------------------------------------------------------------------------- 1 | #main-content{ 2 | min-height:500px; 3 | min-width:1200px; 4 | } 5 | #left-content{ 6 | padding-left:0px; 7 | } 8 | #left-row{ 9 | border-right:1px #dddddd dotted; 10 | width:18%; 11 | } 12 | #right-row{ 13 | width:82%; 14 | } 15 | #my-collections{ 16 | margin: 10px 0 0 0; 17 | padding: 0; 18 | list-style: none; 19 | } 20 | #my-collections li { 21 | position: relative; 22 | padding-bottom: 0px; 23 | /*font-size:16px;*/ 24 | margin-bottom:2px; 25 | } 26 | 27 | #my-collections li .collection-name{ 28 | width: 180px; 29 | display: inline-block; 30 | background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAFVBMVEX///9wcHBwcHBwcHBwcHBwcHBwcHA3RenHAAAABnRSTlMAZoiZzN091q78AAAAH0lEQVQIW2NgIA44wxhqAlAGcyJMKAxdBK7GCUoTDwCd9gIQsibF/QAAAABJRU5ErkJggg==); 31 | background-repeat: no-repeat; 32 | background-position-y: 4px; 33 | background-position-x: -2px; 34 | } 35 | 36 | #my-collections li .collection-ops{ 37 | display: none; 38 | /*width: 90px;*/ 39 | /*margin-right: 0px;*/ 40 | height:17px; 41 | right: 3px; 42 | top: 2px; 43 | position: absolute; 44 | } 45 | 46 | #my-collections li .collection-ops button span{ 47 | top:0px; 48 | 49 | } 50 | 51 | #my-collections .collection-hars{ 52 | list-style:none; 53 | padding-left:0px; 54 | margin: 8px 0; 55 | } 56 | #my-collections .collection-hars a{ 57 | font-size:13px; 58 | font-family: "News Cycle","Arial Narrow Bold",sans-serif; 59 | font-weight: 600; 60 | line-height: 20px; 61 | color: #000000; 62 | padding-left:0; 63 | } 64 | #my-collections .collection-hars span.badge{ 65 | font-size:12px; 66 | vertical-align: 0px; 67 | background-color: #8C8A8A; 68 | } 69 | 70 | #my-collections a.my-collection-a { 71 | font-family: "News Cycle","Arial Narrow Bold",sans-serif; 72 | font-weight: 700; 73 | font-size:14px; 74 | line-height: 20px; 75 | color: #000000; 76 | padding-left:0; 77 | display: block; 78 | margin-left:14px; 79 | } 80 | #my-collections li label{ 81 | position: relative; 82 | margin-bottom:5px; 83 | padding-top:2px; 84 | } 85 | 86 | #harform{ 87 | margin-left:15px; 88 | } 89 | 90 | #harform .glyphicon{ 91 | top:3px; 92 | } 93 | #harform .form-control{ 94 | height:30px; 95 | } 96 | 97 | #harform a{ 98 | line-height: 30px; 99 | height: 30px; 100 | padding:0px; 101 | } 102 | 103 | #harform .no-border-input{ 104 | border-top: 1px #FFF solid; 105 | border-left: 1px #FFF solid; 106 | border-right: 2px #FFF solid; 107 | margin-right:3px; 108 | } 109 | 110 | #harform .form-group.pair{ 111 | width:100%; 112 | } 113 | 114 | #harform div[name=postData-text] p{ 115 | width: 100%; 116 | font-size: 12px; 117 | margin-top: 6px; 118 | } 119 | 120 | #header-form, #cookie-form{ 121 | display:none; 122 | } 123 | 124 | .row{ 125 | margin-left:0px; 126 | } 127 | pre code{ 128 | font-size:12px; 129 | } 130 | 131 | #top-ops{ 132 | margin-bottom: 20px; 133 | } 134 | 135 | #bottom-ops{ 136 | margin-top: 40px; 137 | } 138 | 139 | .op-a{ 140 | font-size:14px; 141 | } 142 | 143 | .input-group-btn .btn-danger{ 144 | color: #151414; 145 | background-color: #FFFFFF; 146 | border-color: #FFFFFF; 147 | } 148 | 149 | .input-group-btn .btn-success{ 150 | color: #151414; 151 | background-color: #FFFFFF; 152 | border-color: #FFFFFF; 153 | } 154 | 155 | .input-group-btn .btn-success:active,.input-group-btn .btn-success.active { 156 | color: #111111; 157 | background-color: #FFFFFF; 158 | border-color: #ffffff 159 | } 160 | 161 | .input-group-btn .btn-success:active:hover,.input-group-btn .btn-success.active:hover { 162 | color: #111111; 163 | background-color: #FFFFFF; 164 | border-color: #ffffff 165 | } 166 | 167 | .input-group-btn .btn-success:active,.input-group-btn .btn-success.active { 168 | background-image: none 169 | } 170 | 171 | .input-group-btn .btn-danger:active,.input-group-btn .btn-danger.active { 172 | color: #111111; 173 | background-color: #FFFFFF; 174 | border-color: #ffffff 175 | } 176 | 177 | .input-group-btn .btn-danger:active:hover,.input-group-btn .btn-danger.active:hover { 178 | color: #111111; 179 | background-color: #FFFFFF; 180 | border-color: #ffffff 181 | } 182 | 183 | .input-group-btn .btn-danger:active,.input-group-btn .btn-danger.active { 184 | background-image: none 185 | } -------------------------------------------------------------------------------- /public/css/status.css: -------------------------------------------------------------------------------- 1 | #main-content{ 2 | min-height:500px; 3 | min-width:1200px; 4 | } 5 | #left-content{ 6 | padding-left:0px; 7 | } 8 | #left-row{ 9 | border-right:1px #dddddd dotted; 10 | width:18%; 11 | } 12 | #right-row{ 13 | width:82%; 14 | } 15 | #status-apis{ 16 | margin: 10px 0 0 0; 17 | padding: 0; 18 | list-style: none; 19 | } 20 | #status-apis li { 21 | position: relative; 22 | padding-bottom: 0px; 23 | font-size:16px; 24 | margin-bottom:2px; 25 | } 26 | 27 | #status-apis li .status-api-name{ 28 | width: 140px; 29 | display: inline-block; 30 | background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAFVBMVEX///9wcHBwcHBwcHBwcHBwcHBwcHA3RenHAAAABnRSTlMAZoiZzN091q78AAAAH0lEQVQIW2NgIA44wxhqAlAGcyJMKAxdBK7GCUoTDwCd9gIQsibF/QAAAABJRU5ErkJggg==); 31 | background-repeat: no-repeat; 32 | background-position-y: 4px; 33 | background-position-x: -2px; 34 | } 35 | 36 | #status-apis li .status-api-ops{ 37 | display: none; 38 | height:17px; 39 | position: absolute; 40 | top:3px; 41 | right:3px; 42 | } 43 | 44 | #status-apis li .status-api-ops button span{ 45 | top:0px; 46 | } 47 | 48 | #status-apis a.status-api-a { 49 | font-family: "News Cycle","Arial Narrow Bold",sans-serif; 50 | font-weight: 700; 51 | line-height: 20px; 52 | color: #000000; 53 | padding-left:0; 54 | display: block; 55 | margin-left:14px; 56 | } 57 | #status-apis li label{ 58 | position: relative; 59 | margin-bottom:5px; 60 | padding-top:2px; 61 | } 62 | 63 | 64 | #right-row a { 65 | line-height: 30px; 66 | height: 30px; 67 | padding: 0 8px; 68 | } 69 | 70 | 71 | .row{ 72 | margin-left:0px; 73 | } 74 | pre code{ 75 | font-size:12px; 76 | } 77 | 78 | #top-ops{ 79 | margin-bottom: 20px; 80 | } 81 | 82 | #bottom-ops{ 83 | margin-top: 40px; 84 | } 85 | 86 | .op-a{ 87 | font-size:14px; 88 | } 89 | 90 | .input-group-btn .btn-danger{ 91 | color: #151414; 92 | background-color: #FFFFFF; 93 | border-color: #FFFFFF; 94 | } 95 | 96 | .input-group-btn .btn-success{ 97 | color: #151414; 98 | background-color: #FFFFFF; 99 | border-color: #FFFFFF; 100 | } 101 | 102 | .input-group-btn .btn-success:active,.input-group-btn .btn-success.active { 103 | color: #111111; 104 | background-color: #FFFFFF; 105 | border-color: #ffffff 106 | } 107 | 108 | .input-group-btn .btn-success:active:hover,.input-group-btn .btn-success.active:hover { 109 | color: #111111; 110 | background-color: #FFFFFF; 111 | border-color: #ffffff 112 | } 113 | 114 | .input-group-btn .btn-success:active,.input-group-btn .btn-success.active { 115 | background-image: none 116 | } 117 | 118 | .input-group-btn .btn-danger:active,.input-group-btn .btn-danger.active { 119 | color: #111111; 120 | background-color: #FFFFFF; 121 | border-color: #ffffff 122 | } 123 | 124 | .input-group-btn .btn-danger:active:hover,.input-group-btn .btn-danger.active:hover { 125 | color: #111111; 126 | background-color: #FFFFFF; 127 | border-color: #ffffff 128 | } 129 | 130 | .input-group-btn .btn-danger:active,.input-group-btn .btn-danger.active { 131 | background-image: none 132 | } 133 | 134 | .form-group input, .form-group select{ 135 | height:30px; 136 | line-height:30px; 137 | } -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /public/img/moklr.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/public/img/moklr.png -------------------------------------------------------------------------------- /public/js/FileSaver.min.js: -------------------------------------------------------------------------------- 1 | /*! @source http://purl.eligrey.com/github/FileSaver.js/blob/master/FileSaver.js */ 2 | var saveAs=saveAs||function(e){"use strict";if("undefined"==typeof navigator||!/MSIE [1-9]\./.test(navigator.userAgent)){var t=e.document,n=function(){return e.URL||e.webkitURL||e},o=t.createElementNS("http://www.w3.org/1999/xhtml","a"),r="download"in o,i=function(e){var t=new MouseEvent("click");e.dispatchEvent(t)},a=e.webkitRequestFileSystem,c=e.requestFileSystem||a||e.mozRequestFileSystem,u=function(t){(e.setImmediate||e.setTimeout)(function(){throw t},0)},f="application/octet-stream",s=0,d=500,l=function(t){var o=function(){"string"==typeof t?n().revokeObjectURL(t):t.remove()};e.chrome?o():setTimeout(o,d)},v=function(e,t,n){t=[].concat(t);for(var o=t.length;o--;){var r=e["on"+t[o]];if("function"==typeof r)try{r.call(e,n||e)}catch(i){u(i)}}},p=function(e){return/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["",e],{type:e.type}):e},w=function(t,u,d){d||(t=p(t));var w,y,m,S=this,h=t.type,O=!1,R=function(){v(S,"writestart progress write writeend".split(" "))},b=function(){if((O||!w)&&(w=n().createObjectURL(t)),y)y.location.href=w;else{var o=e.open(w,"_blank");void 0==o&&"undefined"!=typeof safari&&(e.location.href=w)}S.readyState=S.DONE,R(),l(w)},g=function(e){return function(){return S.readyState!==S.DONE?e.apply(this,arguments):void 0}},E={create:!0,exclusive:!1};return S.readyState=S.INIT,u||(u="download"),r?(w=n().createObjectURL(t),o.href=w,o.download=u,void setTimeout(function(){i(o),R(),l(w),S.readyState=S.DONE})):(e.chrome&&h&&h!==f&&(m=t.slice||t.webkitSlice,t=m.call(t,0,t.size,f),O=!0),a&&"download"!==u&&(u+=".download"),(h===f||a)&&(y=e),c?(s+=t.size,void c(e.TEMPORARY,s,g(function(e){e.root.getDirectory("saved",E,g(function(e){var n=function(){e.getFile(u,E,g(function(e){e.createWriter(g(function(n){n.onwriteend=function(t){y.location.href=e.toURL(),S.readyState=S.DONE,v(S,"writeend",t),l(e)},n.onerror=function(){var e=n.error;e.code!==e.ABORT_ERR&&b()},"writestart progress write abort".split(" ").forEach(function(e){n["on"+e]=S["on"+e]}),n.write(t),S.abort=function(){n.abort(),S.readyState=S.DONE},S.readyState=S.WRITING}),b)}),b)};e.getFile(u,{create:!1},g(function(e){e.remove(),n()}),g(function(e){e.code===e.NOT_FOUND_ERR?n():b()}))}),b)}),b)):void b())},y=w.prototype,m=function(e,t,n){return new w(e,t,n)};return"undefined"!=typeof navigator&&navigator.msSaveOrOpenBlob?function(e,t,n){return n||(e=p(e)),navigator.msSaveOrOpenBlob(e,t||"download")}:(y.abort=function(){var e=this;e.readyState=e.DONE,v(e,"abort")},y.readyState=y.INIT=0,y.WRITING=1,y.DONE=2,y.error=y.onwritestart=y.onprogress=y.onwrite=y.onabort=y.onerror=y.onwriteend=null,m)}}("undefined"!=typeof self&&self||"undefined"!=typeof window&&window||this.content);"undefined"!=typeof module&&module.exports?module.exports.saveAs=saveAs:"undefined"!=typeof define&&null!==define&&null!=define.amd&&define([],function(){return saveAs}); -------------------------------------------------------------------------------- /public/js/common.js: -------------------------------------------------------------------------------- 1 | var Moklr = {}; -------------------------------------------------------------------------------- /public/js/dialog-min.js: -------------------------------------------------------------------------------- 1 | /*! artDialog v6.0.5 | https://github.com/aui/artDialog */ 2 | !function(){function a(b){var d=c[b],e="exports";return"object"==typeof d?d:(d[e]||(d[e]={},d[e]=d.call(d[e],a,d[e],d)||d[e]),d[e])}function b(a,b){c[a]=b}var c={};b("jquery",function(){return jQuery}),b("popup",function(a){function b(){this.destroyed=!1,this.__popup=c("
").css({display:"none",position:"absolute",outline:0}).attr("tabindex","-1").html(this.innerHTML).appendTo("body"),this.__backdrop=this.__mask=c("
").css({opacity:.7,background:"#000"}),this.node=this.__popup[0],this.backdrop=this.__backdrop[0],d++}var c=a("jquery"),d=0,e=!("minWidth"in c("html")[0].style),f=!e;return c.extend(b.prototype,{node:null,backdrop:null,fixed:!1,destroyed:!0,open:!1,returnValue:"",autofocus:!0,align:"bottom left",innerHTML:"",className:"ui-popup",show:function(a){if(this.destroyed)return this;var d=this.__popup,g=this.__backdrop;if(this.__activeElement=this.__getActive(),this.open=!0,this.follow=a||this.follow,!this.__ready){if(d.addClass(this.className).attr("role",this.modal?"alertdialog":"dialog").css("position",this.fixed?"fixed":"absolute"),e||c(window).on("resize",c.proxy(this.reset,this)),this.modal){var h={position:"fixed",left:0,top:0,width:"100%",height:"100%",overflow:"hidden",userSelect:"none",zIndex:this.zIndex||b.zIndex};d.addClass(this.className+"-modal"),f||c.extend(h,{position:"absolute",width:c(window).width()+"px",height:c(document).height()+"px"}),g.css(h).attr({tabindex:"0"}).on("focus",c.proxy(this.focus,this)),this.__mask=g.clone(!0).attr("style","").insertAfter(d),g.addClass(this.className+"-backdrop").insertBefore(d),this.__ready=!0}d.html()||d.html(this.innerHTML)}return d.addClass(this.className+"-show").show(),g.show(),this.reset().focus(),this.__dispatchEvent("show"),this},showModal:function(){return this.modal=!0,this.show.apply(this,arguments)},close:function(a){return!this.destroyed&&this.open&&(void 0!==a&&(this.returnValue=a),this.__popup.hide().removeClass(this.className+"-show"),this.__backdrop.hide(),this.open=!1,this.blur(),this.__dispatchEvent("close")),this},remove:function(){if(this.destroyed)return this;this.__dispatchEvent("beforeremove"),b.current===this&&(b.current=null),this.__popup.remove(),this.__backdrop.remove(),this.__mask.remove(),e||c(window).off("resize",this.reset),this.__dispatchEvent("remove");for(var a in this)delete this[a];return this},reset:function(){var a=this.follow;return a?this.__follow(a):this.__center(),this.__dispatchEvent("reset"),this},focus:function(){var a=this.node,d=this.__popup,e=b.current,f=this.zIndex=b.zIndex++;if(e&&e!==this&&e.blur(!1),!c.contains(a,this.__getActive())){var g=d.find("[autofocus]")[0];!this._autofocus&&g?this._autofocus=!0:g=a,this.__focus(g)}return d.css("zIndex",f),b.current=this,d.addClass(this.className+"-focus"),this.__dispatchEvent("focus"),this},blur:function(){var a=this.__activeElement,b=arguments[0];return b!==!1&&this.__focus(a),this._autofocus=!1,this.__popup.removeClass(this.className+"-focus"),this.__dispatchEvent("blur"),this},addEventListener:function(a,b){return this.__getEventListener(a).push(b),this},removeEventListener:function(a,b){for(var c=this.__getEventListener(a),d=0;dH[E[b]][1]&&(b=B[a]=D[b]),F[a][b]Loading..',title:"",statusbar:"",button:null,ok:null,cancel:null,okValue:"ok",cancelValue:"cancel",cancelDisplay:!0,width:"",height:"",padding:"",skin:"",quickClose:!1,cssUri:"../css/ui-dialog.css",innerHTML:'
'}),b("dialog",function(a){var b=a("jquery"),c=a("popup"),d=a("dialog-config"),e=d.cssUri;if(e){var f=a[a.toUrl?"toUrl":"resolve"];f&&(e=f(e),e='',b("base")[0]?b("base").before(e):b("head").append(e))}var g=0,h=new Date-0,i=!("minWidth"in b("html")[0].style),j="createTouch"in document&&!("onmousemove"in document)||/(iPhone|iPad|iPod)/i.test(navigator.userAgent),k=!i&&!j,l=function(a,c,d){var e=a=a||{};("string"==typeof a||1===a.nodeType)&&(a={content:a,fixed:!j}),a=b.extend(!0,{},l.defaults,a),a.original=e;var f=a.id=a.id||h+g,i=l.get(f);return i?i.focus():(k||(a.fixed=!1),a.quickClose&&(a.modal=!0,a.backdropOpacity=0),b.isArray(a.button)||(a.button=[]),void 0!==d&&(a.cancel=d),a.cancel&&a.button.push({id:"cancel",value:a.cancelValue,callback:a.cancel,display:a.cancelDisplay}),void 0!==c&&(a.ok=c),a.ok&&a.button.push({id:"ok",value:a.okValue,callback:a.ok,autofocus:!0}),l.list[f]=new l.create(a))},m=function(){};m.prototype=c.prototype;var n=l.prototype=new m;return l.create=function(a){var d=this;b.extend(this,new c);var e=(a.original,b(this.node).html(a.innerHTML)),f=b(this.backdrop);return this.options=a,this._popup=e,b.each(a,function(a,b){"function"==typeof d[a]?d[a](b):d[a]=b}),a.zIndex&&(c.zIndex=a.zIndex),e.attr({"aria-labelledby":this._$("title").attr("id","title:"+this.id).attr("id"),"aria-describedby":this._$("content").attr("id","content:"+this.id).attr("id")}),this._$("close").css("display",this.cancel===!1?"none":"").attr("title",this.cancelValue).on("click",function(a){d._trigger("cancel"),a.preventDefault()}),this._$("dialog").addClass(this.skin),this._$("body").css("padding",this.padding),a.quickClose&&f.on("onmousedown"in document?"mousedown":"click",function(){return d._trigger("cancel"),!1}),this.addEventListener("show",function(){f.css({opacity:0,background:a.backdropBackground}).animate({opacity:a.backdropOpacity},150)}),this._esc=function(a){var b=a.target,e=b.nodeName,f=/^input|textarea$/i,g=c.current===d,h=a.keyCode;!g||f.test(e)&&"button"!==b.type||27===h&&d._trigger("cancel")},b(document).on("keydown",this._esc),this.addEventListener("remove",function(){b(document).off("keydown",this._esc),delete l.list[this.id]}),g++,l.oncreate(this),this},l.create.prototype=n,b.extend(n,{content:function(a){var c=this._$("content");return"object"==typeof a?(a=b(a),c.empty("").append(a.show()),this.addEventListener("beforeremove",function(){b("body").append(a.hide())})):c.html(a),this.reset()},title:function(a){return this._$("title").text(a),this._$("header")[a?"show":"hide"](),this},width:function(a){return this._$("content").css("width",a),this.reset()},height:function(a){return this._$("content").css("height",a),this.reset()},button:function(a){a=a||[];var c=this,d="",e=0;return this.callbacks={},"string"==typeof a?(d=a,e++):b.each(a,function(a,f){var g=f.id=f.id||f.value,h="";c.callbacks[g]=f.callback,f.display===!1?h=' style="display:none"':e++,d+='",c._$("button").on("click","[i-id="+g+"]",function(a){var d=b(this);d.attr("disabled")||c._trigger(g),a.preventDefault()})}),this._$("button").html(d),this._$("footer")[e?"show":"hide"](),this},statusbar:function(a){return this._$("statusbar").html(a)[a?"show":"hide"](),this},_$:function(a){return this._popup.find("[i="+a+"]")},_trigger:function(a){var b=this.callbacks[a];return"function"!=typeof b||b.call(this)!==!1?this.close().remove():this}}),l.oncreate=b.noop,l.getCurrent=function(){return c.current},l.get=function(a){return void 0===a?l.list:l.list[a]},l.list={},l.defaults=d,l}),window.dialog=a("dialog")}(); -------------------------------------------------------------------------------- /public/js/icheck.min.js: -------------------------------------------------------------------------------- 1 | /*! iCheck v1.0.2 by Damir Sultanov, http://git.io/arlzeA, MIT Licensed */ 2 | (function(f){function A(a,b,d){var c=a[0],g=/er/.test(d)?_indeterminate:/bl/.test(d)?n:k,e=d==_update?{checked:c[k],disabled:c[n],indeterminate:"true"==a.attr(_indeterminate)||"false"==a.attr(_determinate)}:c[g];if(/^(ch|di|in)/.test(d)&&!e)x(a,g);else if(/^(un|en|de)/.test(d)&&e)q(a,g);else if(d==_update)for(var f in e)e[f]?x(a,f,!0):q(a,f,!0);else if(!b||"toggle"==d){if(!b)a[_callback]("ifClicked");e?c[_type]!==r&&q(a,g):x(a,g)}}function x(a,b,d){var c=a[0],g=a.parent(),e=b==k,u=b==_indeterminate, 3 | v=b==n,s=u?_determinate:e?y:"enabled",F=l(a,s+t(c[_type])),B=l(a,b+t(c[_type]));if(!0!==c[b]){if(!d&&b==k&&c[_type]==r&&c.name){var w=a.closest("form"),p='input[name="'+c.name+'"]',p=w.length?w.find(p):f(p);p.each(function(){this!==c&&f(this).data(m)&&q(f(this),b)})}u?(c[b]=!0,c[k]&&q(a,k,"force")):(d||(c[b]=!0),e&&c[_indeterminate]&&q(a,_indeterminate,!1));D(a,e,b,d)}c[n]&&l(a,_cursor,!0)&&g.find("."+C).css(_cursor,"default");g[_add](B||l(a,b)||"");g.attr("role")&&!u&&g.attr("aria-"+(v?n:k),"true"); 4 | g[_remove](F||l(a,s)||"")}function q(a,b,d){var c=a[0],g=a.parent(),e=b==k,f=b==_indeterminate,m=b==n,s=f?_determinate:e?y:"enabled",q=l(a,s+t(c[_type])),r=l(a,b+t(c[_type]));if(!1!==c[b]){if(f||!d||"force"==d)c[b]=!1;D(a,e,s,d)}!c[n]&&l(a,_cursor,!0)&&g.find("."+C).css(_cursor,"pointer");g[_remove](r||l(a,b)||"");g.attr("role")&&!f&&g.attr("aria-"+(m?n:k),"false");g[_add](q||l(a,s)||"")}function E(a,b){if(a.data(m)){a.parent().html(a.attr("style",a.data(m).s||""));if(b)a[_callback](b);a.off(".i").unwrap(); 5 | f(_label+'[for="'+a[0].id+'"]').add(a.closest(_label)).off(".i")}}function l(a,b,f){if(a.data(m))return a.data(m).o[b+(f?"":"Class")]}function t(a){return a.charAt(0).toUpperCase()+a.slice(1)}function D(a,b,f,c){if(!c){if(b)a[_callback]("ifToggled");a[_callback]("ifChanged")[_callback]("if"+t(f))}}var m="iCheck",C=m+"-helper",r="radio",k="checked",y="un"+k,n="disabled";_determinate="determinate";_indeterminate="in"+_determinate;_update="update";_type="type";_click="click";_touch="touchbegin.i touchend.i"; 6 | _add="addClass";_remove="removeClass";_callback="trigger";_label="label";_cursor="cursor";_mobile=/ipad|iphone|ipod|android|blackberry|windows phone|opera mini|silk/i.test(navigator.userAgent);f.fn[m]=function(a,b){var d='input[type="checkbox"], input[type="'+r+'"]',c=f(),g=function(a){a.each(function(){var a=f(this);c=a.is(d)?c.add(a):c.add(a.find(d))})};if(/^(check|uncheck|toggle|indeterminate|determinate|disable|enable|update|destroy)$/i.test(a))return a=a.toLowerCase(),g(this),c.each(function(){var c= 7 | f(this);"destroy"==a?E(c,"ifDestroyed"):A(c,!0,a);f.isFunction(b)&&b()});if("object"!=typeof a&&a)return this;var e=f.extend({checkedClass:k,disabledClass:n,indeterminateClass:_indeterminate,labelHover:!0},a),l=e.handle,v=e.hoverClass||"hover",s=e.focusClass||"focus",t=e.activeClass||"active",B=!!e.labelHover,w=e.labelHoverClass||"hover",p=(""+e.increaseArea).replace("%","")|0;if("checkbox"==l||l==r)d='input[type="'+l+'"]';-50>p&&(p=-50);g(this);return c.each(function(){var a=f(this);E(a);var c=this, 8 | b=c.id,g=-p+"%",d=100+2*p+"%",d={position:"absolute",top:g,left:g,display:"block",width:d,height:d,margin:0,padding:0,background:"#fff",border:0,opacity:0},g=_mobile?{position:"absolute",visibility:"hidden"}:p?d:{position:"absolute",opacity:0},l="checkbox"==c[_type]?e.checkboxClass||"icheckbox":e.radioClass||"i"+r,z=f(_label+'[for="'+b+'"]').add(a.closest(_label)),u=!!e.aria,y=m+"-"+Math.random().toString(36).substr(2,6),h='
")[_callback]("ifCreated").parent().append(e.insert);d=f('').css(d).appendTo(h);a.data(m,{o:e,s:a.attr("style")}).css(g);e.inheritClass&&h[_add](c.className||"");e.inheritID&&b&&h.attr("id",m+"-"+b);"static"==h.css("position")&&h.css("position","relative");A(a,!0,_update);if(z.length)z.on(_click+".i mouseover.i mouseout.i "+_touch,function(b){var d=b[_type],e=f(this);if(!c[n]){if(d==_click){if(f(b.target).is("a"))return; 10 | A(a,!1,!0)}else B&&(/ut|nd/.test(d)?(h[_remove](v),e[_remove](w)):(h[_add](v),e[_add](w)));if(_mobile)b.stopPropagation();else return!1}});a.on(_click+".i focus.i blur.i keyup.i keydown.i keypress.i",function(b){var d=b[_type];b=b.keyCode;if(d==_click)return!1;if("keydown"==d&&32==b)return c[_type]==r&&c[k]||(c[k]?q(a,k):x(a,k)),!1;if("keyup"==d&&c[_type]==r)!c[k]&&x(a,k);else if(/us|ur/.test(d))h["blur"==d?_remove:_add](s)});d.on(_click+" mousedown mouseup mouseover mouseout "+_touch,function(b){var d= 11 | b[_type],e=/wn|up/.test(d)?t:v;if(!c[n]){if(d==_click)A(a,!1,!0);else{if(/wn|er|in/.test(d))h[_add](e);else h[_remove](e+" "+t);if(z.length&&B&&e==v)z[/ut|nd/.test(d)?_remove:_add](w)}if(_mobile)b.stopPropagation();else return!1}})})}})(window.jQuery||window.Zepto); 12 | -------------------------------------------------------------------------------- /roadmap.md: -------------------------------------------------------------------------------- 1 | 0.5.0版本的moklr已经基本实现了类似于postman这样的HTTP测试工具的基本功能。 2 | 3 | 接下来moklr会陆续发布几个小功能版本,roadmap如下: 4 | 5 | #### v0.6.0 6 | 7 | - 与postman数据的互相导入导出,方便工具间数据的迁移 8 | - 代码的调整和优化 9 | - 去除生成代码时的redis依赖 10 | 11 | 12 | #### v0.7.0 13 | 14 | - 支持restful常用的请求方式 15 | - 批量http请求测试 16 | 17 | 18 | #### v0.8.0 19 | 20 | - status服务设计和实现 21 | - web hook(集成jenkins和其他命令触发hook) -------------------------------------------------------------------------------- /route.js: -------------------------------------------------------------------------------- 1 | var config = require("./config"); 2 | var mockRouter = require('./routes/mock.js'); 3 | var postmanRouter = require('./routes/postman.js'); 4 | var runRouter = require('./routes/run.js'); 5 | var auth = require('./routes/auth.js'); 6 | var statusRouter = require('./routes/status.js'); 7 | 8 | module.exports = function (app) { 9 | app.use('/auth', auth); 10 | app.use('/mock', mockRouter); 11 | app.use('/user', postmanRouter); 12 | app.use('/status', statusRouter); 13 | app.use('/run', runRouter); 14 | 15 | app.get('/help', function(req, res){ 16 | res.render('help'); 17 | }); 18 | 19 | app.get("/", function (req, res, next) { 20 | res.render('index'); 21 | }); 22 | }; -------------------------------------------------------------------------------- /routes/auth.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | var moklrModel = require('../models/moklrModel.js'); 4 | var logger = require('../lib/log.js').logger('authRouter'); 5 | 6 | router.get('/login', function (req, res, next) { 7 | res.render('login'); 8 | }); 9 | 10 | router.get('/logout', function (req, res, next) { 11 | req.session.destroy(); 12 | res.render('login'); 13 | }); 14 | 15 | router.post('/login', function (req, res, next) { 16 | try { 17 | var password = req.body.password.trim(); 18 | var username = req.body.username.trim(); 19 | 20 | if (!username) { 21 | res.render('error', { 22 | msg: "用户名不能为空" 23 | }); 24 | return; 25 | } 26 | if (!password) { 27 | res.render('error', { 28 | msg: "密码不能为空" 29 | }); 30 | return; 31 | } 32 | 33 | moklrModel.findUser(username, password, function (err, user) { 34 | if (err || !user) { 35 | logger.error(err); 36 | return res.render('error', { 37 | msg: "查找用户出错或用户不存在" 38 | }); 39 | } 40 | 41 | req.session.user = user; 42 | res.redirect("/user/profile"); 43 | }); 44 | } catch (e) { 45 | logger.error(e); 46 | res.render('error', { 47 | msg: "登录发生异常" 48 | }); 49 | } 50 | }); 51 | 52 | module.exports = router; -------------------------------------------------------------------------------- /routes/mock.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | var HTTPSnippet = require('httpsnippet'); 4 | var util = require("util"); 5 | var logger = require('../lib/log.js').logger('mock'); 6 | 7 | var availableTargets = HTTPSnippet.availableTargets().reduce(function (targets, target) { 8 | if (target.clients) { 9 | targets[target.key] = target.clients.reduce(function (clients, client) { 10 | clients[client.key] = false; 11 | return clients 12 | }, {}) 13 | } else { 14 | targets[target.key] = false; 15 | } 16 | 17 | return targets 18 | }, {}); 19 | 20 | router.get('/create', function (req, res, next) { 21 | res.render('create'); 22 | }); 23 | 24 | 25 | router.get('/gen', function (req, res, next) { 26 | var har = req.query.har; 27 | var targets = req.query.targets || 'all'; 28 | console.log(har) 29 | 30 | var requestedTargets = targets.split(',').reduce(function (requested, part) { 31 | var i = part.split(':'); 32 | 33 | var target = i[0] || 'all'; 34 | var client = i[1] || 'all'; 35 | 36 | // all targets 37 | if (target === 'all') { 38 | // set all members to true 39 | return Object.keys(availableTargets).reduce(function (requested, target) { 40 | if (typeof availableTargets[target] === 'object') { 41 | requested[target] = Object.keys(availableTargets[target]).reduce(function (clients, client) { 42 | clients[client] = true 43 | return clients 44 | }, {}) 45 | } else { 46 | requested[target] = true 47 | } 48 | 49 | return requested 50 | }, {}) 51 | } 52 | 53 | // all clients? 54 | if (availableTargets.hasOwnProperty(target)) { 55 | if (typeof availableTargets[target] === 'object') { 56 | if (client === 'all') { 57 | requested[target] = Object.keys(availableTargets[target]).reduce(function (clients, client) { 58 | clients[client] = true; 59 | return clients; 60 | }, {}); 61 | } else { 62 | if (availableTargets[target].hasOwnProperty(client)) { 63 | requested[target] = requested[target] ? requested[target] : {}; 64 | requested[target][client] = true; 65 | } 66 | } 67 | } else { 68 | requested[target] = true; 69 | } 70 | 71 | return requested; 72 | 73 | } 74 | 75 | return requested; 76 | }, {}); 77 | 78 | var response = har; 79 | var snippet; 80 | var output = {}; 81 | 82 | if (typeof response !== 'object') { 83 | try { 84 | response = JSON.parse(response); 85 | } catch (err) { 86 | return next(new Error('JSON.parse error')); 87 | } 88 | } 89 | //response = { method: 'GET', 90 | // url: 'http://sumory.com', 91 | // httpVersion: 'HTTP/1.1', 92 | // queryString: [], 93 | // headers: [ { name: 'Content-Type', value: 'application/json' } ], 94 | // cookies: [] }; 95 | //response = util._extend({}, tmp);//不转换会出傻逼错 96 | 97 | console.dir(response); 98 | try { 99 | snippet = new HTTPSnippet(response) 100 | } catch (err) { 101 | return next(new Error('HTTPSnippet constructor error')); 102 | } 103 | 104 | Object.keys(requestedTargets).map(function (target) { 105 | if (typeof requestedTargets[target] === 'object') { 106 | output[target] = {}; 107 | return Object.keys(requestedTargets[target]).map(function (client) { 108 | try { 109 | output[target][client] = snippet.convert(target, client); 110 | } catch (e) { 111 | console.error(target, client, e); 112 | } 113 | }); 114 | } 115 | 116 | output[target] = snippet.convert(target); 117 | }); 118 | 119 | if (Object.keys(output).length === 0) { 120 | return next(new Error('Invalid Targets')); 121 | } 122 | 123 | // console.log(output); 124 | return res.json({ 125 | output: output 126 | }); 127 | }); 128 | 129 | module.exports = router; -------------------------------------------------------------------------------- /routes/run.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | var redis = require("../lib/redisUtils.js"); 4 | var request = require("request"); 5 | var util = require("util"); 6 | 7 | module.exports = router; 8 | 9 | router.get('/exec', function (req, res, next) { 10 | var requestObj = req.query.r; 11 | console.dir(requestObj); 12 | if (!requestObj) { 13 | return res.json({ 14 | success: false, 15 | errorCode: 1, 16 | msg: "缺少请求描述参数:r" 17 | }); 18 | } 19 | 20 | if (requestObj) { 21 | run(requestObj, function (err, response, body) { 22 | if (err) { 23 | return res.json({ 24 | success: false, 25 | errorCode: 2, 26 | msg: err.toString() 27 | }); 28 | } else { 29 | return res.json({ 30 | success: true, 31 | errorCode: 0, 32 | msg: "ok", 33 | data: { 34 | responseStatus: response.statusCode || 'nil', 35 | body: body 36 | } 37 | }); 38 | } 39 | }); 40 | } 41 | }); 42 | 43 | 44 | router.get('/execById', function (req, res, next) { 45 | var rid = req.params.rid; 46 | if (!rid) { 47 | return res.json({ 48 | success: false, 49 | errorCode: 1, 50 | msg: "缺少参数:request id" 51 | }); 52 | } 53 | 54 | redis.get('bin:' + rid, function (err, value) { 55 | if (err) { 56 | return res.json('error', { 57 | success: false, 58 | errorCode: 1, 59 | msg: "无法找到构建的请求" 60 | }); 61 | } 62 | 63 | if (!util.isObject(value)) { 64 | return res.json('error', { 65 | success: false, 66 | errorCode: 1, 67 | msg: "构建的请求不是合法的格式" 68 | }); 69 | } 70 | 71 | 72 | run(value, function (err, response, body) { 73 | if (err) { 74 | return res.json({ 75 | success: false, 76 | errorCode: 2, 77 | msg: err.toString() 78 | }); 79 | } else { 80 | return res.json({ 81 | success: true, 82 | errorCode: 0, 83 | msg: "ok", 84 | data: { 85 | responseStatus: response.statusCode, 86 | body: body 87 | } 88 | }); 89 | } 90 | }); 91 | }) 92 | 93 | }); 94 | 95 | function run(r, callback) { 96 | if (r.method == "GET") { 97 | var options = r; 98 | request(options, function (error, response, body) { 99 | console.log("========"); 100 | console.dir(error); 101 | console.dir(response && (response.statusCode || "")); 102 | console.dir(body); 103 | console.log("++++++++"); 104 | 105 | callback && callback(error, response, body); 106 | 107 | }); 108 | 109 | } else if (r.method == "POST") { 110 | r.form = {}; 111 | var mimeType = r.postData.mimeType; 112 | if (mimeType === 'application/x-www-form-urlencoded' || mimeType === 'multipart/form-data') { 113 | var params = {}; 114 | var toParseParams = r.postData.params; 115 | if (toParseParams && toParseParams.length > 0) { 116 | for (var o = 0, p = toParseParams.length; o < p; o++) { 117 | var f = toParseParams[o]; 118 | params[f.name] = f.value; 119 | } 120 | } 121 | r.form = params || {}; 122 | } else if (mimeType === 'application/json') { 123 | try { 124 | var textjson = JSON.parse(r.postData.text || {}); 125 | r.form = textjson; 126 | } catch (e) { 127 | return callback && callback(new Error("postData[text] must be json format")); 128 | } 129 | 130 | } 131 | 132 | //console.dir(r); 133 | request(r, function (error, response, body) { 134 | console.log("========"); 135 | console.dir(error); 136 | console.dir(response && (response.statusCode || "")); 137 | console.dir(body); 138 | console.log("++++++++"); 139 | 140 | callback && callback(error, response, body); 141 | 142 | }); 143 | } 144 | else { 145 | callback && callback(new Error("request method is illegal")); 146 | } 147 | } 148 | 149 | 150 | //run({ 151 | // "method": "POST", 152 | // "url": "http://192.168.100.122:8001/user/save", 153 | // "httpVersion": "HTTP/1.1", 154 | // "queryString": [], 155 | // "headers": [ 156 | // { 157 | // "name": "Content-type", 158 | // "value": "application/json" 159 | // }, 160 | // { 161 | // "name": "Accept", 162 | // "value": "*/*" 163 | // } 164 | // ], 165 | // "cookies": [], 166 | // "postData": { 167 | // "mimeType": "application/json", 168 | // "text": "{\"name\":\"sumory222\",\"age\":12,\"sex\":\"男\"}" 169 | // } 170 | //}); 171 | 172 | //run({ 173 | // "method": "POST", 174 | // "url": "http://192.168.100.122:8001/user/save", 175 | // "httpVersion": "HTTP/1.1", 176 | // "queryString": [], 177 | // "headers": [ 178 | // { 179 | // "name": "Content-type", 180 | // "value": "application/x-www-form-urlencoded" 181 | // }, 182 | // { 183 | // "name": "Accept", 184 | // "value": "*/*" 185 | // } 186 | // ], 187 | // "cookies": [], 188 | // "postData": { 189 | // "mimeType": "application/x-www-form-urlencoded", 190 | // "params": [ 191 | // { 192 | // name:"name", 193 | // value:"sumory-json" 194 | // }, 195 | // { 196 | // name:"age", 197 | // value:18 198 | // }, 199 | // { 200 | // name:"sex", 201 | // value:true 202 | // } 203 | // ] 204 | // } 205 | //}); 206 | 207 | //run({ 208 | // "method": "GET", 209 | // "url": "http://192.168.100.122:8010/allrelation?uid=856318", 210 | // "httpVersion": "HTTP/1.1", 211 | // "queryString": [ 212 | // { 213 | // "name": "uid", 214 | // "value": "856318" 215 | // } 216 | // ], 217 | // "headers": [ 218 | // { 219 | // "name": "Accept", 220 | // "value": "*/*" 221 | // } 222 | // ], 223 | // "cookies": [] 224 | //}); 225 | 226 | -------------------------------------------------------------------------------- /routes/status.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | var moklrModel = require('../models/moklrModel.js'); 4 | var commonUtils = require('../lib/utils.js'); 5 | var util = require('util'); 6 | var queryString = require('querystring'); 7 | var urlUtil = require('url'); 8 | var async = require('async'); 9 | var request = require("request"); 10 | var config = require("../config"); 11 | 12 | var logger = require('../lib/log.js').logger('statusRouter'); 13 | 14 | //去往用户首页 15 | router.get('/', commonUtils.checkLogin, function (req, res, next) { 16 | var uid = req.session.user.userId; 17 | res.render("status"); 18 | }); 19 | 20 | router.get('/hars', commonUtils.checkLoginAjax, function (req, res, next) { 21 | var uid = req.session.user.userId; 22 | 23 | moklrModel.findHarsOfUser(uid, function (err, hars) { 24 | if (err) { 25 | return res.json({ 26 | success: false, 27 | msg: "获取用户的所有hars出错" 28 | }); 29 | } else { 30 | return res.json({ 31 | success: true, 32 | msg: "ok", 33 | data: hars 34 | }); 35 | } 36 | }); 37 | }); 38 | 39 | router.get('/apis', commonUtils.checkLoginAjax, function (req, res, next) { 40 | var uid = req.session.user.userId; 41 | 42 | moklrModel.findStatusAPIs(uid, function (err, apis) { 43 | if (err) { 44 | return res.json({ 45 | success: false, 46 | msg: "获取用户的所有status api出错" 47 | }); 48 | } else { 49 | return res.json({ 50 | success: true, 51 | msg: "ok", 52 | data: apis 53 | }); 54 | } 55 | }); 56 | }); 57 | 58 | router.get('/api', commonUtils.checkLoginAjax, function (req, res, next) { 59 | var uid = req.session.user.userId; 60 | var statusAPIId = req.query.statusAPIId; 61 | 62 | moklrModel.findStatusAPI(uid, statusAPIId, function (err, api) { 63 | if (err) { 64 | return res.json({ 65 | success: false, 66 | msg: "获取status api出错" 67 | }); 68 | } else { 69 | return res.json({ 70 | success: true, 71 | msg: "ok", 72 | data: api 73 | }); 74 | } 75 | }); 76 | }); 77 | 78 | //创建 79 | router.post('/api/create', commonUtils.checkLoginAjax, function (req, res, next) { 80 | var har = req.body.har; 81 | var name = req.body.name; 82 | var uid = req.session.user.userId; 83 | var cron = req.body.cron; 84 | var monitor = req.body.monitor; 85 | 86 | try { 87 | if (isNaN(cron)) { 88 | return res.json({ 89 | success: false, 90 | msg: "cron must be number" 91 | }); 92 | } 93 | } catch (e) { 94 | return res.json({ 95 | success: false, 96 | msg: "cron must be number" 97 | }); 98 | } 99 | 100 | moklrModel.createStatusAPI(uid, name, monitor || false, cron || "5", har, function (err, newStatusAPI) { 101 | if (err) { 102 | return res.json({ 103 | success: false, 104 | msg: "创建出错" 105 | }); 106 | } else { 107 | return res.json({ 108 | success: true, 109 | msg: "ok", 110 | data: newStatusAPI 111 | }); 112 | } 113 | }); 114 | }); 115 | 116 | //修改名称、时间间隔等 117 | router.post('/api/modify', commonUtils.checkLoginAjax, function (req, res, next) { 118 | var statusAPIId = req.body.statusAPIId; 119 | var uid = req.session.user.userId; 120 | var cron = req.body.cron; 121 | var monitor = req.body.monitor; 122 | if (monitor == true || monitor == 'true') { 123 | monitor = true; 124 | } else { 125 | monitor = false; 126 | } 127 | 128 | try { 129 | if (isNaN(cron)) { 130 | return res.json({ 131 | success: false, 132 | msg: "cron must be number" 133 | }); 134 | } 135 | } catch (e) { 136 | return res.json({ 137 | success: false, 138 | msg: "cron must be number" 139 | }); 140 | } 141 | 142 | var name = req.body.name; 143 | 144 | moklrModel.modifyStatusAPI(uid, statusAPIId, name, monitor, cron, function (err, result) { 145 | if (err) { 146 | return res.json({ 147 | success: false, 148 | msg: "修改出错" 149 | }); 150 | } else { 151 | if (config.runbot.on) {//开启了status服务(定期请求并记录日志) 152 | console.log("开始触发runbot命令", (monitor === true ? "start" : "stop"), statusAPIId); 153 | var options = { 154 | "method": "GET", 155 | "url": config.runbot.address + "/" + (monitor === true ? "start" : "stop") + "?statusAPIId=" + statusAPIId 156 | }; 157 | 158 | request(options, function (error, response, body) { 159 | console.log("========"); 160 | console.log("error: ", error); 161 | console.log("response: ", response && (response.statusCode || "")); 162 | console.log("++++++++"); 163 | 164 | if (!error && response && response.statusCode == 200) { 165 | var r = JSON.parse(body); 166 | if (r.success) { 167 | return res.json({ 168 | success: true, 169 | msg: "ok", 170 | data: result 171 | }); 172 | } else { 173 | return res.json({ 174 | success: false, 175 | msg: r.msg 176 | }); 177 | } 178 | } else { 179 | return res.json({ 180 | success: false, 181 | msg: "修改status api成功,但触发执行runbot失败,请检查" 182 | }); 183 | } 184 | }); 185 | } else { 186 | return res.json({ 187 | success: true, 188 | msg: "ok", 189 | data: result 190 | }); 191 | } 192 | } 193 | }); 194 | }); 195 | 196 | router.post('/api/delete', commonUtils.checkLoginAjax, function (req, res, next) { 197 | var statusAPIId = req.body.statusAPIId; 198 | var uid = req.session.user.userId; 199 | 200 | moklrModel.deleteStatusAPI(uid, statusAPIId, function (err, result) { 201 | if (err) { 202 | return res.json({ 203 | success: false, 204 | msg: "删除status api出错" 205 | }); 206 | } else { 207 | return res.json({ 208 | success: true, 209 | msg: "ok", 210 | data: result 211 | }); 212 | } 213 | }); 214 | }); 215 | 216 | 217 | router.get('/api/logs', commonUtils.checkLoginAjax, function (req, res, next) { 218 | var statusAPIId = req.query.statusAPIId; 219 | var uid = req.session.user.userId; 220 | var limit = 100; 221 | 222 | moklrModel.findStatusAPILogs(statusAPIId, limit, function (err, result) { 223 | if (err) { 224 | return res.json({ 225 | success: false, 226 | msg: "获取status api logs出错" 227 | }); 228 | } else { 229 | return res.json({ 230 | success: true, 231 | msg: "ok", 232 | data: result 233 | }); 234 | } 235 | }); 236 | }); 237 | 238 | router.post('/api/logs/delete', commonUtils.checkLoginAjax, function (req, res, next) { 239 | var statusAPIId = req.body.statusAPIId; 240 | var uid = req.session.user.userId; 241 | 242 | moklrModel.deleteStatusAPILogs(uid, statusAPIId, function (err, result) { 243 | if (err) { 244 | return res.json({ 245 | success: false, 246 | msg: "删除status api logs出错" 247 | }); 248 | } else { 249 | return res.json({ 250 | success: true, 251 | msg: "ok", 252 | data: result 253 | }); 254 | } 255 | }); 256 | }); 257 | 258 | 259 | module.exports = router; 260 | -------------------------------------------------------------------------------- /test/moklrModel.test.js: -------------------------------------------------------------------------------- 1 | var moklrModel = require("../models/moklrModel.js"); 2 | 3 | 4 | 5 | function test() { 6 | moklrModel.findCollections("1", function(err, result){ 7 | console.log(err, result); 8 | }); 9 | 10 | moklrModel.findHarsOfCollection("1", function (err, result) { 11 | console.log(err, result); 12 | }); 13 | 14 | moklrModel.createHar("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "b240fa21-c5b7-4a51-8b54-336f6d2a2e5e", "get", { 15 | "method": "GET", 16 | "url": "http://192.168.100.122:8010/intersect?type=1&uid=2&targets=3", 17 | "httpVersion": "HTTP/1.1", 18 | "queryString": [ 19 | { 20 | "name": "type", 21 | "value": "1" 22 | }, 23 | { 24 | "name": "uid", 25 | "value": "2" 26 | }, 27 | { 28 | "name": "targets", 29 | "value": "3" 30 | } 31 | ], 32 | "headers": [ 33 | { 34 | "name": "Accept", 35 | "value": "*/*" 36 | } 37 | ], 38 | "cookies": [] 39 | }, function (err, result) { 40 | console.log(err, result); 41 | }); 42 | 43 | 44 | moklrModel.createHar("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "b240fa21-c5b7-4a51-8b54-336f6d2a2e5e", "post", { 45 | "method": "POST", 46 | "headers": [ 47 | { 48 | "name": "Content-type", 49 | "value": "application/json" 50 | }, 51 | { 52 | "name": "Accept", 53 | "value": "*/*" 54 | } 55 | ], 56 | "cookies": [], 57 | "url": "http://192.168.100.122:8001/user/save", 58 | "httpVersion": "HTTP/1.1", 59 | "queryString": [], 60 | "postData": { 61 | "mimeType": "application/json", 62 | "text": "{\"name\":\"sumory\",\"sex\":\"男\",\"age\":12}" 63 | } 64 | }, function (err, result) { 65 | console.log(err, result); 66 | }); 67 | 68 | 69 | moklrModel.createHar("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "b240fa21-c5b7-4a51-8b54-336f6d2a2e5e", "post-form",{ 70 | "method": "POST", 71 | "url": "http://192.168.100.122:8001/user/save", 72 | "httpVersion": "HTTP/1.1", 73 | "queryString": [], 74 | "headers": [ 75 | { 76 | "name": "Content-type", 77 | "value": "application/x-www-form-urlencoded" 78 | }, 79 | { 80 | "name": "Accept", 81 | "value": "*/*" 82 | } 83 | ], 84 | "cookies": [], 85 | "postData": { 86 | "mimeType": "application/x-www-form-urlencoded", 87 | "params": [ 88 | { 89 | "name": "name", 90 | "value": "ss" 91 | }, 92 | { 93 | "name": "age", 94 | "value": "45" 95 | } 96 | ] 97 | } 98 | }, function (err, result) { 99 | console.log(err, result); 100 | }); 101 | 102 | moklrModel.deleteCollection("1", "1", function (err, result) { 103 | console.log(err, result); 104 | }); 105 | 106 | moklrModel.createUser({ 107 | username: 'sumory', 108 | pwd: '123456' 109 | }, function (err, result) { 110 | console.log(err, result); 111 | }); 112 | 113 | moklrModel.createCollection("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "/user/"); 114 | moklrModel.createCollection("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "/abc/"); 115 | moklrModel.createCollection("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "/test/"); 116 | moklrModel.createCollection("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "/db/test/"); 117 | moklrModel.createCollection("db46161c-917a-40d8-b1fd-242e7cc8f4b3", "/lmg/"); 118 | 119 | moklrModel.findStatusAPILogsByTime("868c8567-4126-4341-ae8f-50e232fe8602",new Date("2015-08-27 14:20:39"),new Date("2015-08-27 14:40:39"),function(err, result){ 120 | console.log(err, result); 121 | }); 122 | } 123 | 124 | function createUser(){ 125 | moklrModel.createUser({ 126 | username: 'test', 127 | pwd: '123456' 128 | }, function (err, result) { 129 | console.log(err, result); 130 | process.exit(0); 131 | }); 132 | } 133 | 134 | createUser(); 135 | -------------------------------------------------------------------------------- /test/mongo.test.js: -------------------------------------------------------------------------------- 1 | var mongoose = require('mongoose'); 2 | mongoose.connect('mongodb://192.168.100.186/moklr'); 3 | 4 | var User = mongoose.model('user', { username: String, pwd:String }); 5 | 6 | var u = new User({ username: 'test', pwd: 'pwd' }); 7 | u.save(function (err) { 8 | if (err) // ... 9 | console.log('meow'); 10 | }); 11 | -------------------------------------------------------------------------------- /test/mongoose.test.js: -------------------------------------------------------------------------------- 1 | var mongoose = require('mongoose'); 2 | mongoose.connect('mongodb://192.168.100.186:20301/moklr'); 3 | var Schema = mongoose.Schema; 4 | 5 | var UserSchema = new Schema({ 6 | userId: String, 7 | username: String, 8 | pwd: String, 9 | date: {type: Date, default: Date.now} 10 | }); 11 | 12 | UserSchema.statics.findbyUsername = function (username, callback) { 13 | return this.model('User').find({username: username}, callback); 14 | }; 15 | 16 | var CollectionSchema = new Schema({ 17 | collectionId: String, 18 | userId: String, 19 | hars: [String], 20 | date: {type: Date, default: Date.now} 21 | }); 22 | 23 | CollectionSchema.statics.findAllByUserId = function (userId, callback) { 24 | return this.model('Collection').find({userId: userId}, callback); 25 | }; 26 | 27 | var HarSchema = new Schema({ 28 | harId: String, 29 | userId: String, 30 | collectionId: String, 31 | name: String, 32 | content: {}, 33 | date: {type: Date, default: Date.now} 34 | }); 35 | 36 | 37 | var User = mongoose.model('User', UserSchema, "user"); 38 | var Collection = mongoose.model('Collection', CollectionSchema, "collection"); 39 | var Har = mongoose.model('Har', HarSchema, "har"); 40 | 41 | //var u = new User({ 42 | // username: "test", 43 | // pwd:"t11" 44 | //}); 45 | 46 | User.findbyUsername('sumory', function (error, u) { 47 | console.log("find", error, u) 48 | }); 49 | 50 | 51 | //var collection = new Collection({ 52 | // userId: "1", 53 | // collectionId: "1", 54 | // hars: [] 55 | //}); 56 | //collection.save(); 57 | 58 | var har = new Har({ 59 | harId: "1", 60 | userId: "1", 61 | name: "/user/save", 62 | content: { 63 | "method": "GET", 64 | "url": "http://192.168.100.122:8010/allrelation?uid=856318", 65 | "httpVersion": "HTTP/1.1", 66 | "queryString": [ 67 | { 68 | "name": "uid", 69 | "value": "856318" 70 | } 71 | ], 72 | "headers": [ 73 | { 74 | "name": "Accept", 75 | "value": "*/*" 76 | } 77 | ], 78 | "cookies": [] 79 | } 80 | }); 81 | 82 | har.save(); -------------------------------------------------------------------------------- /test/redis.test.js: -------------------------------------------------------------------------------- 1 | var redisUtils = require("../lib/redisUtils.js"); 2 | 3 | var k = "k1"; 4 | var v = "value1"; 5 | 6 | //redisUtils.set(k, v, function (err, reply) { 7 | // console.log(err, reply); 8 | // redisUtils.get(k, function(err, reply){ 9 | // console.log(err, reply); 10 | // }); 11 | //}); 12 | 13 | var hkey = 'hashkey1'; 14 | var f1 = 'f1'; 15 | var v1 = 'v1'; 16 | 17 | //redisUtils.hset(hkey, f1, v1, function(err, reply){ 18 | // console.log('hset', err, reply); 19 | // redisUtils.hget(hkey, f1, function(err, reply){ 20 | // console.log('result', err, reply); 21 | // }); 22 | //}); 23 | 24 | 25 | var fvs ={}; 26 | 27 | for(var i =0;i<10;i++){ 28 | fvs['f'+i]="value"+i; 29 | } 30 | 31 | redisUtils.hmset(hkey,fvs, function(err, reply){ 32 | console.log('hmset', err, reply); 33 | redisUtils.hgetall(hkey,function(err, reply){ 34 | console.log('result', err, reply); 35 | 36 | console.log('keys', Object.keys(reply)); 37 | }); 38 | }); -------------------------------------------------------------------------------- /test/user.test.js: -------------------------------------------------------------------------------- 1 | //var m = require('../models/moklrModel.js'); 2 | 3 | // 4 | //m.createUser({ 5 | // username: 'test', 6 | // pwd: '123456', 7 | // userId: "1" 8 | //}, function (err, result) { 9 | // console.log(err, result); 10 | //}); -------------------------------------------------------------------------------- /views/error.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Moklr - 出错啦! 5 | <% include meta.ejs %> 6 | 7 | 8 | 9 | <% include header.ejs %> 10 | 11 |
12 |

<%= msg %>

13 | 14 |
15 | <% if(locals.error && error.status){ %> 16 | <%= error.status %> 17 | <% } %> 18 |
19 | 20 | 21 | <% if(locals.error && error.status){ %> 22 |
23 |         <%= error.stack %>
24 |         
25 | <% } %> 26 | 27 |
28 | 29 | <% include footer.ejs %> 30 | 31 | 32 | -------------------------------------------------------------------------------- /views/footer.ejs: -------------------------------------------------------------------------------- 1 | 2 | 22 | -------------------------------------------------------------------------------- /views/har.ejs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sumory/moklr/6cc46259d998f134c85b23eb2d7701eab9d32a95/views/har.ejs -------------------------------------------------------------------------------- /views/header.ejs: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /views/help.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Moklr - help 5 | 6 | <%include meta.ejs%> 7 | 8 | 9 | 10 | 11 | 12 | <%include header.ejs%> 13 | 14 | 15 |
16 |

Help

17 | 18 | see github for help or email sumory.wu@gmail.com 19 | 20 |
21 | <%include footer.ejs%> 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /views/index.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Welcome to Moklr 5 | 6 | <%include meta.ejs%> 7 | 8 | 9 | 10 | 11 | 12 | <%include header.ejs%> 13 | 14 | 15 |
16 |

Welcome to Moklr

17 | 18 | 19 | You can take a look at Request Builder 20 |
21 |

or

22 |
23 | Login to have more fun. 24 | 25 | 26 | 27 | 28 | 29 |
30 | <%include footer.ejs%> 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /views/login.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 登录 5 | 6 | <%include meta.ejs%> 7 | 8 | 9 | 10 | 11 | 12 | <%include header.ejs%> 13 | 14 | 15 |
16 |

Login

17 | 18 | 19 |
20 |
21 | 22 | 23 |
24 |
25 | 26 | 27 |
28 | 29 |
30 | 31 | 32 | 33 |
34 | <%include footer.ejs%> 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /views/meta.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | Moklr - Postman, Status server, Mock http request 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /views/postman-modal-tpl.ejs: -------------------------------------------------------------------------------- 1 | 2 | 20 | 21 | 22 | 51 | 52 | 76 | 77 | -------------------------------------------------------------------------------- /views/postman.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | <%include meta.ejs%> 4 | 5 | 6 | 7 | 8 | <%include header.ejs%> 9 | 10 |
11 |
12 |
13 | 14 |
15 |
16 |

Collections

17 |
18 |
19 | 20 |
21 |
22 | 25 |
26 |
27 | 28 | 29 | 30 | 31 |
32 |
    33 | 34 |
35 |
36 | 37 | 38 | 39 |
40 |
41 |
42 | 43 | 44 |
45 |
46 |
47 | 48 | 49 | 50 | <%include footer.ejs%> 51 | <%include postman-tpl.ejs%> 52 | <%include postman-modal-tpl.ejs%> 53 | 54 | 55 | 56 | 61 | 62 | -------------------------------------------------------------------------------- /views/status-tpl.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 23 | 24 | 25 | 41 | 42 | 43 | 44 | 90 | 91 | 92 | 145 | 146 | 147 | -------------------------------------------------------------------------------- /views/status.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | <% include meta.ejs %> 4 | status monitor 5 | 6 | 7 | 8 | 9 | <% include header.ejs %> 10 | 11 |
12 |
13 |
14 | 15 |
16 |
17 |

Status APIs

18 |
19 |
20 | 21 |
22 |
23 | 27 |
28 |
29 | 30 | 31 |
32 |
    33 | 34 |
35 |
36 | 37 | 38 |
39 |
40 |
41 |
42 | 43 |
44 |
45 | 66 | 67 |
68 |
69 |
70 | 71 | <% include footer.ejs %> 72 | <% include status-tpl.ejs %> 73 | 74 | 75 | 76 | 81 | 82 | --------------------------------------------------------------------------------