This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
Mexpress |
pureUI |
/* display:flex; */ | |
.flex { display: -webkit-box; display: -moz-box; display: -ms-flexbox; display: -webkit-flex; display: flex; } | |
/* row reverse */ | |
.flex.flex--reverse { -webkit-box-orient: horizontal; -moz-box-orient: horizontal; -webkit-box-direction: reverse; -moz-box-direction: reverse; -webkit-flex-direction: row-reverse; -ms-flex-direction: row-reverse; flex-direction: row-reverse; } | |
/* column */ | |
.flex--clo { -webkit-box-orient: vertical; -moz-box-orient: vertical; -webkit-box-direction: normal; -moz-box-direction: normal; -webkit-flex-direction: column; -ms-flex-direction: column; flex-direction: column; } | |
/* column reverse*/ | |
.flex--col.flex--reverse { -webkit-box-orient: vertical; -moz-box-orient: vertical; -webkit-box-direction: reverse; -moz-box-direction: reverse; -webkit-flex-direction: column-reverse; -ms-flex-direction: column-reverse; flex-direction: column-reverse; } | |
/* 子元素之间间距 */ | |
.flex--justify-content--space-between { -webkit-box-pack: justify; -moz-box-pack: justify; -ms-flex-pack: justify |
var jsonToString = function(obj) { | |
switch (typeof (obj)) { | |
case 'string': | |
// mod by k00132080 for 替换所有控制字符为空格 for | |
// NSPClient调用接口,当服务器返回的json对象中存在特殊字符时,js报错。 begin | |
var escapable = /[\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g; | |
var str = obj.replace(escapable, " "); | |
return '"' + str.replace(/(["\\])/g, '\\$1') + '"'; | |
// mod by k00132080 for 替换所有控制字符为空格 for | |
// NSPClient调用接口,当服务器返回的json对象中存在特殊字符时,js报错。 end |
var escap = function(string) { | |
// If the string contains no control characters, replace the | |
// offending characterswith safe escape sequences. | |
var escapable = /[\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g; | |
var meta = { // table of character substitutions | |
'\b' : '\\b', | |
'\t' : '\\t', | |
'\n' : '\\n', | |
'\f' : '\\f', | |
'\r' : '\\r', |
DA.loadPage = function(){ | |
var args = Array.from(arguments); | |
var gets = $.param(args[args.length-1]); | |
var basicPathName = location.pathname.match(/^\/\w+\//); | |
var subPathCache = ''; | |
for(var i=0,len=args.length-1; i<len; i++){ | |
subPathCache += args[i]; | |
} | |
var path = basicPathName + subPathCache + '?' + gets; | |
console.log(path); |
var $input = $('.search').val('query'); | |
var e = document.createEvent('HTMLEvents'); | |
e.initEvent('input', true, true); | |
$input[0].dispatchEvent(e); |
var opt = { | |
api: "mtop.method", | |
param: { | |
friendid : "xxx" | |
} | |
}; | |
DA.alinkRequestMtopProxy(opt, function (resp) { | |
callback(resp.result); | |
}); |