2018-01-28 16:40:49 +00:00
/ * *
* ezMark ( Minified ) - A Simple Checkbox and Radio button Styling plugin . This plugin allows you to use a custom Image for
* Checkbox or Radio button . Its very simple , small and easy to use .
*
* Copyright ( c ) Abdullah Rubiyath < http : //www.itsalif.info/>.
* Released under MIT License
*
* @ author Abdullah Rubiyath
* @ version 1.0
* @ date June 27 , 2010
* /
( function ( $ ) { $ . fn . ezMark = function ( options ) { options = options || { } ; var defaultOpt = { checkboxCls : options . checkboxCls || 'ez-checkbox' , radioCls : options . radioCls || 'ez-radio' , checkedCls : options . checkedCls || 'ez-checked' , selectedCls : options . selectedCls || 'ez-selected' , hideCls : 'ez-hide' } ; return this . each ( function ( ) { var $this = $ ( this ) ; var wrapTag = $this . attr ( 'type' ) == 'checkbox' ? '<div class="' + defaultOpt . checkboxCls + '">' : '<div class="' + defaultOpt . radioCls + '">' ; if ( $this . attr ( 'type' ) == 'checkbox' ) { $this . addClass ( defaultOpt . hideCls ) . wrap ( wrapTag ) . change ( function ( ) { if ( $ ( this ) . is ( ':checked' ) ) { $ ( this ) . parent ( ) . addClass ( defaultOpt . checkedCls ) ; }
else { $ ( this ) . parent ( ) . removeClass ( defaultOpt . checkedCls ) ; } } ) ; if ( $this . is ( ':checked' ) ) { $this . parent ( ) . addClass ( defaultOpt . checkedCls ) ; } }
else if ( $this . attr ( 'type' ) == 'radio' ) { $this . addClass ( defaultOpt . hideCls ) . wrap ( wrapTag ) . change ( function ( ) { $ ( 'input[name="' + $ ( this ) . attr ( 'name' ) + '"]' ) . each ( function ( ) { if ( $ ( this ) . is ( ':checked' ) ) { $ ( this ) . parent ( ) . addClass ( defaultOpt . selectedCls ) ; } else { $ ( this ) . parent ( ) . removeClass ( defaultOpt . selectedCls ) ; } } ) ; } ) ; if ( $this . is ( ':checked' ) ) { $this . parent ( ) . addClass ( defaultOpt . selectedCls ) ; } } } ) ; } } ) ( jQuery ) ;
/ * !
* mapAttributes jQuery Plugin v1 . 0.0
* http : //code.google.com/p/jquery-list-attributes/
*
* Copyright 2010 , Michael Riddle
* Licensed under the MIT
* http : //jquery.org/license
*
* Date : Sun Mar 28 05 : 49 : 39 2010 - 0900
* /
if ( jQuery ) {
jQuery ( document ) . ready ( function ( ) {
jQuery . fn . mapAttributes = function ( prefix , cutPrefix ) {
var maps = [ ] ;
var prefixLength = ( prefix && cutPrefix ) ? prefix . length : 0 ;
$ ( this ) . each ( function ( ) {
var map = { } ;
var attr ;
for ( var key in this . attributes ) {
if ( ! isNaN ( key ) && this . attributes [ key ] != null ) {
if ( ! prefix || this . attributes [ key ] . name . substr ( 0 , prefix . length ) == prefix ) {
name = this . attributes [ key ] . name ;
map [ prefixLength ? name . substring ( prefixLength , name . length ) : name ]
= this . attributes [ key ] . value ;
}
}
}
maps . push ( map ) ;
} ) ;
return ( maps . length > 1 ? maps : maps [ 0 ] ) ;
}
} ) ;
}
/ * !
* jQuery JavaScript Library v1 . 4.2
* http : //jquery.com/
*
* Copyright 2010 , John Resig
* Dual licensed under the MIT or GPL Version 2 licenses .
* http : //jquery.org/license
*
* Includes Sizzle . js
* http : //sizzlejs.com/
* Copyright 2010 , The Dojo Foundation
* Released under the MIT , BSD , and GPL Licenses .
*
* http : //www.stanlemon.net/projects/jgrowl.html
*
* Date : Sat Feb 13 22 : 33 : 48 2010 - 0500
*
* Заменил
* ass ( this . defaults . theme ) . prependTo ( self . element ) . anim
* на
* ass ( this . defaults . theme ) . appendTo ( self . element ) . anim
* дабы "закрыть всё" вылазило вверху сообщений
* /
( function ( $ ) { $ . jGrowl = function ( m , o ) { if ( $ ( '#jGrowl' ) . size ( ) == 0 )
$ ( '<div id="jGrowl"></div>' ) . addClass ( ( o && o . position ) ? o . position : $ . jGrowl . defaults . position ) . appendTo ( 'body' ) ; $ ( '#jGrowl' ) . jGrowl ( m , o ) ; } ; $ . fn . jGrowl = function ( m , o ) { if ( $ . isFunction ( this . each ) ) { var args = arguments ; return this . each ( function ( ) { var self = this ; if ( $ ( this ) . data ( 'jGrowl.instance' ) == undefined ) { $ ( this ) . data ( 'jGrowl.instance' , $ . extend ( new $ . fn . jGrowl ( ) , { notifications : [ ] , element : null , interval : null } ) ) ; $ ( this ) . data ( 'jGrowl.instance' ) . startup ( this ) ; }
if ( $ . isFunction ( $ ( this ) . data ( 'jGrowl.instance' ) [ m ] ) ) { $ ( this ) . data ( 'jGrowl.instance' ) [ m ] . apply ( $ ( this ) . data ( 'jGrowl.instance' ) , $ . makeArray ( args ) . slice ( 1 ) ) ; } else { $ ( this ) . data ( 'jGrowl.instance' ) . create ( m , o ) ; } } ) ; } ; } ; $ . extend ( $ . fn . jGrowl . prototype , { defaults : { pool : 0 , header : '' , group : '' , sticky : false , position : 'top-right' , glue : 'after' , theme : 'default' , themeState : 'highlight' , corners : '10px' , check : 250 , life : 3000 , closeDuration : 'normal' , openDuration : 'normal' , easing : 'swing' , closer : true , closeTemplate : '×' , closerTemplate : '<div>[ close all ]</div>' , log : function ( e , m , o ) { } , beforeOpen : function ( e , m , o ) { } , afterOpen : function ( e , m , o ) { } , open : function ( e , m , o ) { } , beforeClose : function ( e , m , o ) { } , close : function ( e , m , o ) { } , animateOpen : { opacity : 'show' } , animateClose : { opacity : 'hide' } } , notifications : [ ] , element : null , interval : null , create : function ( message , o ) { var o = $ . extend ( { } , this . defaults , o ) ; if ( typeof o . speed !== 'undefined' ) { o . openDuration = o . speed ; o . closeDuration = o . speed ; }
this . notifications . push ( { message : message , options : o } ) ; o . log . apply ( this . element , [ this . element , message , o ] ) ; } , render : function ( notification ) { var self = this ; var message = notification . message ; var o = notification . options ; var notification = $ ( '<div class="jGrowl-notification ' + o . themeState + ' ui-corner-all' +
( ( o . group != undefined && o . group != '' ) ? ' ' + o . group : '' ) + '">' + '<div class="jGrowl-close">' + o . closeTemplate + '</div>' + '<div class="jGrowl-header">' + o . header + '</div>' + '<div class="jGrowl-message">' + message + '</div></div>' ) . data ( "jGrowl" , o ) . addClass ( o . theme ) . children ( 'div.jGrowl-close' ) . bind ( "click.jGrowl" , function ( ) { $ ( this ) . parent ( ) . trigger ( 'jGrowl.close' ) ; } ) . parent ( ) ; $ ( notification ) . bind ( "mouseover.jGrowl" , function ( ) { $ ( 'div.jGrowl-notification' , self . element ) . data ( "jGrowl.pause" , true ) ; } ) . bind ( "mouseout.jGrowl" , function ( ) { $ ( 'div.jGrowl-notification' , self . element ) . data ( "jGrowl.pause" , false ) ; } ) . bind ( 'jGrowl.beforeOpen' , function ( ) { if ( o . beforeOpen . apply ( notification , [ notification , message , o , self . element ] ) != false ) { $ ( this ) . trigger ( 'jGrowl.open' ) ; } } ) . bind ( 'jGrowl.open' , function ( ) { if ( o . open . apply ( notification , [ notification , message , o , self . element ] ) != false ) { if ( o . glue == 'after' ) { $ ( 'div.jGrowl-notification:last' , self . element ) . after ( notification ) ; } else { $ ( 'div.jGrowl-notification:first' , self . element ) . before ( notification ) ; }
$ ( this ) . animate ( o . animateOpen , o . openDuration , o . easing , function ( ) { if ( $ . browser . msie && ( parseInt ( $ ( this ) . css ( 'opacity' ) , 10 ) === 1 || parseInt ( $ ( this ) . css ( 'opacity' ) , 10 ) === 0 ) )
this . style . removeAttribute ( 'filter' ) ; if ( $ ( this ) . data ( "jGrowl" ) != null )
$ ( this ) . data ( "jGrowl" ) . created = new Date ( ) ; $ ( this ) . trigger ( 'jGrowl.afterOpen' ) ; } ) ; } } ) . bind ( 'jGrowl.afterOpen' , function ( ) { o . afterOpen . apply ( notification , [ notification , message , o , self . element ] ) ; } ) . bind ( 'jGrowl.beforeClose' , function ( ) { if ( o . beforeClose . apply ( notification , [ notification , message , o , self . element ] ) != false )
$ ( this ) . trigger ( 'jGrowl.close' ) ; } ) . bind ( 'jGrowl.close' , function ( ) { $ ( this ) . data ( 'jGrowl.pause' , true ) ; $ ( this ) . animate ( o . animateClose , o . closeDuration , o . easing , function ( ) { if ( $ . isFunction ( o . close ) ) { if ( o . close . apply ( notification , [ notification , message , o , self . element ] ) !== false )
$ ( this ) . remove ( ) ; } else { $ ( this ) . remove ( ) ; } } ) ; } ) . trigger ( 'jGrowl.beforeOpen' ) ; if ( o . corners != '' && $ . fn . corner != undefined ) $ ( notification ) . corner ( o . corners ) ; if ( $ ( 'div.jGrowl-notification:parent' , self . element ) . size ( ) > 1 && $ ( 'div.jGrowl-closer' , self . element ) . size ( ) == 0 && this . defaults . closer != false ) { $ ( this . defaults . closerTemplate ) . addClass ( 'jGrowl-closer ui-state-highlight ui-corner-all' ) . addClass ( this . defaults . theme ) . prependTo ( self . element ) . animate ( this . defaults . animateOpen , this . defaults . speed , this . defaults . easing ) . bind ( "click.jGrowl" , function ( ) { $ ( this ) . siblings ( ) . trigger ( "jGrowl.beforeClose" ) ; if ( $ . isFunction ( self . defaults . closer ) ) { self . defaults . closer . apply ( $ ( this ) . parent ( ) [ 0 ] , [ $ ( this ) . parent ( ) [ 0 ] ] ) ; } } ) ; } ; } , update : function ( ) { $ ( this . element ) . find ( 'div.jGrowl-notification:parent' ) . each ( function ( ) { if ( $ ( this ) . data ( "jGrowl" ) != undefined && $ ( this ) . data ( "jGrowl" ) . created != undefined && ( $ ( this ) . data ( "jGrowl" ) . created . getTime ( ) + parseInt ( $ ( this ) . data ( "jGrowl" ) . life ) ) < ( new Date ( ) ) . getTime ( ) && $ ( this ) . data ( "jGrowl" ) . sticky != true && ( $ ( this ) . data ( "jGrowl.pause" ) == undefined || $ ( this ) . data ( "jGrowl.pause" ) != true ) ) { $ ( this ) . trigger ( 'jGrowl.beforeClose' ) ; } } ) ; if ( this . notifications . length > 0 && ( this . defaults . pool == 0 || $ ( this . element ) . find ( 'div.jGrowl-notification:parent' ) . size ( ) < this . defaults . pool ) )
this . render ( this . notifications . shift ( ) ) ; if ( $ ( this . element ) . find ( 'div.jGrowl-notification:parent' ) . size ( ) < 2 ) { $ ( this . element ) . find ( 'div.jGrowl-closer' ) . animate ( this . defaults . animateClose , this . defaults . speed , this . defaults . easing , function ( ) { $ ( this ) . remove ( ) ; } ) ; } } , startup : function ( e ) { this . element = $ ( e ) . addClass ( 'jGrowl' ) . append ( '<div class="jGrowl-notification"></div>' ) ; this . interval = setInterval ( function ( ) { $ ( e ) . data ( 'jGrowl.instance' ) . update ( ) ; } , parseInt ( this . defaults . check ) ) ; if ( $ . browser . msie && parseInt ( $ . browser . version ) < 7 && ! window [ "XMLHttpRequest" ] ) { $ ( this . element ) . addClass ( 'ie6' ) ; } } , shutdown : function ( ) { $ ( this . element ) . removeClass ( 'jGrowl' ) . find ( 'div.jGrowl-notification' ) . remove ( ) ; clearInterval ( this . interval ) ; } , close : function ( ) { $ ( this . element ) . find ( 'div.jGrowl-notification' ) . each ( function ( ) { $ ( this ) . trigger ( 'jGrowl.beforeClose' ) ; } ) ; } } ) ; $ . jGrowl . defaults = $ . fn . jGrowl . prototype . defaults ; } ) ( jQuery ) ;
/ *
* JQuery Random Plugin
*
* Adds two random number functions to jQuery -
* one to find a random number and one to find a random number between a max and min limit .
*
* Version 1.0
*
* by Christian Bruun - 23. jan 2009
*
* Like it / use it ? Send me an e - mail : rockechris @ rockechris . com
*
* License : None . Use and abuse . Comes with no warranty , of course !
*
*
* Usage :
* $ . random ( int ) ;
* $ . randomBetween ( min , max ) ;
*
* Code found at :
* http : //www.merlyn.demon.co.uk/js-randm.htm
*
* /
jQuery . extend ( {
random : function ( X ) {
return Math . floor ( X * ( Math . random ( ) % 1 ) ) ;
} ,
randomBetween : function ( MinV , MaxV ) {
return MinV + jQuery . random ( MaxV - MinV + 1 ) ;
}
} ) ;
// VERSION: 1.8 LAST UPDATE: 9.03.2011 jqueryrotate
/ *
* Licensed under the MIT license : http : //www.opensource.org/licenses/mit-license.php
*
* Made by Wilq32 , wilq32 @ gmail . com , Wroclaw , Poland , 01.2009
* Website : http : //code.google.com/p/jqueryrotate/
* http : //www.xiper.net/collect/js-plugins/effects/jqueryrotate.html
* /
// Documentation removed from script file (was kinda useless and outdated)
( function ( g ) { for ( var d , j = document . getElementsByTagName ( "head" ) [ 0 ] . style , h = [ "transformProperty" , "WebkitTransform" , "OTransform" , "msTransform" , "MozTransform" ] , e = 0 ; e < h . length ; e ++ ) void 0 !== j [ h [ e ] ] && ( d = h [ e ] ) ; var i = eval ( '"v"=="\v"' ) ; jQuery . fn . extend ( { ImageRotate : function ( a ) { if ( ! this . Wilq32 || ! this . Wilq32 . PhotoEffect ) return a = g . extend ( ! 0 , { } , a ) , ( new Wilq32 . PhotoEffect ( this . get ( 0 ) , a ) ) . _rootObj } , rotate : function ( a ) { if ( ! ( 0 === this . length || "undefined" == typeof a ) ) { "number" == typeof a && ( a = { angle : a } ) ; for ( var c = [ ] , b = 0 , d = this . length ; b < d ; b ++ ) { var f = this . get ( b ) ; "undefined" == typeof f . Wilq32 ? c . push ( g ( g ( f ) . ImageRotate ( a ) ) ) : f . Wilq32 . PhotoEffect . _handleRotation ( a ) } return c } } } ) ; Wilq32 = window . Wilq32 || { } ; Wilq32 . PhotoEffect = function ( ) { return d ? function ( a , c ) { a . Wilq32 = { PhotoEffect : this } ; this . _img = this . _rootObj = this . _eventObj = a ; this . _handleRotation ( c ) } : function ( a , c ) { this . _img = a ; this . _rootObj = document . createElement ( "span" ) ; this . _rootObj . style . display = "inline-block" ; this . _rootObj . Wilq32 = { PhotoEffect : this } ; a . parentNode . insertBefore ( this . _rootObj , a ) ; if ( a . complete ) this . _Loader ( c ) ; else { var b = this ; jQuery ( this . _img ) . bind ( "load" , function ( ) { b . _Loader ( c ) } ) } } } ( ) ; Wilq32 . PhotoEffect . prototype = { _setupParameters : function ( a ) { this . _parameters = this . _parameters || { } ; "number" !== typeof this . _angle && ( this . _angle = 0 ) ; "number" === typeof a . angle && ( this . _angle = a . angle ) ; this . _parameters . animateTo = "number" === typeof a . animateTo ? a . animateTo : this . _angle ; this . _parameters . easing = a . easing || this . _parameters . easing || function ( a , b , d , f , e ) { return - f * ( ( b = b / e - 1 ) * b * b * b - 1 ) + d } ; this . _parameters . duration = a . duration || this . _parameters . duration || 1E3 ; this . _parameters . callback = a . callback || this . _parameters . callback || function ( ) { } ; a . bind && a . bind != this . _parameters . bind && this . _BindEvents ( a . bind ) } , _handleRotation : function ( a ) { this . _setupParameters ( a ) ; this . _angle == this . _parameters . animateTo ? this . _rotate ( this . _angle ) : this . _animateStart ( ) } , _BindEvents : function ( a ) { if ( a && this . _eventObj ) { if ( this . _parameters . bind ) { var c = this . _parameters . bind , b ; for ( b in c ) c . hasOwnProperty ( b ) && jQuery ( this . _eventObj ) . unbind ( b , c [ b ] ) } this . _parameters . bind = a ; for ( b in a ) a . hasOwnProperty ( b ) && jQuery ( this . _eventObj ) . bind ( b , a [ b ] ) } } , _Loader : function ( ) { return i ? function ( a ) { var c = this . _img . width , b = this . _img . height ; this . _img . parentNode . removeChild ( this . _img ) ; this . _vimage = this . createVMLNode ( "image" ) ; this . _vimage . src = this . _img . src ; this . _vimage . style . height = b + "px" ; this . _vimage . style . width = c + "px" ; this . _vimage . style . position = "absolute" ; this . _vimage . style . top = "0px" ; this . _vimage . style . left = "0px" ; this . _container = this . createVMLNode ( "group" ) ; this . _container . style . width = c ; this . _container . style . height = b ; this . _container . style . position = "absolute" ; this . _container . setAttribute ( "coordsize" , c - 1 + "," + ( b - 1 ) ) ; this . _container . appendChild ( this . _vimage ) ; this . _rootObj . appendChild ( this . _container ) ; this . _rootObj . style . position = "relative" ; this . _rootObj . style . width = c + "px" ; this . _rootObj . style . height = b + "px" ; this . _rootObj . setAttribute ( "id" , this . _img . getAttribute ( "id" ) ) ; this . _rootObj . className = this . _img . className ; this . _eventObj = this . _rootObj ; this . _handleRotation ( a ) } : function ( a ) { this . _rootObj . setAttribute ( "id" , this . _img . getAttribute ( "id" ) ) ; this . _rootObj . className = this . _img . className ; this . _width = this . _img . width ; this . _height = this . _img . height ; this . _widthHalf = this . _width / 2 ; this . _heightHalf = this . _height / 2 ; var c = Math . sqrt ( this . _height * this . _height + this . _width * this . _width ) ; this . _widthAdd = c - this . _width ; this . _heightAdd = c - this . _height ; this . _widthAddHalf = this . _widthAdd / 2 ; this . _heightAddHalf = this . _heightAdd / 2 ; this . _img . parentNode . removeChild ( this . _img ) ; this . _aspectW = ( parseInt ( this . _img . style . width , 10 ) || this . _width ) / this . _img . width ; this . _aspectH = ( parseInt ( this . _img . style . height , 10 ) || this . _height ) / this . _img . height ; this . _canvas = document . createElement ( "canvas" ) ; this . _canvas . setAttribute ( "width" , this . _width ) ; this . _canvas . style . position = "relative" ; this . _canvas . style . left = - this . _widthAddHalf + "px" ; this . _canvas . style . top = - this . _heightAddHalf + "px" ; this . _canvas . Wilq32 = this . _rootObj . Wilq32 ; this . _rootObj . appendChild ( this . _canvas ) ; this . _rootObj . style . width = this . _width + "px" ; this . _rootObj . style . height = this . _hei
/ * *
* jQuery Form Plugin
* version : 3.09 ( 16 - APR - 2012 )
* @ requires jQuery v1 . 3.2 or later
*
* Examples and documentation at : http : //malsup.com/jquery/form/
* Project repository : https : //github.com/malsup/form
* Dual licensed under the MIT and GPL licenses :
* http : //malsup.github.com/mit-license.txt
* http : //malsup.github.com/gpl-license-v2.txt
* /
( function ( $ ) { var feature = { } ; feature . fileapi = $ ( "<input type='file'/>" ) . get ( 0 ) . files !== undefined ; feature . formdata = window . FormData !== undefined ; $ . fn . ajaxSubmit = function ( options ) { if ( ! this . length ) { log ( "ajaxSubmit: skipping submit process - no element selected" ) ; return this } var method , action , url , $form = this ; if ( typeof options == "function" ) options = { success : options } ; method = this . attr ( "method" ) ; action = this . attr ( "action" ) ; url = typeof action === "string" ? $ . trim ( action ) : "" ; url = url || window . location . href || "" ; if ( url ) url = ( url . match ( /^([^#]+)/ ) || [ ] ) [ 1 ] ; options = $ . extend ( true , { url : url , success : $ . ajaxSettings . success , type : method || "GET" , iframeSrc : /^https/i . test ( window . location . href || "" ) ? "javascript:false" : "about:blank" } , options ) ; var veto = { } ; this . trigger ( "form-pre-serialize" , [ this , options , veto ] ) ; if ( veto . veto ) { log ( "ajaxSubmit: submit vetoed via form-pre-serialize trigger" ) ; return this } if ( options . beforeSerialize && options . beforeSerialize ( this , options ) === false ) { log ( "ajaxSubmit: submit aborted via beforeSerialize callback" ) ; return this } var traditional = options . traditional ; if ( traditional === undefined ) traditional = $ . ajaxSettings . traditional ; var elements = [ ] ; var qx , a = this . formToArray ( options . semantic , elements ) ; if ( options . data ) { options . extraData = options . data ; qx = $ . param ( options . data , traditional ) } if ( options . beforeSubmit && options . beforeSubmit ( a , this , options ) === false ) { log ( "ajaxSubmit: submit aborted via beforeSubmit callback" ) ; return this } this . trigger ( "form-submit-validate" , [ a , this , options , veto ] ) ; if ( veto . veto ) { log ( "ajaxSubmit: submit vetoed via form-submit-validate trigger" ) ; return this } var q = $ . param ( a , traditional ) ; if ( qx ) q = q ? q + "&" + qx : qx ; if ( options . type . toUpperCase ( ) == "GET" ) { options . url += ( options . url . indexOf ( "?" ) >= 0 ? "&" : "?" ) + q ; options . data = null } else options . data = q ; var callbacks = [ ] ; if ( options . resetForm ) callbacks . push ( function ( ) { $form . resetForm ( ) } ) ; if ( options . clearForm ) callbacks . push ( function ( ) { $form . clearForm ( options . includeHidden ) } ) ; if ( ! options . dataType && options . target ) { var oldSuccess = options . success || function ( ) { } ; callbacks . push ( function ( data ) { var fn = options . replaceTarget ? "replaceWith" : "html" ; $ ( options . target ) [ fn ] ( data ) . each ( oldSuccess , arguments ) } ) } else if ( options . success ) callbacks . push ( options . success ) ; options . success = function ( data , status , xhr ) { var context = options . context || options ; for ( var i = 0 , max = callbacks . length ; i < max ; i ++ ) callbacks [ i ] . apply ( context , [ data , status , xhr || $form , $form ] ) } ; var fileInputs = $ ( "input:file:enabled[value]" , this ) ; var hasFileInputs = fileInputs . length > 0 ; var mp = "multipart/form-data" ; var multipart = $form . attr ( "enctype" ) == mp || $form . attr ( "encoding" ) == mp ; var fileAPI = feature . fileapi && feature . formdata ; log ( "fileAPI :" + fileAPI ) ; var shouldUseFrame = ( hasFileInputs || multipart ) && ! fileAPI ; if ( options . iframe !== false && ( options . iframe || shouldUseFrame ) ) if ( options . closeKeepAlive ) $ . get ( options . closeKeepAlive , function ( ) { fileUploadIframe ( a ) } ) ; else fileUploadIframe ( a ) ; else if ( ( hasFileInputs || multipart ) && fileAPI ) fileUploadXhr ( a ) ; else $ . ajax ( options ) ; for ( var k = 0 ; k < elements . length ; k ++ ) elements [ k ] = null ; this . trigger ( "form-submit-notify" , [ this , options ] ) ; return this ; function fileUploadXhr ( a ) { var formdata = new FormData ; for ( var i = 0 ; i < a . length ; i ++ ) formdata . append ( a [ i ] . name , a [ i ] . value ) ; if ( options . extraData ) for ( var p in options . extraData ) if ( options . extraData . hasOwnProperty ( p ) ) formdata . append ( p , options . extraData [ p ] ) ; options . data = null ; var s = $ . extend ( true , { } , $ . ajaxSettings , options , { contentType : false , processData : false , cache : false , type : "POST" } ) ; if ( options . uploadProgress ) s . xhr = function ( ) { var xhr = jQuery . ajaxSettings . xhr ( ) ; if ( xhr . upload ) xhr . upload . onprogress = function ( event ) { var percent = 0 ; var position = event . loaded || event . position ; var total = event . total ; if ( event . lengthComputable ) percent = Math . ceil ( position / total * 100 ) ; options . uploadProgress ( event , position , total , percent ) } ; return xhr } ; s . data = null ; var beforeSend = s . beforeSend ; s . beforeSend = function ( xhr , o ) { o . data = formdata ; if ( beforeSend ) beforeSend . call ( o , xhr , options ) } ; $ . ajax ( s ) } function fileUploadIframe ( a ) { var form = $form [ 0 ] , el , i , s , g , id , $io , io , xhr , sub , n , timedOut , timeoutHandle ; var useProp = ! ! $ . fn . prop ; if ( $ ( ":input[name=submit],:input[id=submit]" , form ) . leng
/ * *
* jquery . maphilight . min . js
* /
2019-01-16 17:45:30 +00:00
( function ( G ) { var B , J , C , K , N , M , I , E , H , A , L ; B = document . namespaces ; J = ! ! document . createElement ( "canvas" ) . getContext ; if ( ! ( J || B ) ) { G . fn . maphilight = function ( ) { return this } ; return } if ( J ) { E = function ( O ) { return Math . max ( 0 , Math . min ( parseInt ( O , 16 ) , 255 ) ) } ; H = function ( O , P ) { return "rgba(" + E ( O . substr ( 0 , 2 ) ) + "," + E ( O . substr ( 2 , 2 ) ) + "," + E ( O . substr ( 4 , 2 ) ) + "," + P + ")" } ; C = function ( O ) { var P = G ( '<canvas style="width:' + O . width + "px;height:" + O . height + 'px;"></canvas>' ) . get ( 0 ) ; P . getContext ( "2d" ) . clearRect ( 0 , 0 , P . width , P . height ) ; return P } ; var F = function ( Q , O , R , P , S ) { P = P || 0 ; S = S || 0 ; Q . beginPath ( ) ; if ( O == "rect" ) { Q . rect ( R [ 0 ] + P , R [ 1 ] + S , R [ 2 ] - R [ 0 ] , R [ 3 ] - R [ 1 ] ) } else { if ( O == "poly" ) { Q . moveTo ( R [ 0 ] + P , R [ 1 ] + S ) ; for ( i = 2 ; i < R . length ; i += 2 ) { Q . lineTo ( R [ i ] + P , R [ i + 1 ] + S ) } } else { if ( O == "circ" ) { Q . arc ( R [ 0 ] + P , R [ 1 ] + S , R [ 2 ] , 0 , Math . PI * 2 , false ) } } } Q . closePath ( ) } ; K = function ( Q , T , U , X , O ) { var S , P = Q . getContext ( "2d" ) ; if ( X . shadow ) { P . save ( ) ; if ( X . shadowPosition == "inside" ) { F ( P , T , U ) ; P . clip ( ) } var R = Q . width * 100 ; var W = Q . height * 100 ; F ( P , T , U , R , W ) ; P . shadowOffsetX = X . shadowX - R ; P . shadowOffsetY = X . shadowY - W ; P . shadowBlur = X . shadowRadius ; P . shadowColor = H ( X . shadowColor , X . shadowOpacity ) ; var V = X . shadowFrom ; if ( ! V ) { if ( X . shadowPosition == "outside" ) { V = "fill" } else { V = "stroke" } } if ( V == "stroke" ) { P . strokeStyle = "rgba(0,0,0,1)" ; P . stroke ( ) } else { if ( V == "fill" ) { P . fillStyle = "rgba(0,0,0,1)" ; P . fill ( ) } } P . restore ( ) ; if ( X . shadowPosition == "outside" ) { P . save ( ) ; F ( P , T , U ) ; P . globalCompositeOperation = "destination-out" ; P . fillStyle = "rgba(0,0,0,1);" ; P . fill ( ) ; P . restore ( ) } } P . save ( ) ; F ( P , T , U ) ; if ( X . fill ) { P . fillStyle = H ( X . fillColor , X . fillOpacity ) ; P . fill ( ) } if ( X . stroke ) { P . strokeStyle = H ( X . strokeColor , X . strokeOpacity ) ; P . lineWidth = X . strokeWidth ; P . stroke ( ) } P . restore ( ) ; if ( X . fade ) { G ( Q ) . css ( "opacity" , 0 ) . animate ( { opacity : 1 } , 100 ) } } ; N = function ( O ) { O . getContext ( "2d" ) . clearRect ( 0 , 0 , O . width , O . height ) } } else { C = function ( O ) { return G ( '<var style="zoom:1;overflow:hidden;display:block;width:' + O . width + "px;height:" + O . height + 'px;"></var>' ) . get ( 0 ) } ; K = function ( P , S , T , W , O ) { var U , V , Q , R ; U = '<v:fill color="#' + W . fillColor + '" opacity="' + ( W . fill ? W . fillOpacity : 0 ) + '" />' ; V = ( W . stroke ? 'strokeweight="' + W . strokeWidth + '" stroked="t" strokecolor="#' + W . strokeColor + '"' : 'stroked="f"' ) ; Q = '<v:stroke opacity="' + W . strokeOpacity + '"/>' ; if ( S == "rect" ) { R = G ( '<v:rect name="' + O + '" filled="t" ' + V + ' style="zoom:1;margin:0;padding:0;display:block;position:absolute;left:' + T [ 0 ] + "px;top:" + T [ 1 ] + "px;width:" + ( T [ 2 ] - T [ 0 ] ) + "px;height:" + ( T [ 3 ] - T [ 1 ] ) + 'px;"></v:rect>' ) } else { if ( S == "poly" ) { R = G ( '<v:shape name="' + O + '" filled="t" ' + V + ' coordorigin="0,0" coordsize="' + P . width + "," + P . height + '" path="m ' + T [ 0 ] + "," + T [ 1 ] + " l " + T . join ( "," ) + ' x e" style="zoom:1;margin:0;padding:0;display:block;position:absolute;top:0px;left:0px;width:' + P . width + "px;height:" + P . height + 'px;"></v:shape>' ) } else { if ( S == "circ" ) { R = G ( '<v:oval name="' + O + '" filled="t" ' + V + ' style="zoom:1;margin:0;padding:0;display:block;position:absolute;left:' + ( T [ 0 ] - T [ 2 ] ) + "px;top:" + ( T [ 1 ] - T [ 2 ] ) + "px;width:" + ( T [ 2 ] * 2 ) + "px;height:" + ( T [ 2 ] * 2 ) + 'px;"></v:oval>' ) } } } R . get ( 0 ) . innerHTML = U + Q ; G ( P ) . append ( R ) } ; N = function ( O ) { G ( O ) . find ( "[name=highlighted]" ) . remove ( ) } } M = function ( P ) { var O , Q = P . getAttribute ( "coords" ) . split ( "," ) ; for ( O = 0 ; O < Q . length ; O ++ ) { Q [ O ] = parseFloat ( Q [ O ] ) } return [ P . getAttribute ( "shape" ) . toLowerCase ( ) . substr ( 0 , 4 ) , Q ] } ; L = function ( Q , P ) { var O = G ( Q ) ; return G . extend ( { } , P , G . metadata ? O . metadata ( ) : false , O . data ( "maphilight" ) ) } ; A = function ( O ) { if ( ! O . complete ) { return false } return ! ( typeof O . naturalWidth != "undefined" && O . naturalWidth === 0 ) ; } ; I = { position : "absolute" , left : 0 , top : 0 , padding : 0 , border : 0 } ; var D = false ; G . fn . maphilight = function ( Q ) { Q = G . extend ( { } , G . fn . maphilight . defaults , Q ) ; if ( ! J && G . browser . msie && ! D ) { document . namespaces . add ( "v" , "urn:schemas-microsoft-com:vml" ) ; var P = document . createStyleSheet ( ) ; var O = [ "shape" , "rect" , "oval" , "circ" , "fill" , "stroke" , "imagedata" , "group" , "textbox" ] ; G . each ( O , function ( ) { P . addRule ( "v\\:" + this , "behavior: url(#default#VML); antialias:true" ) } ) ; D = true } return this . each ( function ( ) { var W , T , a , S , V , X , Z , U , Y ; W = G ( this ) ; if ( ! A ( this ) ) { return window . setTimeout ( function ( ) { W . maphilight ( Q ) } , 200 ) } a = G . extend ( { } , Q , G . metadata ? W . metadata ( ) : false , W . data ( "maphilight" ) ) ; Y = W . get ( 0 ) . getAttribute ( "usemap" ) ; S = G ( 'map[name="' + Y . substr ( 1 ) + '
2018-01-28 16:40:49 +00:00
/ *
* xLazyLoader 1.5 - Plugin for jQuery
*
* https : //raw.github.com/kof/xLazyLoader/master/src/jquery.xLazyLoader.js
*
* Load js , css and images asynchron and get different callbacks
*
* Dual licensed under the MIT ( http : //www.opensource.org/licenses/mit-license.php)
* and GPL ( http : //www.opensource.org/licenses/gpl-license.php) licenses.
*
* Depends :
* jquery . js
*
* Copyright ( c ) 2010 Oleg Slobodskoi ( jsui . de )
* /
( function ( a ) { function m ( ) { function l ( b , a ) { m [ b ] ( a , function ( b ) { "error" == b ? e . push ( a ) : i . push ( a ) && c . each ( a ) ; o ( ) } , "lazy-loaded-" + ( c . name ? c . name : ( new Date ) . getTime ( ) ) , c [ b + "Key" ] ? "?key=" + c [ b + "Key" ] : "" ) } function h ( a ) { c . complete ( a , i , e ) ; c [ a ] ( "error" == a ? e : i ) ; clearTimeout ( p ) ; clearTimeout ( q ) } function o ( ) { i . length == j . length ? h ( "success" ) : i . length + e . length == j . length && h ( "error" ) } function r ( ) { e . push ( this . src ) ; o ( ) } var m = this , c , i = [ ] , e = [ ] , p , q , n , j = [ ] ; this . init = function ( b ) { b && ( c = a . extend ( { } , a . xLazyLoader . defaults , b ) , n = { js : c . js , css : c . css , img : c . img } , a . each ( n , function ( a , b ) { "string" == typeof b && ( b = b . split ( "," ) ) ; j = j . concat ( b ) } ) , j . length ? ( c . timeout && ( p = setTimeout ( function ( ) { var b = i . concat ( e ) ; a . each ( j , function ( d , c ) { - 1 == a . inArray ( c , b ) && e . push ( c ) } ) ; h ( "error" ) } , c . timeout ) ) , a . each ( n , function ( b , d ) { a . isArray ( d ) ? a . each ( d , function ( a , d ) { l ( b , d ) } ) : "string" == typeof d && l ( b , d ) } ) ) : h ( "error" ) ) } ; this . js = function ( b , c , d , l ) { var g = a ( 'script[src*="' + b + '"]' ) ; if ( g . length ) g . attr ( "pending" ) ? g . bind ( "scriptload" , c ) : c ( ) ; else { var f = document . createElement ( "script" ) ; f . setAttribute ( "type" , "text/javascript" ) ; f . setAttribute ( "charset" , "Windows-1251" ) ; f . setAttribute ( "src" , b + l ) ; f . setAttribute ( "id" , d ) ; f . setAttribute ( "pending" , 1 ) ; f . onerror = r ; a ( f ) . bind ( "scriptload" , function ( ) { a ( this ) . removeAttr ( "pending" ) ; c ( ) ; setTimeout ( function ( ) { a ( f ) . unbind ( "scriptload" ) } , 10 ) } ) ; var e = ! 1 ; f . onload = f . onreadystatechange = function ( ) { if ( ! e && ( ! this . readyState || /loaded|complete/ . test ( this . readyState ) ) ) e = ! 0 , f . onload = f . onreadystatechange = null , a ( f ) . trigger ( "scriptload" ) } ; k . appendChild ( f ) } } ; this . css = function ( b , c , d , e ) { if ( a ( 'link[href*="' + b + '"]' ) . length ) c ( ) ; else { var g = a ( '<link rel="stylesheet" type="text/css" media="all" href="' + b + e + '" id="' + d + '"></link>' ) [ 0 ] ; a . browser . msie ? g . onreadystatechange = function ( ) { if ( "loaded" == g . readyState || "complete" == g . readyState ) g . onreadystatechange = null , c ( ) } : a . browser . opera ? g . onload = c : ( d = location . hostname . replace ( "www." , "" ) , b = /http:/ . test ( b ) ? /^(\w+:)?\/\/([^\/?#]+)/ . exec ( b ) [ 2 ] : d , d != b && a . browser . mozilla ? c ( ) : function ( ) { try { g . sheet . cssRules } catch ( a ) { q = setTimeout ( arguments . callee , 20 ) ; return } c ( ) } ( ) ) ; k . appendChild ( g ) } } ; this . img = function ( a , c , d , e ) { d = new Image ; d . onload = c ; d . onerror = r ; d . src = a + e } ; this . disable = function ( b ) { a ( "#lazy-loaded-" + b , k ) . attr ( "disabled" , "disabled" ) } ; this . enable = function ( b ) { a ( "#lazy-loaded-" + b , k ) . removeAttr ( "disabled" ) } ; this . destroy = function ( b ) { a ( "#lazy-loaded-" + b , k ) . remove ( ) } } a . xLazyLoader = function ( a , h ) { "object" == typeof a && ( h = a , a = "init" ) ; ( new m ) [ a ] ( h ) } ; a . xLazyLoader . defaults = { js : [ ] , css : [ ] , img : [ ] , jsKey : null , cssKey : null , imgKey : null , name : null , timeout : 2E4 , success : a . noop , error : a . noop , complete : a . noop , each : a . noop } ; var k = document . getElementsByTagName ( "head" ) [ 0 ] } ) ( jQuery ) ;
/ *
* Lazy Load - jQuery plugin for lazy loading images
*
* http : //www.appelsiini.net/projects/lazyload
*
* Copyright ( c ) 2007 - 2012 Mika Tuupola
*
* Licensed under the MIT license :
* http : //www.opensource.org/licenses/mit-license.php
*
* Project home :
* http : //www.appelsiini.net/projects/lazyload
*
* Version : 1.7 . 2
*
* /
( function ( a , b ) { $window = a ( b ) , a . fn . lazyload = function ( c ) { function f ( ) { var b = 0 ; d . each ( function ( ) { var c = a ( this ) ; if ( e . skip _invisible && ! c . is ( ":visible" ) ) return ; if ( ! a . abovethetop ( this , e ) && ! a . leftofbegin ( this , e ) ) if ( ! a . belowthefold ( this , e ) && ! a . rightoffold ( this , e ) ) c . trigger ( "appear" ) ; else if ( ++ b > e . failure _limit ) return ! 1 } ) } var d = this , e = { threshold : 0 , failure _limit : 0 , event : "scroll" , effect : "show" , container : b , data _attribute : "original" , skip _invisible : ! 0 , appear : null , load : null } ; return c && ( undefined !== c . failurelimit && ( c . failure _limit = c . failurelimit , delete c . failurelimit ) , undefined !== c . effectspeed && ( c . effect _speed = c . effectspeed , delete c . effectspeed ) , a . extend ( e , c ) ) , $container = e . container === undefined || e . container === b ? $window : a ( e . container ) , 0 === e . event . indexOf ( "scroll" ) && $container . bind ( e . event , function ( a ) { return f ( ) } ) , this . each ( function ( ) { var b = this , c = a ( b ) ; b . loaded = ! 1 , c . one ( "appear" , function ( ) { if ( ! this . loaded ) { if ( e . appear ) { var f = d . length ; e . appear . call ( b , f , e ) } a ( "<img />" ) . bind ( "load" , function ( ) { c . hide ( ) . attr ( "src" , c . data ( e . data _attribute ) ) [ e . effect ] ( e . effect _speed ) , b . loaded = ! 0 ; var f = a . grep ( d , function ( a ) { return ! a . loaded } ) ; d = a ( f ) ; if ( e . load ) { var g = d . length ; e . load . call ( b , g , e ) } } ) . attr ( "src" , c . data ( e . data _attribute ) ) } } ) , 0 !== e . event . indexOf ( "scroll" ) && c . bind ( e . event , function ( a ) { b . loaded || c . trigger ( "appear" ) } ) } ) , $window . bind ( "resize" , function ( a ) { f ( ) } ) , f ( ) , this } , a . belowthefold = function ( c , d ) { var e ; return d . container === undefined || d . container === b ? e = $window . height ( ) + $window . scrollTop ( ) : e = $container . offset ( ) . top + $container . height ( ) , e <= a ( c ) . offset ( ) . top - d . threshold } , a . rightoffold = function ( c , d ) { var e ; return d . container === undefined || d . container === b ? e = $window . width ( ) + $window . scrollLeft ( ) : e = $container . offset ( ) . left + $container . width ( ) , e <= a ( c ) . offset ( ) . left - d . threshold } , a . abovethetop = function ( c , d ) { var e ; return d . container === undefined || d . container === b ? e = $window . scrollTop ( ) : e = $container . offset ( ) . top , e >= a ( c ) . offset ( ) . top + d . threshold + a ( c ) . height ( ) } , a . leftofbegin = function ( c , d ) { var e ; return d . container === undefined || d . container === b ? e = $window . scrollLeft ( ) : e = $container . offset ( ) . left , e >= a ( c ) . offset ( ) . left + d . threshold + a ( c ) . width ( ) } , a . inviewport = function ( b , c ) { return ! a . rightofscreen ( b , c ) && ! a . leftofscreen ( b , c ) && ! a . belowthefold ( b , c ) && ! a . abovethetop ( b , c ) } , a . extend ( a . expr [ ":" ] , { "below-the-fold" : function ( c ) { return a . belowthefold ( c , { threshold : 0 , container : b } ) } , "above-the-top" : function ( c ) { return ! a . belowthefold ( c , { threshold : 0 , container : b } ) } , "right-of-screen" : function ( c ) { return a . rightoffold ( c , { threshold : 0 , container : b } ) } , "left-of-screen" : function ( c ) { return ! a . rightoffold ( c , { threshold : 0 , container : b } ) } , "in-viewport" : function ( c ) { return ! a . inviewport ( c , { threshold : 0 , container : b } ) } , "above-the-fold" : function ( c ) { return ! a . belowthefold ( c , { threshold : 0 , container : b } ) } , "right-of-fold" : function ( c ) { return a . rightoffold ( c , { threshold : 0 , container : b } ) } , "left-of-fold" : function ( c ) { return ! a . rightoffold ( c , { threshold : 0 , container : b } ) } } ) } ) ( jQuery , window )
/**/
/ * !
* jQuery Cookie Plugin v1 . 3
* https : //github.com/carhartl/jquery-cookie
*
* Copyright 2011 , Klaus Hartl
* Dual licensed under the MIT or GPL Version 2 licenses .
* http : //www.opensource.org/licenses/mit-license.php
* http : //www.opensource.org/licenses/GPL-2.0
* /
( function ( $ , document , undefined ) {
var pluses = /\+/g ;
function raw ( s ) {
return s ;
}
function decoded ( s ) {
return decodeURIComponent ( s . replace ( pluses , ' ' ) ) ;
}
var config = $ . cookie = function ( key , value , options ) {
// write
if ( value !== undefined ) {
options = $ . extend ( { } , config . defaults , options ) ;
if ( value === null ) {
options . expires = - 1 ;
}
if ( typeof options . expires === 'number' ) {
var days = options . expires , t = options . expires = new Date ( ) ;
t . setDate ( t . getDate ( ) + days ) ;
}
value = config . json ? JSON . stringify ( value ) : String ( value ) ;
return ( document . cookie = [
encodeURIComponent ( key ) , '=' , config . raw ? value : encodeURIComponent ( value ) ,
options . expires ? '; expires=' + options . expires . toUTCString ( ) : '' , // use expires attribute, max-age is not supported by IE
options . path ? '; path=' + options . path : '' ,
options . domain ? '; domain=' + options . domain : '' ,
options . secure ? '; secure' : ''
] . join ( '' ) ) ;
}
// read
var decode = config . raw ? raw : decoded ;
var cookies = document . cookie . split ( '; ' ) ;
for ( var i = 0 , l = cookies . length ; i < l ; i ++ ) {
var parts = cookies [ i ] . split ( '=' ) ;
if ( decode ( parts . shift ( ) ) === key ) {
var cookie = decode ( parts . join ( '=' ) ) ;
return config . json ? JSON . parse ( cookie ) : cookie ;
}
}
return null ;
} ;
config . defaults = { } ;
$ . removeCookie = function ( key , options ) {
if ( $ . cookie ( key ) !== null ) {
$ . cookie ( key , null , options ) ;
return true ;
}
return false ;
} ;
} ) ( jQuery , document ) ;
/ * *
* Снежок
* http : //www.jqueryrain.com/?kn4rXFeL
* /
Date . now || ( Date . now = function ( ) { return ( new Date ) . getTime ( ) } ) , function ( ) { "use strict" ; for ( var t = [ "webkit" , "moz" ] , e = 0 ; e < t . length && ! window . requestAnimationFrame ; ++ e ) { var i = t [ e ] ; window . requestAnimationFrame = window [ i + "RequestAnimationFrame" ] , window . cancelAnimationFrame = window [ i + "CancelAnimationFrame" ] || window [ i + "CancelRequestAnimationFrame" ] } if ( /iP(ad|hone|od).*OS 6/ . test ( window . navigator . userAgent ) || ! window . requestAnimationFrame || ! window . cancelAnimationFrame ) { var s = 0 ; window . requestAnimationFrame = function ( t ) { var e = Date . now ( ) , i = Math . max ( s + 16 , e ) ; return setTimeout ( function ( ) { t ( s = i ) } , i - e ) } , window . cancelAnimationFrame = clearTimeout } } ( ) , function ( t ) { t . snowfall = function ( e , i ) { function s ( s , n , a , o ) { this . x = s , this . y = n , this . size = a , this . speed = o , this . step = 0 , this . stepSize = h ( 1 , 10 ) / 100 , i . collection && ( this . target = m [ h ( 0 , m . length - 1 ) ] ) ; var r = null ; i . image ? ( r = document . createElement ( "img" ) , r . src = i . image ) : ( r = document . createElement ( "div" ) , t ( r ) . css ( { background : i . flakeColor } ) ) , t ( r ) . attr ( { "class" : "snowfall-flakes" } ) . css ( { width : this . size , height : this . size , position : i . flakePosition , top : this . y , left : this . x , fontSize : 0 , zIndex : i . flakeIndex } ) , t ( e ) . get ( 0 ) . tagName === t ( document ) . get ( 0 ) . tagName ? ( t ( "body" ) . append ( t ( r ) ) , e = t ( "body" ) ) : t ( e ) . append ( t ( r ) ) , this . element = r , this . update = function ( ) { if ( this . y += this . speed , this . y > l - ( this . size + 6 ) && this . reset ( ) , this . element . style . top = this . y + "px" , this . element . style . left = this . x + "px" , this . step += this . stepSize , this . x += y === ! 1 ? Math . cos ( this . step ) : y + Math . cos ( this . step ) , i . collection && this . x > this . target . x && this . x < this . target . width + this . target . x && this . y > this . target . y && this . y < this . target . height + this . target . y ) { var t = this . target . element . getContext ( "2d" ) , e = this . x - this . target . x , s = this . y - this . target . y , n = this . target . colData ; if ( void 0 !== n [ parseInt ( e ) ] [ parseInt ( s + this . speed + this . size ) ] || s + this . speed + this . size > this . target . height ) if ( s + this . speed + this . size > this . target . height ) { for ( ; s + this . speed + this . size > this . target . height && this . speed > 0 ; ) this . speed *= . 5 ; t . fillStyle = "#fff" , void 0 == n [ parseInt ( e ) ] [ parseInt ( s + this . speed + this . size ) ] ? ( n [ parseInt ( e ) ] [ parseInt ( s + this . speed + this . size ) ] = 1 , t . fillRect ( e , s + this . speed + this . size , this . size , this . size ) ) : ( n [ parseInt ( e ) ] [ parseInt ( s + this . speed ) ] = 1 , t . fillRect ( e , s + this . speed , this . size , this . size ) ) , this . reset ( ) } else this . speed = 1 , this . stepSize = 0 , parseInt ( e ) + 1 < this . target . width && void 0 == n [ parseInt ( e ) + 1 ] [ parseInt ( s ) + 1 ] ? this . x ++ : parseInt ( e ) - 1 > 0 && void 0 == n [ parseInt ( e ) - 1 ] [ parseInt ( s ) + 1 ] ? this . x -- : ( t . fillStyle = "#fff" , t . fillRect ( e , s , this . size , this . size ) , n [ parseInt ( e ) ] [ parseInt ( s ) ] = 1 , this . reset ( ) ) } ( this . x + this . size > d - c || this . x < c ) && this . reset ( ) } , this . reset = function ( ) { this . y = 0 , this . x = h ( c , d - c ) , this . stepSize = h ( 1 , 10 ) / 100 , this . size = h ( 100 * i . minSize , 100 * i . maxSize ) / 100 , this . element . style . width = this . size + "px" , this . element . style . height = this . size + "px" , this . speed = h ( i . minSpeed , i . maxSpeed ) } } function n ( ) { for ( r = 0 ; r < a . length ; r += 1 ) a [ r ] . update ( ) ; f = requestAnimationFrame ( function ( ) { n ( ) } ) } var a = [ ] , o = { flakeCount : 35 , flakeColor : "#ffffff" , flakePosition : "absolute" , flakeIndex : 999999 , minSize : 1 , maxSize : 2 , minSpeed : 1 , maxSpeed : 5 , round : ! 1 , shadow : ! 1 , collection : ! 1 , collectionHeight : 40 , deviceorientation : ! 1 } , i = t . extend ( o , i ) , h = function ( t , e ) { return Math . round ( t + Math . random ( ) * ( e - t ) ) } ; t ( e ) . data ( "snowfall" , this ) ; var r = 0 , l = t ( e ) . height ( ) , d = t ( e ) . width ( ) , c = 0 , f = 0 ; if ( i . collection !== ! 1 ) { var p = document . createElement ( "canvas" ) ; if ( p . getContext && p . getContext ( "2d" ) ) for ( var m = [ ] , w = t ( i . collection ) , g = i . collectionHeight , r = 0 ; r < w . length ; r ++ ) { var u = w [ r ] . getBoundingClientRect ( ) , x = t ( "<canvas/>" , { "class" : "snowfall-canvas" } ) , z = [ ] ; if ( u . top - g > 0 ) { t ( "body" ) . append ( x ) , x . css ( { position : i . flakePosition , left : u . left + "px" , top : u . top - g + "px" } ) . prop ( { width : u . width , height : g } ) ; for ( var v = 0 ; v < u . width ; v ++ ) z [ v ] = [ ] ; m . push ( { element : x . get ( 0 ) , x : u . left , y : u . top - g , width : u . width , height : g , colData : z } ) } } else i . collection = ! 1 } for ( t ( e ) . get ( 0 ) . tagName === t ( document ) . get ( 0 ) . tagName && ( c = 25 ) , t ( window ) . bind ( "resize" , function ( ) { l = t ( e ) [ 0 ] . clientHeight , d = t ( e ) [ 0 ] . offsetWidth } ) , r = 0 ; r < i . flakeCount ; r += 1 ) a . push ( new s ( h ( c , d - c ) , h ( 0 , l ) , h ( 100 * i . minSize , 100 * i . maxSize ) / 100 , h ( i . minSpeed , i . maxSpeed ) ) ) ; i . round && t ( ".snowfall-flakes" ) . css ( { "-moz-border-radius" : i . maxSize , " - w
/ *
* jQuery Tooltip plugin 1.3
*
* http : //bassistance.de/jquery-plugins/jquery-plugin-tooltip/
* http : //docs.jquery.com/Plugins/Tooltip
*
* Copyright ( c ) 2006 - 2008 JГ ¶ rn Zaefferer
*
* $Id : jquery . tooltip . js 5741 2008 - 06 - 21 15 : 22 : 16 Z joern . zaefferer $
*
* Dual licensed under the MIT and GPL licenses :
* http : //www.opensource.org/licenses/mit-license.php
* http : //www.gnu.org/licenses/gpl.html
* /
; ( function ( $ ) {
// the tooltip element
var helper = { } ,
// the current tooltipped element
current ,
// the title of the current element, used for restoring
title ,
// timeout id for delayed tooltips
tID ,
// IE 5.5 or 6
IE = $ . browser . msie && /MSIE\s(5\.5|6\.)/ . test ( navigator . userAgent ) ,
// flag for mouse tracking
track = false ;
$ . tooltip = {
blocked : false ,
defaults : {
delay : 200 ,
fade : false ,
showURL : true ,
extraClass : "" ,
top : 15 ,
left : 15 ,
id : "tooltip"
} ,
block : function ( ) {
$ . tooltip . blocked = ! $ . tooltip . blocked ;
}
} ;
$ . fn . extend ( {
tooltip : function ( settings ) {
settings = $ . extend ( { } , $ . tooltip . defaults , settings ) ;
createHelper ( settings ) ;
return this . each ( function ( ) {
$ . data ( this , "tooltip" , settings ) ;
this . tOpacity = helper . parent . css ( "opacity" ) ;
// copy tooltip into its own expando and remove the title
this . tooltipText = this . title ;
$ ( this ) . attr ( "title" , '' ) ;
//$(this).removeAttr("title"); # в ИЕ не проходит удаление и вылазит всплываха (delegate)
// also remove alt attribute to prevent default tooltip in IE
this . alt = "" ;
} )
. mouseover ( save )
. mouseout ( hide )
. click ( hide ) ;
} ,
fixPNG : IE ? function ( ) {
return this . each ( function ( ) {
var image = $ ( this ) . css ( 'backgroundImage' ) ;
if ( image . match ( /^url\(["']?(.*\.png)["']?\)$/i ) ) {
image = RegExp . $1 ;
$ ( this ) . css ( {
'backgroundImage' : 'none' ,
'filter' : "progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true, sizingMethod=crop, src='" + image + "')"
} ) . each ( function ( ) {
var position = $ ( this ) . css ( 'position' ) ;
if ( position != 'absolute' && position != 'relative' )
$ ( this ) . css ( 'position' , 'relative' ) ;
} ) ;
}
} ) ;
} : function ( ) { return this ; } ,
unfixPNG : IE ? function ( ) {
return this . each ( function ( ) {
$ ( this ) . css ( { 'filter' : '' , backgroundImage : '' } ) ;
} ) ;
} : function ( ) { return this ; } ,
hideWhenEmpty : function ( ) {
return this . each ( function ( ) {
$ ( this ) [ $ ( this ) . html ( ) ? "show" : "hide" ] ( ) ;
} ) ;
} ,
url : function ( ) {
return this . attr ( 'href' ) || this . attr ( 'src' ) ;
} ,
tooltipShow : function ( event ) {
return this . each ( function ( ) {
save . call ( this , event ) ;
} ) ;
}
} ) ;
function createHelper ( settings ) {
// there can be only one tooltip helper
if ( helper . parent )
return ;
// create the helper, h3 for title, div for url
helper . parent = $ ( '<div id="' + settings . id + '"><h3></h3><div class="body"></div><div class="url"></div></div>' )
// add to document
. appendTo ( document . body )
// hide it at first
. hide ( ) ;
// apply bgiframe if available
if ( $ . fn . bgiframe )
helper . parent . bgiframe ( ) ;
// save references to title and url elements
helper . title = $ ( 'h3' , helper . parent ) ;
helper . body = $ ( 'div.body' , helper . parent ) ;
helper . url = $ ( 'div.url' , helper . parent ) ;
}
function settings ( element ) {
return $ . data ( element , "tooltip" ) ;
}
// main event handler to start showing tooltips
function handle ( event ) {
// show helper, either with timeout or on instant
if ( settings ( this ) . delay )
tID = setTimeout ( show , settings ( this ) . delay ) ;
else
show ( ) ;
// if selected, update the helper position when the mouse moves
track = ! ! settings ( this ) . track ;
if ( ! $ . browser . msie ) { // FIXME: !!!
$ ( document . body ) . bind ( 'mousemove' , update ) ;
}
// update at least once
update ( event ) ;
}
// save elements title before the tooltip is displayed
function save ( ) {
// if this is the current source, or it has no title (occurs with click event), stop
if ( $ . tooltip . blocked || this == current || ( ! this . tooltipText && ! settings ( this ) . bodyHandler ) )
return ;
// save current
current = this ;
title = this . tooltipText ;
if ( settings ( this ) . bodyHandler ) {
helper . title . hide ( ) ;
var bodyContent = settings ( this ) . bodyHandler . call ( this ) ;
if ( bodyContent . nodeType || bodyContent . jquery ) {
helper . body . empty ( ) . append ( bodyContent )
} else {
helper . body . html ( bodyContent ) ;
}
helper . body . show ( ) ;
} else if ( settings ( this ) . showBody ) {
var parts = title . split ( settings ( this ) . showBody ) ;
helper . title . text ( parts . shift ( ) ) . show ( ) ;
helper . body . empty ( ) ;
for ( var i in parts ) {
$ ( '<div class=part>' ) . text ( parts [ i ] ) . appendTo ( helper . body ) ;
}
helper . body . hideWhenEmpty ( ) ;
} else {
helper . title . text ( title ) . show ( ) ;
helper . body . hide ( ) ;
}
// if element has href or src, add and show it, otherwise hide it
if ( settings ( this ) . showURL && $ ( this ) . url ( ) )
helper . url . html ( $ ( this ) . url ( ) . replace ( 'http://' , '' ) ) . show ( ) ;
else
helper . url . hide ( ) ;
var a = settings ( this ) . extraClass ;
// add an optional class for this tip
helper . parent . addClass ( a ) ;
// fix PNG background for IE
if ( settings ( this ) . fixPNG )
helper . parent . fixPNG ( ) ;
handle . apply ( this , arguments ) ;
}
// delete timeout and show helper
function show ( ) {
tID = null ;
if ( ( ! IE || ! $ . fn . bgiframe ) && settings ( current ) . fade ) {
if ( helper . parent . is ( ":animated" ) )
helper . parent . stop ( ) . show ( ) . fadeTo ( settings ( current ) . fade , current . tOpacity ) ;
else
helper . parent . is ( ':visible' ) ? helper . parent . fadeTo ( settings ( current ) . fade , current . tOpacity ) : helper . parent . fadeIn ( settings ( current ) . fade ) ;
} else {
helper . parent . show ( ) ;
}
update ( ) ;
}
/ * *
* callback for mousemove
* updates the helper position
* removes itself when no current element
* /
function update ( event ) {
if ( $ . tooltip . blocked )
return ;
if ( event && event . target . tagName == "OPTION" ) {
return ;
}
// stop updating when tracking is disabled and the tooltip is visible
if ( ! track && helper . parent . is ( ":visible" ) ) {
$ ( document . body ) . unbind ( 'mousemove' , update )
}
// if no current element is available, remove this listener
if ( current == null ) {
$ ( document . body ) . unbind ( 'mousemove' , update ) ;
return ;
}
// remove position helper classes
helper . parent . removeClass ( "viewport-right" ) . removeClass ( "viewport-bottom" ) ;
var left = helper . parent [ 0 ] . offsetLeft ;
var top = helper . parent [ 0 ] . offsetTop ;
if ( event ) {
// position the helper 15 pixel to bottom right, starting from mouse position
left = event . pageX + settings ( current ) . left ;
top = event . pageY + settings ( current ) . top ;
var right = 'auto' ;
if ( settings ( current ) . positionLeft ) {
right = $ ( window ) . width ( ) - left ;
left = 'auto' ;
}
helper . parent . css ( {
left : left ,
right : right ,
top : top
} ) ;
}
var v = viewport ( ) ,
h = helper . parent [ 0 ] ;
// check horizontal position
if ( v . x + v . cx < h . offsetLeft + h . offsetWidth ) {
left -= h . offsetWidth + 20 + settings ( current ) . left ;
helper . parent . css ( { left : left + 'px' } ) . addClass ( "viewport-right" ) ;
}
// check vertical position
if ( v . y + v . cy < h . offsetTop + h . offsetHeight ) {
top -= h . offsetHeight + 20 + settings ( current ) . top ;
helper . parent . css ( { top : top + 'px' } ) . addClass ( "viewport-bottom" ) ;
}
}
function viewport ( ) {
return {
x : $ ( window ) . scrollLeft ( ) ,
y : $ ( window ) . scrollTop ( ) ,
cx : $ ( window ) . width ( ) ,
cy : $ ( window ) . height ( )
} ;
}
// hide helper and restore added classes and the title
function hide ( event ) {
if ( $ . tooltip . blocked )
return ;
// clear timeout if possible
if ( tID )
clearTimeout ( tID ) ;
// no more current element
current = null ;
var tsettings = settings ( this ) ;
function complete ( ) {
helper . parent . removeClass ( tsettings . extraClass ) . hide ( ) . css ( "opacity" , "" ) ;
}
if ( ( ! IE || ! $ . fn . bgiframe ) && tsettings . fade ) {
if ( helper . parent . is ( ':animated' ) )
helper . parent . stop ( ) . fadeTo ( tsettings . fade , 0 , complete ) ;
else
helper . parent . stop ( ) . fadeOut ( tsettings . fade , complete ) ;
} else
complete ( ) ;
if ( settings ( this ) . fixPNG )
helper . parent . unfixPNG ( ) ;
}
//DONE -oAndryG -cjquery.plugin: MODIFIED! переопределены значения по умолчанию
$ . tooltip . defaults . showURL = false ;
$ . tooltip . defaults . track = true ;
} ) ( jQuery ) ;
/ * *
* stickyfloat - jQuery plugin for verticaly floating anything in a constrained area
* @ version Version 7.3
* @ author Yair Even - Or ( vsync )
* @ copyright Copyright ( c ) 2012
* @ license MIT and GPL licenses .
* @ link http : //dropthebit.com
*
* * /
( function ( f ) { var l = window , k = document , e , i , d , m , h , g , c = { duration : 200 , lockBottom : true , delay : 0 , easing : "linear" , stickToBottom : false , cssTransition : false } , a = ( function ( ) { var o , p = k . createElement ( "div" ) , n = [ "ms" , "O" , "Moz" , "Webkit" ] , q = "transition" ; if ( p [ q ] == "" ) { return true } q = q . charAt ( 0 ) . toUpperCase ( ) + q . slice ( 1 ) ; for ( o = n . length ; o -- ; ) { if ( p [ n [ o ] + q ] == "" ) { return true } } return false } ) ( ) , b = function ( n , o ) { this . settings = n ; this . obj = f ( o ) } ; b . prototype = { init : function ( ) { var n = this ; this . onScroll = function ( ) { n . rePosition ( ) } ; f ( l ) . ready ( function ( ) { n . rePosition ( true ) ; f ( l ) . on ( "scroll.sticky" , n . onScroll ) } ) ; this . obj . data ( "_stickyfloat" , n ) } , rePosition : function ( t , q ) { var u = this . obj , p = this . settings , s = t ? 0 : p . duration , o = l . pageYOffset || k . documentElement . scrollTop , n = l . innerHeight || k . documentElement . offsetHeight , r = u [ 0 ] . clientHeight ; u . stop ( ) ; if ( p . lockBottom ) { e = u [ 0 ] . parentNode . clientHeight - r - p . offsetBottom } if ( e < 0 ) { e = 0 } d = o > p . startOffset ; m = u . offset ( ) . top > ( p . startOffset + p . offsetY ) ; h = r < n ; if ( ( d || m && h ) || q ) { g = p . stickToBottom ? o + n - r - p . startOffset - p . offsetY : o - p . startOffset + p . offsetY ; if ( g > e && p . lockBottom ) { g = e } if ( g < p . offsetY ) { g = p . offsetY } else { if ( o < p . startOffset && ! p . stickToBottom ) { g = p . offsetY } } if ( s < 5 || ( p . cssTransition && a ) ) { u [ 0 ] . style . top = g + "px" } else { u . stop ( ) . delay ( p . delay ) . animate ( { top : g } , s , p . easing ) } } } , update : function ( n ) { if ( typeof n === "object" ) { if ( ! n . offsetY || n . offsetY == "auto" ) { n . offsetY = j ( this . obj ) . offsetY } if ( ! n . startOffset || n . startOffset == "auto" ) { n . startOffset = j ( this . obj ) . startOffset } this . settings = f . extend ( { } , this . settings , n ) ; this . rePosition ( false , true ) } return this . obj } , destroy : function ( ) { f ( window ) . off ( "scroll.sticky" , this . onScroll ) ; this . obj . removeData ( ) ; return this . obj } } ; function j ( q ) { var o = parseInt ( q . parent ( ) . css ( "padding-bottom" ) ) , n = parseInt ( q . parent ( ) . css ( "padding-top" ) ) , p = q . parent ( ) . offset ( ) . top ; return { startOffset : p , offsetBottom : o , offsetY : n } } f . fn . stickyfloat = function ( o , n ) { if ( typeof o === "object" ) { n = o } else { if ( typeof o === "string" ) { if ( this . data ( "_stickyfloat" ) && typeof this . data ( "_stickyfloat" ) [ o ] == "function" ) { var p = this . data ( "_stickyfloat" ) ; return p [ o ] ( n ) } else { return this } } } return this . each ( function ( ) { var s = f ( this ) , q = f . extend ( { } , c , j ( s ) , n || { } ) ; var r = new b ( q , s ) ; r . init ( ) } ) } } ) ( jQuery ) ;
/*! qtip2 v2.0.0 | http://craigsworks.com/projects/qtip2/ | Licensed MIT, GPL */
( function ( e , t , n ) { ( function ( e ) { "use strict" ; typeof define == "function" && define . amd ? define ( [ "jquery" ] , e ) : jQuery && ! jQuery . fn . qtip && e ( jQuery ) } ) ( function ( r ) { function _ ( n ) { E = { pageX : n . pageX , pageY : n . pageY , type : "mousemove" , scrollX : e . pageXOffset || t . body . scrollLeft || t . documentElement . scrollLeft , scrollY : e . pageYOffset || t . body . scrollTop || t . documentElement . scrollTop } } function D ( e ) { var t = function ( e ) { return e === o || "object" != typeof e } , n = function ( e ) { return ! r . isFunction ( e ) && ( ! e && ! e . attr || e . length < 1 || "object" == typeof e && ! e . jquery && ! e . then ) } ; if ( ! e || "object" != typeof e ) return s ; t ( e . metadata ) && ( e . metadata = { type : e . metadata } ) ; if ( "content" in e ) { if ( t ( e . content ) || e . content . jquery ) e . content = { text : e . content } ; n ( e . content . text || s ) && ( e . content . text = s ) , "title" in e . content && ( t ( e . content . title ) && ( e . content . title = { text : e . content . title } ) , n ( e . content . title . text || s ) && ( e . content . title . text = s ) ) } return "position" in e && t ( e . position ) && ( e . position = { my : e . position , at : e . position } ) , "show" in e && t ( e . show ) && ( e . show = e . show . jquery ? { target : e . show } : { event : e . show } ) , "hide" in e && t ( e . hide ) && ( e . hide = e . hide . jquery ? { target : e . hide } : { event : e . hide } ) , "style" in e && t ( e . style ) && ( e . style = { classes : e . style } ) , r . each ( w , function ( ) { this . sanitize && this . sanitize ( e ) } ) , e } function P ( u , a , f , l ) { function q ( e ) { var t = 0 , n , r = a , i = e . split ( "." ) ; while ( r = r [ i [ t ++ ] ] ) t < i . length && ( n = r ) ; return [ n || a , i . pop ( ) ] } function R ( e ) { return T . concat ( "" ) . join ( e ? "-" + e + " " : " " ) } function U ( ) { var e = a . style . widget , t = H . hasClass ( j ) ; H . removeClass ( j ) , j = e ? "ui-state-disabled" : "qtip-disabled" , H . toggleClass ( j , t ) , H . toggleClass ( "ui-helper-reset " + R ( ) , e ) . toggleClass ( C , a . style . def && ! e ) , F . content && F . content . toggleClass ( R ( "content" ) , e ) , F . titlebar && F . titlebar . toggleClass ( R ( "header" ) , e ) , F . button && F . button . toggleClass ( S + "-icon" , ! e ) } function z ( e ) { F . title && ( F . titlebar . remove ( ) , F . titlebar = F . title = F . button = o , e !== s && m . reposition ( ) ) } function W ( ) { var e = a . content . title . button , t = typeof e == "string" , n = t ? e : "Close tooltip" ; F . button && F . button . remove ( ) , e . jquery ? F . button = e : F . button = r ( "<a />" , { "class" : "qtip-close " + ( a . style . widget ? "" : S + "-icon" ) , title : n , "aria-label" : n } ) . prepend ( r ( "<span />" , { "class" : "ui-icon ui-icon-close" , html : "×" } ) ) , F . button . appendTo ( F . titlebar || H ) . attr ( "role" , "button" ) . click ( function ( e ) { return H . hasClass ( j ) || m . hide ( e ) , s } ) } function X ( ) { var e = y + "-title" ; F . titlebar && z ( ) , F . titlebar = r ( "<div />" , { "class" : S + "-titlebar " + ( a . style . widget ? R ( "header" ) : "" ) } ) . append ( F . title = r ( "<div />" , { id : e , "class" : S + "-title" , "aria-atomic" : i } ) ) . insertBefore ( F . content ) . delegate ( ".qtip-close" , "mousedown keydown mouseup keyup mouseout" , function ( e ) { r ( this ) . toggleClass ( "ui-state-active ui-state-focus" , e . type . substr ( - 4 ) === "down" ) } ) . delegate ( ".qtip-close" , "mouseover mouseout" , function ( e ) { r ( this ) . toggleClass ( "ui-state-hover" , e . type === "mouseover" ) } ) , a . content . title . button && W ( ) } function V ( e ) { var t = F . button ; if ( ! m . rendered ) return s ; e ? W ( ) : t . remove ( ) } function J ( e , t ) { var n = F . title ; if ( ! m . rendered || ! e ) return s ; r . isFunction ( e ) && ( e = e . call ( u , I . event , m ) ) ; if ( e === s || ! e && e !== "" ) return z ( s ) ; e . jquery && e . length > 0 ? n . empty ( ) . append ( e . css ( { display : "block" } ) ) : n . html ( e ) , t !== s && m . rendered && H [ 0 ] . offsetWidth > 0 && m . reposition ( I . event ) } function K ( e ) { e && r . isFunction ( e . done ) && e . done ( function ( e ) { Q ( e , null , s ) } ) } function Q ( e , t , i ) { function f ( e ) { function a ( n ) { n && ( delete u [ n . src ] , clearTimeout ( m . timers . img [ n . src ] ) , r ( n ) . unbind ( B ) ) , r . isEmptyObject ( u ) && ( t !== s && m . reposition ( I . event ) , e ( ) ) } var i , u = { } ; if ( ( i = o . find ( "img[src]:not([height]):not([width])" ) ) . length === 0 ) return a ( ) ; i . each ( function ( e , t ) { if ( u [ t . src ] !== n ) return ; var i = 0 , s = 3 ; ( function o ( ) { if ( t . height || t . width || i > s ) return a ( t ) ; i += 1 , m . timers . img [ t . src ] = setTimeout ( o , 700 ) } ) ( ) , r ( t ) . bind ( "error" + B + " load" + B , function ( ) { a ( this ) } ) , u [ t . src ] = t } ) } var o = F . content ; return ! m . rendered || ! e ? s : ( r . isFunction ( e ) && ( e = e . call ( u , I . event , m ) || "" ) , i !== s && K ( a . content . deferred ) , e . jquery && e . length > 0 ? o . empty ( ) . append ( e . css ( { display : "block" } ) ) : o . html ( e ) , m . rendered < 0 ? H . queue ( "fx" , f ) : ( P = 0 , f ( r . noop ) ) , m ) } function G ( ) { function h ( e ) { if ( H . hasClass ( j ) ) return s ; clearTimeout ( m . timers . show ) , clearTimeout ( m . timers . hide ) ; var t = function ( ) { m . toggle ( i , e ) } ; a . show . delay > 0 ? m . timers . show = setTimeout ( t , a . show . delay ) : t ( ) } function p ( e )
/*! jQuery JSON plugin 2.4.0 | code.google.com/p/jquery-json */
( function ( $ ) { 'use strict' ; var escape = /["\\\x00-\x1f\x7f-\x9f]/g , meta = { '\b' : '\\b' , '\t' : '\\t' , '\n' : '\\n' , '\f' : '\\f' , '\r' : '\\r' , '"' : '\\"' , '\\' : '\\\\' } , hasOwn = Object . prototype . hasOwnProperty ; $ . toJSON = typeof JSON === 'object' && JSON . stringify ? JSON . stringify : function ( o ) { if ( o === null ) { return 'null' ; }
var pairs , k , name , val , type = $ . type ( o ) ; if ( type === 'undefined' ) { return undefined ; }
if ( type === 'number' || type === 'boolean' ) { return String ( o ) ; }
if ( type === 'string' ) { return $ . quoteString ( o ) ; }
if ( typeof o . toJSON === 'function' ) { return $ . toJSON ( o . toJSON ( ) ) ; }
if ( type === 'date' ) { var month = o . getUTCMonth ( ) + 1 , day = o . getUTCDate ( ) , year = o . getUTCFullYear ( ) , hours = o . getUTCHours ( ) , minutes = o . getUTCMinutes ( ) , seconds = o . getUTCSeconds ( ) , milli = o . getUTCMilliseconds ( ) ; if ( month < 10 ) { month = '0' + month ; }
if ( day < 10 ) { day = '0' + day ; }
if ( hours < 10 ) { hours = '0' + hours ; }
if ( minutes < 10 ) { minutes = '0' + minutes ; }
if ( seconds < 10 ) { seconds = '0' + seconds ; }
if ( milli < 100 ) { milli = '0' + milli ; }
if ( milli < 10 ) { milli = '0' + milli ; }
return '"' + year + '-' + month + '-' + day + 'T' +
hours + ':' + minutes + ':' + seconds + '.' + milli + 'Z"' ; }
pairs = [ ] ; if ( $ . isArray ( o ) ) { for ( k = 0 ; k < o . length ; k ++ ) { pairs . push ( $ . toJSON ( o [ k ] ) || 'null' ) ; }
return '[' + pairs . join ( ',' ) + ']' ; }
if ( typeof o === 'object' ) { for ( k in o ) { if ( hasOwn . call ( o , k ) ) { type = typeof k ; if ( type === 'number' ) { name = '"' + k + '"' ; } else if ( type === 'string' ) { name = $ . quoteString ( k ) ; } else { continue ; }
type = typeof o [ k ] ; if ( type !== 'function' && type !== 'undefined' ) { val = $ . toJSON ( o [ k ] ) ; pairs . push ( name + ':' + val ) ; } } }
return '{' + pairs . join ( ',' ) + '}' ; } } ; $ . evalJSON = typeof JSON === 'object' && JSON . parse ? JSON . parse : function ( str ) { return eval ( '(' + str + ')' ) ; } ; $ . secureEvalJSON = typeof JSON === 'object' && JSON . parse ? JSON . parse : function ( str ) { var filtered = str . replace ( /\\["\\\/bfnrtu]/g , '@' ) . replace ( /"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g , ']' ) . replace ( /(?:^|:|,)(?:\s*\[)+/g , '' ) ; if ( /^[\],:{}\s]*$/ . test ( filtered ) ) { return eval ( '(' + str + ')' ) ; }
throw new SyntaxError ( 'Error parsing JSON, source is not valid.' ) ; } ; $ . quoteString = function ( str ) { if ( str . match ( escape ) ) { return '"' + str . replace ( escape , function ( a ) { var c = meta [ a ] ; if ( typeof c === 'string' ) { return c ; }
c = a . charCodeAt ( ) ; return '\\u00' + Math . floor ( c / 16 ) . toString ( 16 ) + ( c % 16 ) . toString ( 16 ) ; } ) + '"' ; }
return '"' + str + '"' ; } ; } ( jQuery ) ) ;
/* Наше допиливание jQuery :) */
// Установка заголовка для ajax-запросов, дабы различать на сервере, что хочет получить браузер.
$ . ajaxPrefilter ( function ( options , originalOptions , jqXHR ) {
if ( options . headers ) {
options . headers [ 'X-Requested-With' ] = options . dataType ;
} else {
options . headers = { 'X-Requested-With' : options . dataType } ;
}
} ) ;
/ * ! !
* Title Alert 0.7
*
* Copyright ( c ) 2009 ESN | http : //esn.me
* Jonatan Heyman | http : //heyman.info
*
* /
; ( function ( $ ) {
$ . titleAlert = function ( text , settings ) {
// check if it currently flashing something, if so reset it
if ( $ . titleAlert . _running )
$ . titleAlert . stop ( ) ;
// override default settings with specified settings
$ . titleAlert . _settings = settings = $ . extend ( { } , $ . titleAlert . defaults , settings ) ;
// if it's required that the window doesn't have focus, and it has, just return
if ( settings . requireBlur && $ . titleAlert . hasFocus )
return ;
// originalTitleInterval defaults to interval if not set
settings . originalTitleInterval = settings . originalTitleInterval || settings . interval ;
$ . titleAlert . _running = true ;
$ . titleAlert . _initialText = document . title ;
document . title = text ;
var showingAlertTitle = true ;
var switchTitle = function ( ) {
// WTF! Sometimes Internet Explorer 6 calls the interval function an extra time!
if ( ! $ . titleAlert . _running )
return ;
showingAlertTitle = ! showingAlertTitle ;
document . title = ( showingAlertTitle ? text : $ . titleAlert . _initialText ) ;
$ . titleAlert . _intervalToken = setTimeout ( switchTitle , ( showingAlertTitle ? settings . interval : settings . originalTitleInterval ) ) ;
}
$ . titleAlert . _intervalToken = setTimeout ( switchTitle , settings . interval ) ;
if ( settings . stopOnMouseMove ) {
$ ( document ) . mousemove ( function ( event ) {
$ ( this ) . unbind ( event ) ;
$ . titleAlert . stop ( ) ;
} ) ;
}
// check if a duration is specified
if ( settings . duration > 0 ) {
$ . titleAlert . _timeoutToken = setTimeout ( function ( ) {
$ . titleAlert . stop ( ) ;
} , settings . duration ) ;
}
} ;
// default settings
$ . titleAlert . defaults = {
interval : 500 ,
originalTitleInterval : null ,
duration : 0 ,
stopOnFocus : true ,
requireBlur : false ,
stopOnMouseMove : false
} ;
// stop current title flash
$ . titleAlert . stop = function ( ) {
if ( ! $ . titleAlert . _running )
return ;
clearTimeout ( $ . titleAlert . _intervalToken ) ;
clearTimeout ( $ . titleAlert . _timeoutToken ) ;
document . title = $ . titleAlert . _initialText ;
$ . titleAlert . _timeoutToken = null ;
$ . titleAlert . _intervalToken = null ;
$ . titleAlert . _initialText = null ;
$ . titleAlert . _running = false ;
$ . titleAlert . _settings = null ;
}
$ . titleAlert . hasFocus = true ;
$ . titleAlert . _running = false ;
$ . titleAlert . _intervalToken = null ;
$ . titleAlert . _timeoutToken = null ;
$ . titleAlert . _initialText = null ;
$ . titleAlert . _settings = null ;
$ . titleAlert . _focus = function ( ) {
$ . titleAlert . hasFocus = true ;
if ( $ . titleAlert . _running && $ . titleAlert . _settings . stopOnFocus ) {
var initialText = $ . titleAlert . _initialText ;
$ . titleAlert . stop ( ) ;
// ugly hack because of a bug in Chrome which causes a change of document.title immediately after tab switch
// to have no effect on the browser title
setTimeout ( function ( ) {
if ( $ . titleAlert . _running )
return ;
document . title = "." ;
document . title = initialText ;
} , 1000 ) ;
}
} ;
$ . titleAlert . _blur = function ( ) {
$ . titleAlert . hasFocus = false ;
} ;
// bind focus and blur event handlers
$ ( window ) . bind ( "focus" , $ . titleAlert . _focus ) ;
$ ( window ) . bind ( "blur" , $ . titleAlert . _blur ) ;
} ) ( jQuery ) ;
/*jslint browser: true*/
/*jslint jquery: true*/
/ *
* jQuery Hotkeys Plugin
* Copyright 2010 , John Resig
* Dual licensed under the MIT or GPL Version 2 licenses .
*
* Based upon the plugin by Tzury Bar Yochay :
* https : //github.com/tzuryby/jquery.hotkeys
*
* Original idea by :
* Binny V A , http : //www.openjs.com/scripts/events/keyboard_shortcuts/
* /
/ *
* One small change is : now keys are passed by object { keys : '...' }
* Might be useful , when you want to pass some other data to your handler
* /
( function ( jQuery ) {
jQuery . hotkeys = {
version : "0.8" ,
specialKeys : {
8 : "backspace" ,
9 : "tab" ,
10 : "return" ,
13 : "return" ,
16 : "shift" ,
17 : "ctrl" ,
18 : "alt" ,
19 : "pause" ,
20 : "capslock" ,
27 : "esc" ,
32 : "space" ,
33 : "pageup" ,
34 : "pagedown" ,
35 : "end" ,
36 : "home" ,
37 : "left" ,
38 : "up" ,
39 : "right" ,
40 : "down" ,
45 : "insert" ,
46 : "del" ,
59 : ";" ,
61 : "=" ,
96 : "0" ,
97 : "1" ,
98 : "2" ,
99 : "3" ,
100 : "4" ,
101 : "5" ,
102 : "6" ,
103 : "7" ,
104 : "8" ,
105 : "9" ,
106 : "*" ,
107 : "+" ,
109 : "-" ,
110 : "." ,
111 : "/" ,
112 : "f1" ,
113 : "f2" ,
114 : "f3" ,
115 : "f4" ,
116 : "f5" ,
117 : "f6" ,
118 : "f7" ,
119 : "f8" ,
120 : "f9" ,
121 : "f10" ,
122 : "f11" ,
123 : "f12" ,
144 : "numlock" ,
145 : "scroll" ,
173 : "-" ,
186 : ";" ,
187 : "=" ,
188 : "," ,
189 : "-" ,
190 : "." ,
191 : "/" ,
192 : "`" ,
219 : "[" ,
220 : "\\" ,
221 : "]" ,
222 : "'"
} ,
shiftNums : {
"`" : "~" ,
"1" : "!" ,
"2" : "@" ,
"3" : "#" ,
"4" : "$" ,
"5" : "%" ,
"6" : "^" ,
"7" : "&" ,
"8" : "*" ,
"9" : "(" ,
"0" : ")" ,
"-" : "_" ,
"=" : "+" ,
";" : ": " ,
"'" : "\"" ,
"," : "<" ,
"." : ">" ,
"/" : "?" ,
"\\" : "|"
} ,
// excludes: button, checkbox, file, hidden, image, password, radio, reset, search, submit, url
textAcceptingInputTypes : [
"text" , "password" , "number" , "email" , "url" , "range" , "date" , "month" , "week" , "time" , "datetime" ,
"datetime-local" , "search" , "color" , "tel" ] ,
// default input types not to bind to unless bound directly
textInputTypes : /textarea|input|select/i ,
options : {
filterInputAcceptingElements : true ,
filterTextInputs : true ,
filterContentEditable : true
}
} ;
function keyHandler ( handleObj ) {
if ( typeof handleObj . data === "string" ) {
handleObj . data = {
keys : handleObj . data
} ;
}
// Only care when a possible input has been specified
if ( ! handleObj . data || ! handleObj . data . keys || typeof handleObj . data . keys !== "string" ) {
return ;
}
var origHandler = handleObj . handler ,
keys = handleObj . data . keys . toLowerCase ( ) . split ( " " ) ;
handleObj . handler = function ( event ) {
// Don't fire in text-accepting inputs that we didn't directly bind to
if ( this !== event . target &&
( jQuery . hotkeys . options . filterInputAcceptingElements &&
jQuery . hotkeys . textInputTypes . test ( event . target . nodeName ) ||
( jQuery . hotkeys . options . filterContentEditable && jQuery ( event . target ) . attr ( 'contenteditable' ) ) ||
( jQuery . hotkeys . options . filterTextInputs &&
jQuery . inArray ( event . target . type , jQuery . hotkeys . textAcceptingInputTypes ) > - 1 ) ) ) {
return ;
}
var special = event . type !== "keypress" && jQuery . hotkeys . specialKeys [ event . which ] ,
character = String . fromCharCode ( event . which ) . toLowerCase ( ) ,
modif = "" ,
possible = { } ;
jQuery . each ( [ "alt" , "ctrl" , "shift" ] , function ( index , specialKey ) {
if ( event [ specialKey + 'Key' ] && special !== specialKey ) {
modif += specialKey + '+' ;
}
} ) ;
// metaKey is triggered off ctrlKey erronously
if ( event . metaKey && ! event . ctrlKey && special !== "meta" ) {
modif += "meta+" ;
}
if ( event . metaKey && special !== "meta" && modif . indexOf ( "alt+ctrl+shift+" ) > - 1 ) {
modif = modif . replace ( "alt+ctrl+shift+" , "hyper+" ) ;
}
if ( special ) {
possible [ modif + special ] = true ;
}
else {
possible [ modif + character ] = true ;
possible [ modif + jQuery . hotkeys . shiftNums [ character ] ] = true ;
// "$" can be triggered as "Shift+4" or "Shift+$" or just "$"
if ( modif === "shift+" ) {
possible [ jQuery . hotkeys . shiftNums [ character ] ] = true ;
}
}
for ( var i = 0 , l = keys . length ; i < l ; i ++ ) {
if ( possible [ keys [ i ] ] ) {
return origHandler . apply ( this , arguments ) ;
}
}
} ;
}
jQuery . each ( [ "keydown" , "keyup" , "keypress" ] , function ( ) {
jQuery . event . special [ this ] = {
add : keyHandler
} ;
} ) ;
} ) ( jQuery || this . jQuery || window . jQuery ) ;
/ * *
* @ license MIT
* @ fileOverview Favico animations
* @ author Miroslav Magda , http : //blog.ejci.net
* @ version 0.3 . 9
* /
! function ( ) { var e = function ( e ) { "use strict" ; function t ( e ) { if ( e . paused || e . ended || g ) return ! 1 ; try { f . clearRect ( 0 , 0 , s , l ) , f . drawImage ( e , 0 , 0 , s , l ) } catch ( o ) { } p = setTimeout ( t , S . duration , e ) , O . setIcon ( h ) } function o ( e ) { var t = /^#?([a-f\d])([a-f\d])([a-f\d])$/i ; e = e . replace ( t , function ( e , t , o , n ) { return t + t + o + o + n + n } ) ; var o = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i . exec ( e ) ; return o ? { r : parseInt ( o [ 1 ] , 16 ) , g : parseInt ( o [ 2 ] , 16 ) , b : parseInt ( o [ 3 ] , 16 ) } : ! 1 } function n ( e , t ) { var o , n = { } ; for ( o in e ) n [ o ] = e [ o ] ; for ( o in t ) n [ o ] = t [ o ] ; return n } function r ( ) { return b . hidden || b . msHidden || b . webkitHidden || b . mozHidden } e = e ? e : { } ; var i , a , l , s , h , f , c , d , u , y , w , g , x , m , p , b , v = { bgColor : "#d00" , textColor : "#fff" , fontFamily : "sans-serif" , fontStyle : "bold" , type : "circle" , position : "down" , animation : "slide" , elementId : ! 1 , dataUrl : ! 1 , win : window } ; x = { } , x . ff = "undefined" != typeof InstallTrigger , x . chrome = ! ! window . chrome , x . opera = ! ! window . opera || navigator . userAgent . indexOf ( "Opera" ) >= 0 , x . ie = /*@cc_on!@*/ ! 1 , x . safari = Object . prototype . toString . call ( window . HTMLElement ) . indexOf ( "Constructor" ) > 0 , x . supported = x . chrome || x . ff || x . opera ; var C = [ ] ; w = function ( ) { } , d = g = ! 1 ; var E = function ( ) { i = n ( v , e ) , i . bgColor = o ( i . bgColor ) , i . textColor = o ( i . textColor ) , i . position = i . position . toLowerCase ( ) , i . animation = S . types [ "" + i . animation ] ? i . animation : v . animation , b = i . win . document ; var t = i . position . indexOf ( "up" ) > - 1 , r = i . position . indexOf ( "left" ) > - 1 ; if ( t || r ) for ( var d = 0 ; d < S . types [ "" + i . animation ] . length ; d ++ ) { var u = S . types [ "" + i . animation ] [ d ] ; t && ( u . y = u . y < . 6 ? u . y - . 4 : u . y - 2 * u . y + ( 1 - u . w ) ) , r && ( u . x = u . x < . 6 ? u . x - . 4 : u . x - 2 * u . x + ( 1 - u . h ) ) , S . types [ "" + i . animation ] [ d ] = u } i . type = A [ "" + i . type ] ? i . type : v . type , a = O . getIcon ( ) , h = document . createElement ( "canvas" ) , c = document . createElement ( "img" ) , a . hasAttribute ( "href" ) ? ( c . setAttribute ( "crossOrigin" , "anonymous" ) , c . setAttribute ( "src" , a . getAttribute ( "href" ) ) , c . onload = function ( ) { l = c . height > 0 ? c . height : 32 , s = c . width > 0 ? c . width : 32 , h . height = l , h . width = s , f = h . getContext ( "2d" ) , M . ready ( ) } ) : ( c . setAttribute ( "src" , "" ) , l = 32 , s = 32 , c . height = l , c . width = s , h . height = l , h . width = s , f = h . getContext ( "2d" ) , M . ready ( ) ) } , M = { } ; M . ready = function ( ) { d = ! 0 , M . reset ( ) , w ( ) } , M . reset = function ( ) { d && ( C = [ ] , u = ! 1 , y = ! 1 , f . clearRect ( 0 , 0 , s , l ) , f . drawImage ( c , 0 , 0 , s , l ) , O . setIcon ( h ) , window . clearTimeout ( m ) , window . clearTimeout ( p ) ) } , M . start = function ( ) { if ( d && ! y ) { var e = function ( ) { u = C [ 0 ] , y = ! 1 , C . length > 0 && ( C . shift ( ) , M . start ( ) ) } ; if ( C . length > 0 ) { y = ! 0 ; var t = function ( ) { [ "type" , "animation" , "bgColor" , "textColor" , "fontFamily" , "fontStyle" ] . forEach ( function ( e ) { e in C [ 0 ] . options && ( i [ e ] = C [ 0 ] . options [ e ] ) } ) , S . run ( C [ 0 ] . options , function ( ) { e ( ) } , ! 1 ) } ; u ? S . run ( u . options , function ( ) { t ( ) } , ! 0 ) : t ( ) } } } ; var A = { } , I = function ( e ) { return e . n = "number" == typeof e . n ? Math . abs ( 0 | e . n ) : e . n , e . x = s * e . x , e . y = l * e . y , e . w = s * e . w , e . h = l * e . h , e . len = ( "" + e . n ) . length , e } ; A . circle = function ( e ) { e = I ( e ) ; var t = ! 1 ; 2 === e . len ? ( e . x = e . x - . 4 * e . w , e . w = 1.4 * e . w , t = ! 0 ) : e . len >= 3 && ( e . x = e . x - . 65 * e . w , e . w = 1.65 * e . w , t = ! 0 ) , f . clearRect ( 0 , 0 , s , l ) , f . drawImage ( c , 0 , 0 , s , l ) , f . beginPath ( ) , f . font = i . fontStyle + " " + Math . floor ( e . h * ( e . n > 99 ? . 85 : 1 ) ) + "px " + i . fontFamily , f . textAlign = "center" , t ? ( f . moveTo ( e . x + e . w / 2 , e . y ) , f . lineTo ( e . x + e . w - e . h / 2 , e . y ) , f . quadraticCurveTo ( e . x + e . w , e . y , e . x + e . w , e . y + e . h / 2 ) , f . lineTo ( e . x + e . w , e . y + e . h - e . h / 2 ) , f . quadraticCurveTo ( e . x + e . w , e . y + e . h , e . x + e . w - e . h / 2 , e . y + e . h ) , f . lineTo ( e . x + e . h / 2 , e . y + e . h ) , f . quadraticCurveTo ( e . x , e . y + e . h , e . x , e . y + e . h - e . h / 2 ) , f . lineTo ( e . x , e . y + e . h / 2 ) , f . quadraticCurveTo ( e . x , e . y , e . x + e . h / 2 , e . y ) ) : f . arc ( e . x + e . w / 2 , e . y + e . h / 2 , e . h / 2 , 0 , 2 * Math . PI ) , f . fillStyle = "rgba(" + i . bgColor . r + "," + i . bgColor . g + "," + i . bgColor . b + "," + e . o + ")" , f . fill ( ) , f . closePath ( ) , f . beginPath ( ) , f . stroke ( ) , f . fillStyle = "rgba(" + i . textColor . r + "," + i . textColor . g + "," + i . textColor . b + "," + e . o + ")" , "number" == typeof e . n && e . n > 999 ? f . fillText ( ( e . n > 9999 ? 9 : Math . floor ( e . n / 1e3 ) ) + "k+" , Math . floor ( e . x + e . w / 2 ) , Math . floor ( e . y + e . h - . 2 * e . h ) ) : f . fillText ( e . n , Math . floor ( e . x + e . w / 2 ) , Math . floor ( e . y + e . h - . 15 * e . h ) ) , f . closePath ( ) } , A . rectangle = function ( e ) { e = I ( e ) ; var t = ! 1 ; 2 === e . len ? ( e . x = e . x - . 4 * e . w , e . w = 1.4 * e . w , t = ! 0 ) : e . len >= 3 && ( e . x = e . x - . 65 * e . w , e . w = 1.65 * e . w , t = ! 0 ) , f . clearRect ( 0 , 0 , s , l ) , f . drawImage ( c , 0 , 0 , s , l ) , f . beginPath ( ) , f . font = i . fontStyle + " " + Math . floor ( e . h * ( e . n > 99 ? . 9 : 1 ) ) + "px " + i . fontFamily , f . textAlign = "center" , f . fillStyle = "rgba(" + i . bgColor . r + "," + i . bgColor . g + "," + i . b
/ * !
* jQuery UI Touch Punch 0.2 . 3
*
* Copyright 2011 – 2014 , Dave Furfero
* Dual licensed under the MIT or GPL Version 2 licenses .
*
* Depends :
* jquery . ui . widget . js
* jquery . ui . mouse . js
* /
! function ( a ) { function f ( a , b ) { if ( ! ( a . originalEvent . touches . length > 1 ) ) { a . preventDefault ( ) ; var c = a . originalEvent . changedTouches [ 0 ] , d = document . createEvent ( "MouseEvents" ) ; d . initMouseEvent ( b , ! 0 , ! 0 , window , 1 , c . screenX , c . screenY , c . clientX , c . clientY , ! 1 , ! 1 , ! 1 , ! 1 , 0 , null ) , a . target . dispatchEvent ( d ) } } if ( a . support . touch = "ontouchend" in document , a . support . touch ) { var e , b = a . ui . mouse . prototype , c = b . _mouseInit , d = b . _mouseDestroy ; b . _touchStart = function ( a ) { var b = this ; ! e && b . _mouseCapture ( a . originalEvent . changedTouches [ 0 ] ) && ( e = ! 0 , b . _touchMoved = ! 1 , f ( a , "mouseover" ) , f ( a , "mousemove" ) , f ( a , "mousedown" ) ) } , b . _touchMove = function ( a ) { e && ( this . _touchMoved = ! 0 , f ( a , "mousemove" ) ) } , b . _touchEnd = function ( a ) { e && ( f ( a , "mouseup" ) , f ( a , "mouseout" ) , this . _touchMoved || f ( a , "click" ) , e = ! 1 ) } , b . _mouseInit = function ( ) { var b = this ; b . element . bind ( { touchstart : a . proxy ( b , "_touchStart" ) , touchmove : a . proxy ( b , "_touchMove" ) , touchend : a . proxy ( b , "_touchEnd" ) } ) , c . call ( b ) } , b . _mouseDestroy = function ( ) { var b = this ; b . element . unbind ( { touchstart : a . proxy ( b , "_touchStart" ) , touchmove : a . proxy ( b , "_touchMove" ) , touchend : a . proxy ( b , "_touchEnd" ) } ) , d . call ( b ) } } } ( jQuery ) ;