1/******* Do not edit this file ******* 2Simple Custom CSS and JS - by Silkypress.com 3Saved: Sep 09 2026 | 14:30:10 */
vendor: 20,584 bytes, lines 3-4
3 4!function(a,b,c,d){"use strict";function e(a,b,c){return setTimeout(j(a,c),b)}function f(a,b,c){return Array.isArray(a)?(g(a,c[b],c),!0):!1}function g(a,b,c){var e;if(a)if(a.forEach)a.forEach(b,c);else if(a.length!==d)for(e=0;e<a.length;)b.call(c,a[e],e,a),e++;else for(e in a)a.hasOwnProperty(e)&&b.call(c,a[e],e,a)}function h(b,c,d){var e="DEPRECATED METHOD: "+c+"\n"+d+" AT \n";return function(){var c=new Error("get-stack-trace"),d=c&&c.stack?c.stack.replace(/^[^\(]+?[\n$]/gm,"").replace(/^\s+at\s+/gm,"").replace(/^Object.<anonymous>\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",f=a.console&&(a.console.warn||a.console.log);return f&&f.call(a.console,e,d),b.apply(this,arguments)}}function i(a,b,c){var d,e=b.prototype;d=a.prototype=Object.create(e),d.constructor=a,d._super=e,c&&la(d,c)}function j(a,b){return function(){return a.apply(b,arguments)}}function k(a,b){return typeof a==oa?a.apply(b?b[0]||d:d,b):a}function l(a,b){return a===d?b:a}function m(a,b,c){g(q(b),function(b){a.addEventListener(b,c,!1)})}function n(a,b,c){g(q(b),function(b){a.removeEventListener(b,c,!1)})}function o(a,b){for(;a;){if(a==b)return!0;a=a.parentNode}return!1}function p(a,b){return a.indexOf(b)>-1}function q(a){return a.trim().split(/\s+/g)}function r(a,b,c){if(a.indexOf&&!c)return a.indexOf(b);for(var d=0;d<a.length;){if(c&&a[d][c]==b||!c&&a[d]===b)return d;d++}return-1}function s(a){return Array.prototype.slice.call(a,0)}function t(a,b,c){for(var d=[],e=[],f=0;f<a.length;){var g=b?a[f][b]:a[f];r(e,g)<0&&d.push(a[f]),e[f]=g,f++}return c&&(d=b?d.sort(function(a,c){return a[b]>c[b]}):d.sort()),d}function u(a,b){for(var c,e,f=b[0].toUpperCase()+b.slice(1),g=0;g<ma.length;){if(c=ma[g],e=c?c+f:b,e in a)return e;g++}return d}function v(){return ua++}function w(b){var c=b.ownerDocument||b;return c.defaultView||c.parentWindow||a}function x(a,b){var c=this;this.manager=a,this.callback=b,this.element=a.element,this.target=a.options.inputTarget,this.domHandler=function(b){k(a.options.enable,[a])&&c.handler(b)},this.init()}function y(a){var b,c=a.options.inputClass;return new(b=c?c:xa?M:ya?P:wa?R:L)(a,z)}function z(a,b,c){var d=c.pointers.length,e=c.changedPointers.length,f=b&Ea&&d-e===0,g=b&(Ga|Ha)&&d-e===0;c.isFirst=!!f,c.isFinal=!!g,f&&(a.session={}),c.eventType=b,A(a,c),a.emit("hammer.input",c),a.recognize(c),a.session.prevInput=c}function A(a,b){var c=a.session,d=b.pointers,e=d.length;c.firstInput||(c.firstInput=D(b)),e>1&&!c.firstMultiple?c.firstMultiple=D(b):1===e&&(c.firstMultiple=!1);var f=c.firstInput,g=c.firstMultiple,h=g?g.center:f.center,i=b.center=E(d);b.timeStamp=ra(),b.deltaTime=b.timeStamp-f.timeStamp,b.angle=I(h,i),b.distance=H(h,i),B(c,b),b.offsetDirection=G(b.deltaX,b.deltaY);var j=F(b.deltaTime,b.deltaX,b.deltaY);b.overallVelocityX=j.x,b.overallVelocityY=j.y,b.overallVelocity=qa(j.x)>qa(j.y)?j.x:j.y,b.scale=g?K(g.pointers,d):1,b.rotation=g?J(g.pointers,d):0,b.maxPointers=c.prevInput?b.pointers.length>c.prevInput.maxPointers?b.pointers.length:c.prevInput.maxPointers:b.pointers.length,C(c,b);var k=a.element;o(b.srcEvent.target,k)&&(k=b.srcEvent.target),b.target=k}function B(a,b){var c=b.center,d=a.offsetDelta||{},e=a.prevDelta||{},f=a.prevInput||{};b.eventType!==Ea&&f.eventType!==Ga||(e=a.prevDelta={x:f.deltaX||0,y:f.deltaY||0},d=a.offsetDelta={x:c.x,y:c.y}),b.deltaX=e.x+(c.x-d.x),b.deltaY=e.y+(c.y-d.y)}function C(a,b){var c,e,f,g,h=a.lastInterval||b,i=b.timeStamp-h.timeStamp;if(b.eventType!=Ha&&(i>Da||h.velocity===d)){var j=b.deltaX-h.deltaX,k=b.deltaY-h.deltaY,l=F(i,j,k);e=l.x,f=l.y,c=qa(l.x)>qa(l.y)?l.x:l.y,g=G(j,k),a.lastInterval=b}else c=h.velocity,e=h.velocityX,f=h.velocityY,g=h.direction;b.velocity=c,b.velocityX=e,b.velocityY=f,b.direction=g}function D(a){for(var b=[],c=0;c<a.pointers.length;)b[c]={clientX:pa(a.pointers[c].clientX),clientY:pa(a.pointers[c].clientY)},c++;return{timeStamp:ra(),pointers:b,center:E(b),deltaX:a.deltaX,deltaY:a.deltaY}}function E(a){var b=a.length;if(1===b)return{x:pa(a[0].clientX),y:pa(a[0].clientY)};for(var c=0,d=0,e=0;b>e;)c+=a[e].clientX,d+=a[e].clientY,e++;return{x:pa(c/b),y:pa(d/b)}}function F(a,b,c){return{x:b/a||0,y:c/a||0}}function G(a,b){return a===b?Ia:qa(a)>=qa(b)?0>a?Ja:Ka:0>b?La:Ma}function H(a,b,c){c||(c=Qa);var d=b[c[0]]-a[c[0]],e=b[c[1]]-a[c[1]];return Math.sqrt(d*d+e*e)}function I(a,b,c){c||(c=Qa);var d=b[c[0]]-a[c[0]],e=b[c[1]]-a[c[1]];return 180*Math.atan2(e,d)/Math.PI}function J(a,b){return I(b[1],b[0],Ra)+I(a[1],a[0],Ra)}function K(a,b){return H(b[0],b[1],Ra)/H(a[0],a[1],Ra)}function L(){this.evEl=Ta,this.evWin=Ua,this.pressed=!1,x.apply(this,arguments)}function M(){this.evEl=Xa,this.evWin=Ya,x.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}function N(){this.evTarget=$a,this.evWin=_a,this.started=!1,x.apply(this,arguments)}function O(a,b){var c=s(a.touches),d=s(a.changedTouches);return b&(Ga|Ha)&&(c=t(c.concat(d),"identifier",!0)),[c,d]}function P(){this.evTarget=bb,this.targetIds={},x.apply(this,arguments)}function Q(a,b){var c=s(a.touches),d=this.targetIds;if(b&(Ea|Fa)&&1===c.length)return d[c[0].identifier]=!0,[c,c];var e,f,g=s(a.changedTouches),h=[],i=this.target;if(f=c.filter(function(a){return o(a.target,i)}),b===Ea)for(e=0;e<f.length;)d[f[e].identifier]=!0,e++;for(e=0;e<g.length;)d[g[e].identifier]&&h.push(g[e]),b&(Ga|Ha)&&delete d[g[e].identifier],e++;return h.length?[t(f.concat(h),"identifier",!0),h]:void 0}function R(){x.apply(this,arguments);var a=j(this.handler,this);this.touch=new P(this.manager,a),this.mouse=new L(this.manager,a),this.primaryTouch=null,this.lastTouches=[]}function S(a,b){a&Ea?(this.primaryTouch=b.changedPointers[0].identifier,T.call(this,b)):a&(Ga|Ha)&&T.call(this,b)}function T(a){var b=a.changedPointers[0];if(b.identifier===this.primaryTouch){var c={x:b.clientX,y:b.clientY};this.lastTouches.push(c);var d=this.lastTouches,e=function(){var a=d.indexOf(c);a>-1&&d.splice(a,1)};setTimeout(e,cb)}}function U(a){for(var b=a.srcEvent.clientX,c=a.srcEvent.clientY,d=0;d<this.lastTouches.length;d++){var e=this.lastTouches[d],f=Math.abs(b-e.x),g=Math.abs(c-e.y);if(db>=f&&db>=g)return!0}return!1}function V(a,b){this.manager=a,this.set(b)}function W(a){if(p(a,jb))return jb;var b=p(a,kb),c=p(a,lb);return b&&c?jb:b||c?b?kb:lb:p(a,ib)?ib:hb}function X(){if(!fb)return!1;var b={},c=a.CSS&&a.CSS.supports;return["auto","manipulation","pan-y","pan-x","pan-x pan-y","none"].forEach(function(d){b[d]=c?a.CSS.supports("touch-action",d):!0}),b}function Y(a){this.options=la({},this.defaults,a||{}),this.id=v(),this.manager=null,this.options.enable=l(this.options.enable,!0),this.state=nb,this.simultaneous={},this.requireFail=[]}function Z(a){return a&sb?"cancel":a&qb?"end":a&pb?"move":a&ob?"start":""}function $(a){return a==Ma?"down":a==La?"up":a==Ja?"left":a==Ka?"right":""}function _(a,b){var c=b.manager;return c?c.get(a):a}function aa(){Y.apply(this,arguments)}function ba(){aa.apply(this,arguments),this.pX=null,this.pY=null}function ca(){aa.apply(this,arguments)}function da(){Y.apply(this,arguments),this._timer=null,this._input=null}function ea(){aa.apply(this,arguments)}function fa(){aa.apply(this,arguments)}function ga(){Y.apply(this,arguments),this.pTime=!1,this.pCenter=!1,this._timer=null,this._input=null,this.count=0}function ha(a,b){return b=b||{},b.recognizers=l(b.recognizers,ha.defaults.preset),new ia(a,b)}function ia(a,b){this.options=la({},ha.defaults,b||{}),this.options.inputTarget=this.options.inputTarget||a,this.handlers={},this.session={},this.recognizers=[],this.oldCssProps={},this.element=a,this.input=y(this),this.touchAction=new V(this,this.options.touchAction),ja(this,!0),g(this.options.recognizers,function(a){var b=this.add(new a[0](a[1]));a[2]&&b.recognizeWith(a[2]),a[3]&&b.requireFailure(a[3])},this)}function ja(a,b){var c=a.element;if(c.style){var d;g(a.options.cssProps,function(e,f){d=u(c.style,f),b?(a.oldCssProps[d]=c.style[d],c.style[d]=e):c.style[d]=a.oldCssProps[d]||""}),b||(a.oldCssProps={})}}function ka(a,c){var d=b.createEvent("Event");d.initEvent(a,!0,!0),d.gesture=c,c.target.dispatchEvent(d)}var la,ma=["","webkit","Moz","MS","ms","o"],na=b.createElement("div"),oa="function",pa=Math.round,qa=Math.abs,ra=Date.now;la="function"!=typeof Object.assign?function(a){if(a===d||null===a)throw new TypeError("Cannot convert undefined or null to object");for(var b=Object(a),c=1;c<arguments.length;c++){var e=arguments[c];if(e!==d&&null!==e)for(var f in e)e.hasOwnProperty(f)&&(b[f]=e[f])}return b}:Object.assign;var sa=h(function(a,b,c){for(var e=Object.keys(b),f=0;f<e.length;)(!c||c&&a[e[f]]===d)&&(a[e[f]]=b[e[f]]),f++;return a},"extend","Use `assign`."),ta=h(function(a,b){return sa(a,b,!0)},"merge","Use `assign`."),ua=1,va=/mobile|tablet|ip(ad|hone|od)|android/i,wa="ontouchstart"in a,xa=u(a,"PointerEvent")!==d,ya=wa&&va.test(navigator.userAgent),za="touch",Aa="pen",Ba="mouse",Ca="kinect",Da=25,Ea=1,Fa=2,Ga=4,Ha=8,Ia=1,Ja=2,Ka=4,La=8,Ma=16,Na=Ja|Ka,Oa=La|Ma,Pa=Na|Oa,Qa=["x","y"],Ra=["clientX","clientY"];x.prototype={handler:function(){},init:function(){this.evEl&&m(this.element,this.evEl,this.domHandler),this.evTarget&&m(this.target,this.evTarget,this.domHandler),this.evWin&&m(w(this.element),this.evWin,this.domHandler)},destroy:function(){this.evEl&&n(this.element,this.evEl,this.domHandler),this.evTarget&&n(this.target,this.evTarget,this.domHandler),this.evWin&&n(w(this.element),this.evWin,this.domHandler)}};var Sa={mousedown:Ea,mousemove:Fa,mouseup:Ga},Ta="mousedown",Ua="mousemove mouseup";i(L,x,{handler:function(a){var b=Sa[a.type];b&Ea&&0===a.button&&(this.pressed=!0),b&Fa&&1!==a.which&&(b=Ga),this.pressed&&(b&Ga&&(this.pressed=!1),this.callback(this.manager,b,{pointers:[a],changedPointers:[a],pointerType:Ba,srcEvent:a}))}});var Va={pointerdown:Ea,pointermove:Fa,pointerup:Ga,pointercancel:Ha,pointerout:Ha},Wa={2:za,3:Aa,4:Ba,5:Ca},Xa="pointerdown",Ya="pointermove pointerup pointercancel";a.MSPointerEvent&&!a.PointerEvent&&(Xa="MSPointerDown",Ya="MSPointerMove MSPointerUp MSPointerCancel"),i(M,x,{handler:function(a){var b=this.store,c=!1,d=a.type.toLowerCase().replace("ms",""),e=Va[d],f=Wa[a.pointerType]||a.pointerType,g=f==za,h=r(b,a.pointerId,"pointerId");e&Ea&&(0===a.button||g)?0>h&&(b.push(a),h=b.length-1):e&(Ga|Ha)&&(c=!0),0>h||(b[h]=a,this.callback(this.manager,e,{pointers:b,changedPointers:[a],pointerType:f,srcEvent:a}),c&&b.splice(h,1))}});var Za={touchstart:Ea,touchmove:Fa,touchend:Ga,touchcancel:Ha},$a="touchstart",_a="touchstart touchmove touchend touchcancel";i(N,x,{handler:function(a){var b=Za[a.type];if(b===Ea&&(this.started=!0),this.started){var c=O.call(this,a,b);b&(Ga|Ha)&&c[0].length-c[1].length===0&&(this.started=!1),this.callback(this.manager,b,{pointers:c[0],changedPointers:c[1],pointerType:za,srcEvent:a})}}});var ab={touchstart:Ea,touchmove:Fa,touchend:Ga,touchcancel:Ha},bb="touchstart touchmove touchend touchcancel";i(P,x,{handler:function(a){var b=ab[a.type],c=Q.call(this,a,b);c&&this.callback(this.manager,b,{pointers:c[0],changedPointers:c[1],pointerType:za,srcEvent:a})}});var cb=2500,db=25;i(R,x,{handler:function(a,b,c){var d=c.pointerType==za,e=c.pointerType==Ba;if(!(e&&c.sourceCapabilities&&c.sourceCapabilities.firesTouchEvents)){if(d)S.call(this,b,c);else if(e&&U.call(this,c))return;this.callback(a,b,c)}},destroy:function(){this.touch.destroy(),this.mouse.destroy()}});var eb=u(na.style,"touchAction"),fb=eb!==d,gb="compute",hb="auto",ib="manipulation",jb="none",kb="pan-x",lb="pan-y",mb=X();V.prototype={set:function(a){a==gb&&(a=this.compute()),fb&&this.manager.element.style&&mb[a]&&(this.manager.element.style[eb]=a),this.actions=a.toLowerCase().trim()},update:function(){this.set(this.manager.options.touchAction)},compute:function(){var a=[];return g(this.manager.recognizers,function(b){k(b.options.enable,[b])&&(a=a.concat(b.getTouchAction()))}),W(a.join(" "))},preventDefaults:function(a){var b=a.srcEvent,c=a.offsetDirection;if(this.manager.session.prevented)return void b.preventDefault();var d=this.actions,e=p(d,jb)&&!mb[jb],f=p(d,lb)&&!mb[lb],g=p(d,kb)&&!mb[kb];if(e){var h=1===a.pointers.length,i=a.distance<2,j=a.deltaTime<250;if(h&&i&&j)return}return g&&f?void 0:e||f&&c&Na||g&&c&Oa?this.preventSrc(b):void 0},preventSrc:function(a){this.manager.session.prevented=!0,a.preventDefault()}};var nb=1,ob=2,pb=4,qb=8,rb=qb,sb=16,tb=32;Y.prototype={defaults:{},set:function(a){return la(this.options,a),this.manager&&this.manager.touchAction.update(),this},recognizeWith:function(a){if(f(a,"recognizeWith",this))return this;var b=this.simultaneous;return a=_(a,this),b[a.id]||(b[a.id]=a,a.recognizeWith(this)),this},dropRecognizeWith:function(a){return f(a,"dropRecognizeWith",this)?this:(a=_(a,this),delete this.simultaneous[a.id],this)},requireFailure:function(a){if(f(a,"requireFailure",this))return this;var b=this.requireFail;return a=_(a,this),-1===r(b,a)&&(b.push(a),a.requireFailure(this)),this},dropRequireFailure:function(a){if(f(a,"dropRequireFailure",this))return this;a=_(a,this);var b=r(this.requireFail,a);return b>-1&&this.requireFail.splice(b,1),this},hasRequireFailures:function(){return this.requireFail.length>0},canRecognizeWith:function(a){return!!this.simultaneous[a.id]},emit:function(a){function b(b){c.manager.emit(b,a)}var c=this,d=this.state;qb>d&&b(c.options.event+Z(d)),b(c.options.event),a.additionalEvent&&b(a.additionalEvent),d>=qb&&b(c.options.event+Z(d))},tryEmit:function(a){return this.canEmit()?this.emit(a):void(this.state=tb)},canEmit:function(){for(var a=0;a<this.requireFail.length;){if(!(this.requireFail[a].state&(tb|nb)))return!1;a++}return!0},recognize:function(a){var b=la({},a);return k(this.options.enable,[this,b])?(this.state&(rb|sb|tb)&&(this.state=nb),this.state=this.process(b),void(this.state&(ob|pb|qb|sb)&&this.tryEmit(b))):(this.reset(),void(this.state=tb))},process:function(a){},getTouchAction:function(){},reset:function(){}},i(aa,Y,{defaults:{pointers:1},attrTest:function(a){var b=this.options.pointers;return 0===b||a.pointers.length===b},process:function(a){var b=this.state,c=a.eventType,d=b&(ob|pb),e=this.attrTest(a);return d&&(c&Ha||!e)?b|sb:d||e?c&Ga?b|qb:b&ob?b|pb:ob:tb}}),i(ba,aa,{defaults:{event:"pan",threshold:10,pointers:1,direction:Pa},getTouchAction:function(){var a=this.options.direction,b=[];return a&Na&&b.push(lb),a&Oa&&b.push(kb),b},directionTest:function(a){var b=this.options,c=!0,d=a.distance,e=a.direction,f=a.deltaX,g=a.deltaY;return e&b.direction||(b.direction&Na?(e=0===f?Ia:0>f?Ja:Ka,c=f!=this.pX,d=Math.abs(a.deltaX)):(e=0===g?Ia:0>g?La:Ma,c=g!=this.pY,d=Math.abs(a.deltaY))),a.direction=e,c&&d>b.threshold&&e&b.direction},attrTest:function(a){return aa.prototype.attrTest.call(this,a)&&(this.state&ob||!(this.state&ob)&&this.directionTest(a))},emit:function(a){this.pX=a.deltaX,this.pY=a.deltaY;var b=$(a.direction);b&&(a.additionalEvent=this.options.event+b),this._super.emit.call(this,a)}}),i(ca,aa,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[jb]},attrTest:function(a){return this._super.attrTest.call(this,a)&&(Math.abs(a.scale-1)>this.options.threshold||this.state&ob)},emit:function(a){if(1!==a.scale){var b=a.scale<1?"in":"out";a.additionalEvent=this.options.event+b}this._super.emit.call(this,a)}}),i(da,Y,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return[hb]},process:function(a){var b=this.options,c=a.pointers.length===b.pointers,d=a.distance<b.threshold,f=a.deltaTime>b.time;if(this._input=a,!d||!c||a.eventType&(Ga|Ha)&&!f)this.reset();else if(a.eventType&Ea)this.reset(),this._timer=e(function(){this.state=rb,this.tryEmit()},b.time,this);else if(a.eventType&Ga)return rb;return tb},reset:function(){clearTimeout(this._timer)},emit:function(a){this.state===rb&&(a&&a.eventType&Ga?this.manager.emit(this.options.event+"up",a):(this._input.timeStamp=ra(),this.manager.emit(this.options.event,this._input)))}}),i(ea,aa,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[jb]},attrTest:function(a){return this._super.attrTest.call(this,a)&&(Math.abs(a.rotation)>this.options.threshold||this.state&ob)}}),i(fa,aa,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:Na|Oa,pointers:1},getTouchAction:function(){return ba.prototype.getTouchAction.call(this)},attrTest:function(a){var b,c=this.options.direction;return c&(Na|Oa)?b=a.overallVelocity:c&Na?b=a.overallVelocityX:c&Oa&&(b=a.overallVelocityY),this._super.attrTest.call(this,a)&&c&a.offsetDirection&&a.distance>this.options.threshold&&a.maxPointers==this.options.pointers&&qa(b)>this.options.velocity&&a.eventType&Ga},emit:function(a){var b=$(a.offsetDirection);b&&this.manager.emit(this.options.event+b,a),this.manager.emit(this.options.event,a)}}),i(ga,Y,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[ib]},process:function(a){var b=this.options,c=a.pointers.length===b.pointers,d=a.distance<b.threshold,f=a.deltaTime<b.time;if(this.reset(),a.eventType&Ea&&0===this.count)return this.failTimeout();if(d&&f&&c){if(a.eventType!=Ga)return this.failTimeout();var g=this.pTime?a.timeStamp-this.pTime<b.interval:!0,h=!this.pCenter||H(this.pCenter,a.center)<b.posThreshold;this.pTime=a.timeStamp,this.pCenter=a.center,h&&g?this.count+=1:this.count=1,this._input=a;var i=this.count%b.taps;if(0===i)return this.hasRequireFailures()?(this._timer=e(function(){this.state=rb,this.tryEmit()},b.interval,this),ob):rb}return tb},failTimeout:function(){return this._timer=e(function(){this.state=tb},this.options.interval,this),tb},reset:function(){clearTimeout(this._timer)},emit:function(){this.state==rb&&(this._input.tapCount=this.count,this.manager.emit(this.options.event,this._input))}}),ha.VERSION="2.0.8",ha.defaults={domEvents:!1,touchAction:gb,enable:!0,inputTarget:null,inputClass:null,preset:[[ea,{enable:!1}],[ca,{enable:!1},["rotate"]],[fa,{direction:Na}],[ba,{direction:Na},["swipe"]],[ga],[ga,{event:"doubletap",taps:2},["tap"]],[da]],cssProps:{userSelect:"none",touchSelect:"none",touchCallout:"none",contentZooming:"none",userDrag:"none",tapHighlightColor:"rgba(0,0,0,0)"}};var ub=1,vb=2;ia.prototype={set:function(a){return la(this.options,a),a.touchAction&&this.touchAction.update(),a.inputTarget&&(this.input.destroy(),this.input.target=a.inputTarget,this.input.init()),this},stop:function(a){this.session.stopped=a?vb:ub},recognize:function(a){var b=this.session;if(!b.stopped){this.touchAction.preventDefaults(a);var c,d=this.recognizers,e=b.curRecognizer;(!e||e&&e.state&rb)&&(e=b.curRecognizer=null);for(var f=0;f<d.length;)c=d[f],b.stopped===vb||e&&c!=e&&!c.canRecognizeWith(e)?c.reset():c.recognize(a),!e&&c.state&(ob|pb|qb)&&(e=b.curRecognizer=c),f++}},get:function(a){if(a instanceof Y)return a;for(var b=this.recognizers,c=0;c<b.length;c++)if(b[c].options.event==a)return b[c];return null},add:function(a){if(f(a,"add",this))return this;var b=this.get(a.options.event);return b&&this.remove(b),this.recognizers.push(a),a.manager=this,this.touchAction.update(),a},remove:function(a){if(f(a,"remove",this))return this;if(a=this.get(a)){var b=this.recognizers,c=r(b,a);-1!==c&&(b.splice(c,1),this.touchAction.update())}return this},on:function(a,b){if(a!==d&&b!==d){var c=this.handlers;return g(q(a),function(a){c[a]=c[a]||[],c[a].push(b)}),this}},off:function(a,b){if(a!==d){var c=this.handlers;return g(q(a),function(a){b?c[a]&&c[a].splice(r(c[a],b),1):delete c[a]}),this}},emit:function(a,b){this.options.domEvents&&ka(a,b);var c=this.handlers[a]&&this.handlers[a].slice();if(c&&c.length){b.type=a,b.preventDefault=function(){b.srcEvent.preventDefault()};for(var d=0;d<c.length;)c[d](b),d++}},destroy:function(){this.element&&ja(this,!1),this.handlers={},this.session={},this.input.destroy(),this.element=null}},la(ha,{INPUT_START:Ea,INPUT_MOVE:Fa,INPUT_END:Ga,INPUT_CANCEL:Ha,STATE_POSSIBLE:nb,STATE_BEGAN:ob,STATE_CHANGED:pb,STATE_ENDED:qb,STATE_RECOGNIZED:rb,STATE_CANCELLED:sb,STATE_FAILED:tb,DIRECTION_NONE:Ia,DIRECTION_LEFT:Ja,DIRECTION_RIGHT:Ka,DIRECTION_UP:La,DIRECTION_DOWN:Ma,DIRECTION_HORIZONTAL:Na,DIRECTION_VERTICAL:Oa,DIRECTION_ALL:Pa,Manager:ia,Input:x,TouchAction:V,TouchInput:P,MouseInput:L,PointerEventInput:M,TouchMouseInput:R,SingleTouchInput:N,Recognizer:Y,AttrRecognizer:aa,Tap:ga,Pan:ba,Swipe:fa,Pinch:ca,Rotate:ea,Press:da,on:m,off:n,each:g,merge:ta,extend:sa,assign:la,inherit:i,bindFn:j,prefixed:u});var wb="undefined"!=typeof a?a:"undefined"!=typeof self?self:{};wb.Hammer=ha,"function"==typeof define&&define.amd?define(function(){return ha}):"undefined"!=typeof module&&module.exports?module.exports=ha:a[c]=ha}(window,document,"Hammer");
5 6var globalMesSelecionado = -1, globalBackgroundAlterado = false, ultimaAlteracao = '07/04/2025, 10h57min'; 7 8function jsGlobalLoadScript(url, callback, charset){ 9 var script = document.createElement("script"); 10 script.type = "text/javascript"; 11 12 if (typeof charset != "undefined") { 13 script.charset = charset; 14 } 15 16 if (script.readyState) { //IE 17 script.onreadystatechange = function() { 18 if ((script.readyState == "loaded") || (script.readyState == "complete")) { 19 script.onreadystatechange = null; 20 callback(); 21 } 22 }; 23 } 24 else { //Others 25 script.onload = function() { 26 callback(); 27 }; 28 } 29 script.src = url; 30 document.getElementsByTagName("head")[0].appendChild(script); 31} 32 33var fuvDlgConst = { 34 ITEM_HEIGHT: 46, 35 COLOR_TITLE_BACKGROUND: "#0077b6", 36 COLOR_TITLE_FONT: "white", 37 SIZE_TITLE_FONT: 16, 38 COLOR_INFO_BACKGROUND: "#feffd6", 39 COLOR_INFO_FONT: "blackcheckC", 40 COLOR_INFO_FONT: "black", 41 COLOR_WARNING_BACKGROUND: "maroon", 42 COLOR_WARNING_FONT: "white", 43 COLOR_WINDOW_BACKGROUND: "#edfafd", 44 COLOR_BANNER_BACKGROUND: "#0096c7", 45 COLOR_BANNER_FONT: "white", 46 COLOR_MENU_BACKGROUND: "rgb(255,255,255)", 47 COLOR_BUTTONS_BACKGROUND: "#ade8f4", 48 COLOR_BUTTONS_FONT: "navy", 49 COLOR_FILTER_FONT: "gray", 50 ALPHA_SHADOW_BACKGROUND: 0.5 51} 52 53var fuvUI = { 54 isMobile: ((navigator.userAgent.match(/Android/i) || navigator.userAgent.match(/webOS/i) || navigator.userAgent.match(/iPhone/i) || navigator.userAgent.match(/iPad/i) || navigator.userAgent.match(/iPod/i) || navigator.userAgent.match(/BlackBerry/i) || navigator.userAgent.match(/Windows Phone/i))), 55 getParam(name) { 56 var url = window.location.href.replace(/&/gi,"&"); 57 var regexS = "[\\?&]"+name+"=([^&#]*)"; 58 var regex = new RegExp( regexS ); 59 var results = regex.exec(url); 60 if (results===null) { 61 return null; 62 } 63 else { 64 return results[1]; 65 } 66 }, 67 isNull(a) { 68 return (typeof a == "undefined") || (a === null) ; 69 }, 70 getBrowser: function() { 71 try { 72 var e; 73 var f = e.width; 74 } catch(e) { 75 var err = e.toString(); 76 77 if(err.indexOf("not an object") !== -1) { 78 return "safari"; 79 } else if(err.indexOf("Cannot read") !== -1) { 80 return "chrome"; 81 } else if(err.indexOf("e is undefined") !== -1) { 82 return "firefox"; 83 } else if(err.indexOf("Unable to get property 'width' of undefined or null reference") !== -1) { 84 if(!(false || !!document.documentMode) && !!window.StyleMedia) { 85 return "edge"; 86 } else { 87 return "IE"; 88 } 89 } else if(err.indexOf("cannot convert e into object") !== -1) { 90 return "opera"; 91 } else { 92 return undefined; 93 } 94 } 95 }, 96 draggable: function(container, handle) { 97 var o = {container: $('#'+container), handle: $('#'+handle), x: 0, y: 0, moving: false, cofs: null}; 98 99 o.handle.off("mousedown"); 100 o.handle.mousedown(function(o1) { 101 return function(e) { 102 o1.moving = true; 103 o1.x = e.pageX; 104 o1.y = e.pageY; 105 o1.cofs = o1.container.offset(); 106 return false; 107 } 108 }(o)); 109 110 111 $(window).mousemove(function(o1) { 112 return function(e) { 113 if (o1.moving) { 114 o1.container.css({"left":(o1.cofs.left+e.pageX-o1.x)+"px", "top":(o1.cofs.top+e.pageY-o1.y)+"px"}); 115 return false; 116 } 117 } 118 }(o)); 119 120 o.handle.off("mouseup"); 121 o.handle.mouseup(function(o1) { 122 return function(e) { 123 o1.moving = false; 124 return false; 125 } 126 }(o)); 127 }, 128 fHint: function(id,m,f) { 129 var o = $('#'+id) 130 if (typeof f === "undefined") { 131 // se forem passados apenas dois argumentos, retirar a mensagem do próprio elemento html. está como "data-hint" 132 f = m; 133 m = o.data("hint"); 134 } 135 o.off("mouseenter"); 136 o.mouseenter(function(id1,m1) { 137 return function() { 138 var o = $(this) 139 var wd = $(document).width() 140 var hd = $(document).height() 141 var x = o.offset().left+o.outerWidth() 142 var y = o.offset().top+o.outerHeight() 143 var c = '<div id="'+id1+'_hint" style="position:absolute;text-align:center;padding:6px;font-size:12px;background-color:black;border:solid 1px white;color:white;top:'+0+'px;left:'+0+'px;z-index:9999999;">'+m1+'<\/div>' 144 $('body').append(c) 145 var o1 = $('#'+id1+'_hint') 146 var w = o1.outerWidth() 147 x = x-w 148 o1.css({"left":x+"px","top":y+"px"}) 149 150 } 151 }(id,m)) 152 153 o.off("mouseleave"); 154 o.mouseleave(function(id1) { 155 return function() { 156 $('#'+id1+'_hint').remove() 157 } 158 }(id)) 159
160 o.off("click"); 161 o.click(function(id1,f1) { 162 return function() { 163 $('#'+id1+'_hint').remove() 164 f1() 165 } 166 }(id,f)) 167 }, 168 clearAndDrawLandmarks(canvas, o1) { 169 var ctx = canvas.getContext('2d'); 170 ctx.clearRect(0, 0, canvas.width, canvas.height); 171 var x,y,j = 1 172 for(var i=0;i<o1.landmark[0];i++) { 173 x = o1.landmark[j++] 174 y = o1.landmark[j++] 175 ctx.beginPath() 176 ctx.arc(x, y, 1, 0, 2 * Math.PI, false) 177 ctx.fillStyle = 'white' 178 ctx.fill() 179 ctx.lineWidth = 0.5 180 ctx.strokeStyle = 'black' 181 ctx.stroke() 182 } 183 }, 184 drawClosedPath: function(ctx, landmarks, start, end, color, closed) { 185 var i=0,j=0,x,y; 186 if (typeof closed === "undefined") { 187 closed = false; 188 } 189 for(i=start;i<end;i++) { 190 if (i==start) { 191 j = 2*(start-1)+1; 192 ctx.beginPath(); 193 ctx.lineWidth = 2; 194 ctx.strokeStyle = color; 195 x = landmarks[j++]; 196 y = landmarks[j++]; 197 ctx.moveTo(x, y); 198 } 199 else { 200 ctx.lineTo(landmarks[j++], landmarks[j++]); 201 } 202 } 203 if (closed) { 204 ctx.lineTo(x, y); 205 } 206 ctx.stroke(); 207 }, 208 drawLeftEye: function(ctx, landmarks, color) { 209 this.drawClosedPath(ctx, landmarks, 18, 22, color); 210 this.drawClosedPath(ctx, landmarks, 37, 42, color, true); 211 }, 212 drawRightEye: function(ctx, landmarks, color) { 213 this.drawClosedPath(ctx, landmarks, 23, 27, color); 214 this.drawClosedPath(ctx, landmarks, 43, 48, color, true); 215 }, 216 drawMouthExternal: function(ctx, landmarks, color) { 217 this.drawClosedPath(ctx, landmarks, 49, 60, color, true); 218 }, 219 drawFace: function(ctx, landmarks, color) { 220 this.drawClosedPath(ctx, landmarks, 1, 17, color); 221 }, 222 clearAndDrawFace(canvas, o1) { 223 var ctx = canvas.getContext('2d'); 224 ctx.clearRect(0, 0, canvas.width, canvas.height); 225 this.drawLeftEye(ctx, o1.landmark, 'rgba(255, 255, 220, 0.75)'); 226 this.drawRightEye(ctx, o1.landmark, 'rgba(255, 255, 220, 0.75)'); 227 this.drawMouthExternal(ctx, o1.landmark, 'rgba(255, 220, 220, 0.75)'); 228 this.drawFace(ctx, o1.landmark, 'rgba(255, 255, 255, 0.75)'); 229 }, 230 addButton: function(id, caption, hint, style, fn, a) { 231 if (typeof a == "undefined") { 232 a = ''; 233 } 234 $('#'+id).remove(); 235 var c = a+'<div id="'+id+'" style="background-color:rgba(255,255,255,0.75);padding:2px;border-radius:2px;box-sizing:content-box;">'+caption+'<\/div>'+((a == "") ? a : "<\/a>"); 236 $('body').append(c); 237 $('#'+id).css(style); 238 this.fHint(id, hint, fn); 239 }, 240 addToogleDIV: function(id, caption, hint, style, fn) { 241 $('#'+id).remove(); 242 var c = '<div id="'+id+'" style="background-color:rgba(255,255,255,0.50);padding:2px;border-radius:2px;min-height:14px;min-width:14px;box-sizing:content-box;">'+ 243 '<span id="'+id+'_button" style="position:absolute;left:2px;padding:2px;top:2px;
243font-family:FontAwesome;background-color:white;border-radius:2px;box-sizing:content-box;">'+caption+'<\/span>'+ 244 '<div id="'+id+'_div"><\/div>'+ 245 '<\/div>'; 246 $('body').append(c); 247 $('#'+id).css(style); 248 this.fHint(id+'_button', hint, fn); 249 250 $('#'+id+'_button').css({"z-index":parseInt($('#'+id).css("z-index"))+1}); 251 }, 252 addDataCaption: function(id, caption, value, hint, style, stylecaption, stylevalue, fn) { 253 $('#'+id).remove(); 254 var c = '<div id="'+id+'" style="background-color:rgba(255,255,255,0.50);padding:2px;border-radius:2px;box-sizing:content-box;">'+ 255 '<span id="'+id+'_caption" style="display:inline-block">'+caption+'<\/span>'+ 256 '<span id="'+id+'_value" style="display:inline-block;font-size:8px;">'+value+'<\/span>'+ 257 '<\/div>'; 258 $('body').append(c); 259 $('#'+id).css(style); 260 $('#'+id+'_caption').css(stylecaption); 261 $('#'+id+'_value').css(stylevalue); 262 this.fHint(id, hint, fn); 263 }, 264 setDataCaptionValue: function(id, value) { 265 $('#'+id+'_value').html(value); 266 }, 267 fShadow: function(id,m,c,z) { 268 var w = $(window).width() 269 var h = $(window).height() 270 return '<div id="'+id+'" style="position:fixed;top:0px;left:0px;width:'+w+'px;height:'+h+'px;background-color:'+c+';z-index:'+z+';">'+ 271 '<p style="text-align:center;margin-top:'+(h/2)+'px;font-size:24px;font-weight:bold;color:white;padding:10px;">'+m+'<\/p>'+ 272 '<\/div>' 273 }, 274 sleep: function(ms) { 275 return new Promise(resolve => setTimeout(resolve, ms)); 276 }, 277 readCookies() { 278 var i,result = []; 279 var a = document.cookie.split("; "); 280 for(i=0; i<a.length; i++) { 281 var c = a[i].split("="); 282 result.push({name: c[0], value: c[1]}); 283 } 284 return result; 285 }, 286 saveCookie(name, value, expires) { 287 document.cookie = name+"="+value+"; expires="+expires+"; path=/"; 288 }, 289 fullBackground: function (id, z, alpha) { 290 var w = $(window).width(), h = $(window).height(); 291 if (typeof alpha === "undefined") { 292 alpha = 0.9; 293 } 294 //return '<div id="'+id+'" style="position:fixed;top:0px;left:0px;width:'+w+'px;height:'+h+'px;background-color:rgba(16,16,16,' + alpha + ');z-index:'+z+';"><\/div>'; 295 return '<div id="' + id + '" style="position:fixed;top:0px;left:0px;right:0px;bottom:0px;background-color:rgba(0,0,0,' + alpha + ');z-index:'+z+';"><\/div>'; 296 }, 297 fCloseWindow: function(id) { 298 $('#'+id+'_background').remove() 299 $('#'+id).remove() 300 $('body').css({"overflow":""}) 301 }, 302 fCreateWindow: function(caller,w,caption,text,id,zindex) { 303 if (w=='max') { 304 } 305 var wm=w,x=0,y=10,o=$(window); 306 if (o.length>0) { 307 x = 0 308 wm = o.width() 309 if (w>wm) { 310 w = wm-20 311 } 312 else { 313 x = (wm-w)/2 314 } 315 } 316 if (x==0) { 317 x = 10 318 } 319 320 var c = this.fullBackground(id+'_background', zindex-1); 321 c += '<div id="'+id+'" style="position:fixed;top:'+y+'px;left:'+x+'px;width:'+w+'px;border-radius:5px;background-color:rgb(245,245,255);border:solid 1px silver;box-shadow:0 3px 3px rgba(0,0,0,0.2);z-index:'+zindex+'">'+ 322 '<div style="padding:4px">'+ 323 '<p style="font-size:16px;font-weight:bold;padding:5px 0px 5px 0px;text-align:center;">'+caption+'<\/p>'+ 324 text+ 325 '<\/div>'+ 326 '<\/div>'; 327 $('body').append(c); 328 $('body').css({"overflow":"hidden"}); 329 330 y = $('#' + id).offset().top; 331 y = (o.height() - $('#' + id).height()) / 2; 332 $('#' + id).css({top: y + "px"}); 333 334 335 336 $('#'+id+'_background').click(function(this1,id1) { 337 return function() { 338 this1.fCloseWindow(id1) 339 } 340 }(this,id)) 341 }, 342 dialogYesNo: function(caption,data,fYes,fNo,zindex) { 343 var c = '<div style="font-size:16px;padding:4px;">' + data+'<p style="text-align:center;margin:10px 0px 5px 0px"><button id="idAlertYes" class="cBootButton"> Sim <\/button> <button id="idAlertNo" class="cBootButton"> Não <\/button><\/p><\/div>'; 344 this.fCreateWindow('',640,caption,c,'alert',zindex) 345 346 $('#idAlertYes').click(function(this1,fYes1){ 347 return function() { 348 fYes1() 349 this1.fCloseWindow('alert') 350 } 351 }(this,fYes)); 352 353 $('#idAlertNo').click(function(this1,fNo1){ 354 return function() { 355 fNo1() 356 this1.fCloseWindow('alert') 357 } 358 }(this,fNo)) 359 }, 360 361 stringToBoolean(s) { 362 return (s === "S") || (s === "1") || (s === 1) || (s === true) || (s === "Y") || (s === "y") || (s === "s"); 363 }, 364 365 formatDate(s) { 366 if ((typeof s == "undefined") || (s == "")) { 367 return ""; 368 } 369 370 s = "" + s; 371 372 return s.substr(6, 2) + "/" + s.substr(4, 2) + "/" + s.substr(0, 4); 373 }, 374 375 formatTime(s) { 376 if ((typeof s == "undefined") || (s == "")) { 377 return ""; 378 } 379 380 s = "" + s; 381 382 return s.substr(0, 2) + ":" + s.substr(2, 2) + ":" + s.substr(4, 2); 383 }, 384 385 formatDateTime(s) { 386 if ((typeof s == "undefined") || (s == "")) { 387 return ""; 388 } 389 390 s = "" + s; 391 392 return this.formatDate(s)+" "+this.formatTime(s.substr(8, 6)); 393 }, 394 395 roundRect(ctx, x, y, w, h, r) { 396 if (typeof r === "undefined") { 397 r = 2; 398 } 399 if (w < (2 * r)) { 400 r = w / 2; 401 } 402 if (h < (2 * r)) { 403 r = h / 2; 404 } 405 ctx.beginPath(); 406 ctx.moveTo(x+r, y); 407 ctx.arcTo(x+w, y, x+w, y+h, r); 408 ctx.arcTo(x+w, y+h, x, y+h, r); 409 ctx.arcTo(x, y+h, x, y, r); 410 ctx.arcTo(x, y, x+w, y, r); 411 ctx.closePath(); 412 return ctx; 413 }, 414 415 fillTextRight(ctx, s, x, y) { 416 x = x - ctx.measureText(s).width; 417 ctx.fillText(s, x, y); 418 }, 419 420 drawText(ctx, s, x, y, w, hl) { 421 var i, c = "", a = s.replace("\n", "").split(" "); 422 for(i=0; i<a.length; i++) { 423 if (ctx.measureText(c + " " + a[i]).width > w) { 424 ctx.fillText(c, x, y); 425 c = a[i]; 426 y += hl; 427 } 428 else { 429 if (c != "") { 430 c += " "; 431 } 432 c += a[i]; 433 } 434 } 435 if (c != "") { 436 ctx.fillText(c, x, y); 437 } 438 return y; 439 }, 440 441 442 443 corsEnabled(url) { 444 var xhr = new XMLHttpRequest(); // use sync to avoid popup blocker 445 446 xhr.open('HEAD', url, false); 447 448 try { 449 xhr.send(); 450 } catch (e) { 451 console.log(e.message); 452 } 453 454 return xhr.status >= 200 && xhr.status <= 299; 455 }, 456 457 click(node) { 458 try { 459 node.dispatchEvent(new MouseEvent('click')); 460 } catch(e) { 461 var evt = document.createEvent('MouseEvents'); 462 evt.initMouseEvent('click', true, true, window, 0, 0, 0, 80, 20, false, false, false, false, 0, null); 463 node.dispatchEvent(evt); 464 } 465 }, 466 467 formatSearch(s) { 468 return (s+"").toUpperCase().normalize("NFD").replace(/[\u0300-\u036f]/g, ""); 469 }, 470 471 getCSS: async function(url) { 472 $.get(url, function() { 473 $('<link>', {rel:'stylesheet', type:'text/css', 'href':url}).appendTo('head'); 474 }); 475 }, 476 477 removeAlert() { 478 $("#idAlert").remove(); 479 }, 480 481 displayAlert(s) { 482 var w = $(window).width()
483 var h = $(window).height() 484 var id = "idAlert"; 485 var fontsize = this.isMobile ? 12 : 24; 486 $("#idAlert").remove(); 487 $("body").append( 488 '<div id="idAlert" style="position:fixed;top:0px;left:0px;width:' + w + 'px;height:' + h + 'px;background-color:rgba(0,0,0,0.75);z-index:999999;">'+ 489 '<p style="position:absolute;width:' + w + 'px;font-size:' + fontsize + 'px;font-weight:bold;color:white;top: 50%;transform: translate(0, -50%);text-align:center;">' + s + '<\/p>' + 490 '<\/div>' 491 ); 492 $('#idAlert').click(function() { 493 $('#idAlert').remove() 494 }) 495 }, 496 497 formatDateTimePG(s) { 498 if ((typeof s == "undefined") || (s == null) || (s == "null") || (s == "")) { 499 return ""; 500 } 501 502 s = "" + s; 503 504 return s.substr(8, 2) + "/" + s.substr(5, 2) + "/" + s.substr(0, 4) + " " + 505 s.substr(11, 2) + ":" + s.substr(14, 2) + ":" + s.substr(17, 2); 506 }, 507 508 coalesce(s, s1) { 509 if ((typeof s == "undefined") || (s == null) || (s == "null")) { 510 return s1; 511 } 512 else { 513 return s; 514 } 515 }, 516 517 loadClass(needToLoad, url, ondone, onfail) { 518 if (needToLoad) { 519 jQuery.getScript(url).done(function() { 520 ondone(); 521 }).fail(function() { 522 onfail(); 523 }); 524 } 525 else { 526 // a classe já foi carregada 527 ondone(); 528 } 529 }, 530 531 strZero(i, j) { 532 i = '' + i; 533 while (i.length < j) { 534 i = '0' + i; 535 } 536 return i; 537 }, 538 539 formataPesquisa(s) { 540 return (''+s).normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase(); 541 }, 542 543 now() { 544 var n = new Date(); 545 return n.getFullYear() + (((n.getMonth()+1) < 10)?"0":"") + (n.getMonth()+1) + ((n.getDate() < 10)?"0":"") + n.getDate() + ((n.getHours() < 10)?"0":"") + n.getHours() + ((n.getMinutes() < 10)?"0":"") + n.getMinutes() + ((n.getSeconds() < 10)?"0":"") + n.getSeconds(); 546 }, 547 548 volumeAudioProcess(event) { 549 var buf = event.inputBuffer.getChannelData(0); 550 var bufLength = buf.length; 551 var sum = 0; 552 var x; 553 554 // Do a root-mean-square on the samples: sum up the squares... 555 for (var i=0; i<bufLength; i++) { 556 x = buf[i]; 557 if (Math.abs(x)>=this.clipLevel) { 558 this.clipping = true; 559 this.lastClip = window.performance.now(); 560 } 561 sum += x * x; 562 } 563 564 // ... then take the square root of the sum. 565 var rms = Math.sqrt(sum / bufLength); 566 567 // Now smooth this out with the averaging factor applied 568 // to the previous sample - take the max here because we 569 // want "fast attack, slow release." 570 this.volume = Math.max(rms, this.volume*this.averaging); 571 }, 572 573 createAudioMeter(audioContext,clipLevel,averaging,clipLag) { 574 var processor = audioContext.createScriptProcessor(512); 575 processor.onaudioprocess = fuvUI.volumeAudioProcess; 576 processor.clipping = false; 577 processor.lastClip = 0; 578 processor.volume = 0; 579 processor.clipLevel = clipLevel || 0.98; 580 processor.averaging = averaging || 0.95; 581 processor.clipLag = clipLag || 750; 582 583 // this will have no effect, since we don't copy the input to the output, 584 // but works around a current Chrome bug. 585 processor.connect(audioContext.destination); 586 587 processor.checkClipping = 588 function(){ 589 if (!this.clipping) 590 return false; 591 if ((this.lastClip + this.clipLag) < window.performance.now()) 592 this.clipping = false; 593 return this.clipping; 594 }; 595 596 processor.shutdown = 597 function(){ 598 this.disconnect(); 599 this.onaudioprocess = null; 600 }; 601 602 return processor; 603 }, 604 605 formatCPF(cpf) { 606 cpf = '' + cpf; 607 while (cpf.length < 11) cpf = '0' + cpf; 608 return cpf.substr(0, 3) + '.' + cpf.substr(3, 3) + '.' + cpf.substr(6, 3) + '-' + cpf.substr(9, 2); 609 }, 610 611 formataNome(nome) { 612 var i, a = nome.toLowerCase().split(" "), minusculas = ['de', 'da', 'do', 'das', 'dos', 'em', 'no', 'na', 'e']; 613 for(i = 0; i < a.length; i++) { 614 if (!minusculas.includes(a[i])) { 615 a[i] = a[i].charAt(0).toUpperCase() + a[i].substr(1); 616 } 617 } 618 return a.join(" "); 619 }, 620 621 plural(i, sing, plur) { 622 if (i == 1) { 623 return '1 ' + sing; 624 } 625 else { 626 return i + ' ' + plur; 627 } 628 }, 629 630 fFormatMoney: function(f) { 631 if ((typeof f === "undefined") || (f == null)) { 632 f = 0; 633 } 634 f = parseFloat(f); 635 if (isNaN(f)) { 636 f = 0; 637 } 638 return f.toFixed(2).replace('.', ','); 639 }, 640} 641 642class FuvApresentaMenu { 643 constructor(id, x, y, w, h, items, z, onclose, roundtop) { 644 if (typeof z === "undefined") { 645 z = 0; 646 } 647 if (typeof roundtop === "undefined") {
648 roundtop = true; 649 } 650 var t = this; 651 t.id = id; 652 t.x = x; 653 t.y = y; 654 t.w = w; 655 t.h = h; 656 t.items = items; 657 t.z = z; 658 t.roundtop = roundtop; 659 660 661 662 t.desenha(); 663 664 if (typeof onclose === "undefined") { 665 onclose = function() {}; 666 } 667 t.onclose = onclose; 668 } 669 670 adiciona_itens() { 671 var t = this, i, c = ''; 672 for(i = 0; i < t.items.length; i++) { 673 var divisao = false; 674 if ((t.items[i][2] !== "undefined") && (t.items[i][2] !== null) && (t.items[i][2] === true)) { 675 divisao = true; 676 } 677 c += '<p id="' + t.id + '_item_' + i + '" data-item="' + i + '" style="margin:0px;padding:10px 2px 10px 2px;cursor:pointer;' + ((i == 0) ? '' : ((divisao ? 'border-top:solid 1px black;' : 'border-top:dotted 1px silver'))) + '">' + t.items[i][0] + '<\/p>'; 678 } 679 return c; 680 } 681 682 remove() { 683 var t = this, $ = jQuery; 684 $('#' + t.id + '_background').click(); 685 } 686 687 desenha() { 688 var t = this, $ = jQuery, win = $(window), w = win.width(), h = win.height(), c = ''; 689 690 if (((t.x + t.w) > w) || (t.x < 0)) { 691 if (t.w > w) { 692 t.w = w - 10; 693 } 694 t.x = (w - t.w) / 2; 695 } 696 697 if (t.roundtop) { 698 c = 'border-radius:4px;'; 699 } 700 else { 701 c = 'border-bottom-left-radius:4px;border-bottom-right-radius:4px;'; 702 } 703 704 c = '<div id="' + t.id + '_background" style="position:fixed;top:0px;left:0px;width:' + w + 'px;height:' + h + 'px;background-color:rgba(0,0,0,' + fuvDlgConst.ALPHA_SHADOW_BACKGROUND + ');' + ((t.z == 0) ? '' : ('z-index:' + t.z + ';')) + '"><\/div>' + 705 '<div id="' + t.id + '" style="position:fixed;top:' + t.y + 'px;left:' + t.x + 'px;width:' + t.w + 'px;' + ((t.h == 0) ? '' : ('height:' + t.h + 'px;')) + c + 'box-shadow:0 3px 3px rgba(0,0,0,0.2);background-color:' + fuvDlgConst.COLOR_MENU_BACKGROUND + ';' + ((t.z == 0) ? '' : ('z-index:' + t.z + ';')) + '">' + 706 '<div style="padding:5px;">' + t.adiciona_itens() + 707 '<\/div>' + 708 '<\/div>'; 709 710 $('body').append(c); 711 712 var m = $('#' + t.id), o = m.offset(); 713 if ((o.top + m.height()) > h) { 714 m.css({top: (h - 5 - m.height()) + 'px'}); 715 } 716 //fuvDialogUtils.posicionaDIV(t.id); 717 718 $('#' + t.id + '_close').click(function() { 719 $('#' + t.id + '_background').click(); 720 }); 721 722 $('#' + t.id + '_background').click(function() { 723 $('#' + t.id).remove(); 724 $('#' + t.id + '_background').remove(); 725 t.onclose(); 726 }); 727 728 $("[id^='" + t.id + "_item_']").click(function() { 729 var b = $(this), item = b.data('item'); 730 if ((t.items[item][3] !== "undefined") && (t.items[item][3] !== null) && (t.items[item][3] === true)) { 731 732 } 733 else { 734 //$('#' + t.id + '_background').click(); 735 } 736 t.items[item][1](b); 737 }); 738 } 739} 740 741class FuvApresentaBanner { 742 constructor(id, razao_aspecto, items, el, mostraMenu) { 743 var t = this, $ = jQuery; 744 t.id = id; 745 t.items = items; 746 t.razao_aspecto = razao_aspecto; 747 t.item_index = 0; 748 if (typeof mostraMenu === "undefined") { 749 mostraMenu = false; 750 } 751 t.mostraMenu = mostraMenu; 752 753 if (typeof el === "undefined") { 754 t.el = $('#' + t.id); 755 } 756 else { 757 t.el = $(el); 758 } 759 760 $(window).on('resize.' + t.id, function() { 761 var w = t.el.width(); 762 t.el.height(w / t.razao_aspecto); 763 t.desenha(); 764 }).trigger('resize.' + t.id); 765 } 766 767 verificaBotoes() { 768 var t = this, $ = jQuery; 769 if (t.item_index < (t.items.length-1)) { 770 $('#' + t.id + '_proximo').show(); 771 } 772 else { 773 $('#' + t.id + '_proximo').hide(); 774 } 775 776 if (t.item_index == 0) { 777 $('#' + t.id + '_anterior').hide(); 778 } 779 else { 780 $('#' + t.id + '_anterior').show(); 781 } 782 783 for(var i = 0; i < t.items.length; i++) { 784 if (t.item_index == i) { 785 $('#' + t.id + '_circulo_' + i).html('\uf111'); 786 } 787 else { 788 $('#' + t.id + '_circulo_' + i).html('\uf1db'); 789 } 790 } 791 } 792 793 desenha() { 794 var t = this, $ = jQuery, d = t.el, w = d.width(), h = d.height(), y = d.innerHeight() - 40, c = '', i; 795 796 c += '<div id="' + t.id + '_container" style="position:relative;width:' + w + 'px;height:' + h + 'px;overflow:hidden;">'; 797 c += '<div id="' + t.id + '_banners" style="position:relative;width:' + (w * t.items.length) + 'px;height:' + h + 'px;">'; 798 for(i = 0; i < t.items.length; i++) { 799 c += '<div style="position:absolute;top:0px;left:' + (i * w) + 'px;width:' + w + 'px;height:' + h + 'px;background:url(' + t.items[i][0] + ');background-position:' + t.items[i][1] + ';background-repeat:no-repeat;background-size:cover;">'+ 800 ((t.items[i][3] == '') ? 801 '' : 802 ( 803 '<div style="position:absolute;top:0px;right:0px;overflow:hidden;width:150px;height:150px;transform: rotate(90deg);">' + 804 '<div style="width:200%;text-align:center;margin:50px 0px 0px 0px;padding:5px 40px;background-color:rgba(122,24,24,0.56);color:white;font-size:10px;font-weight:bold;transform: translateY(-50%) translateX(-50%) translateX(50px) rotate(-45deg);">' + t.items[i][3] + '<\/div>' + 805 '<\/div>' 806 )) + 807 '<span style="position:absolute;line-height:100%;left:4px;top:4px;font-size:16px;background-color:rgba(0,0,0,0.2);color:white;padding:4px;">' + t.items[i][2] + '<\/span>' + 808 '<\/div>'; 809 } 810 c += '<\/div>'; 811 c += '<\/div>'; 812 c += '<p style="position:absolute;
812left:0px;bottom:4px;width:' + w + 'px;margin:0px;padding:2px;font-size:16px;text-align:center;">'; 813 for(i = 0; i < t.items.length; i++) { 814 c += '<span id="' + t.id + '_circulo_' + i + '" data-item="' + i + '" style="padding:4px;line-height:100%;color:white;font-family:FontAwesome;font-size:10px;">\uf1db<\/span>'; 815 } 816 c += '<\/p>'; 817 818 819 d.css({position:"relative"}).html( 820 c + 821 ((t.mostraMenu) ? ('<span id="' + t.id + '_menu" style="position:absolute;line-height:100%;right:10px;top:10px;font-family:FontAwesome;font-size:16px;cursor:pointer;background-color:rgba(0,0,0,0.2);color:white;padding:4px;">ï¸<\/span>') : '') + 822 '<span id="' + t.id + '_anterior" style="position:absolute;line-height:100%;left:10px;top:' + y +'px;font-family:FontAwesome;font-size:24px;cursor:pointer;background-color:rgba(0,0,0,0.2);color:white;padding:4px;">ï<\/span>' + 823 '<span id="' + t.id + '_proximo" style="position:absolute;line-height:100%;right:10px;top:' + y + 'px;font-family:FontAwesome;font-size:24px;cursor:pointer;background-color:rgba(0,0,0,0.2);color:white;padding:4px;">ï<\/span>' 824 ); 825 826 $('#' + t.id + '_banners').click(function(e) { 827 window.location.href = t.items[t.item_index][4]; 828 e.stopPropagation(); 829 }); 830 831 $("[id^='" + t.id + "_circulo_']").click(function(e) { 832 var i = $(this).data('item'); 833 t.item_index = i; 834 $('#' + t.id + '_container').animate({scrollLeft: t.item_index * w}, 800); 835 t.verificaBotoes(); 836 e.stopPropagation(); 837 }); 838 839 t.verificaBotoes(); 840 841 var mc = new Hammer(t.el[0]); 842 843 mc.on("swipeleft", function(ev) { 844 $('#' + t.id + '_proximo').click(); 845 }); 846 847 mc.on("swiperight", function(ev) { 848 $('#' + t.id + '_anterior').click(); 849 }); 850 851 $('#' + t.id + '_menu').click(function(e) { 852 var d = $(this), x = d.offset().left, y = d.offset().top, items = [], wm = 240, i; 853 for(i = 0; i < t.items.length; i++) { 854 items.push([t.items[i][2], function(index) { 855 return function() { 856 t.item_index = index; 857 $('#' + t.id + '_container').animate({scrollLeft: t.item_index * w}, 800); 858 t.verificaBotoes(); 859 } 860 }(i)]); 861 } 862 var m = new FuvApresentaMenu(t.id + '_escolhe_edital', x - wm + 8, y + 8, wm, 0, items, 11000); 863 e.stopPropagation(); 864 }); 865 866 $('#' + t.id + '_anterior').click(function(e) { 867 --t.item_index; 868 if (t.item_index < 0) { 869 t.item_index = 0; 870 } 871 $('#' + t.id + '_container').animate({scrollLeft: t.item_index * w}, 800); 872 t.verificaBotoes(); 873 e.stopPropagation(); 874 }); 875 876 $('#' + t.id + '_proximo').click(function(e) { 877 ++t.item_index; 878 if (t.item_index >= t.items.length) { 879 t.item_index = t.items.length - 1; 880 } 881 882 $('#' + t.id + '_container').animate({scrollLeft: t.item_index * w}, 800); 883 t.verificaBotoes(); 884 e.stopPropagation(); 885 }); 886 887 } 888 889 fecha() { 890 var t = this, $ = jQuery; 891 $(window).off('resize.' + t.id); 892 } 893} 894 895class FuvApresentaCalendario { 896 constructor(id, items, el, mostraMenu, padding) { 897 var t = this, $ = jQuery, i; 898 t.id = id; 899 t.items = items; 900 for(i = 0; i < t.items.length; i++) { 901 t.items[i] = t.items[i].split("|"); 902 if ((t.items[i][2] == null) || (t.items[i][2] === "undefined")) { 903 t.items[i][2] = ""; 904 } 905 } 906 907 if (typeof padding === "undefined") { 908 padding = "5px"; 909 } 910 t.padding = padding; 911 912 if (typeof mostraMenu === "undefined") { 913 mostraMenu = false; 914 } 915 t.mostraMenu = mostraMenu; 916 917 t.fontSizeMes = '19px'; 918 t.paddingMes = '16px'; 919 if (typeof el === "undefined") { 920 t.el = $('#' + t.id); 921 } 922 else { 923 t.el = $(el); 924 } 925 926 var v = t.el.data('font-size-mes'); 927 if (v) { 928 t.fontSizeMes = v; 929 } 930 931 v = t.el.data('padding-mes'); 932 if (v) { 933 t.paddingMes = v; 934 } 935 936 t.meses = []; 937 for(i = 0; i < t.items.length; i++) { 938 var mes = t.items[i][0].substr(0, 6); 939 if (t.meses.indexOf(mes) < 0) { 940 t.meses.push(mes); 941 } 942 } 943 t.meses.sort(); 944 t.mesSelecionado = globalMesSelecionado; 945 946 $(window).on('resize.' + t.id, function() { 947 t.desenha(); 948 }).trigger('resize.' + t.id); 949 } 950 951 pegaNomeMes(mes) { 952 return ["Janeiro", "Fevereiro", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Setembro", "Outubro", "Novembro", "Dezembro"][mes - 1]; 953 } 954 955 formataHora(s) { 956 if (s.substr(2, 4) == '0000') { 957 if ((s.length > 6) && (s.charAt(6) == "p")) { 958 return ' - a partir das ' + parseInt(s.substr(0, 2)) + 'h'; 959 } 960 else if ((s.length > 6) && (s.charAt(6) == "a")) { 961 return ' - até as ' + parseInt(s.substr(0, 2)) + 'h'; 962 } 963 else if ((s.length > 6) && (s.charAt(6) == "P")) { 964 return ' <span style="font-size:75%;">(a partir das ' + parseInt(s.substr(0, 2)) + 'h)<\/span>'; 965 } 966 else { 967 return ' - à s ' + parseInt(s.substr(0, 2)) + 'h'; 968 } 969 } 970 else if (s.substr(4, 4) == '00') { 971 return ' - à s ' + parseInt(s.substr(0, 2)) + 'h' + parseInt(s.substr(2, 2)) + 'min'; 972 } 973 else { 974 return s; 975 } 976 } 977 978 formataData(s) { 979 var t = this, c = ''; 980 981 if (s.length > 15) { 982 // duas datas 983 var s2 = s.substr(14, 14), flag = " e "; 984 if (s.substr(0, 6) == s2.substr(0, 6)) { 985 // só varia o dia 986 987 if (s.length > 28) { 988 flag = s.charAt(28); 989 if ((flag == "a") || (flag == "A")) { 990 flag = " a "; 991 } 992 else if ((flag == "e") || (flag == "E")) { 993 flag = " e "; 994 } 995 } 996 997 c = parseInt(s.substr(6, 2)) + flag + parseInt(s2.substr(6, 2)) + ' de ' + t.pegaNomeMes(parseFloat(s.substr(4, 2))) + ' de ' + s.substr(0, 4); 998 } 999 else { 1000 c = s; 1001 } 1002 } 1003 else { 1004 var dia = parseInt(s.substr(6, 2)); 1005 if (dia == 1) { 1006 dia += 'º'; 1007 } 1008 c = dia + ' de ' + t.pegaNomeMes(parseFloat(s.substr(4, 2))) + ' de ' + s.substr(0, 4); 1009 1010 var h = s.substr(8, 7); 1011 if (h.substr(0, 6) != '000000') { 1012 c += t.formataHora(h); 1013 } 1014 } 1015 1016 1017 return c; 1018 } 1019 1020 toDate(s) { 1021 return new Date(s.substr(0, 4), parseInt(s.substr(4, 2)) - 1, s.substr(6, 2), s.substr(8, 2), s.substr(10, 2)); 1022 } 1023 1024 desenhaConteudo(mobile, index) { 1025 var t = this, $ = jQuery, i, c = '', hoje = new Date(); 1026 c += '<ul>'; 1027 for(i = 0; i < t.items.length; i++) { 1028 var mes = t.items[i][0].substr(0, 6), bullet = '\uf111', color = 'gray'; 1029 if (mes == t.meses[index]) { 1030 var data = t.toDate(t.items[i][0]); 1031 1032 if (hoje >= data) { 1033 bullet = '\uf058'; 1034 color = 'green'; 1035 } 1036
1037 c += '<li style="font-family:FontAwesome;list-style-type:\'' + bullet + '\u0020\u0020\';color:' + color + ';font-size:18px;line-height:24px;vertical-align:baseline;padding:' + t.padding + ' 0px;">' + 1038 '<span style="color:#54595f;font-size:18px;font-family:Arial, sans-serif;">'; 1039 1040 c += t.formataData(t.items[i][0]); 1041 c += ' - <span style="font-weight:600;">' + t.items[i][1] + '<\/span>'; 1042 if ((t.items[i][2] != '') || (t.items[i][3] != '')) { 1043 var texto_link = '', cor_link = '#4db14a'; 1044 1045 if (typeof t.items[i][3] !== "undefined") { 1046 texto_link = t.items[i][3]; 1047 } 1048 1049 if (typeof t.items[i][4] !== "undefined") { 1050 cor_link = t.items[i][4]; 1051 } 1052 1053 if (t.items[i][2] == '') { 1054 c += ' <span style="color:' + cor_link + ';font-weight:600;font-size:75%;">' + texto_link + '<\/span>'; 1055 } 1056 else { 1057 if (texto_link == '') { 1058 texto_link = '[clique aqui]'; 1059 } 1060 c += ' <a href="' + t.items[i][2] + '" style="color:' + cor_link + ';font-weight:600;font-size:75%;">' + texto_link + '<\/a>'; 1061 } 1062 } 1063 c += '<\/span><\/li>'; 1064 } 1065 } 1066 c += '<\/ul>'; 1067 $('#' + t.id + '_conteudo').html(c); 1068 1069 if (mobile) { 1070 c = '<div style="font-size:22px;font-family:\'Fira Sans\', sans-serif;">'; 1071 if (index > 0) { 1072 c += '<span id="' + t.id + '_mes_anterior" style="font-size:16px;
1072font-family:FontAwesome;margin-right:20px;cursor:pointer;">ï<\/span>'; 1073 } 1074 1075 c += '<span id="' + t.id + '_apresenta_menu" style="cursor:pointer;position:relative;color:#747e84;"><span style="font-family:FontAwesome;">ï³<\/span> <span style="font-weight:800;">' + t.pegaNomeMes(parseFloat(t.meses[index].substr(4, 2))) + ' de ' + t.meses[index].substr(0, 4) + '<\/span><\/span>'; 1076 1077 if (index < (t.meses.length - 1)) { 1078 c += '<span id="' + t.id + '_proximo_mes" style="font-size:16px;font-family:FontAwesome;cursor:pointer;margin-left:20px;">ï<\/span>'; 1079 } 1080 1081 c += '<\/div>'; 1082 1083 $('#' + t.id + '_cabecalho').html(c); 1084 1085 $('#' + t.id + '_proximo_mes').click(function() { 1086 if (t.mesSelecionado < (t.meses.length - 1)) { 1087 ++t.mesSelecionado; 1088 globalMesSelecionado = t.mesSelecionado; 1089 t.desenhaConteudo(mobile, t.mesSelecionado); 1090 } 1091 }); 1092 1093 $('#' + t.id + '_mes_anterior').click(function() { 1094 if (t.mesSelecionado > 0) { 1095 --t.mesSelecionado; 1096 globalMesSelecionado = t.mesSelecionado; 1097 t.desenhaConteudo(mobile, t.mesSelecionado); 1098 } 1099 }); 1100 1101 $('#' + t.id + '_apresenta_menu').click(function() { 1102 var d = $(this), x = d.offset().left - $(window).scrollLeft(), y = d.offset().top - $(window).scrollTop(), items = [], w = 240, i = 0; 1103 for(i = 0; i < t.meses.length; i++) { 1104 items.push([ 1105 t.pegaNomeMes(parseFloat(t.meses[i].substr(4, 2))) + ' de ' + t.meses[i].substr(0, 4), 1106 function(i1) { 1107 return function() { 1108 t.mesSelecionado = i1; 1109 globalMesSelecionado = t.mesSelecionado; 1110 t.desenhaConteudo(mobile, t.mesSelecionado); 1111 } 1112 }(i) 1113 ]); 1114 } 1115 var menu = new FuvApresentaMenu(i.id + '_menu_meses', x - w + 8, y + 18, w, 0, items, 10000); 1116 }); 1117 } 1118 1119 } 1120 1121 desenha() { 1122 var t = this, $ = jQuery, d = t.el, w = d.width(), h = d.height(), c = '', i, mobile = (w <= 768); 1123 1124 if (t.mesSelecionado < 0) { 1125 // procurar um mês que seja menor ou igual ao mês atual 1126 var hoje = new Date(), mesAtual = fuvUI.strZero(hoje.getFullYear(), 4) + fuvUI.strZero(hoje.getMonth() + 1, 2); 1127 for(i = 0; i < t.meses.length; i++) { 1128 if (t.meses[i] <= mesAtual) { 1129 t.mesSelecionado = i; 1130 globalMesSelecionado = t.mesSelecionado; 1131 } 1132 } 1133 1134 if (t.mesSelecionado < 0) { 1135 t.mesSelecionado = 0; 1136 globalMesSelecionado = t.mesSelecionado; 1137 } 1138 } 1139 1140 if (mobile) { 1141 c += '<div style="padding:10px 20px 10px 10px;background-color:rgb(251,251,251);border:solid 1px rgb(236,236,236);margin-top:-1px;font-size:18px;">'; 1142 c += '<div id="' + t.id + '_cabecalho">Testing....<\/div>'; 1143 c += '<div id="' + t.id + '_conteudo">Testing....<\/div>'; 1144 c += '<\/div>'; 1145 1146 d.css({position:"relative"}).html(c); 1147 1148 t.desenhaConteudo(mobile, t.mesSelecionado); 1149 } 1150 else { 1151 c += '<div>'; 1152 for(i = 0; i < t.meses.length; i++) { 1153 c += '<div id="' + t.id + '_mes_' + i + '" data-indice-mes="' + i + '" style="padding:' + t.paddingMes + ';float:left;cursor:pointer;border:solid 1px transparent;font-size:' + t.fontSizeMes + ';letter-spacing:-1px;font-family:Arial,sans-serif;font-weight:700;color:#747e84;">' + t.pegaNomeMes(parseFloat(t.meses[i].substr(4, 2))).toUpperCase() + '<\/div>'; 1154 } 1155 c += '<div style="clear:both;"><\/div>'; 1156 c += '<\/div>'; 1157 1158 c += '<div id="' + t.id + '_conteudo" style="padding:20px;background-color:rgb(251,251,251);border:solid 1px rgb(236,236,236);margin-top:-2px;font-size:18px;">Testing....<\/div>'; 1159 d.css({position:"relative"}).html(c); 1160 1161 $("[id^='" + t.id + "_mes_']").click(function() { 1162 var d = $(this), index = d.data('indice-mes'), c = '', i; 1163 1164 t.desenhaConteudo(mobile, index); 1165 1166 if (mobile) { 1167 $("[id^='" + t.id + "_mes_']").hide(); 1168 d.show(); 1169 } 1170 else { 1171 $("[id^='" + t.id + "_mes_']").css({border:"solid 1px transparent", backgroundColor:""}); 1172 d.css({border:"solid 1px rgb(236,236,236)", borderBottom:"solid 1px rgba(251,251,251)", backgroundColor:"rgb(251,251,251)"}); 1173 } 1174 }).mouseenter(function() { 1175 var d = $(this); 1176 d.css({color: "#00adee"}); 1177 }).mouseleave(function() { 1178 var d = $(this); 1179 d.css({color: "#747e84"}); 1180 }); 1181 1182 $('#' + t.id + '_mes_' + t.mesSelecionado).click(); 1183 } 1184 1185 } 1186 1187 fecha() { 1188 var t = this, $ = jQuery; 1189 $(window).off('resize.' + t.id); 1190 } 1191} 1192 1193 1194 1195
1196class FuvApresentaMenuLocal { 1197 constructor(id, nome, items, el, top, right, color) { 1198 var t = this, $ = jQuery; 1199 t.id = id; 1200 t.nome = nome; 1201 t.items = items; 1202 t.el = el; 1203 t.top = top; 1204 t.right = right; 1205 t.color = color; 1206 t.zindex = 10000; 1207 t.open = false; 1208 t.menu = [null, null, null, null, null]; 1209 t.w = 240; 1210 1211 $(window).on('resize.' + t.id, function() { 1212 t.desenha(); 1213 }).trigger('resize.' + t.id); 1214 } 1215 1216 apresentaSubmenu(d, nivel) { 1217 var t = this, $ = jQuery, x, y, items = [], i = 0; 1218 1219 var onclose = function() { 1220 t.fecharMenu(); 1221 } 1222 1223 if (nivel == 1) { 1224 x = d.offset().left - $(window).scrollLeft() - t.w + d.width(); 1225 y = d.offset().top - $(window).scrollTop() + d.height(); 1226 } 1227 else { 1228 x = d.offset().left - $(window).scrollLeft() - t.w + 8; 1229 y = d.offset().top - $(window).scrollTop() + 18; 1230 } 1231 1232 for(i = 0; i < t.items[nivel].length; i++) { 1233 var a = t.items[nivel][i].split("|"); 1234 if (a[1].length < 3) { 1235 a[0] += '<span style="font-family:FontAwesome;margin-left:10px;font-size:75%;">\uf0da<\/span>'; 1236 } 1237 items.push([ 1238 a[0], 1239 function(a1) { 1240 return function(it) { 1241 if (a1[1].length < 3) { 1242 // apresenta submenu 1243 //console.log(it, a1); 1244 t.apresentaSubmenu(it, parseFloat(a1[1])); 1245 } 1246 else { 1247 window.location.href = a1[1]; 1248 } 1249 } 1250 }(a), 1251 false, 1252 true 1253 ]); 1254 } 1255 1256 t.menu[nivel] = new FuvApresentaMenu(t.id + '_menu_nivel_' + nivel, x, y, t.w, 0, items, (nivel == 1) ? t.zindex : (t.zindex + 10), (nivel == 1) ? onclose : function() {}, (nivel == 1) ? false : true); 1257 } 1258 1259 fecharMenu() { 1260 var t = this, $ = jQuery; 1261 1262 t.open = false; 1263 $('#' + t.id + '_botao_menu').css({backgroundColor:"transparent", boxShadow:"none", borderBottom: "solid 1px transparent", color: t.color}); 1264 $('#' + t.id + '_botao_menu_icone').html('\uf0c9'); 1265 $('#' + t.id + '_botao_menu_label').hide(); 1266 t.menu[1].remove(); 1267 } 1268 1269 desenha() { 1270 var t = this, $ = jQuery; 1271 1272 $('#' + t.id + '_botao_menu').remove(); 1273 t.el.css({position:"relative"}).append( 1274 '<span id="' + t.id + '_botao_menu" style="position:absolute;width:' + t.w + 'px;height:28px;font-size:24px;cursor:pointer;top:' + t.top + ';right:' + t.right + ';color:' + t.color + ';z-index:' + (t.zindex + 1) + ';border-top-left-radius:4px;border-top-right-radius:4px;">' + 1275 '<span id="' + t.id + '_botao_menu_label" style="position:absolute;top:5px;left:4px;font-size:16px;color:#222;display:none;font-weight:bold;margin:0px;padding:0px;line-height:100%;">' + t.nome + '<\/span>' + 1276 '<span id="' + t.id + '_botao_menu_icone" style="position:absolute;top:2px;right:4px;
1276font-family:FontAwesome;margin:0px;padding:0px;line-height:100%;">\uf0c9<\/span>' + 1277 '<\/span>' 1278 ); 1279 1280 1281 $('#' + t.id + '_botao_menu').click(function() { 1282 if (!t.open) { 1283 t.open = true; 1284 $('#' + t.id + '_botao_menu').css({backgroundColor:"white", color:"black", boxShadow:"0 3px 3px rgba(0,0,0,0.2);", borderBottom: "solid 1px gray"}); 1285 $('#' + t.id + '_botao_menu_label').show(); 1286 $('#' + t.id + '_botao_menu_icone').html('\uf00d'); 1287 t.apresentaSubmenu($(this), 1); 1288 } 1289 else { 1290 t.fecharMenu(); 1291 } 1292 }); 1293 1294 } 1295} 1296 1297 1298class FuvApresentaMenuFull { 1299 constructor(id, x, y, w, h, items, z, onclose, roundtop) { 1300 if (typeof z === "undefined") { 1301 z = 0; 1302 } 1303 if (typeof roundtop === "undefined") { 1304 roundtop = true; 1305 } 1306 var t = this; 1307 t.id = id; 1308 t.x = x; 1309 t.y = y; 1310 t.w = w; 1311 t.h = h; 1312 t.items = items; 1313 t.z = z; 1314 t.roundtop = roundtop; 1315 1316 t.desenha(); 1317 1318 if (typeof onclose === "undefined") { 1319 onclose = function() {}; 1320 } 1321 t.onclose = onclose; 1322 } 1323 1324 adiciona_itens() { 1325 var t = this, i, c = ''; 1326 for(i = 0; i < t.items.length; i++) { 1327 var divisao = false; 1328 if ((t.items[i][2] !== "undefined") && (t.items[i][2] !== null) && (t.items[i][2] === true)) { 1329 divisao = true; 1330 } 1331 c += '<p id="' + t.id + '_item_' + i + '" data-item="' + i + '" style="margin:0px;font-size:16px;padding:10px 2px 10px 2px;cursor:pointer;' + ((i == 0) ? '' : ((divisao ? 'border-top:solid 1px black;' : 'border-top:dotted 1px silver'))) + '">' + t.items[i][0] + '<\/p>'; 1332 } 1333 return c; 1334 } 1335 1336 remove() { 1337 var t = this, $ = jQuery; 1338 $('#' + t.id + '_background').click(); 1339 } 1340 1341 close() { 1342 var $ = jQuery, t = this; 1343 $('#' + t.id).animate({left: t.ww + "px"}, 1000, function() { 1344 $('#' + t.id).remove(); 1345 $('#' + t.id + '_background').remove(); 1346 t.onclose(); 1347 }); 1348 } 1349 1350 desenha() { 1351 var t = this, $ = jQuery, win = $(window), w = win.width(), h = win.height(), c = ''; 1352 1353 if (((t.x + t.w) > w) || (t.x < 0)) { 1354 if (t.w > w) { 1355 t.w = w - 10; 1356 } 1357 t.x = (w - t.w) / 2; 1358 } 1359 1360 if (t.roundtop) { 1361 c = 'border-radius:4px;'; 1362 } 1363 else { 1364 c = 'border-bottom-left-radius:4px;border-bottom-right-radius:4px;'; 1365 } 1366 1367 t.ww = win.width(); 1368 t.w = 300; 1369 t.h = h; 1370 t.y = 0; 1371 t.x = t.ww; 1372 1373 c = '<div id="' + t.id + '_background" style="position:fixed;top:0px;left:0px;bottom:0px;right:0px;background-color:rgba(0,0,0,' + fuvDlgConst.ALPHA_SHADOW_BACKGROUND + ');' + ((t.z == 0) ? '' : ('z-index:' + t.z + ';')) + '"><\/div>' + 1374 '<div id="' + t.id + '" style="position:fixed;top:' + t.y + 'px;left:' + t.x + 'px;width:' + t.w + 'px;' + ((t.h == 0) ? '' : ('height:' + t.h + 'px;')) + c + 'box-shadow:0 3px 3px rgba(0,0,0,0.2);background-color:rgba(255,255,255,0.95);' + ((t.z == 0) ? '' : ('z-index:' + t.z + ';')) + '">' + 1375 '<div style="position:relative;padding:5px;height:' + (t.h - 10) + 'px;">' + 1376 '<p style="text-align:center;margin:5px 0px 5px 0px;"><img src="https://www.fuvest.br/wp-content/uploads/fuvest_logo.png" style="width:180px;"></p>' + 1377 t.adiciona_itens() + 1378 '<div id="' + t.id + '_close" style="position:absolute;padding:4px;border-radius:4px;background-color:rgb(230,230,230);bottom:5px;right:5px;font-size:16px;cursor:pointer;"> <span style="color:gray;
1378font-family:FontAwesome;">\uf00d<\/span> Fechar <\/div>' + 1379 '<\/div>' + 1380 '<\/div>'; 1381 1382 $('body').append(c); 1383 1384 $('#' + t.id).animate({left: (t.ww - t.w) + "px"}, 1000); 1385 1386 1387 $('#' + t.id + '_close').click(function(evt) { 1388 evt.preventDefault(); 1389 $('#' + t.id + '_background').click(); 1390 }); 1391 1392 $('#' + t.id + '_background').click(function() { 1393 t.close(); 1394 }); 1395 1396 $("[id^='" + t.id + "_item_']").click(function(evt) { 1397 var b = $(this), item = b.data('item'), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1398 1399 evt.stopPropagation(); 1400 evt.preventDefault(); 1401 1402 if ((t.items[item][3] !== "undefined") && (t.items[item][3] !== null) && (t.items[item][3] === true)) { 1403 1404 } 1405 else { 1406 //$('#' + t.id + '_background').click(); 1407 } 1408 t.items[item][1](b, x, y, w, h); 1409 }); 1410 } 1411} 1412 1413var fuvFuncoesLocais = { 1414 menuConcursoHospitalUniversitario(p, z) { 1415 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1416 items.push(['Técnico Enfermagem', function() { window.location.href = "https://www.fuvest.br/hospital-universitario-tecnico-enfermagem/" }]); 1417 items.push(['Enfermeiro', function() { window.location.href = "https://www.fuvest.br/hospital-universitario-enfermeiro/" }]); 1418 items.push(['Médico', function() { window.location.href = "https://www.fuvest.br/hospital-universitario-medico/" }]); 1419 var menuConcurso = new FuvApresentaMenu( 1420 'id_apresenta_menu_concurso_hu', 1421 x + w - 240, 1422 y + h, 1423 240, 0, 1424 items, z, 1425 function() { 1426 }, 1427 true) 1428 }, 1429 1430 menuConcurso(p, z) { 1431 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1432 items.push(['Analista de Comunicação', function(b) { window.location.href = "https://www.fuvest.br/analista-comunicacao/" }]); 1433 items.push(['Ãrea da Saúde', function(b) { window.location.href = "https://www.fuvest.br/concursos-area-da-saude/" }]); 1434 items.push(['Bibliotecário', function(b) { window.location.href = "https://www.fuvest.br/bibliotecario/" }]); 1435 items.push(['Educador', function(b) { window.location.href = "https://www.fuvest.br/educador/" }]); 1436 items.push(['Engenheiro Eletricista', function(b) { window.location.href = "https://www.fuvest.br/engenheiro-eletricista/" }]); 1437 items.push(['Especialista Coop/Ext Univ', function(b) { window.location.href = "https://www.fuvest.br/especialista-cooperacao/" }]); 1438 items.push(['Especialista em Laboratório', function(b) { window.location.href = "https://www.fuvest.br/especialista-laboratorio/" }]); 1439 items.push(['Especialista em Pesquisa/Museu', function(b) { window.location.href = "https://www.fuvest.br/especialista-pesquisa/" }]); 1440 items.push(['Médico', function(b) { window.location.href = "https://www.fuvest.br/concurso-medico/" }]); 1441 items.push(['Médico Veterinário', function(b) { window.location.href = "https://www.fuvest.br/veterinario/" }]); 1442 items.push(['Nutricionista', function(b) { window.location.href = "https://www.fuvest.br/nutricionista/" }]); 1443 items.push(['PROFEM', function(b) { window.location.href = "https://www.fuvest.br/profem/" }]); 1444 items.push(['Secretário', function(b) { window.location.href = "https://www.fuvest.br/secretario/" }]); 1445 items.push(['Segundo Solista', function(b) { window.location.href = "https://www.fuvest.br/segundo-solista/" }]); 1446 items.push(['Técnico de Laboratório', function(b) { window.location.href = "https://www.fuvest.br/tecnico-laboratorio/" }]); 1447 items.push(['>> Concursos Anteriores', function(b) { window.location.href = "https://www.fuvest.br/acervo/" }]); 1448 //items.push(['Hospital Universitário <span style="margin-left:20px;color:gray;
1448font-family:FontAwesome;">\uf0da<\/span>', function(b) { fuvFuncoesLocais.menuConcursoHospitalUniversitario(b, z) }]); 1449 //items.push(['Outro Concurso', function(b) { alert('Outro Concurso') }]); 1450 //items.push(['Mais um Concurso', function(b) { alert('Mais um Concurso') }]); 1451 var menuConcurso = new FuvApresentaMenu( 1452 'id_apresenta_menu_concurso', 1453 x + w - 240, 1454 y + h, 1455 240, 0, 1456 items, z, 1457 function() { 1458 }, 1459 true) 1460 }, 1461 1462 menuFAU(p, z) { 1463 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1464 items.push(['Design', function(b) { window.location.href = "https://www.fuvest.br/fauusp/" }]); 1465 items.push(['Arquitetura', function(b) { window.location.href = "https://www.fuvest.br/fauusp/" }]); 1466 var menuConcurso = new FuvApresentaMenu( 1467 'id_apresenta_menu_fau', 1468 x + w - 240, 1469 y + h, 1470 240, 0, 1471 items, z, 1472 function() { 1473 }, 1474 true) 1475 }, 1476 1477 menuFFLCH(p, z) { 1478 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1479 items.push(['Sociologia', function(b) { window.location.href = "https://www.fuvest.br/fflch-sociologia/" }]); 1480 items.push(['História Social', function(b) { window.location.href = "https://www.fuvest.br/fflch-historia-social/" }]); 1481 var menuConcurso = new FuvApresentaMenu( 1482 'id_apresenta_menu_fflch', 1483 x + w - 240, 1484 y + h, 1485 240, 0, 1486 items, z, 1487 function() { 1488 }, 1489 true) 1490 }, 1491 1492 menuResidenciaFMUSP(p, z) { 1493 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1494 items.push(['Editais 1 a 6', function(b) { window.location.href = "https://www.fuvest.br/residencia-medica//" }]); 1495 items.push(['Edital 7', function(b) { window.location.href = "https://www.fuvest.br/residencia-medica-072023/" }]); 1496 var menuConcurso = new FuvApresentaMenu( 1497 'id_apresenta_menu_residencia_FMUSP', 1498 x + w - 240, 1499 y + h, 1500 240, 0, 1501 items, z, 1502 function() { 1503 }, 1504 true) 1505 }, 1506 1507 menuDireito(p, z) { 1508 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1509 items.push(['Conhecimentos JurÃdicos', function(b) { window.location.href = "https://www.fuvest.br/direito/" }]); 1510 var menuConcurso = new FuvApresentaMenu( 1511 'id_apresenta_menu_direito', 1512 x + w - 240, 1513 y + h, 1514 240, 0, 1515 items, z, 1516 function() { 1517 }, 1518 true) 1519 }, 1520 1521 menuGraduacao(p, z) { 1522 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1523 items.push(['Vestibular', function(b) { window.location.href = "https://www.fuvest.br/vestibular-da-usp" }]); 1524 items.push(['ENEM-USP', function(b) { window.location.href = "https://www.fuvest.br/enem-usp/" }]); 1525 items.push(['Transferência USP', function(b) { window.location.href = "https://www.fuvest.br/transferencia/" }]); 1526 items.push(['Competições do Conhecimento', function(b) { window.location.href = "https://www.fuvest.br/olimpiadas/" }]); 1527 1528 var menuConcurso = new FuvApresentaMenu( 1529 'id_apresenta_menu_graduacao', 1530 x + w - 240, 1531 y + h, 1532 240, 0, 1533 items, z, 1534 function() { 1535 }, 1536 true) 1537 }, 1538 1539 1540 menuPosgraduacao(p, z) { 1541 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1542 items.push(['EESC', function(b) { window.location.href = "https://www.fuvest.br/eescusp/" }]); 1543 items.push(['FAU <span style="margin-left:20px;color:gray;
1543font-family:FontAwesome;">\uf0da<\/span>', function(b) { fuvFuncoesLocais.menuFAU(b, z) }]); 1544 items.push(['FFLCH <span style="margin-left:20px;color:gray;font-family:FontAwesome;">\uf0da<\/span>', function(b) { fuvFuncoesLocais.menuFFLCH(b, z) }]); 1545 1546 items.push(['FD', function(b) { window.location.href = "https://www.fuvest.br/direito/" }]); 1547 items.push(['FMRP', function(b) { window.location.href = "https://www.fuvest.br/fmrpusp/" }]); 1548 items.push(['IP', function(b) { window.location.href = "https://www.fuvest.br/ipusp/" }]); 1549 items.push(['IRI', function(b) { window.location.href = "https://www.fuvest.br/iriusp/" }]); 1550 items.push(['Proficiência em LÃnguas Estrangeiras', function(b) { window.location.href = "https://www.fuvest.br/proficiencia/" }]); 1551 1552 var menuConcurso = new FuvApresentaMenu( 1553 'id_apresenta_menu_posgraduacao', 1554 x + w - 240, 1555 y + h, 1556 240, 0, 1557 items, z, 1558 function() { 1559 }, 1560 true) 1561 }, 1562 1563 menuResidencia(p, z) { 1564 var $ = jQuery, items = [], b = $(p), x = b.offset().left, y = b.offset().top, w = b.width(), h = b.height(); 1565 items.push(['Residência em área da Saúde', function(b) { window.location.href = "https://www.fuvest.br/residencia-area-profissional-da-saude/" }]); 1566 items.push(['Residência Médica-FMUSP', function(b) { window.location.href = "https://www.fuvest.br/residencia-medica" }]); 1567 // items.push(['Residência Médica-FMUSP <span style="margin-left:20px;color:gray;
1567font-family:FontAwesome;">\uf0da<\/span>', function(b) { fuvFuncoesLocais.menuResidenciaFMUSP(b, z) }]); 1568 items.push(['Residência Médica-HRACUSP', function(b) { window.location.href = "https://www.fuvest.br/residencia-medica-hracusp/" }]); 1569 var menuConcurso = new FuvApresentaMenu( 1570 'id_apresenta_menu_residencia', 1571 x + w - 240, 1572 y + h, 1573 240, 0, 1574 items, z, 1575 function() { 1576 }, 1577 true) 1578 }, 1579 1580 verificaSecoes(tipoTela) { 1581 var $ = jQuery; 1582 1583 $('section[data-menu-local]').each(function(index) { 1584 var e = $(this), tipo = '' + e.data('elemento'), mostrar = '' + e.data('mostrar-em'), elementos = [], items = [null], i, j, id = "id_elemento_menu_local_" + index; 1585 for(i = 1;i < 16; i++) { 1586 var el = e.data('menu-item-' + i + '-1'); 1587 if ((typeof el !== "undefined") && (el != null)) { 1588 // existe informação sobre o menu 1 1589 var menu_item = []; 1590 for(j = 1;j < 16; j++) { 1591 el = e.data('menu-item-' + i + '-' + j); 1592 if ((typeof el !== "undefined") && (el != null)) { 1593 menu_item.push(el); 1594 } 1595 } 1596 items[i] = menu_item; 1597 } 1598 } 1599 elementos.push(new FuvApresentaMenuLocal(id, e.data('menu-local'), items, e, e.data('menu-top'), e.data('menu-right'), e.data('menu-color'))); 1600 }); 1601 1602 if (!globalBackgroundAlterado) { 1603 globalBackgroundAlterado = true; 1604 $('section[data-backdinamico]').each(function(index) { 1605 var e = $(this), a = e.data('backdinamico').split(','), i = Math.floor(Math.random() * a.length); 1606 1607 e.css({ 1608 "background-color" : "#ffffff", 1609 "background-image" : "url(" + a[i] + ")", 1610 "background-position" : "bottom center", 1611 "background-repeat" : "no-repeat", 1612 "background-size" : "contain" 1613 }); 1614 1615 }); 1616 } 1617 1618 $('section[data-elemento]').each(function(index) { 1619 var e = $(this), tipo = '' + e.data('elemento'), mostrar = '' + e.data('mostrar-em'), elementos = []; 1620 if (mostrar.indexOf(tipoTela) >= 0) { 1621 if (tipo == 'carrossel') { 1622 var numero_items = parseInt(e.data('numero-items')), apresentaMenu = e.data('apresenta-menu'), parametros = [], i = 0, razao_aspecto = parseFloat(e.data('razao-aspecto')), id = "id_carrossel_" + index; 1623 for (i = 1; i <= numero_items; i++) { 1624 parametros.push([ 1625 e.data('imagem-' + i), 1626 e.data('centro-' + i), 1627 e.data('texto-' + i), 1628 e.data('faixa-' + i), 1629 e.data('url-' + i) 1630 ]); 1631 } 1632 elementos.push(new FuvApresentaBanner(id, razao_aspecto, parametros, e, apresentaMenu == "S")); 1633 } 1634 else if (tipo == 'calendario') { 1635 var numero_items = parseInt(e.data('numero-items')), apresentaMenu = e.data('apresenta-menu'), parametros = [], i = 0, id = "id_elemento_calendario_" + index; 1636 for (i = 1; i <= numero_items; i++) { 1637 parametros.push(e.data('elemento-' + i)); 1638 } 1639 elementos.push(new FuvApresentaCalendario(id, parametros, e, apresentaMenu == "S", e.data('padding'))); 1640 } 1641 } 1642 }); 1643 1644 window.setTimeout(() => { 1645 $("[id^='id_banner_edital_aviso_2025_']").remove() 1646 for(var numCarrossel = 1; numCarrossel < 10; numCarrossel++) { 1647 $('[data-carrossel="' + numCarrossel + '"] [data-swiper-slide-index]').each(function(car) { 1648 return function(index) { 1649 var o = $(this); 1650 1651 o.click(function() { 1652 var indice = $(this).data('swiper-slide-index'), pai = $('[data-carrossel="' + car + '"]'), url = pai.data('edital-onclick-' + (parseFloat(indice) + 1)); 1653 if (url) { 1654 window.location.href = url; 1655 } 1656 //alert('clicado no indice [' + car + '][' + indice + '][' + url + ']'); 1657 1658 }).css({cursor: 'pointer'}); 1659 1660 var pai = $('[data-carrossel="' + car + '"]'), 1661 o1 = o.children('div.elementor-testimonial'), 1662 now = fuvUI.now(), 1663 idx = o.data('swiper-slide-index') + 1, 1664 d_inscr_ini = pai.data('edital-inicio-inscricao-' + idx), 1665 d_inscr_fim = pai.data('edital-fim-inscricao-' + idx), 1666 d_inscr_img = pai.data('edital-img-inscricao-' + idx), 1667 d_inscr_x = pai.data('edital-x-inscricao-' + idx), 1668 d_inscr_y = pai.data('edital-y-inscricao-' + idx), 1669 d_inscr_w = pai.data('edital-w-inscricao-' + idx),
1670 d_isencao_ini = pai.data('edital-inicio-isencao-' + idx), 1671 d_isencao_fim = pai.data('edital-fim-isencao-' + idx), 1672 d_isencao_img = pai.data('edital-img-isencao-' + idx), 1673 d_isencao_x = pai.data('edital-x-isencao-' + idx), 1674 d_isencao_y = pai.data('edital-y-isencao-' + idx), 1675 d_isencao_w = pai.data('edital-w-isencao-' + idx), 1676 d_edital_fim = pai.data('edital-fim-encerramento-' + idx); 1677 1678 if (d_inscr_ini && d_inscr_fim) { 1679 if ((now >= d_inscr_ini) && (now <= d_inscr_fim)) { 1680 if (fuvUI.isNull(d_inscr_img)) { 1681 d_inscr_img = '/wp-content/uploads/inscricoes_abertas.png'; 1682 } 1683 1684 if (fuvUI.isNull(d_inscr_x)) { 1685 d_inscr_x = 0; 1686 } 1687 1688 if (fuvUI.isNull(d_inscr_y)) { 1689 d_inscr_y = 0; 1690 } 1691 1692 if (fuvUI.isNull(d_inscr_w)) { 1693 d_inscr_w = 100; 1694 } 1695 1696 $(`#id_banner_edital_aviso_2025_i_${car}_${index}`).remove(); 1697 o1.append(`<img id="id_banner_edital_aviso_2025_i_${car}_${index}" style="position:absolute;top:${d_inscr_y}px;left:${d_inscr_x}px;width:${d_inscr_w}px;height:auto;" src="${d_inscr_img}">`); 1698 return; 1699 } 1700 } 1701 1702 if (d_isencao_ini && d_isencao_fim) { 1703 if ((now >= d_isencao_ini) && (now <= d_isencao_fim)) { 1704 if (fuvUI.isNull(d_isencao_img)) { 1705 d_isencao_img = '/wp-content/uploads/reducoes_abertas.png'; 1706 } 1707 1708 if (fuvUI.isNull(d_isencao_x)) { 1709 d_isencao_x = 0; 1710 } 1711 1712 if (fuvUI.isNull(d_isencao_y)) { 1713 d_isencao_y = 0; 1714 } 1715 1716 if (fuvUI.isNull(d_isencao_w)) { 1717 d_isencao_w = 100; 1718 } 1719 1720 $(`#id_banner_edital_aviso_2025_r_${car}_${index}`).remove(); 1721 o1.append(`<img id="id_banner_edital_aviso_2025_r_${car}_${index}" style="position:absolute;top:${d_isencao_y}px;left:${d_isencao_x}px;width:${d_isencao_w}px;height:auto;" src="${d_isencao_img}">`); 1722 return; 1723 } 1724 } 1725 1726 } 1727 }(numCarrossel)); 1728 } 1729 }, 1000); 1730 1731 $('section[data-inscricao]').each(function(index) { 1732 var d = $(this), codigo = d.data('inscricao'), 1733 topo = d.data('inscricao-top'), 1734 direita = d.data('inscricao-right'), 1735 bottom = d.data('inscricao-bottom'), 1736 c = '', 1737 tipo = d.data('inscricao-tipo'), 1738 color = d.data('inscricao-color'), 1739 url = d.data('inscricao-url'), 1740 texto = d.data('inscricao-texto'), 1741 icone = d.data('inscricao-icone'), 1742 mostrarEm = d.data('inscricao-mostrar-em'); 1743 1744 // remove todos os botões, caso existam 1745 $("[id^='id_inscricao_edital_']").remove(); 1746 1747 if (typeof topo === "undefined") { 1748 if (typeof bottom === "undefined") { 1749 topo = d.data('inscricao-topo'); 1750 if (typeof topo === "undefined") { 1751 topo = "10px"; 1752 } 1753 } 1754 } 1755 1756 if (typeof mostrarEm === "undefined") { 1757 mostrarEm = "mobile"; 1758 } 1759 1760 if (typeof color === "undefined") { 1761 color = "white"; 1762 } 1763 1764 if (typeof direita === "undefined") { 1765 direita = "6px"; 1766 } 1767 1768 if (typeof url === "undefined") { 1769 if (tipo == 'area-candidato') { 1770 url = "https://app.fuvest.br/login"; 1771 } 1772 else { 1773 url = "https://app.fuvest.br/concurso?hash_identificacao=" + codigo; 1774 } 1775 } 1776 1777 if (typeof texto === "undefined") { 1778 if (tipo == 'area-candidato') { 1779 texto = "ÃREA DO<br>CANDIDATO"; 1780 } 1781 else if (tipo == 'inscricao') { 1782 texto = "FAÃA AQUI A<br>SUA INSCRIÃÃO"; 1783 } 1784 else if (tipo == 'isencao') { 1785 texto = "FAÃA AQUI SEU<br>PEDIDO DE ISENÃÃO"; 1786 } 1787 else if (tipo == 'reducao') { 1788 texto = "FAÃA AQUI SEU<br>PEDIDO DE REDUCAO"; 1789 } 1790 else { 1791 texto = ""; 1792 } 1793 } 1794 1795 if (typeof icone === "undefined") { 1796 if (tipo == 'area-candidato') { 1797 icone = "f007"; 1798 } 1799 else if (tipo == 'inscricao') { 1800 icone = "f234"; 1801 } 1802 else if (tipo == 'isencao') { 1803 icone = "f234"; 1804 } 1805 else if (tipo == 'reducao') { 1806 icone = "f234"; 1807 } 1808 else { 1809 icone = "f234"; 1810 } 1811 } 1812 1813 if (mostrarEm.indexOf(tipoTela) >= 0) { 1814 var s = ''; 1815 if (typeof bottom === "undefined") { 1816 s = 'top:' + topo + ';'; 1817 } 1818 else { 1819 s = 'bottom:' + bottom + ';'; 1820 } 1821 c = '<span id="id_inscricao_edital_' + codigo + '_' + index + '" style="position:absolute;' + s + 'right:' + direita + ';padding:4px;color:' + color + ';line-height:100%;text-align:center;cursor:pointer;">' + 1822 '<span style="font-size:40px;
1822font-family:FontAwesome;line-height:100%;">&#x' + icone + ';<\/span><br>' + 1823 '<span style="font-size:13px;font-family:\'Fira Sans\';font-weight:bold;line-height:15px;">' + texto + '<\/span><br>' + 1824 '<\/span>'; 1825 d.css({position:"relative"}).append(c); 1826 1827 $('#id_inscricao_edital_' + codigo + '_' + index).click(function(url1) { 1828 return function() { 1829 window.location.href = url1; 1830 } 1831 }(url)); 1832 } 1833 }); 1834 1835 // remover todos os avisos 1836 $("[id^='id_banner_edital_aviso']").remove(); 1837 $('.elementor-skin-carousel').each(function(index, carousel) { 1838 var o = $(carousel), items = o.data('status-edital'); 1839 for(var i = 1; i <= items; i++) { 1840 $(`[data-swiper-slide-index='${i - 1}']`).each(function(carousel1) { 1841 return function(index, el) { 1842 var o = $(el), avo = o.parent().parent().parent().parent().parent(); 1843 if (carousel1.data('id') == avo.data('id')) { 1844 var idx = o.data('swiper-slide-index') + 1, now = fuvUI.now(), 1845 d_inscr_ini = carousel1.data('edital-inicio-inscricao-' + idx), 1846 d_inscr_fim = carousel1.data('edital-fim-inscricao-' + idx), 1847 d_isencao_ini = carousel1.data('edital-inicio-isencao-' + idx), 1848 d_isencao_fim = carousel1.data('edital-fim-isencao-' + idx), 1849 d_edital_fim = carousel1.data('edital-fim-encerramento-' + idx); 1850 1851 //console.log(now, d_inscr_ini, d_inscr_fim); 1852 if (d_inscr_ini && d_inscr_fim) { 1853 o.css({position: "relative"}); 1854 if ((now >= d_inscr_ini) && (now <= d_inscr_fim)) { 1855 o.append('<img id="id_banner_edital_aviso" style="position:absolute;top:0px;left:0px;" src="/wp-content/uploads/inscricoes_abertas.png">'); 1856 return; 1857 } 1858 } 1859 1860 if (d_isencao_ini && d_isencao_fim) { 1861 o.css({position: "relative"}); 1862 if ((now >= d_isencao_ini) && (now <= d_isencao_fim)) { 1863 o.append('<img id="id_banner_edital_aviso" style="position:absolute;top:0px;left:0px;" src="/wp-content/uploads/reducoes_abertas.png">'); 1864 return; 1865 } 1866 } 1867 } 1868 } 1869 }(o)); 1870 } 1871 }); 1872 1873 } 1874} 1875 1876jQuery(document).ready(function() { 1877 var $ = jQuery, wwin = $(window).width(), isMobile = (wwin < 768), tipoTela = 'desktop', menu = null; 1878 $('#site-header').css({'z-index': 20}); 1879 1880 $(window).resize(function() { 1881 wwin = $(window).width(); 1882 isMobile = (wwin < 768); 1883 1884 if (wwin < 768) { 1885 tipoTela = 'mobile'; 1886 } 1887 else if (wwin < 1025) { 1888 tipoTela = 'tablet'; 1889 } 1890 1891 fuvFuncoesLocais.verificaSecoes(tipoTela); 1892 1893 if (menu != null) { 1894 menu.remove(); 1895 menu = null; 1896 return; 1897 } 1898 1899 if ($('#id_menu_principal').length > 0) { 1900 $('#id_menu_principal').remove(); 1901 } 1902 1903 1904 }).resize(); 1905 1906 if (wwin < 768) { 1907 tipoTela = 'mobile'; 1908 } 1909 else if (wwin < 1025) { 1910 tipoTela = 'tablet'; 1911 } 1912 1913 if (isMobile) { 1914 1915 } 1916 1917 1918 1919 //jQuery('#wpadminbar.mobile').css({position:"absolute", top:"-24px"}); 1920 if (isMobile) { 1921 jQuery('.a11y-toolbar').css({top: "auto", bottom: "10px"}); 1922 } 1923 1924 jsGlobalLoadScript("https://bin.fuvest.br/js/lgpd.js", function() { 1925 1926 }, 'utf-8'); 1927 1928 jsGlobalLoadScript("https://bin.fuvest.br/js/wpel.js", function() { 1929 1930 }, 'utf-8'); 1931 1932 if (true) { 1933 var c = `<div vw class="enabled">` + 1934 `<div vw-access-button class="active"></div>` + 1935 `<div vw-plugin-wrapper>` + 1936 `<div class="vw-plugin-top-wrapper"></div>` + 1937 `</div>` + 1938 `</div>`; 1939 jQuery('body').append(c); 1940 1941 jQuery.ajax({ 1942 url: "https://vlibras.gov.br/app/vlibras-plugin.js", 1943 dataType: "script", 1944 scriptCharset: "utf-8", 1945 success: function(script, textStatus) { 1946 console.log('loaded'); 1947 try { 1948 new window.VLibras.Widget('https://vlibras.gov.br/app'); 1949 } 1950 catch(e) { 1951 console.log(e); 1952 } 1953 }, 1954 error:function(jqxhr, settings, e) { 1955 console.log(e); 1956 } 1957 }); 1958 } 1959 1960 1961 1962 const urlAtual = new URLSearchParams(window.location.search), 1963 param1 = urlAtual.get('utm_source'), 1964 param2 = urlAtual.get('utm_medium'), 1965 param3 = urlAtual.get('utm_campaign'), 1966 param4 = urlAtual.get('utm_content'), 1967 param5 = urlAtual.get('utm_term'), 1968 paramsParaAdicionar = {}; 1969 1970 if (param1 !== null && param1.trim() !== '') { 1971 paramsParaAdicionar['utm_source'] = param1; 1972 } 1973 if (param2 !== null && param2.trim() !== '') { 1974 paramsParaAdicionar['utm_medium'] = param2; 1975 } 1976 if (param3 !== null && param3.trim() !== '') { 1977 paramsParaAdicionar['utm_campaign'] = param3; 1978 } 1979 if (param4 !== null && param4.trim() !== '') { 1980 paramsParaAdicionar['utm_content'] = param4; 1981 } 1982 if (param5 !== null && param5.trim() !== '') { 1983 paramsParaAdicionar['utm_term'] = param5; 1984 } 1985 1986 if (Object.keys(paramsParaAdicionar).length > 0) { 1987 const links = document.querySelectorAll('a[href]'); 1988 1989 links.forEach(link => { 1990 const hrefOriginal = link.getAttribute('href'); 1991 1992 // Ignora âncoras locais, links vazios ou esquemas especiais (javascript, mailto, tel) 1993 if (!hrefOriginal || hrefOriginal.startsWith('#') || hrefOriginal.startsWith('javascript:') || hrefOriginal.startsWith('mailto:') || hrefOriginal.startsWith('tel:')) { 1994 1995 } 1996 else { 1997 try { 1998 // Cria o objeto URL preservando caminhos relativos ou absolutos 1999 const urlDestino = new URL(hrefOriginal, window.location.href); 2000 2001 for (const [chave, valor] of Object.entries(paramsParaAdicionar)) { 2002 urlDestino.searchParams.set(chave, valor); 2003 } 2004 2005 // Se o link original era relativo, mantém relativo; caso contrário, usa a URL completa 2006 if (!hrefOriginal.startsWith('http://') && !hrefOriginal.startsWith('https://') && !hrefOriginal.startsWith('//')) { 2007 link.setAttribute('href', urlDestino.pathname + urlDestino.search + urlDestino.hash); 2008 } else { 2009 link.setAttribute('href', urlDestino.href); 2010 } 2011 } catch (e) { 2012 // Ignora URLs com formato inválido 2013 } 2014 } 2015 }) 2016 } 2017 2018});
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.