Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More β†’
Socket
Sign inDemoInstall
Socket

febs

Package Overview
Dependencies
Maintainers
1
Versions
206
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

febs - npm Package Compare versions

Comparing version 0.0.10 to 0.1.1

2

dist/febs/febs.min.js

@@ -1,1 +0,1 @@

function febs(){}febs.crypt=function(){},febs.crypt.crc32_table=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117],febs.crypt.crc32=function(e,n){n==window.undefined&&(n=0),n=-1^n;for(var a=0,r=e.length;r>a;a++)n=n>>>8^febs.crypt.crc32_table[255&(n^e.charCodeAt(a))];return-1^n},febs.crypt.crc32_file=function(e,n){if(!e&&!n)return void(n&&n(0));var a=File.prototype.mozSlice||File.prototype.webkitSlice||File.prototype.slice,r=new FileReader,t=2097152,i=Math.ceil(e.size/t),s=0,o=function(){var n=s*t,i=n+t>=e.size?e.size:n+t;r.readAsBinaryString(a.call(e,n,i))},f=0;r.onload=function(e){f=crc32(e.target.result,f),s++,i>s?o():n(f)},o()},febs.crypt.uuid=function(){for(var e=[],n="0123456789abcdef",a=0;36>a;a++)e[a]=n.substr(Math.floor(16*Math.random()),1);e[14]="4",e[19]=n.substr(3&e[19]|8,1),e[8]=e[13]=e[18]=e[23]="-";var r=e.join("");return r},febs.crypt.base64_encode=function(e){var n,a,r,t,i,s,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(r=e.length,a=0,n="";r>a;){if(t=255&e[a++],a==r){n+=o.charAt(t>>2),n+=o.charAt((3&t)<<4),n+="==";break}if(i=e[a++],a==r){n+=o.charAt(t>>2),n+=o.charAt((3&t)<<4|(240&i)>>4),n+=o.charAt((15&i)<<2),n+="=";break}s=e[a++],n+=o.charAt(t>>2),n+=o.charAt((3&t)<<4|(240&i)>>4),n+=o.charAt((15&i)<<2|(192&s)>>6),n+=o.charAt(63&s)}return n},febs.crypt.base64_decode=function(e){for(var n,a,r,t,i=new Array(-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,62,-1,-1,-1,63,52,53,54,55,56,57,58,59,60,61,-1,-1,-1,-1,-1,-1,-1,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1,-1,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,51,-1,-1,-1,-1,-1),s=0,o=e.length,f=[];o>s;){do n=i[255&e.charCodeAt(s++)];while(o>s&&-1==n);if(-1==n)break;do a=i[255&e.charCodeAt(s++)];while(o>s&&-1==a);if(-1==a)break;f.push(n<<2|(48&a)>>4);do{if(r=255&e.charCodeAt(s++),61==r)return f;r=i[r]}while(o>s&&-1==r);if(-1==r)break;f.push((15&a)<<4|(60&r)>>2);do{if(t=255&e.charCodeAt(s++),61==t)return f;t=i[t]}while(o>s&&-1==t);if(-1==t)break;f.push((3&r)<<6|t)}return f},febs.utils=function(){},febs.utils.browserIsMobile=function(){var e=window.navigator.userAgent,n=["Android","webOS","iPhone","iPad","iPod","Blackberry","Windows Phone"],a=new RegExp(n.join("|"),"i");return null!=e.match(a)},febs.utils.browserIsIOS=function(){var e=window.navigator.userAgent,n=["iPhone","iPad","iPod"],a=new RegExp(n.join("|"),"i");return null!=e.match(a)},febs.utils.browserIsWeixin=function(){var e=window.navigator.userAgent;return"MicroMessenger"==e.match(/MicroMessenger/i)?!0:!1},febs.utils.browserIsPhone=function(){var e=window.navigator.userAgent,n=["Android","iPhone","iPod","Blackberry","Windows Phone"],a=new RegExp(n.join("|"),"i");return null!=e.match(a)},febs.utils.browserIsSupportHtml5=function(){return"undefined"!=typeof Worker?!0:!1},febs.utils.getTimeString=function(e,n,a){if("number"!=typeof e)return"";n=n||"HH:mm:ss";var r=new Date(e),t={"M+":r.getMonth()+1,"d+":r.getDate(),"h+":r.getHours()%12==0?12:r.getHours()%12,"H+":r.getHours(),"m+":r.getMinutes(),"s+":r.getSeconds(),"q+":Math.floor((r.getMonth()+3)/3),S:r.getMilliseconds()},i=a||{0:"星期倩",1:"ζ˜ŸζœŸδΈ€",2:"星期二",3:"ζ˜ŸζœŸδΈ‰",4:"ζ˜ŸζœŸε››",5:"ζ˜ŸζœŸδΊ”",6:"ζ˜ŸζœŸε…­"};/(y+)/.test(n)&&(n=n.replace(RegExp.$1,(r.getFullYear()+"").substr(4-RegExp.$1.length))),/(E+)/.test(n)&&(n=n.replace(RegExp.$1,i[r.getDay()+""]));for(var s in t)new RegExp("("+s+")").test(n)&&(n=n.replace(RegExp.$1,1==RegExp.$1.length?t[s]:("00"+t[s]).substr((""+t[s]).length)));return n},febs.utils.getDate=function(strDate){var date=eval("new Date("+strDate.replace(/\d+(?=-[^-]+$)/,function(e){return parseInt(e,10)-1}).match(/\d+/g)+")");return date},febs.utils.mergeMap=function(){for(var e,n={},a=0;a<arguments.length;a++)if(e=arguments[a])for(var r in e)n[r]=e[r];return n},febs.utils.isNull=function(e){return null===e||void 0===e||Number.isNaN(e)},febs.string=function(){},febs.string.isPhoneMobile=function(e){return e&&/^0?1[2|3|4|5|6|7|8][0-9]\d{8}$/.test(e)?!0:!1},febs.string.isEmpty=function(e){return e?"string"!=typeof e?!0:0==e.length?!0:!1:!0},febs.string.getByteSize=function(e){if(!e)return 0;var n,a,r=0;for(n=0;n<e.length;n++)a=e.charCodeAt(n),127>a?r+=1:a>=128&&2047>=a?r+=2:a>=2048&&65535>=a?r+=3:a>=65536&&(r+=4);return r},febs.string.replace=function(e,n,a){if(!e||!n)return e;if(0==e.length)return e;var r="",t=e.length,i=0,s=0;do{if(i=e.indexOf(n,s),!(-1!=i&&t>i)){r+=e.slice(s);break}i!=s&&(r+=e.slice(s,i)),r+=a,s=i+n.length}while(t>i);return r},febs.nav=function(){},febs.nav.nav_map={},febs.nav.nav_arr=[],febs.nav.nav_max_length=20,febs.nav.nav_callback=null,febs.nav.nav_url_equal_callback=null,febs.nav.nav_ajax_count=0,febs.nav.nav_cur_url=null,febs.nav.nav_options={defaultTimeout:1e4},febs.nav.nav_ajax=function(e){if(e.url){var n=e.url.indexOf("?");0>n?(e.url+="?ajaxmark="+febs.nav.nav_ajax_count,febs.nav.nav_ajax_count++):n==e.url.length-1?(e.url+="ajaxmark="+febs.nav.nav_ajax_count,febs.nav.nav_ajax_count++):(e.url+="&ajaxmark="+febs.nav.nav_ajax_count,febs.nav.nav_ajax_count++)}e.timeout||(e.timeout=febs.nav.nav_options.defaultTimeout),jQuery.ajax(e)},febs.nav.nav_init=function(e,n,a){document.onkeydown=function(e){e=window.event||e;var n=e.keyCode||e.which;if(116==n){if(window.event){try{e.keyCode=0}catch(e){}e.returnValue=!1}else e.preventDefault();nav_refresh()}},a=a||{},a.defaultTimeout=a.defaultTimeout||1e4,febs.nav.nav_options=a,febs.nav.nav_callback=e,febs.nav.nav_url_equal_callback=n},febs.nav.nav_url=function(e){var n=null;return e&&(n=febs.nav.nav_map[e],n=n?n:null),n},febs.nav.nav_hash_change=function(){if(null!=febs.nav.nav_cur_url)return void(febs.nav.nav_cur_url=null);var e=location.hash;if(null!=e&&""!=e){var n=nav_url(e);n&&febs.nav.nav_callback&&febs.nav.nav_callback(n)}},febs.nav.nav_push=function(e){if(febs.nav.nav_url_equal_callback){for(var n=0;n<febs.nav.nav_arr.length;n++){var a=febs.nav.nav_map[febs.nav.nav_arr[n]];if(febs.nav.nav_url_equal_callback(a,e))return window.onhashchange=null,window.location.href=febs.nav.nav_arr[n],febs.nav.nav_cur_url=!0,void(window.onhashchange=nav_hash_change)}var r="#"+febs.crypt.uuid();return febs.nav.nav_arr.length>=febs.nav.nav_max_length&&(delete febs.nav.nav_map[febs.nav.nav_arr[0]],febs.nav.nav_arr.splice(0,1)),window.onhashchange=null,window.location.href=r,febs.nav.nav_cur_url=!0,window.onhashchange=nav_hash_change,febs.nav.nav_map[r]=e,febs.nav.nav_arr.push(r),r}},febs.nav.nav_go=function(e){febs.nav.nav_callback&&(e&&nav_push(e),nav_hash_change())},febs.nav.nav_refresh=function(){nav_go(null)},febs.nav.nav_refresh_elem=function(e,n){nav_ajax({type:"GET",url:n,success:function(n){e.html(n)}})},window.onhashchange=febs.nav.nav_hash_change,febs.controls=febs.controls||function(){},febs.control.upload=function(e){var n=e.finishCB,a=e.progressCB,r=e.uploadUrl,t=e.maxFileSize?e.maxFileSize:1/0;if(e.fileType&&e.fileObj.attr("accept",e.fileType),!e.fileObj[0].files[0])return void(n&&n("no file",e.fileObj,null));if(e.fileObj[0].files[0].size>t)return void(n&&n("size too big",e.fileObj,null));var i=r.indexOf("?");0>i?r+="?":i<r.length-1&&(r+="&");var s=e.formObj,o=e.fileObj;febs.crypt.crc32_file(o[0].files[0],function(t){t?s.ajaxSubmit({method:"POST",url:r+"crc32="+t+"&size="+o[0].files[0].size+(e.data?"&data="+e.data:""),dataType:"json",contentType:"application/json; charset=utf-8",uploadProgress:function(e,n,r,t){a&&a(o,t/100)},error:function(){n&&n("ajax err",o,null)},success:function(e){n&&n(null,o,e)}}):n&&n("check crc32 err",o,null)})};
function febs(){}febs.crypt=function(){},febs.crypt.crc32_table=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117],febs.crypt.crc32=function(e,n){n==window.undefined&&(n=0),n=-1^n;for(var a=0,r=e.length;r>a;a++)n=n>>>8^febs.crypt.crc32_table[255&(n^e.charCodeAt(a))];return-1^n},febs.crypt.crc32_file=function(e,n){if(!e&&!n)return void(n&&n(0));var a=File.prototype.mozSlice||File.prototype.webkitSlice||File.prototype.slice,r=new FileReader,t=2097152,i=Math.ceil(e.size/t),s=0,o=function(){var n=s*t,i=n+t>=e.size?e.size:n+t;r.readAsBinaryString(a.call(e,n,i))},f=0;r.onload=function(e){f=crc32(e.target.result,f),s++,i>s?o():n(f)},o()},febs.crypt.uuid=function(){for(var e=[],n="0123456789abcdef",a=0;36>a;a++)e[a]=n.substr(Math.floor(16*Math.random()),1);e[14]="4",e[19]=n.substr(3&e[19]|8,1),e[8]=e[13]=e[18]=e[23]="-";var r=e.join("");return r},febs.crypt.base64_encode=function(e){var n,a,r,t,i,s,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(r=e.length,a=0,n="";r>a;){if(t=255&e[a++],a==r){n+=o.charAt(t>>2),n+=o.charAt((3&t)<<4),n+="==";break}if(i=e[a++],a==r){n+=o.charAt(t>>2),n+=o.charAt((3&t)<<4|(240&i)>>4),n+=o.charAt((15&i)<<2),n+="=";break}s=e[a++],n+=o.charAt(t>>2),n+=o.charAt((3&t)<<4|(240&i)>>4),n+=o.charAt((15&i)<<2|(192&s)>>6),n+=o.charAt(63&s)}return n},febs.crypt.base64_decode=function(e){for(var n,a,r,t,i=new Array(-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,62,-1,-1,-1,63,52,53,54,55,56,57,58,59,60,61,-1,-1,-1,-1,-1,-1,-1,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1,-1,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,51,-1,-1,-1,-1,-1),s=0,o=e.length,f=[];o>s;){do n=i[255&e.charCodeAt(s++)];while(o>s&&-1==n);if(-1==n)break;do a=i[255&e.charCodeAt(s++)];while(o>s&&-1==a);if(-1==a)break;f.push(n<<2|(48&a)>>4);do{if(r=255&e.charCodeAt(s++),61==r)return f;r=i[r]}while(o>s&&-1==r);if(-1==r)break;f.push((15&a)<<4|(60&r)>>2);do{if(t=255&e.charCodeAt(s++),61==t)return f;t=i[t]}while(o>s&&-1==t);if(-1==t)break;f.push((3&r)<<6|t)}return f},febs.utils=function(){},febs.utils.browserIsMobile=function(){var e=window.navigator.userAgent,n=["Android","webOS","iPhone","iPad","iPod","Blackberry","Windows Phone"],a=new RegExp(n.join("|"),"i");return null!=e.match(a)},febs.utils.browserIsIOS=function(){var e=window.navigator.userAgent,n=["iPhone","iPad","iPod"],a=new RegExp(n.join("|"),"i");return null!=e.match(a)},febs.utils.browserIsWeixin=function(){var e=window.navigator.userAgent;return"MicroMessenger"==e.match(/MicroMessenger/i)?!0:!1},febs.utils.browserIsPhone=function(){var e=window.navigator.userAgent,n=["Android","iPhone","iPod","Blackberry","Windows Phone"],a=new RegExp(n.join("|"),"i");return null!=e.match(a)},febs.utils.browserIsSupportHtml5=function(){return"undefined"!=typeof Worker?!0:!1},febs.utils.getTimeString=function(e,n,a){if("number"!=typeof e)return"";n=n||"HH:mm:ss";var r=new Date(e),t={"M+":r.getMonth()+1,"d+":r.getDate(),"h+":r.getHours()%12==0?12:r.getHours()%12,"H+":r.getHours(),"m+":r.getMinutes(),"s+":r.getSeconds(),"q+":Math.floor((r.getMonth()+3)/3),S:r.getMilliseconds()},i=a||{0:"星期倩",1:"ζ˜ŸζœŸδΈ€",2:"星期二",3:"ζ˜ŸζœŸδΈ‰",4:"ζ˜ŸζœŸε››",5:"ζ˜ŸζœŸδΊ”",6:"ζ˜ŸζœŸε…­"};/(y+)/.test(n)&&(n=n.replace(RegExp.$1,(r.getFullYear()+"").substr(4-RegExp.$1.length))),/(E+)/.test(n)&&(n=n.replace(RegExp.$1,i[r.getDay()+""]));for(var s in t)new RegExp("("+s+")").test(n)&&(n=n.replace(RegExp.$1,1==RegExp.$1.length?t[s]:("00"+t[s]).substr((""+t[s]).length)));return n},febs.utils.getDate=function(strDate){var date=eval("new Date("+strDate.replace(/\d+(?=-[^-]+$)/,function(e){return parseInt(e,10)-1}).match(/\d+/g)+")");return date},febs.utils.mergeMap=function(){for(var e,n={},a=0;a<arguments.length;a++)if(e=arguments[a])for(var r in e)n[r]=e[r];return n},febs.utils.isNull=function(e){return null===e||void 0===e||Number.isNaN(e)},febs.string=function(){},febs.string.isPhoneMobile=function(e){return e&&/^0?1[2|3|4|5|6|7|8][0-9]\d{8}$/.test(e)?!0:!1},febs.string.isEmpty=function(e){return e?"string"!=typeof e?!0:0==e.length?!0:!1:!0},febs.string.getByteSize=function(e){if(!e)return 0;var n,a,r=0;for(n=0;n<e.length;n++)a=e.charCodeAt(n),127>a?r+=1:a>=128&&2047>=a?r+=2:a>=2048&&65535>=a?r+=3:a>=65536&&(r+=4);return r},febs.string.replace=function(e,n,a){if(!e||!n)return e;if(0==e.length)return e;var r="",t=e.length,i=0,s=0;do{if(i=e.indexOf(n,s),!(-1!=i&&t>i)){r+=e.slice(s);break}i!=s&&(r+=e.slice(s,i)),r+=a,s=i+n.length}while(t>i);return r},febs.nav=function(){},febs.nav.nav_map={},febs.nav.nav_arr=[],febs.nav.nav_max_length=20,febs.nav.nav_callback=null,febs.nav.nav_url_equal_callback=null,febs.nav.nav_ajax_count=0,febs.nav.nav_cur_url=null,febs.nav.nav_options={defaultTimeout:1e4},febs.nav.nav_ajax=function(e){if(e.url){var n=e.url.indexOf("?");0>n?(e.url+="?ajaxmark="+febs.nav.nav_ajax_count,febs.nav.nav_ajax_count++):n==e.url.length-1?(e.url+="ajaxmark="+febs.nav.nav_ajax_count,febs.nav.nav_ajax_count++):(e.url+="&ajaxmark="+febs.nav.nav_ajax_count,febs.nav.nav_ajax_count++)}e.timeout||(e.timeout=febs.nav.nav_options.defaultTimeout),jQuery.ajax(e)},febs.nav.nav_init=function(e,n,a){document.onkeydown=function(e){e=window.event||e;var n=e.keyCode||e.which;if(116==n){if(window.event){try{e.keyCode=0}catch(e){}e.returnValue=!1}else e.preventDefault();nav_refresh()}},a=a||{},a.defaultTimeout=a.defaultTimeout||1e4,febs.nav.nav_options=a,febs.nav.nav_callback=e,febs.nav.nav_url_equal_callback=n},febs.nav.nav_url=function(e){var n=null;return e&&(n=febs.nav.nav_map[e],n=n?n:null),n},febs.nav.nav_hash_change=function(){if(null!=febs.nav.nav_cur_url)return void(febs.nav.nav_cur_url=null);var e=location.hash;if(null!=e&&""!=e){var n=nav_url(e);n&&febs.nav.nav_callback&&febs.nav.nav_callback(n)}},febs.nav.nav_push=function(e){if(febs.nav.nav_url_equal_callback){for(var n=0;n<febs.nav.nav_arr.length;n++){var a=febs.nav.nav_map[febs.nav.nav_arr[n]];if(febs.nav.nav_url_equal_callback(a,e))return window.onhashchange=null,window.location.href=febs.nav.nav_arr[n],febs.nav.nav_cur_url=!0,void(window.onhashchange=nav_hash_change)}var r="#"+febs.crypt.uuid();return febs.nav.nav_arr.length>=febs.nav.nav_max_length&&(delete febs.nav.nav_map[febs.nav.nav_arr[0]],febs.nav.nav_arr.splice(0,1)),window.onhashchange=null,window.location.href=r,febs.nav.nav_cur_url=!0,window.onhashchange=nav_hash_change,febs.nav.nav_map[r]=e,febs.nav.nav_arr.push(r),r}},febs.nav.nav_go=function(e){febs.nav.nav_callback&&(e&&nav_push(e),nav_hash_change())},febs.nav.nav_refresh=function(){nav_go(null)},febs.nav.nav_refresh_elem=function(e,n){nav_ajax({type:"GET",url:n,success:function(n){e.html(n)}})},window.onhashchange=febs.nav.nav_hash_change,febs.controls=febs.controls||function(){},febs.controls.upload=function(e){var n=e.finishCB,a=e.progressCB,r=e.uploadUrl,t=e.maxFileSize?e.maxFileSize:1/0;if(e.fileType&&e.fileObj.attr("accept",e.fileType),!e.fileObj[0].files[0])return void(n&&n("no file",e.fileObj,null));if(e.fileObj[0].files[0].size>t)return void(n&&n("size too big",e.fileObj,null));var i=r.indexOf("?");0>i?r+="?":i<r.length-1&&(r+="&");var s=e.formObj,o=e.fileObj;febs.crypt.crc32_file(o[0].files[0],function(t){t?s.ajaxSubmit({method:"POST",url:r+"crc32="+t+"&size="+o[0].files[0].size+(e.data?"&data="+e.data:""),dataType:"json",contentType:"application/json; charset=utf-8",uploadProgress:function(e,n,r,t){a&&a(o,t/100)},error:function(){n&&n("ajax err",o,null)},success:function(e){n&&n(null,o,e)}}):n&&n("check crc32 err",o,null)})};

@@ -40,3 +40,3 @@ {

"name": "febs",
"version": "0.0.10"
"version": "0.1.1"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚑️ by Socket Inc