Diferencia entre revisiones de «Widget:QuizStyle»

De CNB
Ir a la navegación Ir a la búsqueda
Busca en cnbGuatemala con Google

(Página creada con «<script> /** * ***** BEGIN LICENSE BLOCK ***** * This file is part of Quiz. * Copyright © 2007 Louis-Rémi Babe. All rights reserved. * * Quiz is free software; you c...»)
 
 
(No se muestran 2 ediciones intermedias del mismo usuario)
Línea 150: Línea 150:
 
}
 
}
 
})();
 
})();
 +
/*
 +
* qTip2 - Pretty powerful tooltips - v2.2.0
 +
* http://qtip2.com
 +
*
 +
* Copyright (c) 2013 Craig Michael Thompson
 +
* Released under the MIT, GPL licenses
 +
* http://jquery.org/license
 +
*
 +
* Date: Thu Nov 21 2013 08:34 GMT+0000
 +
* Plugins: tips modal viewport svg imagemap ie6
 +
* Styles: basic css3
 +
*/
 +
/*global window: false, jQuery: false, console: false, define: false */
 +
 +
/* Cache window, document, undefined */
 +
(function( window, document, undefined ) {
 +
 +
// Uses AMD or browser globals to create a jQuery plugin.
 +
(function( factory ) {
 +
"use strict";
 +
if(typeof define === 'function' && define.amd) {
 +
define(['jquery'], factory);
 +
}
 +
else if(jQuery && !jQuery.fn.qtip) {
 +
factory(jQuery);
 +
}
 +
}
 +
(function($) {
 +
"use strict"; // Enable ECMAScript "strict" operation for this function. See more: http://ejohn.org/blog/ecmascript-5-strict-mode-json-and-more/
 +
 +
;// Munge the primitives - Paul Irish tip
 +
var TRUE = true,
 +
FALSE = false,
 +
NULL = null,
 +
 +
// Common variables
 +
X = 'x', Y = 'y',
 +
WIDTH = 'width',
 +
HEIGHT = 'height',
 +
 +
// Positioning sides
 +
TOP = 'top',
 +
LEFT = 'left',
 +
BOTTOM = 'bottom',
 +
RIGHT = 'right',
 +
CENTER = 'center',
 +
 +
// Position adjustment types
 +
FLIP = 'flip',
 +
FLIPINVERT = 'flipinvert',
 +
SHIFT = 'shift',
 +
 +
// Shortcut vars
 +
QTIP, PROTOTYPE, CORNER, CHECKS,
 +
PLUGINS = {},
 +
NAMESPACE = 'qtip',
 +
ATTR_HAS = 'data-hasqtip',
 +
ATTR_ID = 'data-qtip-id',
 +
WIDGET = ['ui-widget', 'ui-tooltip'],
 +
SELECTOR = '.'+NAMESPACE,
 +
INACTIVE_EVENTS = 'click dblclick mousedown mouseup mousemove mouseleave mouseenter'.split(' '),
 +
 +
CLASS_FIXED = NAMESPACE+'-fixed',
 +
CLASS_DEFAULT = NAMESPACE + '-default',
 +
CLASS_FOCUS = NAMESPACE + '-focus',
 +
CLASS_HOVER = NAMESPACE + '-hover',
 +
CLASS_DISABLED = NAMESPACE+'-disabled',
 +
 +
replaceSuffix = '_replacedByqTip',
 +
oldtitle = 'oldtitle',
 +
trackingBound,
 +
 +
// Browser detection
 +
BROWSER = {
 +
/*
 +
* IE version detection
 +
*
 +
* Adapted from: http://ajaxian.com/archives/attack-of-the-ie-conditional-comment
 +
* Credit to James Padolsey for the original implemntation!
 +
*/
 +
ie: (function(){
 +
var v = 3, div = document.createElement('div');
 +
while ((div.innerHTML = '<!--[if gt IE '+(++v)+']><i></i><![endif]-->')) {
 +
if(!div.getElementsByTagName('i')[0]) { break; }
 +
}
 +
return v > 4 ? v : NaN;
 +
}()),
 +
 +
/*
 +
* iOS version detection
 +
*/
 +
iOS: parseFloat(
 +
('' + (/CPU.*OS ([0-9_]{1,5})|(CPU like).*AppleWebKit.*Mobile/i.exec(navigator.userAgent) || [0,''])[1])
 +
.replace('undefined', '3_2').replace('_', '.').replace('_', '')
 +
) || FALSE
 +
};
 +
 +
;function QTip(target, options, id, attr) {
 +
// Elements and ID
 +
this.id = id;
 +
this.target = target;
 +
this.tooltip = NULL;
 +
this.elements = { target: target };
 +
 +
// Internal constructs
 +
this._id = NAMESPACE + '-' + id;
 +
this.timers = { img: {} };
 +
this.options = options;
 +
this.plugins = {};
 +
 +
// Cache object
 +
this.cache = {
 +
event: {},
 +
target: $(),
 +
disabled: FALSE,
 +
attr: attr,
 +
onTooltip: FALSE,
 +
lastClass: ''
 +
};
 +
 +
// Set the initial flags
 +
this.rendered = this.destroyed = this.disabled = this.waiting =
 +
this.hiddenDuringWait = this.positioning = this.triggering = FALSE;
 +
}
 +
PROTOTYPE = QTip.prototype;
 +
 +
PROTOTYPE._when = function(deferreds) {
 +
return $.when.apply($, deferreds);
 +
};
 +
 +
PROTOTYPE.render = function(show) {
 +
if(this.rendered || this.destroyed) { return this; } // If tooltip has already been rendered, exit
 +
 +
var self = this,
 +
options = this.options,
 +
cache = this.cache,
 +
elements = this.elements,
 +
text = options.content.text,
 +
title = options.content.title,
 +
button = options.content.button,
 +
posOptions = options.position,
 +
namespace = '.'+this._id+' ',
 +
deferreds = [],
 +
tooltip;
 +
 +
// Add ARIA attributes to target
 +
$.attr(this.target[0], 'aria-describedby', this._id);
 +
 +
// Create tooltip element
 +
this.tooltip = elements.tooltip = tooltip = $('<div/>', {
 +
'id': this._id,
 +
'class': [ NAMESPACE, CLASS_DEFAULT, options.style.classes, NAMESPACE + '-pos-' + options.position.my.abbrev() ].join(' '),
 +
'width': options.style.width || '',
 +
'height': options.style.height || '',
 +
'tracking': posOptions.target === 'mouse' && posOptions.adjust.mouse,
 +
 +
/* ARIA specific attributes */
 +
'role': 'alert',
 +
'aria-live': 'polite',
 +
'aria-atomic': FALSE,
 +
'aria-describedby': this._id + '-content',
 +
'aria-hidden': TRUE
 +
})
 +
.toggleClass(CLASS_DISABLED, this.disabled)
 +
.attr(ATTR_ID, this.id)
 +
.data(NAMESPACE, this)
 +
.appendTo(posOptions.container)
 +
.append(
 +
// Create content element
 +
elements.content = $('<div />', {
 +
'class': NAMESPACE + '-content',
 +
'id': this._id + '-content',
 +
'aria-atomic': TRUE
 +
})
 +
);
 +
 +
// Set rendered flag and prevent redundant reposition calls for now
 +
this.rendered = -1;
 +
this.positioning = TRUE;
 +
 +
// Create title...
 +
if(title) {
 +
this._createTitle();
 +
 +
// Update title only if its not a callback (called in toggle if so)
 +
if(!$.isFunction(title)) {
 +
deferreds.push( this._updateTitle(title, FALSE) );
 +
}
 +
}
 +
 +
// Create button
 +
if(button) { this._createButton(); }
 +
 +
// Set proper rendered flag and update content if not a callback function (called in toggle)
 +
if(!$.isFunction(text)) {
 +
deferreds.push( this._updateContent(text, FALSE) );
 +
}
 +
this.rendered = TRUE;
 +
 +
// Setup widget classes
 +
this._setWidget();
 +
 +
// Initialize 'render' plugins
 +
$.each(PLUGINS, function(name) {
 +
var instance;
 +
if(this.initialize === 'render' && (instance = this(self))) {
 +
self.plugins[name] = instance;
 +
}
 +
});
 +
 +
// Unassign initial events and assign proper events
 +
this._unassignEvents();
 +
this._assignEvents();
 +
 +
// When deferreds have completed
 +
this._when(deferreds).then(function() {
 +
// tooltiprender event
 +
self._trigger('render');
 +
 +
// Reset flags
 +
self.positioning = FALSE;
 +
 +
// Show tooltip if not hidden during wait period
 +
if(!self.hiddenDuringWait && (options.show.ready || show)) {
 +
self.toggle(TRUE, cache.event, FALSE);
 +
}
 +
self.hiddenDuringWait = FALSE;
 +
});
 +
 +
// Expose API
 +
QTIP.api[this.id] = this;
 +
 +
return this;
 +
};
 +
 +
PROTOTYPE.destroy = function(immediate) {
 +
// Set flag the signify destroy is taking place to plugins
 +
// and ensure it only gets destroyed once!
 +
if(this.destroyed) { return this.target; }
 +
 +
function process() {
 +
if(this.destroyed) { return; }
 +
this.destroyed = TRUE;
 +
 +
var target = this.target,
 +
title = target.attr(oldtitle);
 +
 +
// Destroy tooltip if rendered
 +
if(this.rendered) {
 +
this.tooltip.stop(1,0).find('*').remove().end().remove();
 +
}
 +
 +
// Destroy all plugins
 +
$.each(this.plugins, function(name) {
 +
this.destroy && this.destroy();
 +
});
 +
 +
// Clear timers and remove bound events
 +
clearTimeout(this.timers.show);
 +
clearTimeout(this.timers.hide);
 +
this._unassignEvents();
 +
 +
// Remove api object and ARIA attributes
 +
target.removeData(NAMESPACE)
 +
.removeAttr(ATTR_ID)
 +
.removeAttr(ATTR_HAS)
 +
.removeAttr('aria-describedby');
 +
 +
// Reset old title attribute if removed
 +
if(this.options.suppress && title) {
 +
target.attr('title', title).removeAttr(oldtitle);
 +
}
 +
 +
// Remove qTip events associated with this API
 +
this._unbind(target);
 +
 +
// Remove ID from used id objects, and delete object references
 +
// for better garbage collection and leak protection
 +
this.options = this.elements = this.cache = this.timers =
 +
this.plugins = this.mouse = NULL;
 +
 +
// Delete epoxsed API object
 +
delete QTIP.api[this.id];
 +
}
 +
 +
// If an immediate destory is needed
 +
if((immediate !== TRUE || this.triggering === 'hide') && this.rendered) {
 +
this.tooltip.one('tooltiphidden', $.proxy(process, this));
 +
!this.triggering && this.hide();
 +
}
 +
 +
// If we're not in the process of hiding... process
 +
else { process.call(this); }
 +
 +
return this.target;
 +
};
 +
 +
;function invalidOpt(a) {
 +
return a === NULL || $.type(a) !== 'object';
 +
}
 +
 +
function invalidContent(c) {
 +
return !( $.isFunction(c) || (c && c.attr) || c.length || ($.type(c) === 'object' && (c.jquery || c.then) ));
 +
}
 +
 +
// Option object sanitizer
 +
function sanitizeOptions(opts) {
 +
var content, text, ajax, once;
 +
 +
if(invalidOpt(opts)) { return FALSE; }
 +
 +
if(invalidOpt(opts.metadata)) {
 +
opts.metadata = { type: opts.metadata };
 +
}
 +
 +
if('content' in opts) {
 +
content = opts.content;
 +
 +
if(invalidOpt(content) || content.jquery || content.done) {
 +
content = opts.content = {
 +
text: (text = invalidContent(content) ? FALSE : content)
 +
};
 +
}
 +
else { text = content.text; }
 +
 +
// DEPRECATED - Old content.ajax plugin functionality
 +
// Converts it into the proper Deferred syntax
 +
if('ajax' in content) {
 +
ajax = content.ajax;
 +
once = ajax && ajax.once !== FALSE;
 +
delete content.ajax;
 +
 +
content.text = function(event, api) {
 +
var loading = text || $(this).attr(api.options.content.attr) || 'Loading...',
 +
 +
deferred = $.ajax(
 +
$.extend({}, ajax, { context: api })
 +
)
 +
.then(ajax.success, NULL, ajax.error)
 +
.then(function(content) {
 +
if(content && once) { api.set('content.text', content); }
 +
return content;
 +
},
 +
function(xhr, status, error) {
 +
if(api.destroyed || xhr.status === 0) { return; }
 +
api.set('content.text', status + ': ' + error);
 +
});
 +
 +
return !once ? (api.set('content.text', loading), deferred) : loading;
 +
};
 +
}
 +
 +
if('title' in content) {
 +
if(!invalidOpt(content.title)) {
 +
content.button = content.title.button;
 +
content.title = content.title.text;
 +
}
 +
 +
if(invalidContent(content.title || FALSE)) {
 +
content.title = FALSE;
 +
}
 +
}
 +
}
 +
 +
if('position' in opts && invalidOpt(opts.position)) {
 +
opts.position = { my: opts.position, at: opts.position };
 +
}
 +
 +
if('show' in opts && invalidOpt(opts.show)) {
 +
opts.show = opts.show.jquery ? { target: opts.show } :
 +
opts.show === TRUE ? { ready: TRUE } : { event: opts.show };
 +
}
 +
 +
if('hide' in opts && invalidOpt(opts.hide)) {
 +
opts.hide = opts.hide.jquery ? { target: opts.hide } : { event: opts.hide };
 +
}
 +
 +
if('style' in opts && invalidOpt(opts.style)) {
 +
opts.style = { classes: opts.style };
 +
}
 +
 +
// Sanitize plugin options
 +
$.each(PLUGINS, function() {
 +
this.sanitize && this.sanitize(opts);
 +
});
 +
 +
return opts;
 +
}
 +
 +
// Setup builtin .set() option checks
 +
CHECKS = PROTOTYPE.checks = {
 +
builtin: {
 +
// Core checks
 +
'^id$': function(obj, o, v, prev) {
 +
var id = v === TRUE ? QTIP.nextid : v,
 +
new_id = NAMESPACE + '-' + id;
 +
 +
if(id !== FALSE && id.length > 0 && !$('#'+new_id).length) {
 +
this._id = new_id;
 +
 +
if(this.rendered) {
 +
this.tooltip[0].id = this._id;
 +
this.elements.content[0].id = this._id + '-content';
 +
this.elements.title[0].id = this._id + '-title';
 +
}
 +
}
 +
else { obj[o] = prev; }
 +
},
 +
'^prerender': function(obj, o, v) {
 +
v && !this.rendered && this.render(this.options.show.ready);
 +
},
 +
 +
// Content checks
 +
'^content.text$': function(obj, o, v) {
 +
this._updateContent(v);
 +
},
 +
'^content.attr$': function(obj, o, v, prev) {
 +
if(this.options.content.text === this.target.attr(prev)) {
 +
this._updateContent( this.target.attr(v) );
 +
}
 +
},
 +
'^content.title$': function(obj, o, v) {
 +
// Remove title if content is null
 +
if(!v) { return this._removeTitle(); }
 +
 +
// If title isn't already created, create it now and update
 +
v && !this.elements.title && this._createTitle();
 +
this._updateTitle(v);
 +
},
 +
'^content.button$': function(obj, o, v) {
 +
this._updateButton(v);
 +
},
 +
'^content.title.(text|button)$': function(obj, o, v) {
 +
this.set('content.'+o, v); // Backwards title.text/button compat
 +
},
 +
 +
// Position checks
 +
'^position.(my|at)$': function(obj, o, v){
 +
'string' === typeof v && (obj[o] = new CORNER(v, o === 'at'));
 +
},
 +
'^position.container$': function(obj, o, v){
 +
this.rendered && this.tooltip.appendTo(v);
 +
},
 +
 +
// Show checks
 +
'^show.ready$': function(obj, o, v) {
 +
v && (!this.rendered && this.render(TRUE) || this.toggle(TRUE));
 +
},
 +
 +
// Style checks
 +
'^style.classes$': function(obj, o, v, p) {
 +
this.rendered && this.tooltip.removeClass(p).addClass(v);
 +
},
 +
'^style.(width|height)': function(obj, o, v) {
 +
this.rendered && this.tooltip.css(o, v);
 +
},
 +
'^style.widget|content.title': function() {
 +
this.rendered && this._setWidget();
 +
},
 +
'^style.def': function(obj, o, v) {
 +
this.rendered && this.tooltip.toggleClass(CLASS_DEFAULT, !!v);
 +
},
 +
 +
// Events check
 +
'^events.(render|show|move|hide|focus|blur)$': function(obj, o, v) {
 +
this.rendered && this.tooltip[($.isFunction(v) ? '' : 'un') + 'bind']('tooltip'+o, v);
 +
},
 +
 +
// Properties which require event reassignment
 +
'^(show|hide|position).(event|target|fixed|inactive|leave|distance|viewport|adjust)': function() {
 +
if(!this.rendered) { return; }
 +
 +
// Set tracking flag
 +
var posOptions = this.options.position;
 +
this.tooltip.attr('tracking', posOptions.target === 'mouse' && posOptions.adjust.mouse);
 +
 +
// Reassign events
 +
this._unassignEvents();
 +
this._assignEvents();
 +
}
 +
}
 +
};
 +
 +
// Dot notation converter
 +
function convertNotation(options, notation) {
 +
var i = 0, obj, option = options,
 +
 +
// Split notation into array
 +
levels = notation.split('.');
 +
 +
// Loop through
 +
while( option = option[ levels[i++] ] ) {
 +
if(i < levels.length) { obj = option; }
 +
}
 +
 +
return [obj || options, levels.pop()];
 +
}
 +
 +
PROTOTYPE.get = function(notation) {
 +
if(this.destroyed) { return this; }
 +
 +
var o = convertNotation(this.options, notation.toLowerCase()),
 +
result = o[0][ o[1] ];
 +
 +
return result.precedance ? result.string() : result;
 +
};
 +
 +
function setCallback(notation, args) {
 +
var category, rule, match;
 +
 +
for(category in this.checks) {
 +
for(rule in this.checks[category]) {
 +
if(match = (new RegExp(rule, 'i')).exec(notation)) {
 +
args.push(match);
 +
 +
if(category === 'builtin' || this.plugins[category]) {
 +
this.checks[category][rule].apply(
 +
this.plugins[category] || this, args
 +
);
 +
}
 +
}
 +
}
 +
}
 +
}
 +
 +
var rmove = /^position\.(my|at|adjust|target|container|viewport)|style|content|show\.ready/i,
 +
rrender = /^prerender|show\.ready/i;
 +
 +
PROTOTYPE.set = function(option, value) {
 +
if(this.destroyed) { return this; }
 +
 +
var rendered = this.rendered,
 +
reposition = FALSE,
 +
options = this.options,
 +
checks = this.checks,
 +
name;
 +
 +
// Convert singular option/value pair into object form
 +
if('string' === typeof option) {
 +
name = option; option = {}; option[name] = value;
 +
}
 +
else { option = $.extend({}, option); }
 +
 +
// Set all of the defined options to their new values
 +
$.each(option, function(notation, value) {
 +
if(rendered && rrender.test(notation)) {
 +
delete option[notation]; return;
 +
}
 +
 +
// Set new obj value
 +
var obj = convertNotation(options, notation.toLowerCase()), previous;
 +
previous = obj[0][ obj[1] ];
 +
obj[0][ obj[1] ] = value && value.nodeType ? $(value) : value;
 +
 +
// Also check if we need to reposition
 +
reposition = rmove.test(notation) || reposition;
 +
 +
// Set the new params for the callback
 +
option[notation] = [obj[0], obj[1], value, previous];
 +
});
 +
 +
// Re-sanitize options
 +
sanitizeOptions(options);
 +
 +
/*
 +
* Execute any valid callbacks for the set options
 +
* Also set positioning flag so we don't get loads of redundant repositioning calls.
 +
*/
 +
this.positioning = TRUE;
 +
$.each(option, $.proxy(setCallback, this));
 +
this.positioning = FALSE;
 +
 +
// Update position if needed
 +
if(this.rendered && this.tooltip[0].offsetWidth > 0 && reposition) {
 +
this.reposition( options.position.target === 'mouse' ? NULL : this.cache.event );
 +
}
 +
 +
return this;
 +
};
 +
 +
;PROTOTYPE._update = function(content, element, reposition) {
 +
var self = this,
 +
cache = this.cache;
 +
 +
// Make sure tooltip is rendered and content is defined. If not return
 +
if(!this.rendered || !content) { return FALSE; }
 +
 +
// Use function to parse content
 +
if($.isFunction(content)) {
 +
content = content.call(this.elements.target, cache.event, this) || '';
 +
}
 +
 +
// Handle deferred content
 +
if($.isFunction(content.then)) {
 +
cache.waiting = TRUE;
 +
return content.then(function(c) {
 +
cache.waiting = FALSE;
 +
return self._update(c, element);
 +
}, NULL, function(e) {
 +
return self._update(e, element);
 +
});
 +
}
 +
 +
// If content is null... return false
 +
if(content === FALSE || (!content && content !== '')) { return FALSE; }
 +
 +
// Append new content if its a DOM array and show it if hidden
 +
if(content.jquery && content.length > 0) {
 +
element.empty().append(
 +
content.css({ display: 'block', visibility: 'visible' })
 +
);
 +
}
 +
 +
// Content is a regular string, insert the new content
 +
else { element.html(content); }
 +
 +
// Wait for content to be loaded, and reposition
 +
return this._waitForContent(element).then(function(images) {
 +
if(images.images && images.images.length && self.rendered && self.tooltip[0].offsetWidth > 0) {
 +
self.reposition(cache.event, !images.length);
 +
}
 +
});
 +
};
 +
 +
PROTOTYPE._waitForContent = function(element) {
 +
var cache = this.cache;
 +
 +
// Set flag
 +
cache.waiting = TRUE;
 +
 +
// If imagesLoaded is included, ensure images have loaded and return promise
 +
return ( $.fn.imagesLoaded ? element.imagesLoaded() : $.Deferred().resolve([]) )
 +
.done(function() { cache.waiting = FALSE; })
 +
.promise();
 +
};
 +
 +
PROTOTYPE._updateContent = function(content, reposition) {
 +
this._update(content, this.elements.content, reposition);
 +
};
 +
 +
PROTOTYPE._updateTitle = function(content, reposition) {
 +
if(this._update(content, this.elements.title, reposition) === FALSE) {
 +
this._removeTitle(FALSE);
 +
}
 +
};
 +
 +
PROTOTYPE._createTitle = function()
 +
{
 +
var elements = this.elements,
 +
id = this._id+'-title';
 +
 +
// Destroy previous title element, if present
 +
if(elements.titlebar) { this._removeTitle(); }
 +
 +
// Create title bar and title elements
 +
elements.titlebar = $('<div />', {
 +
'class': NAMESPACE + '-titlebar ' + (this.options.style.widget ? createWidgetClass('header') : '')
 +
})
 +
.append(
 +
elements.title = $('<div />', {
 +
'id': id,
 +
'class': NAMESPACE + '-title',
 +
'aria-atomic': TRUE
 +
})
 +
)
 +
.insertBefore(elements.content)
 +
 +
// Button-specific events
 +
.delegate('.qtip-close', 'mousedown keydown mouseup keyup mouseout', function(event) {
 +
$(this).toggleClass('ui-state-active ui-state-focus', event.type.substr(-4) === 'down');
 +
})
 +
.delegate('.qtip-close', 'mouseover mouseout', function(event){
 +
$(this).toggleClass('ui-state-hover', event.type === 'mouseover');
 +
});
 +
 +
// Create button if enabled
 +
if(this.options.content.button) { this._createButton(); }
 +
};
 +
 +
PROTOTYPE._removeTitle = function(reposition)
 +
{
 +
var elements = this.elements;
 +
 +
if(elements.title) {
 +
elements.titlebar.remove();
 +
elements.titlebar = elements.title = elements.button = NULL;
 +
 +
// Reposition if enabled
 +
if(reposition !== FALSE) { this.reposition(); }
 +
}
 +
};
 +
 +
;PROTOTYPE.reposition = function(event, effect) {
 +
if(!this.rendered || this.positioning || this.destroyed) { return this; }
 +
 +
// Set positioning flag
 +
this.positioning = TRUE;
 +
 +
var cache = this.cache,
 +
tooltip = this.tooltip,
 +
posOptions = this.options.position,
 +
target = posOptions.target,
 +
my = posOptions.my,
 +
at = posOptions.at,
 +
viewport = posOptions.viewport,
 +
container = posOptions.container,
 +
adjust = posOptions.adjust,
 +
method = adjust.method.split(' '),
 +
tooltipWidth = tooltip.outerWidth(FALSE),
 +
tooltipHeight = tooltip.outerHeight(FALSE),
 +
targetWidth = 0,
 +
targetHeight = 0,
 +
type = tooltip.css('position'),
 +
position = { left: 0, top: 0 },
 +
visible = tooltip[0].offsetWidth > 0,
 +
isScroll = event && event.type === 'scroll',
 +
win = $(window),
 +
doc = container[0].ownerDocument,
 +
mouse = this.mouse,
 +
pluginCalculations, offset;
 +
 +
// Check if absolute position was passed
 +
if($.isArray(target) && target.length === 2) {
 +
// Force left top and set position
 +
at = { x: LEFT, y: TOP };
 +
position = { left: target[0], top: target[1] };
 +
}
 +
 +
// Check if mouse was the target
 +
else if(target === 'mouse') {
 +
// Force left top to allow flipping
 +
at = { x: LEFT, y: TOP };
 +
 +
// Use the cached mouse coordinates if available, or passed event has no coordinates
 +
if(mouse && mouse.pageX && (adjust.mouse || !event || !event.pageX) ) {
 +
event = mouse;
 +
}
 +
 +
// If the passed event has no coordinates (such as a scroll event)
 +
else if(!event || !event.pageX) {
 +
// Use the mouse origin that caused the show event, if distance hiding is enabled
 +
if((!adjust.mouse || this.options.show.distance) && cache.origin && cache.origin.pageX) {
 +
event =  cache.origin;
 +
}
 +
 +
// Use cached event for resize/scroll events
 +
else if(!event || (event && (event.type === 'resize' || event.type === 'scroll'))) {
 +
event = cache.event;
 +
}
 +
}
 +
 +
// Calculate body and container offset and take them into account below
 +
if(type !== 'static') { position = container.offset(); }
 +
if(doc.body.offsetWidth !== (window.innerWidth || doc.documentElement.clientWidth)) {
 +
offset = $(document.body).offset();
 +
}
 +
 +
// Use event coordinates for position
 +
position = {
 +
left: event.pageX - position.left + (offset && offset.left || 0),
 +
top: event.pageY - position.top + (offset && offset.top || 0)
 +
};
 +
 +
// Scroll events are a pain, some browsers
 +
if(adjust.mouse && isScroll && mouse) {
 +
position.left -= (mouse.scrollX || 0) - win.scrollLeft();
 +
position.top -= (mouse.scrollY || 0) - win.scrollTop();
 +
}
 +
}
 +
 +
// Target wasn't mouse or absolute...
 +
else {
 +
// Check if event targetting is being used
 +
if(target === 'event') {
 +
if(event && event.target && event.type !== 'scroll' && event.type !== 'resize') {
 +
cache.target = $(event.target);
 +
}
 +
else if(!event.target) {
 +
cache.target = this.elements.target;
 +
}
 +
}
 +
else if(target !== 'event'){
 +
cache.target = $(target.jquery ? target : this.elements.target);
 +
}
 +
target = cache.target;
 +
 +
// Parse the target into a jQuery object and make sure there's an element present
 +
target = $(target).eq(0);
 +
if(target.length === 0) { return this; }
 +
 +
// Check if window or document is the target
 +
else if(target[0] === document || target[0] === window) {
 +
targetWidth = BROWSER.iOS ? window.innerWidth : target.width();
 +
targetHeight = BROWSER.iOS ? window.innerHeight : target.height();
 +
 +
if(target[0] === window) {
 +
position = {
 +
top: (viewport || target).scrollTop(),
 +
left: (viewport || target).scrollLeft()
 +
};
 +
}
 +
}
 +
 +
// Check if the target is an <AREA> element
 +
else if(PLUGINS.imagemap && target.is('area')) {
 +
pluginCalculations = PLUGINS.imagemap(this, target, at, PLUGINS.viewport ? method : FALSE);
 +
}
 +
 +
// Check if the target is an SVG element
 +
else if(PLUGINS.svg && target && target[0].ownerSVGElement) {
 +
pluginCalculations = PLUGINS.svg(this, target, at, PLUGINS.viewport ? method : FALSE);
 +
}
 +
 +
// Otherwise use regular jQuery methods
 +
else {
 +
targetWidth = target.outerWidth(FALSE);
 +
targetHeight = target.outerHeight(FALSE);
 +
position = target.offset();
 +
}
 +
 +
// Parse returned plugin values into proper variables
 +
if(pluginCalculations) {
 +
targetWidth = pluginCalculations.width;
 +
targetHeight = pluginCalculations.height;
 +
offset = pluginCalculations.offset;
 +
position = pluginCalculations.position;
 +
}
 +
 +
// Adjust position to take into account offset parents
 +
position = this.reposition.offset(target, position, container);
 +
 +
// Adjust for position.fixed tooltips (and also iOS scroll bug in v3.2-4.0 & v4.3-4.3.2)
 +
if((BROWSER.iOS > 3.1 && BROWSER.iOS < 4.1) ||
 +
(BROWSER.iOS >= 4.3 && BROWSER.iOS < 4.33) ||
 +
(!BROWSER.iOS && type === 'fixed')
 +
){
 +
position.left -= win.scrollLeft();
 +
position.top -= win.scrollTop();
 +
}
 +
 +
// Adjust position relative to target
 +
if(!pluginCalculations || (pluginCalculations && pluginCalculations.adjustable !== FALSE)) {
 +
position.left += at.x === RIGHT ? targetWidth : at.x === CENTER ? targetWidth / 2 : 0;
 +
position.top += at.y === BOTTOM ? targetHeight : at.y === CENTER ? targetHeight / 2 : 0;
 +
}
 +
}
 +
 +
// Adjust position relative to tooltip
 +
position.left += adjust.x + (my.x === RIGHT ? -tooltipWidth : my.x === CENTER ? -tooltipWidth / 2 : 0);
 +
position.top += adjust.y + (my.y === BOTTOM ? -tooltipHeight : my.y === CENTER ? -tooltipHeight / 2 : 0);
 +
 +
// Use viewport adjustment plugin if enabled
 +
if(PLUGINS.viewport) {
 +
position.adjusted = PLUGINS.viewport(
 +
this, position, posOptions, targetWidth, targetHeight, tooltipWidth, tooltipHeight
 +
);
 +
 +
// Apply offsets supplied by positioning plugin (if used)
 +
if(offset && position.adjusted.left) { position.left += offset.left; }
 +
if(offset && position.adjusted.top) {  position.top += offset.top; }
 +
}
 +
 +
// Viewport adjustment is disabled, set values to zero
 +
else { position.adjusted = { left: 0, top: 0 }; }
 +
 +
// tooltipmove event
 +
if(!this._trigger('move', [position, viewport.elem || viewport], event)) { return this; }
 +
delete position.adjusted;
 +
 +
// If effect is disabled, target it mouse, no animation is defined or positioning gives NaN out, set CSS directly
 +
if(effect === FALSE || !visible || isNaN(position.left) || isNaN(position.top) || target === 'mouse' || !$.isFunction(posOptions.effect)) {
 +
tooltip.css(position);
 +
}
 +
 +
// Use custom function if provided
 +
else if($.isFunction(posOptions.effect)) {
 +
posOptions.effect.call(tooltip, this, $.extend({}, position));
 +
tooltip.queue(function(next) {
 +
// Reset attributes to avoid cross-browser rendering bugs
 +
$(this).css({ opacity: '', height: '' });
 +
if(BROWSER.ie) { this.style.removeAttribute('filter'); }
 +
 +
next();
 +
});
 +
}
 +
 +
// Set positioning flag
 +
this.positioning = FALSE;
 +
 +
return this;
 +
};
 +
 +
// Custom (more correct for qTip!) offset calculator
 +
PROTOTYPE.reposition.offset = function(elem, pos, container) {
 +
if(!container[0]) { return pos; }
 +
 +
var ownerDocument = $(elem[0].ownerDocument),
 +
quirks = !!BROWSER.ie && document.compatMode !== 'CSS1Compat',
 +
parent = container[0],
 +
scrolled, position, parentOffset, overflow;
 +
 +
function scroll(e, i) {
 +
pos.left += i * e.scrollLeft();
 +
pos.top += i * e.scrollTop();
 +
}
 +
 +
// Compensate for non-static containers offset
 +
do {
 +
if((position = $.css(parent, 'position')) !== 'static') {
 +
if(position === 'fixed') {
 +
parentOffset = parent.getBoundingClientRect();
 +
scroll(ownerDocument, -1);
 +
}
 +
else {
 +
parentOffset = $(parent).position();
 +
parentOffset.left += (parseFloat($.css(parent, 'borderLeftWidth')) || 0);
 +
parentOffset.top += (parseFloat($.css(parent, 'borderTopWidth')) || 0);
 +
}
 +
 +
pos.left -= parentOffset.left + (parseFloat($.css(parent, 'marginLeft')) || 0);
 +
pos.top -= parentOffset.top + (parseFloat($.css(parent, 'marginTop')) || 0);
 +
 +
// If this is the first parent element with an overflow of "scroll" or "auto", store it
 +
if(!scrolled && (overflow = $.css(parent, 'overflow')) !== 'hidden' && overflow !== 'visible') { scrolled = $(parent); }
 +
}
 +
}
 +
while((parent = parent.offsetParent));
 +
 +
// Compensate for containers scroll if it also has an offsetParent (or in IE quirks mode)
 +
if(scrolled && (scrolled[0] !== ownerDocument[0] || quirks)) {
 +
scroll(scrolled, 1);
 +
}
 +
 +
return pos;
 +
};
 +
 +
// Corner class
 +
var C = (CORNER = PROTOTYPE.reposition.Corner = function(corner, forceY) {
 +
corner = ('' + corner).replace(/([A-Z])/, ' $1').replace(/middle/gi, CENTER).toLowerCase();
 +
this.x = (corner.match(/left|right/i) || corner.match(/center/) || ['inherit'])[0].toLowerCase();
 +
this.y = (corner.match(/top|bottom|center/i) || ['inherit'])[0].toLowerCase();
 +
this.forceY = !!forceY;
 +
 +
var f = corner.charAt(0);
 +
this.precedance = (f === 't' || f === 'b' ? Y : X);
 +
}).prototype;
 +
 +
C.invert = function(z, center) {
 +
this[z] = this[z] === LEFT ? RIGHT : this[z] === RIGHT ? LEFT : center || this[z];
 +
};
 +
 +
C.string = function() {
 +
var x = this.x, y = this.y;
 +
return x === y ? x : this.precedance === Y || (this.forceY && y !== 'center') ? y+' '+x : x+' '+y;
 +
};
 +
 +
C.abbrev = function() {
 +
var result = this.string().split(' ');
 +
return result[0].charAt(0) + (result[1] && result[1].charAt(0) || '');
 +
};
 +
 +
C.clone = function() {
 +
return new CORNER( this.string(), this.forceY );
 +
};;
 +
PROTOTYPE.toggle = function(state, event) {
 +
var cache = this.cache,
 +
options = this.options,
 +
tooltip = this.tooltip;
 +
 +
// Try to prevent flickering when tooltip overlaps show element
 +
if(event) {
 +
if((/over|enter/).test(event.type) && (/out|leave/).test(cache.event.type) &&
 +
options.show.target.add(event.target).length === options.show.target.length &&
 +
tooltip.has(event.relatedTarget).length) {
 +
return this;
 +
}
 +
 +
// Cache event
 +
cache.event = cloneEvent(event);
 +
}
 +
 +
// If we're currently waiting and we've just hidden... stop it
 +
this.waiting && !state && (this.hiddenDuringWait = TRUE);
 +
 +
// Render the tooltip if showing and it isn't already
 +
if(!this.rendered) { return state ? this.render(1) : this; }
 +
else if(this.destroyed || this.disabled) { return this; }
 +
 +
var type = state ? 'show' : 'hide',
 +
opts = this.options[type],
 +
otherOpts = this.options[ !state ? 'show' : 'hide' ],
 +
posOptions = this.options.position,
 +
contentOptions = this.options.content,
 +
width = this.tooltip.css('width'),
 +
visible = this.tooltip.is(':visible'),
 +
animate = state || opts.target.length === 1,
 +
sameTarget = !event || opts.target.length < 2 || cache.target[0] === event.target,
 +
identicalState, allow, showEvent, delay, after;
 +
 +
// Detect state if valid one isn't provided
 +
if((typeof state).search('boolean|number')) { state = !visible; }
 +
 +
// Check if the tooltip is in an identical state to the new would-be state
 +
identicalState = !tooltip.is(':animated') && visible === state && sameTarget;
 +
 +
// Fire tooltip(show/hide) event and check if destroyed
 +
allow = !identicalState ? !!this._trigger(type, [90]) : NULL;
 +
 +
// Check to make sure the tooltip wasn't destroyed in the callback
 +
if(this.destroyed) { return this; }
 +
 +
// If the user didn't stop the method prematurely and we're showing the tooltip, focus it
 +
if(allow !== FALSE && state) { this.focus(event); }
 +
 +
// If the state hasn't changed or the user stopped it, return early
 +
if(!allow || identicalState) { return this; }
 +
 +
// Set ARIA hidden attribute
 +
$.attr(tooltip[0], 'aria-hidden', !!!state);
 +
 +
// Execute state specific properties
 +
if(state) {
 +
// Store show origin coordinates
 +
cache.origin = cloneEvent(this.mouse);
 +
 +
// Update tooltip content & title if it's a dynamic function
 +
if($.isFunction(contentOptions.text)) { this._updateContent(contentOptions.text, FALSE); }
 +
if($.isFunction(contentOptions.title)) { this._updateTitle(contentOptions.title, FALSE); }
 +
 +
// Cache mousemove events for positioning purposes (if not already tracking)
 +
if(!trackingBound && posOptions.target === 'mouse' && posOptions.adjust.mouse) {
 +
$(document).bind('mousemove.'+NAMESPACE, this._storeMouse);
 +
trackingBound = TRUE;
 +
}
 +
 +
// Update the tooltip position (set width first to prevent viewport/max-width issues)
 +
if(!width) { tooltip.css('width', tooltip.outerWidth(FALSE)); }
 +
this.reposition(event, arguments[2]);
 +
if(!width) { tooltip.css('width', ''); }
 +
 +
// Hide other tooltips if tooltip is solo
 +
if(!!opts.solo) {
 +
(typeof opts.solo === 'string' ? $(opts.solo) : $(SELECTOR, opts.solo))
 +
.not(tooltip).not(opts.target).qtip('hide', $.Event('tooltipsolo'));
 +
}
 +
}
 +
else {
 +
// Clear show timer if we're hiding
 +
clearTimeout(this.timers.show);
 +
 +
// Remove cached origin on hide
 +
delete cache.origin;
 +
 +
// Remove mouse tracking event if not needed (all tracking qTips are hidden)
 +
if(trackingBound && !$(SELECTOR+'[tracking="true"]:visible', opts.solo).not(tooltip).length) {
 +
$(document).unbind('mousemove.'+NAMESPACE);
 +
trackingBound = FALSE;
 +
}
 +
 +
// Blur the tooltip
 +
this.blur(event);
 +
}
 +
 +
// Define post-animation, state specific properties
 +
after = $.proxy(function() {
 +
if(state) {
 +
// Prevent antialias from disappearing in IE by removing filter
 +
if(BROWSER.ie) { tooltip[0].style.removeAttribute('filter'); }
 +
 +
// Remove overflow setting to prevent tip bugs
 +
tooltip.css('overflow', '');
 +
 +
// Autofocus elements if enabled
 +
if('string' === typeof opts.autofocus) {
 +
$(this.options.show.autofocus, tooltip).focus();
 +
}
 +
 +
// If set, hide tooltip when inactive for delay period
 +
this.options.show.target.trigger('qtip-'+this.id+'-inactive');
 +
}
 +
else {
 +
// Reset CSS states
 +
tooltip.css({
 +
display: '',
 +
visibility: '',
 +
opacity: '',
 +
left: '',
 +
top: ''
 +
});
 +
}
 +
 +
// tooltipvisible/tooltiphidden events
 +
this._trigger(state ? 'visible' : 'hidden');
 +
}, this);
 +
 +
// If no effect type is supplied, use a simple toggle
 +
if(opts.effect === FALSE || animate === FALSE) {
 +
tooltip[ type ]();
 +
after();
 +
}
 +
 +
// Use custom function if provided
 +
else if($.isFunction(opts.effect)) {
 +
tooltip.stop(1, 1);
 +
opts.effect.call(tooltip, this);
 +
tooltip.queue('fx', function(n) {
 +
after(); n();
 +
});
 +
}
 +
 +
// Use basic fade function by default
 +
else { tooltip.fadeTo(90, state ? 1 : 0, after); }
 +
 +
// If inactive hide method is set, active it
 +
if(state) { opts.target.trigger('qtip-'+this.id+'-inactive'); }
 +
 +
return this;
 +
};
 +
 +
PROTOTYPE.show = function(event) { return this.toggle(TRUE, event); };
 +
 +
PROTOTYPE.hide = function(event) { return this.toggle(FALSE, event); };
 +
 +
;PROTOTYPE.focus = function(event) {
 +
if(!this.rendered || this.destroyed) { return this; }
 +
 +
var qtips = $(SELECTOR),
 +
tooltip = this.tooltip,
 +
curIndex = parseInt(tooltip[0].style.zIndex, 10),
 +
newIndex = QTIP.zindex + qtips.length,
 +
focusedElem;
 +
 +
// Only update the z-index if it has changed and tooltip is not already focused
 +
if(!tooltip.hasClass(CLASS_FOCUS)) {
 +
// tooltipfocus event
 +
if(this._trigger('focus', [newIndex], event)) {
 +
// Only update z-index's if they've changed
 +
if(curIndex !== newIndex) {
 +
// Reduce our z-index's and keep them properly ordered
 +
qtips.each(function() {
 +
if(this.style.zIndex > curIndex) {
 +
this.style.zIndex = this.style.zIndex - 1;
 +
}
 +
});
 +
 +
// Fire blur event for focused tooltip
 +
qtips.filter('.' + CLASS_FOCUS).qtip('blur', event);
 +
}
 +
 +
// Set the new z-index
 +
tooltip.addClass(CLASS_FOCUS)[0].style.zIndex = newIndex;
 +
}
 +
}
 +
 +
return this;
 +
};
 +
 +
PROTOTYPE.blur = function(event) {
 +
if(!this.rendered || this.destroyed) { return this; }
 +
 +
// Set focused status to FALSE
 +
this.tooltip.removeClass(CLASS_FOCUS);
 +
 +
// tooltipblur event
 +
this._trigger('blur', [ this.tooltip.css('zIndex') ], event);
 +
 +
return this;
 +
};
 +
 +
;PROTOTYPE.disable = function(state) {
 +
if(this.destroyed) { return this; }
 +
 +
// If 'toggle' is passed, toggle the current state
 +
if(state === 'toggle') {
 +
state = !(this.rendered ? this.tooltip.hasClass(CLASS_DISABLED) : this.disabled);
 +
}
 +
 +
// Disable if no state passed
 +
else if('boolean' !== typeof state) {
 +
state = TRUE;
 +
}
 +
 +
if(this.rendered) {
 +
this.tooltip.toggleClass(CLASS_DISABLED, state)
 +
.attr('aria-disabled', state);
 +
}
 +
 +
this.disabled = !!state;
 +
 +
return this;
 +
};
 +
 +
PROTOTYPE.enable = function() { return this.disable(FALSE); };
 +
 +
;PROTOTYPE._createButton = function()
 +
{
 +
var self = this,
 +
elements = this.elements,
 +
tooltip = elements.tooltip,
 +
button = this.options.content.button,
 +
isString = typeof button === 'string',
 +
close = isString ? button : 'Close tooltip';
 +
 +
if(elements.button) { elements.button.remove(); }
 +
 +
// Use custom button if one was supplied by user, else use default
 +
if(button.jquery) {
 +
elements.button = button;
 +
}
 +
else {
 +
elements.button = $('<a />', {
 +
'class': 'qtip-close ' + (this.options.style.widget ? '' : NAMESPACE+'-icon'),
 +
'title': close,
 +
'aria-label': close
 +
})
 +
.prepend(
 +
$('<span />', {
 +
'class': 'ui-icon ui-icon-close',
 +
'html': '&times;'
 +
})
 +
);
 +
}
 +
 +
// Create button and setup attributes
 +
elements.button.appendTo(elements.titlebar || tooltip)
 +
.attr('role', 'button')
 +
.click(function(event) {
 +
if(!tooltip.hasClass(CLASS_DISABLED)) { self.hide(event); }
 +
return FALSE;
 +
});
 +
};
 +
 +
PROTOTYPE._updateButton = function(button)
 +
{
 +
// Make sure tooltip is rendered and if not, return
 +
if(!this.rendered) { return FALSE; }
 +
 +
var elem = this.elements.button;
 +
if(button) { this._createButton(); }
 +
else { elem.remove(); }
 +
};
 +
 +
;// Widget class creator
 +
function createWidgetClass(cls) {
 +
return WIDGET.concat('').join(cls ? '-'+cls+' ' : ' ');
 +
}
 +
 +
// Widget class setter method
 +
PROTOTYPE._setWidget = function()
 +
{
 +
var on = this.options.style.widget,
 +
elements = this.elements,
 +
tooltip = elements.tooltip,
 +
disabled = tooltip.hasClass(CLASS_DISABLED);
 +
 +
tooltip.removeClass(CLASS_DISABLED);
 +
CLASS_DISABLED = on ? 'ui-state-disabled' : 'qtip-disabled';
 +
tooltip.toggleClass(CLASS_DISABLED, disabled);
 +
 +
tooltip.toggleClass('ui-helper-reset '+createWidgetClass(), on).toggleClass(CLASS_DEFAULT, this.options.style.def && !on);
 +
 +
if(elements.content) {
 +
elements.content.toggleClass( createWidgetClass('content'), on);
 +
}
 +
if(elements.titlebar) {
 +
elements.titlebar.toggleClass( createWidgetClass('header'), on);
 +
}
 +
if(elements.button) {
 +
elements.button.toggleClass(NAMESPACE+'-icon', !on);
 +
}
 +
};;function cloneEvent(event) {
 +
return event && {
 +
type: event.type,
 +
pageX: event.pageX,
 +
pageY: event.pageY,
 +
target: event.target,
 +
relatedTarget: event.relatedTarget,
 +
scrollX: event.scrollX || window.pageXOffset || document.body.scrollLeft || document.documentElement.scrollLeft,
 +
scrollY: event.scrollY || window.pageYOffset || document.body.scrollTop || document.documentElement.scrollTop
 +
} || {};
 +
}
 +
 +
function delay(callback, duration) {
 +
// If tooltip has displayed, start hide timer
 +
if(duration > 0) {
 +
return setTimeout(
 +
$.proxy(callback, this), duration
 +
);
 +
}
 +
else{ callback.call(this); }
 +
}
 +
 +
function showMethod(event) {
 +
if(this.tooltip.hasClass(CLASS_DISABLED)) { return FALSE; }
 +
 +
// Clear hide timers
 +
clearTimeout(this.timers.show);
 +
clearTimeout(this.timers.hide);
 +
 +
// Start show timer
 +
this.timers.show = delay.call(this,
 +
function() { this.toggle(TRUE, event); },
 +
this.options.show.delay
 +
);
 +
}
 +
 +
function hideMethod(event) {
 +
if(this.tooltip.hasClass(CLASS_DISABLED)) { return FALSE; }
 +
 +
// Check if new target was actually the tooltip element
 +
var relatedTarget = $(event.relatedTarget),
 +
ontoTooltip = relatedTarget.closest(SELECTOR)[0] === this.tooltip[0],
 +
ontoTarget = relatedTarget[0] === this.options.show.target[0];
 +
 +
// Clear timers and stop animation queue
 +
clearTimeout(this.timers.show);
 +
clearTimeout(this.timers.hide);
 +
 +
// Prevent hiding if tooltip is fixed and event target is the tooltip.
 +
// Or if mouse positioning is enabled and cursor momentarily overlaps
 +
if(this !== relatedTarget[0] &&
 +
(this.options.position.target === 'mouse' && ontoTooltip) ||
 +
(this.options.hide.fixed && (
 +
(/mouse(out|leave|move)/).test(event.type) && (ontoTooltip || ontoTarget))
 +
))
 +
{
 +
try {
 +
event.preventDefault();
 +
event.stopImmediatePropagation();
 +
} catch(e) {}
 +
 +
return;
 +
}
 +
 +
// If tooltip has displayed, start hide timer
 +
this.timers.hide = delay.call(this,
 +
function() { this.toggle(FALSE, event); },
 +
this.options.hide.delay,
 +
this
 +
);
 +
}
 +
 +
function inactiveMethod(event) {
 +
if(this.tooltip.hasClass(CLASS_DISABLED) || !this.options.hide.inactive) { return FALSE; }
 +
 +
// Clear timer
 +
clearTimeout(this.timers.inactive);
 +
 +
this.timers.inactive = delay.call(this,
 +
function(){ this.hide(event); },
 +
this.options.hide.inactive
 +
);
 +
}
 +
 +
function repositionMethod(event) {
 +
if(this.rendered && this.tooltip[0].offsetWidth > 0) { this.reposition(event); }
 +
}
 +
 +
// Store mouse coordinates
 +
PROTOTYPE._storeMouse = function(event) {
 +
(this.mouse = cloneEvent(event)).type = 'mousemove';
 +
};
 +
 +
// Bind events
 +
PROTOTYPE._bind = function(targets, events, method, suffix, context) {
 +
var ns = '.' + this._id + (suffix ? '-'+suffix : '');
 +
events.length && $(targets).bind(
 +
(events.split ? events : events.join(ns + ' ')) + ns,
 +
$.proxy(method, context || this)
 +
);
 +
};
 +
PROTOTYPE._unbind = function(targets, suffix) {
 +
$(targets).unbind('.' + this._id + (suffix ? '-'+suffix : ''));
 +
};
 +
 +
// Apply common event handlers using delegate (avoids excessive .bind calls!)
 +
var ns = '.'+NAMESPACE;
 +
function delegate(selector, events, method) {
 +
$(document.body).delegate(selector,
 +
(events.split ? events : events.join(ns + ' ')) + ns,
 +
function() {
 +
var api = QTIP.api[ $.attr(this, ATTR_ID) ];
 +
api && !api.disabled && method.apply(api, arguments);
 +
}
 +
);
 +
}
 +
 +
$(function() {
 +
delegate(SELECTOR, ['mouseenter', 'mouseleave'], function(event) {
 +
var state = event.type === 'mouseenter',
 +
tooltip = $(event.currentTarget),
 +
target = $(event.relatedTarget || event.target),
 +
options = this.options;
 +
 +
// On mouseenter...
 +
if(state) {
 +
// Focus the tooltip on mouseenter (z-index stacking)
 +
this.focus(event);
 +
 +
// Clear hide timer on tooltip hover to prevent it from closing
 +
tooltip.hasClass(CLASS_FIXED) && !tooltip.hasClass(CLASS_DISABLED) && clearTimeout(this.timers.hide);
 +
}
 +
 +
// On mouseleave...
 +
else {
 +
// Hide when we leave the tooltip and not onto the show target (if a hide event is set)
 +
if(options.position.target === 'mouse' && options.hide.event &&
 +
options.show.target && !target.closest(options.show.target[0]).length) {
 +
this.hide(event);
 +
}
 +
}
 +
 +
// Add hover class
 +
tooltip.toggleClass(CLASS_HOVER, state);
 +
});
 +
 +
// Define events which reset the 'inactive' event handler
 +
delegate('['+ATTR_ID+']', INACTIVE_EVENTS, inactiveMethod);
 +
});
 +
 +
// Event trigger
 +
PROTOTYPE._trigger = function(type, args, event) {
 +
var callback = $.Event('tooltip'+type);
 +
callback.originalEvent = (event && $.extend({}, event)) || this.cache.event || NULL;
 +
 +
this.triggering = type;
 +
this.tooltip.trigger(callback, [this].concat(args || []));
 +
this.triggering = FALSE;
 +
 +
return !callback.isDefaultPrevented();
 +
};
 +
 +
PROTOTYPE._bindEvents = function(showEvents, hideEvents, showTarget, hideTarget, showMethod, hideMethod) {
 +
// If hide and show targets are the same...
 +
if(hideTarget.add(showTarget).length === hideTarget.length) {
 +
var toggleEvents = [];
 +
 +
// Filter identical show/hide events
 +
hideEvents = $.map(hideEvents, function(type) {
 +
var showIndex = $.inArray(type, showEvents);
 +
 +
// Both events are identical, remove from both hide and show events
 +
// and append to toggleEvents
 +
if(showIndex > -1) {
 +
toggleEvents.push( showEvents.splice( showIndex, 1 )[0] );
 +
return;
 +
}
 +
 +
return type;
 +
});
 +
 +
// Toggle events are special case of identical show/hide events, which happen in sequence
 +
toggleEvents.length && this._bind(showTarget, toggleEvents, function(event) {
 +
var state = this.rendered ? this.tooltip[0].offsetWidth > 0 : false;
 +
(state ? hideMethod : showMethod).call(this, event);
 +
});
 +
}
 +
 +
// Apply show/hide/toggle events
 +
this._bind(showTarget, showEvents, showMethod);
 +
this._bind(hideTarget, hideEvents, hideMethod);
 +
};
 +
 +
PROTOTYPE._assignInitialEvents = function(event) {
 +
var options = this.options,
 +
showTarget = options.show.target,
 +
hideTarget = options.hide.target,
 +
showEvents = options.show.event ? $.trim('' + options.show.event).split(' ') : [],
 +
hideEvents = options.hide.event ? $.trim('' + options.hide.event).split(' ') : [];
 +
 +
/*
 +
* Make sure hoverIntent functions properly by using mouseleave as a hide event if
 +
* mouseenter/mouseout is used for show.event, even if it isn't in the users options.
 +
*/
 +
if(/mouse(over|enter)/i.test(options.show.event) && !/mouse(out|leave)/i.test(options.hide.event)) {
 +
hideEvents.push('mouseleave');
 +
}
 +
 +
/*
 +
* Also make sure initial mouse targetting works correctly by caching mousemove coords
 +
* on show targets before the tooltip has rendered. Also set onTarget when triggered to
 +
* keep mouse tracking working.
 +
*/
 +
this._bind(showTarget, 'mousemove', function(event) {
 +
this._storeMouse(event);
 +
this.cache.onTarget = TRUE;
 +
});
 +
 +
// Define hoverIntent function
 +
function hoverIntent(event) {
 +
// Only continue if tooltip isn't disabled
 +
if(this.disabled || this.destroyed) { return FALSE; }
 +
 +
// Cache the event data
 +
this.cache.event = cloneEvent(event);
 +
this.cache.target = event ? $(event.target) : [undefined];
 +
 +
// Start the event sequence
 +
clearTimeout(this.timers.show);
 +
this.timers.show = delay.call(this,
 +
function() { this.render(typeof event === 'object' || options.show.ready); },
 +
options.show.delay
 +
);
 +
}
 +
 +
// Filter and bind events
 +
this._bindEvents(showEvents, hideEvents, showTarget, hideTarget, hoverIntent, function() {
 +
clearTimeout(this.timers.show);
 +
});
 +
 +
// Prerendering is enabled, create tooltip now
 +
if(options.show.ready || options.prerender) { hoverIntent.call(this, event); }
 +
};
 +
 +
// Event assignment method
 +
PROTOTYPE._assignEvents = function() {
 +
var self = this,
 +
options = this.options,
 +
posOptions = options.position,
 +
 +
tooltip = this.tooltip,
 +
showTarget = options.show.target,
 +
hideTarget = options.hide.target,
 +
containerTarget = posOptions.container,
 +
viewportTarget = posOptions.viewport,
 +
documentTarget = $(document),
 +
bodyTarget = $(document.body),
 +
windowTarget = $(window),
 +
 +
showEvents = options.show.event ? $.trim('' + options.show.event).split(' ') : [],
 +
hideEvents = options.hide.event ? $.trim('' + options.hide.event).split(' ') : [];
 +
 +
 +
// Assign passed event callbacks
 +
$.each(options.events, function(name, callback) {
 +
self._bind(tooltip, name === 'toggle' ? ['tooltipshow','tooltiphide'] : ['tooltip'+name], callback, null, tooltip);
 +
});
 +
 +
// Hide tooltips when leaving current window/frame (but not select/option elements)
 +
if(/mouse(out|leave)/i.test(options.hide.event) && options.hide.leave === 'window') {
 +
this._bind(documentTarget, ['mouseout', 'blur'], function(event) {
 +
if(!/select|option/.test(event.target.nodeName) && !event.relatedTarget) {
 +
this.hide(event);
 +
}
 +
});
 +
}
 +
 +
// Enable hide.fixed by adding appropriate class
 +
if(options.hide.fixed) {
 +
hideTarget = hideTarget.add( tooltip.addClass(CLASS_FIXED) );
 +
}
 +
 +
/*
 +
* Make sure hoverIntent functions properly by using mouseleave to clear show timer if
 +
* mouseenter/mouseout is used for show.event, even if it isn't in the users options.
 +
*/
 +
else if(/mouse(over|enter)/i.test(options.show.event)) {
 +
this._bind(hideTarget, 'mouseleave', function() {
 +
clearTimeout(this.timers.show);
 +
});
 +
}
 +
 +
// Hide tooltip on document mousedown if unfocus events are enabled
 +
if(('' + options.hide.event).indexOf('unfocus') > -1) {
 +
this._bind(containerTarget.closest('html'), ['mousedown', 'touchstart'], function(event) {
 +
var elem = $(event.target),
 +
enabled = this.rendered && !this.tooltip.hasClass(CLASS_DISABLED) && this.tooltip[0].offsetWidth > 0,
 +
isAncestor = elem.parents(SELECTOR).filter(this.tooltip[0]).length > 0;
 +
 +
if(elem[0] !== this.target[0] && elem[0] !== this.tooltip[0] && !isAncestor &&
 +
!this.target.has(elem[0]).length && enabled
 +
) {
 +
this.hide(event);
 +
}
 +
});
 +
}
 +
 +
// Check if the tooltip hides when inactive
 +
if('number' === typeof options.hide.inactive) {
 +
// Bind inactive method to show target(s) as a custom event
 +
this._bind(showTarget, 'qtip-'+this.id+'-inactive', inactiveMethod);
 +
 +
// Define events which reset the 'inactive' event handler
 +
this._bind(hideTarget.add(tooltip), QTIP.inactiveEvents, inactiveMethod, '-inactive');
 +
}
 +
 +
// Filter and bind events
 +
this._bindEvents(showEvents, hideEvents, showTarget, hideTarget, showMethod, hideMethod);
 +
 +
// Mouse movement bindings
 +
this._bind(showTarget.add(tooltip), 'mousemove', function(event) {
 +
// Check if the tooltip hides when mouse is moved a certain distance
 +
if('number' === typeof options.hide.distance) {
 +
var origin = this.cache.origin || {},
 +
limit = this.options.hide.distance,
 +
abs = Math.abs;
 +
 +
// Check if the movement has gone beyond the limit, and hide it if so
 +
if(abs(event.pageX - origin.pageX) >= limit || abs(event.pageY - origin.pageY) >= limit) {
 +
this.hide(event);
 +
}
 +
}
 +
 +
// Cache mousemove coords on show targets
 +
this._storeMouse(event);
 +
});
 +
 +
// Mouse positioning events
 +
if(posOptions.target === 'mouse') {
 +
// If mouse adjustment is on...
 +
if(posOptions.adjust.mouse) {
 +
// Apply a mouseleave event so we don't get problems with overlapping
 +
if(options.hide.event) {
 +
// Track if we're on the target or not
 +
this._bind(showTarget, ['mouseenter', 'mouseleave'], function(event) {
 +
this.cache.onTarget = event.type === 'mouseenter';
 +
});
 +
}
 +
 +
// Update tooltip position on mousemove
 +
this._bind(documentTarget, 'mousemove', function(event) {
 +
// Update the tooltip position only if the tooltip is visible and adjustment is enabled
 +
if(this.rendered && this.cache.onTarget && !this.tooltip.hasClass(CLASS_DISABLED) && this.tooltip[0].offsetWidth > 0) {
 +
this.reposition(event);
 +
}
 +
});
 +
}
 +
}
 +
 +
// Adjust positions of the tooltip on window resize if enabled
 +
if(posOptions.adjust.resize || viewportTarget.length) {
 +
this._bind( $.event.special.resize ? viewportTarget : windowTarget, 'resize', repositionMethod );
 +
}
 +
 +
// Adjust tooltip position on scroll of the window or viewport element if present
 +
if(posOptions.adjust.scroll) {
 +
this._bind( windowTarget.add(posOptions.container), 'scroll', repositionMethod );
 +
}
 +
};
 +
 +
// Un-assignment method
 +
PROTOTYPE._unassignEvents = function() {
 +
var targets = [
 +
this.options.show.target[0],
 +
this.options.hide.target[0],
 +
this.rendered && this.tooltip[0],
 +
this.options.position.container[0],
 +
this.options.position.viewport[0],
 +
this.options.position.container.closest('html')[0], // unfocus
 +
window,
 +
document
 +
];
 +
 +
this._unbind($([]).pushStack( $.grep(targets, function(i) {
 +
return typeof i === 'object';
 +
})));
 +
};
 +
 +
;// Initialization method
 +
function init(elem, id, opts) {
 +
var obj, posOptions, attr, config, title,
 +
 +
// Setup element references
 +
docBody = $(document.body),
 +
 +
// Use document body instead of document element if needed
 +
newTarget = elem[0] === document ? docBody : elem,
 +
 +
// Grab metadata from element if plugin is present
 +
metadata = (elem.metadata) ? elem.metadata(opts.metadata) : NULL,
 +
 +
// If metadata type if HTML5, grab 'name' from the object instead, or use the regular data object otherwise
 +
metadata5 = opts.metadata.type === 'html5' && metadata ? metadata[opts.metadata.name] : NULL,
 +
 +
// Grab data from metadata.name (or data-qtipopts as fallback) using .data() method,
 +
html5 = elem.data(opts.metadata.name || 'qtipopts');
 +
 +
// If we don't get an object returned attempt to parse it manualyl without parseJSON
 +
try { html5 = typeof html5 === 'string' ? $.parseJSON(html5) : html5; } catch(e) {}
 +
 +
// Merge in and sanitize metadata
 +
config = $.extend(TRUE, {}, QTIP.defaults, opts,
 +
typeof html5 === 'object' ? sanitizeOptions(html5) : NULL,
 +
sanitizeOptions(metadata5 || metadata));
 +
 +
// Re-grab our positioning options now we've merged our metadata and set id to passed value
 +
posOptions = config.position;
 +
config.id = id;
 +
 +
// Setup missing content if none is detected
 +
if('boolean' === typeof config.content.text) {
 +
attr = elem.attr(config.content.attr);
 +
 +
// Grab from supplied attribute if available
 +
if(config.content.attr !== FALSE && attr) { config.content.text = attr; }
 +
 +
// No valid content was found, abort render
 +
else { return FALSE; }
 +
}
 +
 +
// Setup target options
 +
if(!posOptions.container.length) { posOptions.container = docBody; }
 +
if(posOptions.target === FALSE) { posOptions.target = newTarget; }
 +
if(config.show.target === FALSE) { config.show.target = newTarget; }
 +
if(config.show.solo === TRUE) { config.show.solo = posOptions.container.closest('body'); }
 +
if(config.hide.target === FALSE) { config.hide.target = newTarget; }
 +
if(config.position.viewport === TRUE) { config.position.viewport = posOptions.container; }
 +
 +
// Ensure we only use a single container
 +
posOptions.container = posOptions.container.eq(0);
 +
 +
// Convert position corner values into x and y strings
 +
posOptions.at = new CORNER(posOptions.at, TRUE);
 +
posOptions.my = new CORNER(posOptions.my);
 +
 +
// Destroy previous tooltip if overwrite is enabled, or skip element if not
 +
if(elem.data(NAMESPACE)) {
 +
if(config.overwrite) {
 +
elem.qtip('destroy', true);
 +
}
 +
else if(config.overwrite === FALSE) {
 +
return FALSE;
 +
}
 +
}
 +
 +
// Add has-qtip attribute
 +
elem.attr(ATTR_HAS, id);
 +
 +
// Remove title attribute and store it if present
 +
if(config.suppress && (title = elem.attr('title'))) {
 +
// Final attr call fixes event delegatiom and IE default tooltip showing problem
 +
elem.removeAttr('title').attr(oldtitle, title).attr('title', '');
 +
}
 +
 +
// Initialize the tooltip and add API reference
 +
obj = new QTip(elem, config, id, !!attr);
 +
elem.data(NAMESPACE, obj);
 +
 +
// Catch remove/removeqtip events on target element to destroy redundant tooltip
 +
elem.one('remove.qtip-'+id+' removeqtip.qtip-'+id, function() {
 +
var api; if((api = $(this).data(NAMESPACE))) { api.destroy(true); }
 +
});
 +
 +
return obj;
 +
}
 +
 +
// jQuery $.fn extension method
 +
QTIP = $.fn.qtip = function(options, notation, newValue)
 +
{
 +
var command = ('' + options).toLowerCase(), // Parse command
 +
returned = NULL,
 +
args = $.makeArray(arguments).slice(1),
 +
event = args[args.length - 1],
 +
opts = this[0] ? $.data(this[0], NAMESPACE) : NULL;
 +
 +
// Check for API request
 +
if((!arguments.length && opts) || command === 'api') {
 +
return opts;
 +
}
 +
 +
// Execute API command if present
 +
else if('string' === typeof options) {
 +
this.each(function() {
 +
var api = $.data(this, NAMESPACE);
 +
if(!api) { return TRUE; }
 +
 +
// Cache the event if possible
 +
if(event && event.timeStamp) { api.cache.event = event; }
 +
 +
// Check for specific API commands
 +
if(notation && (command === 'option' || command === 'options')) {
 +
if(newValue !== undefined || $.isPlainObject(notation)) {
 +
api.set(notation, newValue);
 +
}
 +
else {
 +
returned = api.get(notation);
 +
return FALSE;
 +
}
 +
}
 +
 +
// Execute API command
 +
else if(api[command]) {
 +
api[command].apply(api, args);
 +
}
 +
});
 +
 +
return returned !== NULL ? returned : this;
 +
}
 +
 +
// No API commands. validate provided options and setup qTips
 +
else if('object' === typeof options || !arguments.length) {
 +
// Sanitize options first
 +
opts = sanitizeOptions($.extend(TRUE, {}, options));
 +
 +
return this.each(function(i) {
 +
var api, id;
 +
 +
// Find next available ID, or use custom ID if provided
 +
id = $.isArray(opts.id) ? opts.id[i] : opts.id;
 +
id = !id || id === FALSE || id.length < 1 || QTIP.api[id] ? QTIP.nextid++ : id;
 +
 +
// Initialize the qTip and re-grab newly sanitized options
 +
api = init($(this), id, opts);
 +
if(api === FALSE) { return TRUE; }
 +
else { QTIP.api[id] = api; }
 +
 +
// Initialize plugins
 +
$.each(PLUGINS, function() {
 +
if(this.initialize === 'initialize') { this(api); }
 +
});
 +
 +
// Assign initial pre-render events
 +
api._assignInitialEvents(event);
 +
});
 +
}
 +
};
 +
 +
// Expose class
 +
$.qtip = QTip;
 +
 +
// Populated in render method
 +
QTIP.api = {};
 +
;$.each({
 +
/* Allow other plugins to successfully retrieve the title of an element with a qTip applied */
 +
attr: function(attr, val) {
 +
if(this.length) {
 +
var self = this[0],
 +
title = 'title',
 +
api = $.data(self, 'qtip');
 +
 +
if(attr === title && api && 'object' === typeof api && api.options.suppress) {
 +
if(arguments.length < 2) {
 +
return $.attr(self, oldtitle);
 +
}
 +
 +
// If qTip is rendered and title was originally used as content, update it
 +
if(api && api.options.content.attr === title && api.cache.attr) {
 +
api.set('content.text', val);
 +
}
 +
 +
// Use the regular attr method to set, then cache the result
 +
return this.attr(oldtitle, val);
 +
}
 +
}
 +
 +
return $.fn['attr'+replaceSuffix].apply(this, arguments);
 +
},
 +
 +
/* Allow clone to correctly retrieve cached title attributes */
 +
clone: function(keepData) {
 +
var titles = $([]), title = 'title',
 +
 +
// Clone our element using the real clone method
 +
elems = $.fn['clone'+replaceSuffix].apply(this, arguments);
 +
 +
// Grab all elements with an oldtitle set, and change it to regular title attribute, if keepData is false
 +
if(!keepData) {
 +
elems.filter('['+oldtitle+']').attr('title', function() {
 +
return $.attr(this, oldtitle);
 +
})
 +
.removeAttr(oldtitle);
 +
}
 +
 +
return elems;
 +
}
 +
}, function(name, func) {
 +
if(!func || $.fn[name+replaceSuffix]) { return TRUE; }
 +
 +
var old = $.fn[name+replaceSuffix] = $.fn[name];
 +
$.fn[name] = function() {
 +
return func.apply(this, arguments) || old.apply(this, arguments);
 +
};
 +
});
 +
 +
/* Fire off 'removeqtip' handler in $.cleanData if jQuery UI not present (it already does similar).
 +
* This snippet is taken directly from jQuery UI source code found here:
 +
*    http://code.jquery.com/ui/jquery-ui-git.js
 +
*/
 +
if(!$.ui) {
 +
$['cleanData'+replaceSuffix] = $.cleanData;
 +
$.cleanData = function( elems ) {
 +
for(var i = 0, elem; (elem = $( elems[i] )).length; i++) {
 +
if(elem.attr(ATTR_HAS)) {
 +
try { elem.triggerHandler('removeqtip'); }
 +
catch( e ) {}
 +
}
 +
}
 +
$['cleanData'+replaceSuffix].apply(this, arguments);
 +
};
 +
}
 +
 +
;// qTip version
 +
QTIP.version = '2.2.0';
 +
 +
// Base ID for all qTips
 +
QTIP.nextid = 0;
 +
 +
// Inactive events array
 +
QTIP.inactiveEvents = INACTIVE_EVENTS;
 +
 +
// Base z-index for all qTips
 +
QTIP.zindex = 15000;
 +
 +
// Define configuration defaults
 +
QTIP.defaults = {
 +
prerender: FALSE,
 +
id: FALSE,
 +
overwrite: TRUE,
 +
suppress: TRUE,
 +
content: {
 +
text: TRUE,
 +
attr: 'title',
 +
title: FALSE,
 +
button: FALSE
 +
},
 +
position: {
 +
my: 'top left',
 +
at: 'bottom right',
 +
target: FALSE,
 +
container: FALSE,
 +
viewport: FALSE,
 +
adjust: {
 +
x: 0, y: 0,
 +
mouse: TRUE,
 +
scroll: TRUE,
 +
resize: TRUE,
 +
method: 'flipinvert flipinvert'
 +
},
 +
effect: function(api, pos, viewport) {
 +
$(this).animate(pos, {
 +
duration: 200,
 +
queue: FALSE
 +
});
 +
}
 +
},
 +
show: {
 +
target: FALSE,
 +
event: 'mouseenter',
 +
effect: TRUE,
 +
delay: 90,
 +
solo: FALSE,
 +
ready: FALSE,
 +
autofocus: FALSE
 +
},
 +
hide: {
 +
target: FALSE,
 +
event: 'mouseleave',
 +
effect: TRUE,
 +
delay: 0,
 +
fixed: FALSE,
 +
inactive: FALSE,
 +
leave: 'window',
 +
distance: FALSE
 +
},
 +
style: {
 +
classes: '',
 +
widget: FALSE,
 +
width: FALSE,
 +
height: FALSE,
 +
def: TRUE
 +
},
 +
events: {
 +
render: NULL,
 +
move: NULL,
 +
show: NULL,
 +
hide: NULL,
 +
toggle: NULL,
 +
visible: NULL,
 +
hidden: NULL,
 +
focus: NULL,
 +
blur: NULL
 +
}
 +
};
 +
 +
;var TIP,
 +
 +
// .bind()/.on() namespace
 +
TIPNS = '.qtip-tip',
 +
 +
// Common CSS strings
 +
MARGIN = 'margin',
 +
BORDER = 'border',
 +
COLOR = 'color',
 +
BG_COLOR = 'background-color',
 +
TRANSPARENT = 'transparent',
 +
IMPORTANT = ' !important',
 +
 +
// Check if the browser supports <canvas/> elements
 +
HASCANVAS = !!document.createElement('canvas').getContext,
 +
 +
// Invalid colour values used in parseColours()
 +
INVALID = /rgba?\(0, 0, 0(, 0)?\)|transparent|#123456/i;
 +
 +
// Camel-case method, taken from jQuery source
 +
// http://code.jquery.com/jquery-1.8.0.js
 +
function camel(s) { return s.charAt(0).toUpperCase() + s.slice(1); }
 +
 +
/*
 +
* Modified from Modernizr's testPropsAll()
 +
* http://modernizr.com/downloads/modernizr-latest.js
 +
*/
 +
var cssProps = {}, cssPrefixes = ["Webkit", "O", "Moz", "ms"];
 +
function vendorCss(elem, prop) {
 +
var ucProp = prop.charAt(0).toUpperCase() + prop.slice(1),
 +
props = (prop + ' ' + cssPrefixes.join(ucProp + ' ') + ucProp).split(' '),
 +
cur, val, i = 0;
 +
 +
// If the property has already been mapped...
 +
if(cssProps[prop]) { return elem.css(cssProps[prop]); }
 +
 +
while((cur = props[i++])) {
 +
if((val = elem.css(cur)) !== undefined) {
 +
return cssProps[prop] = cur, val;
 +
}
 +
}
 +
}
 +
 +
// Parse a given elements CSS property into an int
 +
function intCss(elem, prop) {
 +
return Math.ceil(parseFloat(vendorCss(elem, prop)));
 +
}
 +
 +
 +
// VML creation (for IE only)
 +
if(!HASCANVAS) {
 +
var createVML = function(tag, props, style) {
 +
return '<qtipvml:'+tag+' xmlns="urn:schemas-microsoft.com:vml" class="qtip-vml" '+(props||'')+
 +
' style="behavior: url(#default#VML); '+(style||'')+ '" />';
 +
};
 +
}
 +
 +
// Canvas only definitions
 +
else {
 +
var PIXEL_RATIO = window.devicePixelRatio || 1,
 +
BACKING_STORE_RATIO = (function() {
 +
var context = document.createElement('canvas').getContext('2d');
 +
return context.backingStorePixelRatio || context.webkitBackingStorePixelRatio || context.mozBackingStorePixelRatio ||
 +
context.msBackingStorePixelRatio || context.oBackingStorePixelRatio || 1;
 +
}()),
 +
SCALE = PIXEL_RATIO / BACKING_STORE_RATIO;
 +
}
 +
 +
 +
function Tip(qtip, options) {
 +
this._ns = 'tip';
 +
this.options = options;
 +
this.offset = options.offset;
 +
this.size = [ options.width, options.height ];
 +
 +
// Initialize
 +
this.init( (this.qtip = qtip) );
 +
}
 +
 +
$.extend(Tip.prototype, {
 +
init: function(qtip) {
 +
var context, tip;
 +
 +
// Create tip element and prepend to the tooltip
 +
tip = this.element = qtip.elements.tip = $('<div />', { 'class': NAMESPACE+'-tip' }).prependTo(qtip.tooltip);
 +
 +
// Create tip drawing element(s)
 +
if(HASCANVAS) {
 +
// save() as soon as we create the canvas element so FF2 doesn't bork on our first restore()!
 +
context = $('<canvas />').appendTo(this.element)[0].getContext('2d');
 +
 +
// Setup constant parameters
 +
context.lineJoin = 'miter';
 +
context.miterLimit = 100000;
 +
context.save();
 +
}
 +
else {
 +
context = createVML('shape', 'coordorigin="0,0"', 'position:absolute;');
 +
this.element.html(context + context);
 +
 +
// Prevent mousing down on the tip since it causes problems with .live() handling in IE due to VML
 +
qtip._bind( $('*', tip).add(tip), ['click', 'mousedown'], function(event) { event.stopPropagation(); }, this._ns);
 +
}
 +
 +
// Bind update events
 +
qtip._bind(qtip.tooltip, 'tooltipmove', this.reposition, this._ns, this);
 +
 +
// Create it
 +
this.create();
 +
},
 +
 +
_swapDimensions: function() {
 +
this.size[0] = this.options.height;
 +
this.size[1] = this.options.width;
 +
},
 +
_resetDimensions: function() {
 +
this.size[0] = this.options.width;
 +
this.size[1] = this.options.height;
 +
},
 +
 +
_useTitle: function(corner) {
 +
var titlebar = this.qtip.elements.titlebar;
 +
return titlebar && (
 +
corner.y === TOP || (corner.y === CENTER && this.element.position().top + (this.size[1] / 2) + this.options.offset < titlebar.outerHeight(TRUE))
 +
);
 +
},
 +
 +
_parseCorner: function(corner) {
 +
var my = this.qtip.options.position.my;
 +
 +
// Detect corner and mimic properties
 +
if(corner === FALSE || my === FALSE) {
 +
corner = FALSE;
 +
}
 +
else if(corner === TRUE) {
 +
corner = new CORNER( my.string() );
 +
}
 +
else if(!corner.string) {
 +
corner = new CORNER(corner);
 +
corner.fixed = TRUE;
 +
}
 +
 +
return corner;
 +
},
 +
 +
_parseWidth: function(corner, side, use) {
 +
var elements = this.qtip.elements,
 +
prop = BORDER + camel(side) + 'Width';
 +
 +
return (use ? intCss(use, prop) : (
 +
intCss(elements.content, prop) ||
 +
intCss(this._useTitle(corner) && elements.titlebar || elements.content, prop) ||
 +
intCss(elements.tooltip, prop)
 +
)) || 0;
 +
},
 +
 +
_parseRadius: function(corner) {
 +
var elements = this.qtip.elements,
 +
prop = BORDER + camel(corner.y) + camel(corner.x) + 'Radius';
 +
 +
return BROWSER.ie < 9 ? 0 :
 +
intCss(this._useTitle(corner) && elements.titlebar || elements.content, prop) ||
 +
intCss(elements.tooltip, prop) || 0;
 +
},
 +
 +
_invalidColour: function(elem, prop, compare) {
 +
var val = elem.css(prop);
 +
return !val || (compare && val === elem.css(compare)) || INVALID.test(val) ? FALSE : val;
 +
},
 +
 +
_parseColours: function(corner) {
 +
var elements = this.qtip.elements,
 +
tip = this.element.css('cssText', ''),
 +
borderSide = BORDER + camel(corner[ corner.precedance ]) + camel(COLOR),
 +
colorElem = this._useTitle(corner) && elements.titlebar || elements.content,
 +
css = this._invalidColour, color = [];
 +
 +
// Attempt to detect the background colour from various elements, left-to-right precedance
 +
color[0] = css(tip, BG_COLOR) || css(colorElem, BG_COLOR) || css(elements.content, BG_COLOR) ||
 +
css(elements.tooltip, BG_COLOR) || tip.css(BG_COLOR);
 +
 +
// Attempt to detect the correct border side colour from various elements, left-to-right precedance
 +
color[1] = css(tip, borderSide, COLOR) || css(colorElem, borderSide, COLOR) ||
 +
css(elements.content, borderSide, COLOR) || css(elements.tooltip, borderSide, COLOR) || elements.tooltip.css(borderSide);
 +
 +
// Reset background and border colours
 +
$('*', tip).add(tip).css('cssText', BG_COLOR+':'+TRANSPARENT+IMPORTANT+';'+BORDER+':0'+IMPORTANT+';');
 +
 +
return color;
 +
},
 +
 +
_calculateSize: function(corner) {
 +
var y = corner.precedance === Y,
 +
width = this.options['width'],
 +
height = this.options['height'],
 +
isCenter = corner.abbrev() === 'c',
 +
base = (y ? width: height) * (isCenter ? 0.5 : 1),
 +
pow = Math.pow,
 +
round = Math.round,
 +
bigHyp, ratio, result,
 +
 +
smallHyp = Math.sqrt( pow(base, 2) + pow(height, 2) ),
 +
hyp = [ (this.border / base) * smallHyp, (this.border / height) * smallHyp ];
 +
 +
hyp[2] = Math.sqrt( pow(hyp[0], 2) - pow(this.border, 2) );
 +
hyp[3] = Math.sqrt( pow(hyp[1], 2) - pow(this.border, 2) );
 +
 +
bigHyp = smallHyp + hyp[2] + hyp[3] + (isCenter ? 0 : hyp[0]);
 +
ratio = bigHyp / smallHyp;
 +
 +
result = [ round(ratio * width), round(ratio * height) ];
 +
return y ? result : result.reverse();
 +
},
 +
 +
// Tip coordinates calculator
 +
_calculateTip: function(corner, size, scale) {
 +
scale = scale || 1;
 +
size = size || this.size;
 +
 +
var width = size[0] * scale,
 +
height = size[1] * scale,
 +
width2 = Math.ceil(width / 2), height2 = Math.ceil(height / 2),
 +
 +
// Define tip coordinates in terms of height and width values
 +
tips = {
 +
br: [0,0, width,height, width,0],
 +
bl: [0,0, width,0, 0,height],
 +
tr: [0,height, width,0, width,height],
 +
tl: [0,0, 0,height, width,height],
 +
tc: [0,height, width2,0, width,height],
 +
bc: [0,0, width,0, width2,height],
 +
rc: [0,0, width,height2, 0,height],
 +
lc: [width,0, width,height, 0,height2]
 +
};
 +
 +
// Set common side shapes
 +
tips.lt = tips.br; tips.rt = tips.bl;
 +
tips.lb = tips.tr; tips.rb = tips.tl;
 +
 +
return tips[ corner.abbrev() ];
 +
},
 +
 +
// Tip coordinates drawer (canvas)
 +
_drawCoords: function(context, coords) {
 +
context.beginPath();
 +
context.moveTo(coords[0], coords[1]);
 +
context.lineTo(coords[2], coords[3]);
 +
context.lineTo(coords[4], coords[5]);
 +
context.closePath();
 +
},
 +
 +
create: function() {
 +
// Determine tip corner
 +
var c = this.corner = (HASCANVAS || BROWSER.ie) && this._parseCorner(this.options.corner);
 +
 +
// If we have a tip corner...
 +
if( (this.enabled = !!this.corner && this.corner.abbrev() !== 'c') ) {
 +
// Cache it
 +
this.qtip.cache.corner = c.clone();
 +
 +
// Create it
 +
this.update();
 +
}
 +
 +
// Toggle tip element
 +
this.element.toggle(this.enabled);
 +
 +
return this.corner;
 +
},
 +
 +
update: function(corner, position) {
 +
if(!this.enabled) { return this; }
 +
 +
var elements = this.qtip.elements,
 +
tip = this.element,
 +
inner = tip.children(),
 +
options = this.options,
 +
curSize = this.size,
 +
mimic = options.mimic,
 +
round = Math.round,
 +
color, precedance, context,
 +
coords, bigCoords, translate, newSize, border, BACKING_STORE_RATIO;
 +
 +
// Re-determine tip if not already set
 +
if(!corner) { corner = this.qtip.cache.corner || this.corner; }
 +
 +
// Use corner property if we detect an invalid mimic value
 +
if(mimic === FALSE) { mimic = corner; }
 +
 +
// Otherwise inherit mimic properties from the corner object as necessary
 +
else {
 +
mimic = new CORNER(mimic);
 +
mimic.precedance = corner.precedance;
 +
 +
if(mimic.x === 'inherit') { mimic.x = corner.x; }
 +
else if(mimic.y === 'inherit') { mimic.y = corner.y; }
 +
else if(mimic.x === mimic.y) {
 +
mimic[ corner.precedance ] = corner[ corner.precedance ];
 +
}
 +
}
 +
precedance = mimic.precedance;
 +
 +
// Ensure the tip width.height are relative to the tip position
 +
if(corner.precedance === X) { this._swapDimensions(); }
 +
else { this._resetDimensions(); }
 +
 +
// Update our colours
 +
color = this.color = this._parseColours(corner);
 +
 +
// Detect border width, taking into account colours
 +
if(color[1] !== TRANSPARENT) {
 +
// Grab border width
 +
border = this.border = this._parseWidth(corner, corner[corner.precedance]);
 +
 +
// If border width isn't zero, use border color as fill if it's not invalid (1.0 style tips)
 +
if(options.border && border < 1 && !INVALID.test(color[1])) { color[0] = color[1]; }
 +
 +
// Set border width (use detected border width if options.border is true)
 +
this.border = border = options.border !== TRUE ? options.border : border;
 +
}
 +
 +
// Border colour was invalid, set border to zero
 +
else { this.border = border = 0; }
 +
 +
// Determine tip size
 +
newSize = this.size = this._calculateSize(corner);
 +
tip.css({
 +
width: newSize[0],
 +
height: newSize[1],
 +
lineHeight: newSize[1]+'px'
 +
});
 +
 +
// Calculate tip translation
 +
if(corner.precedance === Y) {
 +
translate = [
 +
round(mimic.x === LEFT ? border : mimic.x === RIGHT ? newSize[0] - curSize[0] - border : (newSize[0] - curSize[0]) / 2),
 +
round(mimic.y === TOP ? newSize[1] - curSize[1] : 0)
 +
];
 +
}
 +
else {
 +
translate = [
 +
round(mimic.x === LEFT ? newSize[0] - curSize[0] : 0),
 +
round(mimic.y === TOP ? border : mimic.y === BOTTOM ? newSize[1] - curSize[1] - border : (newSize[1] - curSize[1]) / 2)
 +
];
 +
}
 +
 +
// Canvas drawing implementation
 +
if(HASCANVAS) {
 +
// Grab canvas context and clear/save it
 +
context = inner[0].getContext('2d');
 +
context.restore(); context.save();
 +
context.clearRect(0,0,6000,6000);
 +
 +
// Calculate coordinates
 +
coords = this._calculateTip(mimic, curSize, SCALE);
 +
bigCoords = this._calculateTip(mimic, this.size, SCALE);
 +
 +
// Set the canvas size using calculated size
 +
inner.attr(WIDTH, newSize[0] * SCALE).attr(HEIGHT, newSize[1] * SCALE);
 +
inner.css(WIDTH, newSize[0]).css(HEIGHT, newSize[1]);
 +
 +
// Draw the outer-stroke tip
 +
this._drawCoords(context, bigCoords);
 +
context.fillStyle = color[1];
 +
context.fill();
 +
 +
// Draw the actual tip
 +
context.translate(translate[0] * SCALE, translate[1] * SCALE);
 +
this._drawCoords(context, coords);
 +
context.fillStyle = color[0];
 +
context.fill();
 +
}
 +
 +
// VML (IE Proprietary implementation)
 +
else {
 +
// Calculate coordinates
 +
coords = this._calculateTip(mimic);
 +
 +
// Setup coordinates string
 +
coords = 'm' + coords[0] + ',' + coords[1] + ' l' + coords[2] +
 +
',' + coords[3] + ' ' + coords[4] + ',' + coords[5] + ' xe';
 +
 +
// Setup VML-specific offset for pixel-perfection
 +
translate[2] = border && /^(r|b)/i.test(corner.string()) ?
 +
BROWSER.ie === 8 ? 2 : 1 : 0;
 +
 +
// Set initial CSS
 +
inner.css({
 +
coordsize: (newSize[0]+border) + ' ' + (newSize[1]+border),
 +
antialias: ''+(mimic.string().indexOf(CENTER) > -1),
 +
left: translate[0] - (translate[2] * Number(precedance === X)),
 +
top: translate[1] - (translate[2] * Number(precedance === Y)),
 +
width: newSize[0] + border,
 +
height: newSize[1] + border
 +
})
 +
.each(function(i) {
 +
var $this = $(this);
 +
 +
// Set shape specific attributes
 +
$this[ $this.prop ? 'prop' : 'attr' ]({
 +
coordsize: (newSize[0]+border) + ' ' + (newSize[1]+border),
 +
path: coords,
 +
fillcolor: color[0],
 +
filled: !!i,
 +
stroked: !i
 +
})
 +
.toggle(!!(border || i));
 +
 +
// Check if border is enabled and add stroke element
 +
!i && $this.html( createVML(
 +
'stroke', 'weight="'+(border*2)+'px" color="'+color[1]+'" miterlimit="1000" joinstyle="miter"'
 +
) );
 +
});
 +
}
 +
 +
// Opera bug #357 - Incorrect tip position
 +
// https://github.com/Craga89/qTip2/issues/367
 +
window.opera && setTimeout(function() {
 +
elements.tip.css({
 +
display: 'inline-block',
 +
visibility: 'visible'
 +
});
 +
}, 1);
 +
 +
// Position if needed
 +
if(position !== FALSE) { this.calculate(corner, newSize); }
 +
},
 +
 +
calculate: function(corner, size) {
 +
if(!this.enabled) { return FALSE; }
 +
 +
var self = this,
 +
elements = this.qtip.elements,
 +
tip = this.element,
 +
userOffset = this.options.offset,
 +
isWidget = elements.tooltip.hasClass('ui-widget'),
 +
position = {  },
 +
precedance, corners;
 +
 +
// Inherit corner if not provided
 +
corner = corner || this.corner;
 +
precedance = corner.precedance;
 +
 +
// Determine which tip dimension to use for adjustment
 +
size = size || this._calculateSize(corner);
 +
 +
// Setup corners and offset array
 +
corners = [ corner.x, corner.y ];
 +
if(precedance === X) { corners.reverse(); }
 +
 +
// Calculate tip position
 +
$.each(corners, function(i, side) {
 +
var b, bc, br;
 +
 +
if(side === CENTER) {
 +
b = precedance === Y ? LEFT : TOP;
 +
position[ b ] = '50%';
 +
position[MARGIN+'-' + b] = -Math.round(size[ precedance === Y ? 0 : 1 ] / 2) + userOffset;
 +
}
 +
else {
 +
b = self._parseWidth(corner, side, elements.tooltip);
 +
bc = self._parseWidth(corner, side, elements.content);
 +
br = self._parseRadius(corner);
 +
 +
position[ side ] = Math.max(-self.border, i ? bc : (userOffset + (br > b ? br : -b)));
 +
}
 +
});
 +
 +
// Adjust for tip size
 +
position[ corner[precedance] ] -= size[ precedance === X ? 0 : 1 ];
 +
 +
// Set and return new position
 +
tip.css({ margin: '', top: '', bottom: '', left: '', right: '' }).css(position);
 +
return position;
 +
},
 +
 +
reposition: function(event, api, pos, viewport) {
 +
if(!this.enabled) { return; }
 +
 +
var cache = api.cache,
 +
newCorner = this.corner.clone(),
 +
adjust = pos.adjusted,
 +
method = api.options.position.adjust.method.split(' '),
 +
horizontal = method[0],
 +
vertical = method[1] || method[0],
 +
shift = { left: FALSE, top: FALSE, x: 0, y: 0 },
 +
offset, css = {}, props;
 +
 +
function shiftflip(direction, precedance, popposite, side, opposite) {
 +
// Horizontal - Shift or flip method
 +
if(direction === SHIFT && newCorner.precedance === precedance && adjust[side] && newCorner[popposite] !== CENTER) {
 +
newCorner.precedance = newCorner.precedance === X ? Y : X;
 +
}
 +
else if(direction !== SHIFT && adjust[side]){
 +
newCorner[precedance] = newCorner[precedance] === CENTER ?
 +
(adjust[side] > 0 ? side : opposite) : (newCorner[precedance] === side ? opposite : side);
 +
}
 +
}
 +
 +
function shiftonly(xy, side, opposite) {
 +
if(newCorner[xy] === CENTER) {
 +
css[MARGIN+'-'+side] = shift[xy] = offset[MARGIN+'-'+side] - adjust[side];
 +
}
 +
else {
 +
props = offset[opposite] !== undefined ?
 +
[ adjust[side], -offset[side] ] : [ -adjust[side], offset[side] ];
 +
 +
if( (shift[xy] = Math.max(props[0], props[1])) > props[0] ) {
 +
pos[side] -= adjust[side];
 +
shift[side] = FALSE;
 +
}
 +
 +
css[ offset[opposite] !== undefined ? opposite : side ] = shift[xy];
 +
}
 +
}
 +
 +
// If our tip position isn't fixed e.g. doesn't adjust with viewport...
 +
if(this.corner.fixed !== TRUE) {
 +
// Perform shift/flip adjustments
 +
shiftflip(horizontal, X, Y, LEFT, RIGHT);
 +
shiftflip(vertical, Y, X, TOP, BOTTOM);
 +
 +
// Update and redraw the tip if needed (check cached details of last drawn tip)
 +
if(newCorner.string() !== cache.corner.string() && (cache.cornerTop !== adjust.top || cache.cornerLeft !== adjust.left)) {
 +
this.update(newCorner, FALSE);
 +
}
 +
}
 +
 +
// Setup tip offset properties
 +
offset = this.calculate(newCorner);
 +
 +
// Readjust offset object to make it left/top
 +
if(offset.right !== undefined) { offset.left = -offset.right; }
 +
if(offset.bottom !== undefined) { offset.top = -offset.bottom; }
 +
offset.user = this.offset;
 +
 +
// Perform shift adjustments
 +
if(shift.left = (horizontal === SHIFT && !!adjust.left)) { shiftonly(X, LEFT, RIGHT); }
 +
if(shift.top = (vertical === SHIFT && !!adjust.top)) { shiftonly(Y, TOP, BOTTOM); }
 +
 +
/*
 +
* If the tip is adjusted in both dimensions, or in a
 +
* direction that would cause it to be anywhere but the
 +
* outer border, hide it!
 +
*/
 +
this.element.css(css).toggle(
 +
!((shift.x && shift.y) || (newCorner.x === CENTER && shift.y) || (newCorner.y === CENTER && shift.x))
 +
);
 +
 +
// Adjust position to accomodate tip dimensions
 +
pos.left -= offset.left.charAt ? offset.user :
 +
horizontal !== SHIFT || shift.top || !shift.left && !shift.top ? offset.left + this.border : 0;
 +
pos.top -= offset.top.charAt ? offset.user :
 +
vertical !== SHIFT || shift.left || !shift.left && !shift.top ? offset.top + this.border : 0;
 +
 +
// Cache details
 +
cache.cornerLeft = adjust.left; cache.cornerTop = adjust.top;
 +
cache.corner = newCorner.clone();
 +
},
 +
 +
destroy: function() {
 +
// Unbind events
 +
this.qtip._unbind(this.qtip.tooltip, this._ns);
 +
 +
// Remove the tip element(s)
 +
if(this.qtip.elements.tip) {
 +
this.qtip.elements.tip.find('*')
 +
.remove().end().remove();
 +
}
 +
}
 +
});
 +
 +
TIP = PLUGINS.tip = function(api) {
 +
return new Tip(api, api.options.style.tip);
 +
};
 +
 +
// Initialize tip on render
 +
TIP.initialize = 'render';
 +
 +
// Setup plugin sanitization options
 +
TIP.sanitize = function(options) {
 +
if(options.style && 'tip' in options.style) {
 +
var opts = options.style.tip;
 +
if(typeof opts !== 'object') { opts = options.style.tip = { corner: opts }; }
 +
if(!(/string|boolean/i).test(typeof opts.corner)) { opts.corner = TRUE; }
 +
}
 +
};
 +
 +
// Add new option checks for the plugin
 +
CHECKS.tip = {
 +
'^position.my|style.tip.(corner|mimic|border)$': function() {
 +
// Make sure a tip can be drawn
 +
this.create();
 +
 +
// Reposition the tooltip
 +
this.qtip.reposition();
 +
},
 +
'^style.tip.(height|width)$': function(obj) {
 +
// Re-set dimensions and redraw the tip
 +
this.size = [ obj.width, obj.height ];
 +
this.update();
 +
 +
// Reposition the tooltip
 +
this.qtip.reposition();
 +
},
 +
'^content.title|style.(classes|widget)$': function() {
 +
this.update();
 +
}
 +
};
 +
 +
// Extend original qTip defaults
 +
$.extend(TRUE, QTIP.defaults, {
 +
style: {
 +
tip: {
 +
corner: TRUE,
 +
mimic: FALSE,
 +
width: 6,
 +
height: 6,
 +
border: TRUE,
 +
offset: 0
 +
}
 +
}
 +
});
 +
 +
;var MODAL, OVERLAY,
 +
MODALCLASS = 'qtip-modal',
 +
MODALSELECTOR = '.'+MODALCLASS;
 +
 +
OVERLAY = function()
 +
{
 +
var self = this,
 +
focusableElems = {},
 +
current, onLast,
 +
prevState, elem;
 +
 +
// Modified code from jQuery UI 1.10.0 source
 +
// http://code.jquery.com/ui/1.10.0/jquery-ui.js
 +
function focusable(element) {
 +
// Use the defined focusable checker when possible
 +
if($.expr[':'].focusable) { return $.expr[':'].focusable; }
 +
 +
var isTabIndexNotNaN = !isNaN($.attr(element, 'tabindex')),
 +
nodeName = element.nodeName && element.nodeName.toLowerCase(),
 +
map, mapName, img;
 +
 +
if('area' === nodeName) {
 +
map = element.parentNode;
 +
mapName = map.name;
 +
if(!element.href || !mapName || map.nodeName.toLowerCase() !== 'map') {
 +
return false;
 +
}
 +
img = $('img[usemap=#' + mapName + ']')[0];
 +
return !!img && img.is(':visible');
 +
}
 +
return (/input|select|textarea|button|object/.test( nodeName ) ?
 +
!element.disabled :
 +
'a' === nodeName ?
 +
element.href || isTabIndexNotNaN :
 +
isTabIndexNotNaN
 +
);
 +
}
 +
 +
// Focus inputs using cached focusable elements (see update())
 +
function focusInputs(blurElems) {
 +
// Blurring body element in IE causes window.open windows to unfocus!
 +
if(focusableElems.length < 1 && blurElems.length) { blurElems.not('body').blur(); }
 +
 +
// Focus the inputs
 +
else { focusableElems.first().focus(); }
 +
}
 +
 +
// Steal focus from elements outside tooltip
 +
function stealFocus(event) {
 +
if(!elem.is(':visible')) { return; }
 +
 +
var target = $(event.target),
 +
tooltip = current.tooltip,
 +
container = target.closest(SELECTOR),
 +
targetOnTop;
 +
 +
// Determine if input container target is above this
 +
targetOnTop = container.length < 1 ? FALSE :
 +
(parseInt(container[0].style.zIndex, 10) > parseInt(tooltip[0].style.zIndex, 10));
 +
 +
// If we're showing a modal, but focus has landed on an input below
 +
// this modal, divert focus to the first visible input in this modal
 +
// or if we can't find one... the tooltip itself
 +
if(!targetOnTop && target.closest(SELECTOR)[0] !== tooltip[0]) {
 +
focusInputs(target);
 +
}
 +
 +
// Detect when we leave the last focusable element...
 +
onLast = event.target === focusableElems[focusableElems.length - 1];
 +
}
 +
 +
$.extend(self, {
 +
init: function() {
 +
// Create document overlay
 +
elem = self.elem = $('<div />', {
 +
id: 'qtip-overlay',
 +
html: '<div></div>',
 +
mousedown: function() { return FALSE; }
 +
})
 +
.hide();
 +
 +
// Make sure we can't focus anything outside the tooltip
 +
$(document.body).bind('focusin'+MODALSELECTOR, stealFocus);
 +
 +
// Apply keyboard "Escape key" close handler
 +
$(document).bind('keydown'+MODALSELECTOR, function(event) {
 +
if(current && current.options.show.modal.escape && event.keyCode === 27) {
 +
current.hide(event);
 +
}
 +
});
 +
 +
// Apply click handler for blur option
 +
elem.bind('click'+MODALSELECTOR, function(event) {
 +
if(current && current.options.show.modal.blur) {
 +
current.hide(event);
 +
}
 +
});
 +
 +
return self;
 +
},
 +
 +
update: function(api) {
 +
// Update current API reference
 +
current = api;
 +
 +
// Update focusable elements if enabled
 +
if(api.options.show.modal.stealfocus !== FALSE) {
 +
focusableElems = api.tooltip.find('*').filter(function() {
 +
return focusable(this);
 +
});
 +
}
 +
else { focusableElems = []; }
 +
},
 +
 +
toggle: function(api, state, duration) {
 +
var docBody = $(document.body),
 +
tooltip = api.tooltip,
 +
options = api.options.show.modal,
 +
effect = options.effect,
 +
type = state ? 'show': 'hide',
 +
visible = elem.is(':visible'),
 +
visibleModals = $(MODALSELECTOR).filter(':visible:not(:animated)').not(tooltip),
 +
zindex;
 +
 +
// Set active tooltip API reference
 +
self.update(api);
 +
 +
// If the modal can steal the focus...
 +
// Blur the current item and focus anything in the modal we an
 +
if(state && options.stealfocus !== FALSE) {
 +
focusInputs( $(':focus') );
 +
}
 +
 +
// Toggle backdrop cursor style on show
 +
elem.toggleClass('blurs', options.blur);
 +
 +
// Append to body on show
 +
if(state) {
 +
elem.appendTo(document.body);
 +
}
 +
 +
// Prevent modal from conflicting with show.solo, and don't hide backdrop is other modals are visible
 +
if((elem.is(':animated') && visible === state && prevState !== FALSE) || (!state && visibleModals.length)) {
 +
return self;
 +
}
 +
 +
// Stop all animations
 +
elem.stop(TRUE, FALSE);
 +
 +
// Use custom function if provided
 +
if($.isFunction(effect)) {
 +
effect.call(elem, state);
 +
}
 +
 +
// If no effect type is supplied, use a simple toggle
 +
else if(effect === FALSE) {
 +
elem[ type ]();
 +
}
 +
 +
// Use basic fade function
 +
else {
 +
elem.fadeTo( parseInt(duration, 10) || 90, state ? 1 : 0, function() {
 +
if(!state) { elem.hide(); }
 +
});
 +
}
 +
 +
// Reset position and detach from body on hide
 +
if(!state) {
 +
elem.queue(function(next) {
 +
elem.css({ left: '', top: '' });
 +
if(!$(MODALSELECTOR).length) { elem.detach(); }
 +
next();
 +
});
 +
}
 +
 +
// Cache the state
 +
prevState = state;
 +
 +
// If the tooltip is destroyed, set reference to null
 +
if(current.destroyed) { current = NULL; }
 +
 +
return self;
 +
}
 +
});
 +
 +
self.init();
 +
};
 +
OVERLAY = new OVERLAY();
 +
 +
function Modal(api, options) {
 +
this.options = options;
 +
this._ns = '-modal';
 +
 +
this.init( (this.qtip = api) );
 +
}
 +
 +
$.extend(Modal.prototype, {
 +
init: function(qtip) {
 +
var tooltip = qtip.tooltip;
 +
 +
// If modal is disabled... return
 +
if(!this.options.on) { return this; }
 +
 +
// Set overlay reference
 +
qtip.elements.overlay = OVERLAY.elem;
 +
 +
// Add unique attribute so we can grab modal tooltips easily via a SELECTOR, and set z-index
 +
tooltip.addClass(MODALCLASS).css('z-index', QTIP.modal_zindex + $(MODALSELECTOR).length);
 +
 +
// Apply our show/hide/focus modal events
 +
qtip._bind(tooltip, ['tooltipshow', 'tooltiphide'], function(event, api, duration) {
 +
var oEvent = event.originalEvent;
 +
 +
// Make sure mouseout doesn't trigger a hide when showing the modal and mousing onto backdrop
 +
if(event.target === tooltip[0]) {
 +
if(oEvent && event.type === 'tooltiphide' && /mouse(leave|enter)/.test(oEvent.type) && $(oEvent.relatedTarget).closest(OVERLAY.elem[0]).length) {
 +
try { event.preventDefault(); } catch(e) {}
 +
}
 +
else if(!oEvent || (oEvent && oEvent.type !== 'tooltipsolo')) {
 +
this.toggle(event, event.type === 'tooltipshow', duration);
 +
}
 +
}
 +
}, this._ns, this);
 +
 +
// Adjust modal z-index on tooltip focus
 +
qtip._bind(tooltip, 'tooltipfocus', function(event, api) {
 +
// If focus was cancelled before it reached us, don't do anything
 +
if(event.isDefaultPrevented() || event.target !== tooltip[0]) { return; }
 +
 +
var qtips = $(MODALSELECTOR),
 +
 +
// Keep the modal's lower than other, regular qtips
 +
newIndex = QTIP.modal_zindex + qtips.length,
 +
curIndex = parseInt(tooltip[0].style.zIndex, 10);
 +
 +
// Set overlay z-index
 +
OVERLAY.elem[0].style.zIndex = newIndex - 1;
 +
 +
// Reduce modal z-index's and keep them properly ordered
 +
qtips.each(function() {
 +
if(this.style.zIndex > curIndex) {
 +
this.style.zIndex -= 1;
 +
}
 +
});
 +
 +
// Fire blur event for focused tooltip
 +
qtips.filter('.' + CLASS_FOCUS).qtip('blur', event.originalEvent);
 +
 +
// Set the new z-index
 +
tooltip.addClass(CLASS_FOCUS)[0].style.zIndex = newIndex;
 +
 +
// Set current
 +
OVERLAY.update(api);
 +
 +
// Prevent default handling
 +
try { event.preventDefault(); } catch(e) {}
 +
}, this._ns, this);
 +
 +
// Focus any other visible modals when this one hides
 +
qtip._bind(tooltip, 'tooltiphide', function(event) {
 +
if(event.target === tooltip[0]) {
 +
$(MODALSELECTOR).filter(':visible').not(tooltip).last().qtip('focus', event);
 +
}
 +
}, this._ns, this);
 +
},
 +
 +
toggle: function(event, state, duration) {
 +
// Make sure default event hasn't been prevented
 +
if(event && event.isDefaultPrevented()) { return this; }
 +
 +
// Toggle it
 +
OVERLAY.toggle(this.qtip, !!state, duration);
 +
},
 +
 +
destroy: function() {
 +
// Remove modal class
 +
this.qtip.tooltip.removeClass(MODALCLASS);
 +
 +
// Remove bound events
 +
this.qtip._unbind(this.qtip.tooltip, this._ns);
 +
 +
// Delete element reference
 +
OVERLAY.toggle(this.qtip, FALSE);
 +
delete this.qtip.elements.overlay;
 +
}
 +
});
 +
 +
 +
MODAL = PLUGINS.modal = function(api) {
 +
return new Modal(api, api.options.show.modal);
 +
};
 +
 +
// Setup sanitiztion rules
 +
MODAL.sanitize = function(opts) {
 +
if(opts.show) {
 +
if(typeof opts.show.modal !== 'object') { opts.show.modal = { on: !!opts.show.modal }; }
 +
else if(typeof opts.show.modal.on === 'undefined') { opts.show.modal.on = TRUE; }
 +
}
 +
};
 +
 +
// Base z-index for all modal tooltips (use qTip core z-index as a base)
 +
QTIP.modal_zindex = QTIP.zindex - 200;
 +
 +
// Plugin needs to be initialized on render
 +
MODAL.initialize = 'render';
 +
 +
// Setup option set checks
 +
CHECKS.modal = {
 +
'^show.modal.(on|blur)$': function() {
 +
// Initialise
 +
this.destroy();
 +
this.init();
 +
 +
// Show the modal if not visible already and tooltip is visible
 +
this.qtip.elems.overlay.toggle(
 +
this.qtip.tooltip[0].offsetWidth > 0
 +
);
 +
}
 +
};
 +
 +
// Extend original api defaults
 +
$.extend(TRUE, QTIP.defaults, {
 +
show: {
 +
modal: {
 +
on: FALSE,
 +
effect: TRUE,
 +
blur: TRUE,
 +
stealfocus: TRUE,
 +
escape: TRUE
 +
}
 +
}
 +
});
 +
;PLUGINS.viewport = function(api, position, posOptions, targetWidth, targetHeight, elemWidth, elemHeight)
 +
{
 +
var target = posOptions.target,
 +
tooltip = api.elements.tooltip,
 +
my = posOptions.my,
 +
at = posOptions.at,
 +
adjust = posOptions.adjust,
 +
method = adjust.method.split(' '),
 +
methodX = method[0],
 +
methodY = method[1] || method[0],
 +
viewport = posOptions.viewport,
 +
container = posOptions.container,
 +
cache = api.cache,
 +
adjusted = { left: 0, top: 0 },
 +
fixed, newMy, newClass, containerOffset, containerStatic,
 +
viewportWidth, viewportHeight, viewportScroll, viewportOffset;
 +
 +
// If viewport is not a jQuery element, or it's the window/document, or no adjustment method is used... return
 +
if(!viewport.jquery || target[0] === window || target[0] === document.body || adjust.method === 'none') {
 +
return adjusted;
 +
}
 +
 +
// Cach container details
 +
containerOffset = container.offset() || adjusted;
 +
containerStatic = container.css('position') === 'static';
 +
 +
// Cache our viewport details
 +
fixed = tooltip.css('position') === 'fixed';
 +
viewportWidth = viewport[0] === window ? viewport.width() : viewport.outerWidth(FALSE);
 +
viewportHeight = viewport[0] === window ? viewport.height() : viewport.outerHeight(FALSE);
 +
viewportScroll = { left: fixed ? 0 : viewport.scrollLeft(), top: fixed ? 0 : viewport.scrollTop() };
 +
viewportOffset = viewport.offset() || adjusted;
 +
 +
// Generic calculation method
 +
function calculate(side, otherSide, type, adjust, side1, side2, lengthName, targetLength, elemLength) {
 +
var initialPos = position[side1],
 +
mySide = my[side],
 +
atSide = at[side],
 +
isShift = type === SHIFT,
 +
myLength = mySide === side1 ? elemLength : mySide === side2 ? -elemLength : -elemLength / 2,
 +
atLength = atSide === side1 ? targetLength : atSide === side2 ? -targetLength : -targetLength / 2,
 +
sideOffset = viewportScroll[side1] + viewportOffset[side1] - (containerStatic ? 0 : containerOffset[side1]),
 +
overflow1 = sideOffset - initialPos,
 +
overflow2 = initialPos + elemLength - (lengthName === WIDTH ? viewportWidth : viewportHeight) - sideOffset,
 +
offset = myLength - (my.precedance === side || mySide === my[otherSide] ? atLength : 0) - (atSide === CENTER ? targetLength / 2 : 0);
 +
 +
// shift
 +
if(isShift) {
 +
offset = (mySide === side1 ? 1 : -1) * myLength;
 +
 +
// Adjust position but keep it within viewport dimensions
 +
position[side1] += overflow1 > 0 ? overflow1 : overflow2 > 0 ? -overflow2 : 0;
 +
position[side1] = Math.max(
 +
-containerOffset[side1] + viewportOffset[side1],
 +
initialPos - offset,
 +
Math.min(
 +
Math.max(
 +
-containerOffset[side1] + viewportOffset[side1] + (lengthName === WIDTH ? viewportWidth : viewportHeight),
 +
initialPos + offset
 +
),
 +
position[side1],
 +
 +
// Make sure we don't adjust complete off the element when using 'center'
 +
mySide === 'center' ? initialPos - myLength : 1E9
 +
)
 +
);
 +
 +
}
 +
 +
// flip/flipinvert
 +
else {
 +
// Update adjustment amount depending on if using flipinvert or flip
 +
adjust *= (type === FLIPINVERT ? 2 : 0);
 +
 +
// Check for overflow on the left/top
 +
if(overflow1 > 0 && (mySide !== side1 || overflow2 > 0)) {
 +
position[side1] -= offset + adjust;
 +
newMy.invert(side, side1);
 +
}
 +
 +
// Check for overflow on the bottom/right
 +
else if(overflow2 > 0 && (mySide !== side2 || overflow1 > 0)  ) {
 +
position[side1] -= (mySide === CENTER ? -offset : offset) + adjust;
 +
newMy.invert(side, side2);
 +
}
 +
 +
// Make sure we haven't made things worse with the adjustment and reset if so
 +
if(position[side1] < viewportScroll && -position[side1] > overflow2) {
 +
position[side1] = initialPos; newMy = my.clone();
 +
}
 +
}
 +
 +
return position[side1] - initialPos;
 +
}
 +
 +
// Set newMy if using flip or flipinvert methods
 +
if(methodX !== 'shift' || methodY !== 'shift') { newMy = my.clone(); }
 +
 +
// Adjust position based onviewport and adjustment options
 +
adjusted = {
 +
left: methodX !== 'none' ? calculate( X, Y, methodX, adjust.x, LEFT, RIGHT, WIDTH, targetWidth, elemWidth ) : 0,
 +
top: methodY !== 'none' ? calculate( Y, X, methodY, adjust.y, TOP, BOTTOM, HEIGHT, targetHeight, elemHeight ) : 0
 +
};
 +
 +
// Set tooltip position class if it's changed
 +
if(newMy && cache.lastClass !== (newClass = NAMESPACE + '-pos-' + newMy.abbrev())) {
 +
tooltip.removeClass(api.cache.lastClass).addClass( (api.cache.lastClass = newClass) );
 +
}
 +
 +
return adjusted;
 +
};
 +
;PLUGINS.polys = {
 +
// POLY area coordinate calculator
 +
// Special thanks to Ed Cradock for helping out with this.
 +
// Uses a binary search algorithm to find suitable coordinates.
 +
polygon: function(baseCoords, corner) {
 +
var result = {
 +
width: 0, height: 0,
 +
position: {
 +
top: 1e10, right: 0,
 +
bottom: 0, left: 1e10
 +
},
 +
adjustable: FALSE
 +
},
 +
i = 0, next,
 +
coords = [],
 +
compareX = 1, compareY = 1,
 +
realX = 0, realY = 0,
 +
newWidth, newHeight;
 +
 +
// First pass, sanitize coords and determine outer edges
 +
i = baseCoords.length; while(i--) {
 +
next = [ parseInt(baseCoords[--i], 10), parseInt(baseCoords[i+1], 10) ];
 +
 +
if(next[0] > result.position.right){ result.position.right = next[0]; }
 +
if(next[0] < result.position.left){ result.position.left = next[0]; }
 +
if(next[1] > result.position.bottom){ result.position.bottom = next[1]; }
 +
if(next[1] < result.position.top){ result.position.top = next[1]; }
 +
 +
coords.push(next);
 +
}
 +
 +
// Calculate height and width from outer edges
 +
newWidth = result.width = Math.abs(result.position.right - result.position.left);
 +
newHeight = result.height = Math.abs(result.position.bottom - result.position.top);
 +
 +
// If it's the center corner...
 +
if(corner.abbrev() === 'c') {
 +
result.position = {
 +
left: result.position.left + (result.width / 2),
 +
top: result.position.top + (result.height / 2)
 +
};
 +
}
 +
else {
 +
// Second pass, use a binary search algorithm to locate most suitable coordinate
 +
while(newWidth > 0 && newHeight > 0 && compareX > 0 && compareY > 0)
 +
{
 +
newWidth = Math.floor(newWidth / 2);
 +
newHeight = Math.floor(newHeight / 2);
 +
 +
if(corner.x === LEFT){ compareX = newWidth; }
 +
else if(corner.x === RIGHT){ compareX = result.width - newWidth; }
 +
else{ compareX += Math.floor(newWidth / 2); }
 +
 +
if(corner.y === TOP){ compareY = newHeight; }
 +
else if(corner.y === BOTTOM){ compareY = result.height - newHeight; }
 +
else{ compareY += Math.floor(newHeight / 2); }
 +
 +
i = coords.length; while(i--)
 +
{
 +
if(coords.length < 2){ break; }
 +
 +
realX = coords[i][0] - result.position.left;
 +
realY = coords[i][1] - result.position.top;
 +
 +
if((corner.x === LEFT && realX >= compareX) ||
 +
(corner.x === RIGHT && realX <= compareX) ||
 +
(corner.x === CENTER && (realX < compareX || realX > (result.width - compareX))) ||
 +
(corner.y === TOP && realY >= compareY) ||
 +
(corner.y === BOTTOM && realY <= compareY) ||
 +
(corner.y === CENTER && (realY < compareY || realY > (result.height - compareY)))) {
 +
coords.splice(i, 1);
 +
}
 +
}
 +
}
 +
result.position = { left: coords[0][0], top: coords[0][1] };
 +
}
 +
 +
return result;
 +
},
 +
 +
rect: function(ax, ay, bx, by) {
 +
return {
 +
width: Math.abs(bx - ax),
 +
height: Math.abs(by - ay),
 +
position: {
 +
left: Math.min(ax, bx),
 +
top: Math.min(ay, by)
 +
}
 +
};
 +
},
 +
 +
_angles: {
 +
tc: 3 / 2, tr: 7 / 4, tl: 5 / 4,
 +
bc: 1 / 2, br: 1 / 4, bl: 3 / 4,
 +
rc: 2, lc: 1, c: 0
 +
},
 +
ellipse: function(cx, cy, rx, ry, corner) {
 +
var c = PLUGINS.polys._angles[ corner.abbrev() ],
 +
rxc = c === 0 ? 0 : rx * Math.cos( c * Math.PI ),
 +
rys = ry * Math.sin( c * Math.PI );
 +
 +
return {
 +
width: (rx * 2) - Math.abs(rxc),
 +
height: (ry * 2) - Math.abs(rys),
 +
position: {
 +
left: cx + rxc,
 +
top: cy + rys
 +
},
 +
adjustable: FALSE
 +
};
 +
},
 +
circle: function(cx, cy, r, corner) {
 +
return PLUGINS.polys.ellipse(cx, cy, r, r, corner);
 +
}
 +
};;PLUGINS.svg = function(api, svg, corner)
 +
{
 +
var doc = $(document),
 +
elem = svg[0],
 +
root = $(elem.ownerSVGElement),
 +
xScale = 1, yScale = 1,
 +
complex = true,
 +
rootWidth, rootHeight,
 +
mtx, transformed, viewBox,
 +
len, next, i, points,
 +
result, position, dimensions;
 +
 +
// Ascend the parentNode chain until we find an element with getBBox()
 +
while(!elem.getBBox) { elem = elem.parentNode; }
 +
if(!elem.getBBox || !elem.parentNode) { return FALSE; }
 +
 +
// Determine dimensions where possible
 +
rootWidth = root.attr('width') || root.width() || parseInt(root.css('width'), 10);
 +
rootHeight = root.attr('height') || root.height() || parseInt(root.css('height'), 10);
 +
 +
// Add stroke characteristics to scaling
 +
var strokeWidth2 = (parseInt(svg.css('stroke-width'), 10) || 0) / 2;
 +
if(strokeWidth2) {
 +
xScale += strokeWidth2 / rootWidth;
 +
yScale += strokeWidth2 / rootHeight;
 +
}
 +
 +
// Determine which shape calculation to use
 +
switch(elem.nodeName) {
 +
case 'ellipse':
 +
case 'circle':
 +
result = PLUGINS.polys.ellipse(
 +
elem.cx.baseVal.value,
 +
elem.cy.baseVal.value,
 +
(elem.rx || elem.r).baseVal.value + strokeWidth2,
 +
(elem.ry || elem.r).baseVal.value + strokeWidth2,
 +
corner
 +
);
 +
break;
 +
 +
case 'line':
 +
case 'polygon':
 +
case 'polyline':
 +
// Determine points object (line has none, so mimic using array)
 +
points = elem.points || [
 +
{ x: elem.x1.baseVal.value, y: elem.y1.baseVal.value },
 +
{ x: elem.x2.baseVal.value, y: elem.y2.baseVal.value }
 +
];
 +
 +
for(result = [], i = -1, len = points.numberOfItems || points.length; ++i < len;) {
 +
next = points.getItem ? points.getItem(i) : points[i];
 +
result.push.apply(result, [next.x, next.y]);
 +
}
 +
 +
result = PLUGINS.polys.polygon(result, corner);
 +
break;
 +
 +
// Unknown shape or rectangle? Use bounding box
 +
default:
 +
result = elem.getBoundingClientRect();
 +
result = {
 +
width: result.width, height: result.height,
 +
position: {
 +
left: result.left,
 +
top: result.top
 +
}
 +
};
 +
complex = false;
 +
break;
 +
}
 +
 +
// Shortcut assignments
 +
position = result.position;
 +
root = root[0];
 +
 +
// If the shape was complex (i.e. not using bounding box calculations)
 +
if(complex) {
 +
// Convert position into a pixel value
 +
if(root.createSVGPoint) {
 +
mtx = elem.getScreenCTM();
 +
points = root.createSVGPoint();
 +
 +
points.x = position.left;
 +
points.y = position.top;
 +
transformed = points.matrixTransform( mtx );
 +
position.left = transformed.x;
 +
position.top = transformed.y;
 +
}
 +
 +
// Calculate viewBox characteristics
 +
if(root.viewBox && (viewBox = root.viewBox.baseVal) && viewBox.width && viewBox.height) {
 +
xScale *= rootWidth / viewBox.width;
 +
yScale *= rootHeight / viewBox.height;
 +
}
 +
}
 +
 +
// Adjust by scroll offset
 +
position.left += doc.scrollLeft();
 +
position.top += doc.scrollTop();
 +
 +
return result;
 +
};;PLUGINS.imagemap = function(api, area, corner, adjustMethod)
 +
{
 +
if(!area.jquery) { area = $(area); }
 +
 +
var shape = area.attr('shape').toLowerCase().replace('poly', 'polygon'),
 +
image = $('img[usemap="#'+area.parent('map').attr('name')+'"]'),
 +
coordsString = $.trim(area.attr('coords')),
 +
coordsArray = coordsString.replace(/,$/, '').split(','),
 +
imageOffset, coords, i, next, result, len;
 +
 +
// If we can't find the image using the map...
 +
if(!image.length) { return FALSE; }
 +
 +
// Pass coordinates string if polygon
 +
if(shape === 'polygon') {
 +
result = PLUGINS.polys.polygon(coordsArray, corner);
 +
}
 +
 +
// Otherwise parse the coordinates and pass them as arguments
 +
else if(PLUGINS.polys[shape]) {
 +
for(i = -1, len = coordsArray.length, coords = []; ++i < len;) {
 +
coords.push( parseInt(coordsArray[i], 10) );
 +
}
 +
 +
result = PLUGINS.polys[shape].apply(
 +
this, coords.concat(corner)
 +
);
 +
}
 +
 +
// If no shapre calculation method was found, return false
 +
else { return FALSE; }
 +
 +
// Make sure we account for padding and borders on the image
 +
imageOffset = image.offset();
 +
imageOffset.left += Math.ceil((image.outerWidth(FALSE) - image.width()) / 2);
 +
imageOffset.top += Math.ceil((image.outerHeight(FALSE) - image.height()) / 2);
 +
 +
// Add image position to offset coordinates
 +
result.position.left += imageOffset.left;
 +
result.position.top += imageOffset.top;
 +
 +
return result;
 +
};;var IE6,
 +
 +
/*
 +
* BGIFrame adaption (http://plugins.jquery.com/project/bgiframe)
 +
* Special thanks to Brandon Aaron
 +
*/
 +
BGIFRAME = '<iframe class="qtip-bgiframe" frameborder="0" tabindex="-1" src="javascript:\'\';" ' +
 +
' style="display:block; position:absolute; z-index:-1; filter:alpha(opacity=0); ' +
 +
'-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";"></iframe>';
 +
 +
function Ie6(api, qtip) {
 +
this._ns = 'ie6';
 +
this.init( (this.qtip = api) );
 +
}
 +
 +
$.extend(Ie6.prototype, {
 +
_scroll : function() {
 +
var overlay = this.qtip.elements.overlay;
 +
overlay && (overlay[0].style.top = $(window).scrollTop() + 'px');
 +
},
 +
 +
init: function(qtip) {
 +
var tooltip = qtip.tooltip,
 +
scroll;
 +
 +
// Create the BGIFrame element if needed
 +
if($('select, object').length < 1) {
 +
this.bgiframe = qtip.elements.bgiframe = $(BGIFRAME).appendTo(tooltip);
 +
 +
// Update BGIFrame on tooltip move
 +
qtip._bind(tooltip, 'tooltipmove', this.adjustBGIFrame, this._ns, this);
 +
}
 +
 +
// redraw() container for width/height calculations
 +
this.redrawContainer = $('<div/>', { id: NAMESPACE+'-rcontainer' })
 +
.appendTo(document.body);
 +
 +
// Fixup modal plugin if present too
 +
if( qtip.elements.overlay && qtip.elements.overlay.addClass('qtipmodal-ie6fix') ) {
 +
qtip._bind(window, ['scroll', 'resize'], this._scroll, this._ns, this);
 +
qtip._bind(tooltip, ['tooltipshow'], this._scroll, this._ns, this);
 +
}
 +
 +
// Set dimensions
 +
this.redraw();
 +
},
 +
 +
adjustBGIFrame: function() {
 +
var tooltip = this.qtip.tooltip,
 +
dimensions = {
 +
height: tooltip.outerHeight(FALSE),
 +
width: tooltip.outerWidth(FALSE)
 +
},
 +
plugin = this.qtip.plugins.tip,
 +
tip = this.qtip.elements.tip,
 +
tipAdjust, offset;
 +
 +
// Adjust border offset
 +
offset = parseInt(tooltip.css('borderLeftWidth'), 10) || 0;
 +
offset = { left: -offset, top: -offset };
 +
 +
// Adjust for tips plugin
 +
if(plugin && tip) {
 +
tipAdjust = (plugin.corner.precedance === 'x') ? [WIDTH, LEFT] : [HEIGHT, TOP];
 +
offset[ tipAdjust[1] ] -= tip[ tipAdjust[0] ]();
 +
}
 +
 +
// Update bgiframe
 +
this.bgiframe.css(offset).css(dimensions);
 +
},
 +
 +
// Max/min width simulator function
 +
redraw: function() {
 +
if(this.qtip.rendered < 1 || this.drawing) { return this; }
 +
 +
var tooltip = this.qtip.tooltip,
 +
style = this.qtip.options.style,
 +
container = this.qtip.options.position.container,
 +
perc, width, max, min;
 +
 +
// Set drawing flag
 +
this.qtip.drawing = 1;
 +
 +
// If tooltip has a set height/width, just set it... like a boss!
 +
if(style.height) { tooltip.css(HEIGHT, style.height); }
 +
if(style.width) { tooltip.css(WIDTH, style.width); }
 +
 +
// Simulate max/min width if not set width present...
 +
else {
 +
// Reset width and add fluid class
 +
tooltip.css(WIDTH, '').appendTo(this.redrawContainer);
 +
 +
// Grab our tooltip width (add 1 if odd so we don't get wrapping problems.. huzzah!)
 +
width = tooltip.width();
 +
if(width % 2 < 1) { width += 1; }
 +
 +
// Grab our max/min properties
 +
max = tooltip.css('maxWidth') || '';
 +
min = tooltip.css('minWidth') || '';
 +
 +
// Parse into proper pixel values
 +
perc = (max + min).indexOf('%') > -1 ? container.width() / 100 : 0;
 +
max = ((max.indexOf('%') > -1 ? perc : 1) * parseInt(max, 10)) || width;
 +
min = ((min.indexOf('%') > -1 ? perc : 1) * parseInt(min, 10)) || 0;
 +
 +
// Determine new dimension size based on max/min/current values
 +
width = max + min ? Math.min(Math.max(width, min), max) : width;
 +
 +
// Set the newly calculated width and remvoe fluid class
 +
tooltip.css(WIDTH, Math.round(width)).appendTo(container);
 +
}
 +
 +
// Set drawing flag
 +
this.drawing = 0;
 +
 +
return this;
 +
},
 +
 +
destroy: function() {
 +
// Remove iframe
 +
this.bgiframe && this.bgiframe.remove();
 +
 +
// Remove bound events
 +
this.qtip._unbind([window, this.qtip.tooltip], this._ns);
 +
}
 +
});
 +
 +
IE6 = PLUGINS.ie6 = function(api) {
 +
// Proceed only if the browser is IE6
 +
return BROWSER.ie === 6 ? new Ie6(api) : FALSE;
 +
};
 +
 +
IE6.initialize = 'render';
 +
 +
CHECKS.ie6 = {
 +
'^content|style$': function() {
 +
this.redraw();
 +
}
 +
};;}));
 +
}( window, document ));
 +
 +
 +
 +
/**
 +
* Javascript handler for the Lingo extension
 +
*
 +
* @author Stephan Gambke
 +
*/
 +
 +
/*global jQuery, mediaWiki */
 +
/*global confirm */
 +
 +
( function ( $, mw ) {
 +
 +
'use strict';
 +
 +
$( function ( $ ) {
 +
 +
$( '.mw-lingo-tooltip' ).each( function ( index ) {
 +
 +
var tooltip = $( this ).find( '.mw-lingo-tooltip-tip' );
 +
 +
$( this ).qtip( {
 +
content : tooltip.html(),
 +
position: {
 +
my: 'top left',  // Position tooltip's top left...
 +
at: 'bottom left' // at the bottom left of target
 +
},
 +
hide    : {
 +
fixed: true,
 +
delay: 300
 +
},
 +
style  : {
 +
classes: tooltip.attr( 'class' ) + ' qtip-shadow',
 +
def    : false
 +
}
 +
 +
} );
 +
 +
tooltip.remove();
 +
 +
} );
 +
 +
} );
 +
}( jQuery, mediaWiki ) );
  
 
</script>
 
</script>
Línea 195: Línea 3678:
 
position: absolute;
 
position: absolute;
 
margin: 1.8em 0 0 0.1em;
 
margin: 1.8em 0 0 0.1em;
 +
}
 +
/*
 +
* qTip2 - Pretty powerful tooltips - v2.2.0
 +
* http://qtip2.com
 +
*
 +
* Copyright (c) 2013 Craig Michael Thompson
 +
* Released under the MIT, GPL licenses
 +
* http://jquery.org/license
 +
*
 +
* Date: Thu Nov 21 2013 08:34 GMT+0000
 +
* Plugins: tips modal viewport svg imagemap ie6
 +
* Styles: basic css3
 +
*/
 +
.qtip{
 +
position: absolute;
 +
left: -28000px;
 +
top: -28000px;
 +
display: none;
 +
 +
max-width: 280px;
 +
min-width: 50px;
 +
 +
font-size: 10.5px;
 +
line-height: 12px;
 +
 +
direction: ltr;
 +
 +
box-shadow: none;
 +
padding: 0;
 +
}
 +
 +
.qtip-content{
 +
position: relative;
 +
padding: 5px 9px;
 +
overflow: hidden;
 +
 +
text-align: left;
 +
word-wrap: break-word;
 +
}
 +
 +
.qtip-titlebar{
 +
position: relative;
 +
padding: 5px 35px 5px 10px;
 +
overflow: hidden;
 +
 +
border-width: 0 0 1px;
 +
font-weight: bold;
 +
}
 +
 +
.qtip-titlebar + .qtip-content{ border-top-width: 0 !important; }
 +
 +
/* Default close button class */
 +
.qtip-close{
 +
position: absolute;
 +
right: -9px; top: -9px;
 +
 +
cursor: pointer;
 +
outline: medium none;
 +
 +
border-width: 1px;
 +
border-style: solid;
 +
border-color: transparent;
 +
}
 +
 +
.qtip-titlebar .qtip-close{
 +
right: 4px; top: 50%;
 +
margin-top: -9px;
 +
}
 +
 +
* html .qtip-titlebar .qtip-close{ top: 16px; } /* IE fix */
 +
 +
.qtip-titlebar .ui-icon,
 +
.qtip-icon .ui-icon{
 +
display: block;
 +
text-indent: -1000em;
 +
direction: ltr;
 +
}
 +
 +
.qtip-icon, .qtip-icon .ui-icon{
 +
-moz-border-radius: 3px;
 +
-webkit-border-radius: 3px;
 +
border-radius: 3px;
 +
text-decoration: none;
 +
}
 +
 +
.qtip-icon .ui-icon{
 +
width: 18px;
 +
height: 14px;
 +
 +
line-height: 14px;
 +
text-align: center;
 +
text-indent: 0;
 +
font: normal bold 10px/13px Tahoma,sans-serif;
 +
 +
color: inherit;
 +
background: transparent none no-repeat -100em -100em;
 +
}
 +
 +
/* Applied to 'focused' tooltips e.g. most recently displayed/interacted with */
 +
.qtip-focus{}
 +
 +
/* Applied on hover of tooltips i.e. added/removed on mouseenter/mouseleave respectively */
 +
.qtip-hover{}
 +
 +
/* Default tooltip style */
 +
.qtip-default{
 +
border-width: 1px;
 +
border-style: solid;
 +
border-color: #F1D031;
 +
 +
background-color: #FFFFA3;
 +
color: #555;
 +
}
 +
 +
.qtip-default .qtip-titlebar{
 +
background-color: #FFEF93;
 +
}
 +
 +
.qtip-default .qtip-icon{
 +
border-color: #CCC;
 +
background: #F1F1F1;
 +
color: #777;
 +
}
 +
 +
.qtip-default .qtip-titlebar .qtip-close{
 +
border-color: #AAA;
 +
color: #111;
 +
}
 +
 +
 +
 +
/*! Light tooltip style */
 +
.qtip-light{
 +
background-color: white;
 +
border-color: #E2E2E2;
 +
color: #454545;
 +
}
 +
 +
.qtip-light .qtip-titlebar{
 +
background-color: #f1f1f1;
 +
}
 +
 +
 +
/*! Dark tooltip style */
 +
.qtip-dark{
 +
background-color: #505050;
 +
border-color: #303030;
 +
color: #f3f3f3;
 +
}
 +
 +
.qtip-dark .qtip-titlebar{
 +
background-color: #404040;
 +
}
 +
 +
.qtip-dark .qtip-icon{
 +
border-color: #444;
 +
}
 +
 +
.qtip-dark .qtip-titlebar .ui-state-hover{
 +
border-color: #303030;
 +
}
 +
 +
 +
/*! Cream tooltip style */
 +
.qtip-cream{
 +
background-color: #FBF7AA;
 +
border-color: #F9E98E;
 +
color: #A27D35;
 +
}
 +
 +
.qtip-cream .qtip-titlebar{
 +
background-color: #F0DE7D;
 +
}
 +
 +
.qtip-cream .qtip-close .qtip-icon{
 +
background-position: -82px 0;
 +
}
 +
 +
 +
/*! Red tooltip style */
 +
.qtip-red{
 +
background-color: #F78B83;
 +
border-color: #D95252;
 +
color: #912323;
 +
}
 +
 +
.qtip-red .qtip-titlebar{
 +
background-color: #F06D65;
 +
}
 +
 +
.qtip-red .qtip-close .qtip-icon{
 +
background-position: -102px 0;
 +
}
 +
 +
.qtip-red .qtip-icon{
 +
border-color: #D95252;
 +
}
 +
 +
.qtip-red .qtip-titlebar .ui-state-hover{
 +
border-color: #D95252;
 +
}
 +
 +
 +
/*! Green tooltip style */
 +
.qtip-green{
 +
background-color: #CAED9E;
 +
border-color: #90D93F;
 +
color: #3F6219;
 +
}
 +
 +
.qtip-green .qtip-titlebar{
 +
background-color: #B0DE78;
 +
}
 +
 +
.qtip-green .qtip-close .qtip-icon{
 +
background-position: -42px 0;
 +
}
 +
 +
 +
/*! Blue tooltip style */
 +
.qtip-blue{
 +
background-color: #E5F6FE;
 +
border-color: #ADD9ED;
 +
color: #5E99BD;
 +
}
 +
 +
.qtip-blue .qtip-titlebar{
 +
background-color: #D0E9F5;
 +
}
 +
 +
.qtip-blue .qtip-close .qtip-icon{
 +
background-position: -2px 0;
 +
}
 +
 +
 +
 +
.qtip-shadow{
 +
-webkit-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15);
 +
-moz-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15);
 +
box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15);
 +
}
 +
 +
/* Add rounded corners to your tooltips in: FF3+, Chrome 2+, Opera 10.6+, IE9+, Safari 2+ */
 +
.qtip-rounded,
 +
.qtip-tipsy,
 +
.qtip-bootstrap{
 +
-moz-border-radius: 5px;
 +
-webkit-border-radius: 5px;
 +
border-radius: 5px;
 +
}
 +
 +
.qtip-rounded .qtip-titlebar{
 +
-moz-border-radius: 4px 4px 0 0;
 +
-webkit-border-radius: 4px 4px 0 0;
 +
border-radius: 4px 4px 0 0;
 +
}
 +
 +
/* Youtube tooltip style */
 +
.qtip-youtube{
 +
-moz-border-radius: 2px;
 +
-webkit-border-radius: 2px;
 +
border-radius: 2px;
 +
 +
-webkit-box-shadow: 0 0 3px #333;
 +
-moz-box-shadow: 0 0 3px #333;
 +
box-shadow: 0 0 3px #333;
 +
 +
color: white;
 +
border-width: 0;
 +
 +
background: #4A4A4A;
 +
background-image: -webkit-gradient(linear,left top,left bottom,color-stop(0,#4A4A4A),color-stop(100%,black));
 +
background-image: -webkit-linear-gradient(top,#4A4A4A 0,black 100%);
 +
background-image: -moz-linear-gradient(top,#4A4A4A 0,black 100%);
 +
background-image: -ms-linear-gradient(top,#4A4A4A 0,black 100%);
 +
background-image: -o-linear-gradient(top,#4A4A4A 0,black 100%);
 +
}
 +
 +
.qtip-youtube .qtip-titlebar{
 +
background-color: #4A4A4A;
 +
background-color: rgba(0,0,0,0);
 +
}
 +
 +
.qtip-youtube .qtip-content{
 +
padding: .75em;
 +
font: 12px arial,sans-serif;
 +
 +
filter: progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#4a4a4a,EndColorStr=#000000);
 +
-ms-filter: "progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#4a4a4a,EndColorStr=#000000);";
 +
}
 +
 +
.qtip-youtube .qtip-icon{
 +
border-color: #222;
 +
}
 +
 +
.qtip-youtube .qtip-titlebar .ui-state-hover{
 +
border-color: #303030;
 +
}
 +
 +
 +
/* jQuery TOOLS Tooltip style */
 +
.qtip-jtools{
 +
background: #232323;
 +
background: rgba(0, 0, 0, 0.7);
 +
background-image: -webkit-gradient(linear, left top, left bottom, from(#717171), to(#232323));
 +
background-image: -moz-linear-gradient(top, #717171, #232323);
 +
background-image: -webkit-linear-gradient(top, #717171, #232323);
 +
background-image: -ms-linear-gradient(top, #717171, #232323);
 +
background-image: -o-linear-gradient(top, #717171, #232323);
 +
 +
border: 2px solid #ddd;
 +
border: 2px solid rgba(241,241,241,1);
 +
 +
-moz-border-radius: 2px;
 +
-webkit-border-radius: 2px;
 +
border-radius: 2px;
 +
 +
-webkit-box-shadow: 0 0 12px #333;
 +
-moz-box-shadow: 0 0 12px #333;
 +
box-shadow: 0 0 12px #333;
 +
}
 +
 +
/* IE Specific */
 +
.qtip-jtools .qtip-titlebar{
 +
background-color: transparent;
 +
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#717171,endColorstr=#4A4A4A);
 +
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#717171,endColorstr=#4A4A4A)";
 +
}
 +
.qtip-jtools .qtip-content{
 +
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#4A4A4A,endColorstr=#232323);
 +
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#4A4A4A,endColorstr=#232323)";
 +
}
 +
 +
.qtip-jtools .qtip-titlebar,
 +
.qtip-jtools .qtip-content{
 +
background: transparent;
 +
color: white;
 +
border: 0 dashed transparent;
 +
}
 +
 +
.qtip-jtools .qtip-icon{
 +
border-color: #555;
 +
}
 +
 +
.qtip-jtools .qtip-titlebar .ui-state-hover{
 +
border-color: #333;
 +
}
 +
 +
 +
/* Cluetip style */
 +
.qtip-cluetip{
 +
-webkit-box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4);
 +
-moz-box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4);
 +
box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4);
 +
 +
background-color: #D9D9C2;
 +
color: #111;
 +
border: 0 dashed transparent;
 +
}
 +
 +
.qtip-cluetip .qtip-titlebar{
 +
background-color: #87876A;
 +
color: white;
 +
border: 0 dashed transparent;
 +
}
 +
 +
.qtip-cluetip .qtip-icon{
 +
border-color: #808064;
 +
}
 +
 +
.qtip-cluetip .qtip-titlebar .ui-state-hover{
 +
border-color: #696952;
 +
color: #696952;
 +
}
 +
 +
 +
/* Tipsy style */
 +
.qtip-tipsy{
 +
background: black;
 +
background: rgba(0, 0, 0, .87);
 +
 +
color: white;
 +
border: 0 solid transparent;
 +
 +
font-size: 11px;
 +
font-family: 'Lucida Grande', sans-serif;
 +
font-weight: bold;
 +
line-height: 16px;
 +
text-shadow: 0 1px black;
 +
}
 +
 +
.qtip-tipsy .qtip-titlebar{
 +
padding: 6px 35px 0 10px;
 +
background-color: transparent;
 +
}
 +
 +
.qtip-tipsy .qtip-content{
 +
padding: 6px 10px;
 +
}
 +
 +
.qtip-tipsy .qtip-icon{
 +
border-color: #222;
 +
text-shadow: none;
 +
}
 +
 +
.qtip-tipsy .qtip-titlebar .ui-state-hover{
 +
border-color: #303030;
 +
}
 +
 +
 +
/* Tipped style */
 +
.qtip-tipped{
 +
border: 3px solid #959FA9;
 +
 +
-moz-border-radius: 3px;
 +
-webkit-border-radius: 3px;
 +
border-radius: 3px;
 +
 +
background-color: #F9F9F9;
 +
color: #454545;
 +
 +
font-weight: normal;
 +
font-family: serif;
 +
}
 +
 +
.qtip-tipped .qtip-titlebar{
 +
border-bottom-width: 0;
 +
 +
color: white;
 +
background: #3A79B8;
 +
background-image: -webkit-gradient(linear, left top, left bottom, from(#3A79B8), to(#2E629D));
 +
background-image: -webkit-linear-gradient(top, #3A79B8, #2E629D);
 +
background-image: -moz-linear-gradient(top, #3A79B8, #2E629D);
 +
background-image: -ms-linear-gradient(top, #3A79B8, #2E629D);
 +
background-image: -o-linear-gradient(top, #3A79B8, #2E629D);
 +
filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#3A79B8,endColorstr=#2E629D);
 +
-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#3A79B8,endColorstr=#2E629D)";
 +
}
 +
 +
.qtip-tipped .qtip-icon{
 +
border: 2px solid #285589;
 +
background: #285589;
 +
}
 +
 +
.qtip-tipped .qtip-icon .ui-icon{
 +
background-color: #FBFBFB;
 +
color: #555;
 +
}
 +
 +
 +
/**
 +
* Twitter Bootstrap style.
 +
*
 +
* Tested with IE 8, IE 9, Chrome 18, Firefox 9, Opera 11.
 +
* Does not work with IE 7.
 +
*/
 +
.qtip-bootstrap{
 +
/** Taken from Bootstrap body */
 +
font-size: 14px;
 +
line-height: 20px;
 +
color: #333333;
 +
 +
/** Taken from Bootstrap .popover */
 +
padding: 1px;
 +
background-color: #ffffff;
 +
border: 1px solid #ccc;
 +
border: 1px solid rgba(0, 0, 0, 0.2);
 +
-webkit-border-radius: 6px;
 +
-moz-border-radius: 6px;
 +
border-radius: 6px;
 +
-webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
 +
-moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
 +
box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
 +
-webkit-background-clip: padding-box;
 +
-moz-background-clip: padding;
 +
background-clip: padding-box;
 
}
 
}
  
 +
.qtip-bootstrap .qtip-titlebar{
 +
/** Taken from Bootstrap .popover-title */
 +
padding: 8px 14px;
 +
margin: 0;
 +
font-size: 14px;
 +
font-weight: normal;
 +
line-height: 18px;
 +
background-color: #f7f7f7;
 +
border-bottom: 1px solid #ebebeb;
 +
-webkit-border-radius: 5px 5px 0 0;
 +
-moz-border-radius: 5px 5px 0 0;
 +
border-radius: 5px 5px 0 0;
 +
}
 +
 +
.qtip-bootstrap .qtip-titlebar .qtip-close{
 +
/**
 +
* Overrides qTip2:
 +
* .qtip-titlebar .qtip-close{
 +
*  [...]
 +
*  right: 4px;
 +
*  top: 50%;
 +
*  [...]
 +
*  border-style: solid;
 +
* }
 +
*/
 +
right: 11px;
 +
top: 45%;
 +
border-style: none;
 +
}
 +
 +
.qtip-bootstrap .qtip-content{
 +
/** Taken from Bootstrap .popover-content */
 +
padding: 9px 14px;
 +
}
 +
 +
.qtip-bootstrap .qtip-icon{
 +
/**
 +
* Overrides qTip2:
 +
* .qtip-default .qtip-icon {
 +
*  border-color: #CCC;
 +
*  background: #F1F1F1;
 +
*  color: #777;
 +
* }
 +
*/
 +
background: transparent;
 +
}
 +
 +
.qtip-bootstrap .qtip-icon .ui-icon{
 +
/**
 +
* Overrides qTip2:
 +
* .qtip-icon .ui-icon{
 +
*  width: 18px;
 +
*  height: 14px;
 +
* }
 +
*/
 +
width: auto;
 +
height: auto;
 +
 +
/* Taken from Bootstrap .close */
 +
float: right;
 +
font-size: 20px;
 +
font-weight: bold;
 +
line-height: 18px;
 +
color: #000000;
 +
text-shadow: 0 1px 0 #ffffff;
 +
opacity: 0.2;
 +
filter: alpha(opacity=20);
 +
}
 +
 +
.qtip-bootstrap .qtip-icon .ui-icon:hover{
 +
/* Taken from Bootstrap .close:hover */
 +
color: #000000;
 +
text-decoration: none;
 +
cursor: pointer;
 +
opacity: 0.4;
 +
filter: alpha(opacity=40);
 +
}
 +
 +
 +
/* IE9 fix - removes all filters */
 +
.qtip:not(.ie9haxors) div.qtip-content,
 +
.qtip:not(.ie9haxors) div.qtip-titlebar{
 +
filter: none;
 +
-ms-filter: none;
 +
}
 +
 +
 +
 +
.qtip .qtip-tip{
 +
margin: 0 auto;
 +
overflow: hidden;
 +
z-index: 10;
 +
 +
}
 +
 +
/* Opera bug #357 - Incorrect tip position
 +
https://github.com/Craga89/qTip2/issues/367 */
 +
x:-o-prefocus, .qtip .qtip-tip{
 +
visibility: hidden;
 +
}
 +
 +
.qtip .qtip-tip,
 +
.qtip .qtip-tip .qtip-vml,
 +
.qtip .qtip-tip canvas{
 +
position: absolute;
 +
 +
color: #123456;
 +
background: transparent;
 +
border: 0 dashed transparent;
 +
}
 +
 +
.qtip .qtip-tip canvas{ top: 0; left: 0; }
 +
 +
.qtip .qtip-tip .qtip-vml{
 +
behavior: url(#default#VML);
 +
display: inline-block;
 +
visibility: visible;
 +
}
 +
 +
#qtip-overlay{
 +
position: fixed;
 +
left: 0; top: 0;
 +
width: 100%; height: 100%;
 +
}
 +
 +
/* Applied to modals with show.modal.blur set to true */
 +
#qtip-overlay.blurs{ cursor: pointer; }
 +
 +
/* Change opacity of overlay here */
 +
#qtip-overlay div{
 +
position: absolute;
 +
left: 0; top: 0;
 +
width: 100%; height: 100%;
 +
 +
background-color: black;
 +
 +
opacity: 0.7;
 +
filter:alpha(opacity=70);
 +
-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=70)";
 +
}
 +
 +
 +
 +
.qtipmodal-ie6fix{
 +
position: absolute !important;
 +
}
 +
/*
 +
* Stylesheet for the markup of glossary terms in wiki pages.
 +
*/
 +
 +
.mw-lingo-tooltip {
 +
/*display: inline;*/
 +
position: relative;
 +
/*cursor: help;*/
 +
}
 +
 +
.mw-lingo-tooltip-abbr {
 +
border-bottom: 1px dotted #bbbbff;
 +
cursor:        default;
 +
}
 +
 +
.mw-lingo-tooltip-abbr:hover {
 +
background-color: rgba(0, 0, 0, 0.1);
 +
}
 +
 +
.mw-lingo-tooltip-tip {
 +
display:              none;
 +
 +
/* qtip-default */
 +
border-width:          1px;
 +
border-style:          solid;
 +
 +
/* qtip shadow */
 +
-webkit-box-shadow:    1px 1px 3px 1px rgba(0, 0, 0, 0.15);
 +
-moz-box-shadow:      1px 1px 3px 1px rgba(0, 0, 0, 0.15);
 +
box-shadow:            1px 1px 3px 1px rgba(0, 0, 0, 0.15);
 +
 +
/* qtip light */
 +
background-color:      white;
 +
border-color:          #e2e2e2;
 +
color:                #454545;
 +
 +
/* qtip rounded */
 +
-moz-border-radius:    5px;
 +
-webkit-border-radius: 5px;
 +
border-radius:        5px;
 +
}
 +
 +
.mw-lingo-tooltip-definition {
 +
display: block;
 +
padding: .5ex 0;
 +
}
 +
 +
/* Style for JS disabled browsers*/
 +
.mw-lingo-tooltip:hover .mw-lingo-tooltip-tip {
 +
display:  block;
 +
 +
position:  absolute;
 +
top:      1.5em;
 +
left:      0;
 +
 +
padding:  5px 9px;
 +
z-index:  15000;
 +
font-size: smaller;
 +
}
 +
.mw-lingo-tooltip{position:relative}.mw-lingo-tooltip-abbr{border-bottom:1px dotted #bbbbff;cursor:default}.mw-lingo-tooltip-abbr:hover{background-color:rgba(0,0,0,0.1)}.mw-lingo-tooltip-tip{display:none;border-width:1px;border-style:solid;-webkit-box-shadow:1px 1px 3px 1px rgba(0,0,0,0.15);-moz-box-shadow:1px 1px 3px 1px rgba(0,0,0,0.15);box-shadow:1px 1px 3px 1px rgba(0,0,0,0.15);background-color:white;border-color:#e2e2e2;color:#454545;-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.mw-lingo-tooltip-definition{display:block;padding:.5ex 0}.mw-lingo-tooltip:hover .mw-lingo-tooltip-tip{display:block;position:absolute;top:1.5em;left:0;padding:5px 9px;z-index:15000;font-size:smaller}.client-nojs #ca-ve-edit,.client-nojs .mw-editsection-divider,.client-nojs .mw-editsection-visualeditor,.ve-not-available #ca-ve-edit,.ve-not-available .mw-editsection-divider,.ve-not-available .mw-editsection-visualeditor{display:none}.client-js .mw-content-ltr .mw-editsection-bracket:first-of-type,.client-js .mw-content-rtl .mw-editsection-bracket:not(:first-of-type){margin-right:0.25em;color:#555}.client-js .mw-content-rtl .mw-editsection-bracket:first-of-type,.client-js .mw-content-ltr .mw-editsection-bracket:not(:first-of-type){margin-left:0.25em;color:#555}@media print{.noprint,div#jump-to-nav,.mw-jump,div.top,div#column-one,.mw-editsection,.mw-editsection-like,.toctoggle,#toc.tochidden,div#f-poweredbyico,div#f-copyrightico,li#about,li#disclaimer,li#mobileview,li#privacy,#footer-places,.mw-hidden-catlinks,.usermessage,.patrollink,.ns-0 .mw-redirectedfrom,#mw-navigation,#siteNotice{display:none}.wikitable,.thumb,img{page-break-inside:avoid}h2,h3,h4,h5,h6{page-break-after:avoid}p{widows:3;orphans:3}body{background:white;color:black;margin:0;padding:0}ul{list-style-type:square}h1,h2,h3,h4,h5,h6{font-weight:bold}dt{font-weight:bold}p{margin:1em 0;line-height:1.2em}pre,.mw-code{border:1pt dashed black;white-space:pre;font-size:8pt;overflow:auto;padding:1em 0;background:white;color:black}#globalWrapper{width:100% !important;min-width:0 !important}.mw-body{background:white;border:none !important;padding:0 !important;margin:0 !important;direction:ltr;color:black}#column-content{margin:0 !important}#column-content .mw-body{padding:1em;margin:0 !important}#toc{border:1px solid #aaaaaa;background-color:#f9f9f9;padding:5px;display:inline-block;display:table;zoom:1;*display:inline}#footer{background:white;color:black;margin-top:1em;border-top:1px solid #AAA;direction:ltr}img{border:none;vertical-align:middle}span.texhtml{font-family:serif}a.stub,a.new{color:#ba0000;text-decoration:none}a{color:black !important;background:none !important;padding:0 !important}a:link,a:visited{color:#520;background:transparent;text-decoration:underline}.mw-body a.external.text:after,.mw-body a.external.autonumber:after{content:" (" attr(href) ")"}.mw-body a.external.text[href^='//']:after,.mw-body a.external.autonumber[href^='//']:after{content:" (https:" attr(href) ")"}a,a.external,a.new,a.stub{color:black !important;text-decoration:none !important}a,a.external,a.new,a.stub{color:inherit !important;text-decoration:inherit !important}div.floatright{float:right;clear:right;position:relative;margin:0.5em 0 0.8em 1.4em}div.floatright p{font-style:italic}div.floatleft{float:left;clear:left;position:relative;margin:0.5em 1.4em 0.8em 0}div.floatleft p{font-style:italic}div.center{text-align:center}div.thumb{border:none;width:auto;margin-top:0.5em;margin-bottom:0.8em;background-color:transparent}div.thumbinner{border:1px solid #cccccc;padding:3px !important;background-color:White;font-size:94%;text-align:center;overflow:hidden}html .thumbimage{border:1px solid #cccccc}html .thumbcaption{border:none;text-align:left;line-height:1.4em;padding:3px !important;font-size:94%}div.magnify{display:none}div.tright{float:right;clear:right;margin:0.5em 0 0.8em 1.4em}div.tleft{float:left;clear:left;margin:0.5em 1.4em 0.8em 0}img.thumbborder{border:1px solid #dddddd}table.wikitable,table.mw_metadata{margin:1em 0;border:1px #aaa solid;background:white;border-collapse:collapse}table.wikitable > tr > th,table.wikitable > tr > td,table.wikitable > * > tr > th,table.wikitable > * > tr > td,.mw_metadata th,.mw_metadata td{border:1px #aaa solid;padding:0.2em}table.wikitable > tr > th,table.wikitable > * > tr > th,.mw_metadata th{text-align:center;background:white;font-weight:bold}table.wikitable > caption,.mw_metadata caption{font-weight:bold}table.listing,table.listing td{border:1pt solid black;border-collapse:collapse}a.sortheader{margin:0 0.3em}.catlinks ul{display:inline;margin:0;padding:0;list-style:none;list-style-type:none;list-style-image:none;vertical-align:middle !ie}.catlinks li{display:inline-block;line-height:1.15em;padding:0 .4em;border-left:1px solid #AAA;margin:0.1em 0;zoom:1;display:inline !ie}.catlinks li:first-child{padding-left:.2em;border-left:none}.printfooter{padding:1em 0 1em 0}}@media screen{.mw-content-ltr{direction:ltr}.mw-content-rtl{direction:rtl}.sitedir-ltr textarea,.sitedir-ltr input{direction:ltr}.sitedir-rtl textarea,.sitedir-rtl input{direction:rtl}.mw-userlink{unicode-bidi:embed}mark{background-color:yellow;color:black}wbr{display:inline-block}input[type="submit"],input[type="button"],input[type="reset"],input[type="file"]{direction:ltr}textarea[dir="ltr"],input[dir="ltr"]{direction:ltr}textarea[dir="rtl"],input[dir="rtl"]{direction:rtl}abbr[title],.explain[title]{border-bottom:1px dotted;cursor:help}@supports (text-decoration:underline dotted){abbr[title],.explain[title]{border-bottom:none;text-decoration:underline dotted}}.mw-plusminus-pos{color:#006400}.mw-plusminus-neg{color:#8b0000}.mw-plusminus-null{color:#aaa}.mw-plusminus-pos,.mw-plusminus-neg,.mw-plusminus-null{unicode-bidi:-moz-isolate;unicode-bidi:-webkit-isolate;unicode-bidi:isolate}.allpagesredirect,.redirect-in-category,.watchlistredir{font-style:italic}span.comment{font-style:italic}.texvc{direction:ltr;unicode-bidi:embed}img.tex{vertical-align:middle}span.texhtml{font-family:serif}#wikiPreview.ontop{margin-bottom:1em}#editform,#toolbar,#wpTextbox1{clear:both}li span.deleted,span.history-deleted{text-decoration:line-through;color:#888;font-style:italic}.not-patrolled{background-color:#ffa}.unpatrolled{font-weight:bold;color:red}div.patrollink{font-size:75%;text-align:right}td.mw-label{text-align:right}td.mw-input{text-align:left}td.mw-submit{text-align:left}td.mw-label{vertical-align:middle}td.mw-submit{white-space:nowrap}input#wpSummary{width:80%;margin-bottom:1em}.mw-content-ltr .thumbcaption{text-align:left}.mw-content-ltr .magnify{float:right}.mw-content-rtl .thumbcaption{text-align:right}.mw-content-rtl .magnify{float:left}#catlinks{text-align:left}.catlinks ul{display:inline;margin:0;padding:0;list-style:none;list-style-type:none;list-style-image:none;vertical-align:middle !ie}.catlinks li{display:inline-block;line-height:1.25em;border-left:1px solid #AAA;margin:0.125em 0;padding:0 0.5em;zoom:1;display:inline !ie}.catlinks li:first-child{padding-left:0.25em;border-left:none}.catlinks li a.mw-redirect{font-style:italic}.mw-hidden-cats-hidden{display:none}.catlinks-allhidden{display:none}p.mw-ipb-conveniencelinks,p.mw-protect-editreasons,p.mw-filedelete-editreasons,p.mw-delete-editreasons,p.mw-revdel-editreasons,p.mw-upload-editlicenses{font-size:90%;text-align:right}.autocomment{color:gray}#pagehistory .history-user{margin-left:0.4em;margin-right:0.2em}#pagehistory span.minor{font-weight:bold}#pagehistory li{border:1px solid white}#pagehistory li.selected{background-color:#f9f9f9;border:1px dashed #aaa}.mw-history-revisionactions,#mw-fileduplicatesearch-icon{float:right}.newpage,.minoredit,.botedit{font-weight:bold}div.mw-warning-with-logexcerpt{padding:3px;margin-bottom:3px;border:2px solid #2F6FAB;clear:both}div.mw-warning-with-logexcerpt ul li{font-size:90%}span.mw-revdelundel-link,strong.mw-revdelundel-link{font-size:90%}span.mw-revdelundel-hidden,input.mw-revdelundel-hidden{visibility:hidden}td.mw-revdel-checkbox,th.mw-revdel-checkbox{padding-right:10px;text-align:center}a.new{color:#BA0000}.plainlinks a.external{background:none !important;padding:0 !important}.rtl a.external.free,.rtl a.external.autonumber{direction:ltr;unicode-bidi:embed}table.wikitable{margin:1em 0;background-color:#f9f9f9;border:1px solid #aaa;border-collapse:collapse;color:black}table.wikitable > tr > th,table.wikitable > tr > td,table.wikitable > * > tr > th,table.wikitable > * > tr > td{border:1px solid #aaa;padding:0.2em 0.4em}table.wikitable > tr > th,table.wikitable > * > tr > th{background-color:#f2f2f2;text-align:center}table.wikitable > caption{font-weight:bold}.error,.warning,.success{font-size:larger}.error{color:#cc0000}.warning{color:#705000}.success{color:#009000}.errorbox,.warningbox,.successbox{border:1px solid;padding:.5em 1em;margin-bottom:1em;display:inline-block;zoom:1;*display:inline}.errorbox h2,.warningbox h2,.successbox h2{font-size:1em;color:inherit;font-weight:bold;display:inline;margin:0 .5em 0 0;border:none}.errorbox{color:#cc0000;border-color:#fac5c5;background-color:#fae3e3}.warningbox{color:#705000;border-color:#fde29b;background-color:#fdf1d1}.successbox{color:#008000;border-color:#b7fdb5;background-color:#e1fddf}.mw-infobox{border:2px solid #ff7f00;margin:0.5em;clear:left;overflow:hidden}.mw-infobox-left{margin:7px;float:left;width:35px}.mw-infobox-right{margin:0.5em 0.5em 0.5em 49px}.previewnote{color:#c00;margin-bottom:1em}.previewnote p{text-indent:3em;margin:0.8em 0}.visualClear{clear:both}.mw-datatable{border-collapse:collapse}.mw-datatable,.mw-datatable td,.mw-datatable th{border:1px solid #aaaaaa;padding:0 0.15em 0 0.15em}.mw-datatable th{background-color:#ddddff}.mw-datatable td{background-color:#ffffff}.mw-datatable tr:hover td{background-color:#eeeeff}table.mw_metadata{font-size:0.8em;margin-left:0.5em;margin-bottom:0.5em;width:400px}table.mw_metadata caption{font-weight:bold}table.mw_metadata th{font-weight:normal}table.mw_metadata td{padding:0.1em}table.mw_metadata{border:none;border-collapse:collapse}table.mw_metadata td,table.mw_metadata th{text-align:center;border:1px solid #aaaaaa;padding-left:5px;padding-right:5px}table.mw_metadata th{background-color:#f9f9f9}table.mw_metadata td{background-color:#fcfcfc}table.mw_metadata ul.metadata-langlist{list-style-type:none;list-style-image:none;padding-right:5px;padding-left:5px;margin:0}.mw-content-ltr ul,.mw-content-rtl .mw-content-ltr ul{margin:0.3em 0 0 1.6em;padding:0}.mw-content-rtl ul,.mw-content-ltr .mw-content-rtl ul{margin:0.3em 1.6em 0 0;padding:0}.mw-content-ltr ol,.mw-content-rtl .mw-content-ltr ol{margin:0.3em 0 0 3.2em;padding:0}.mw-content-rtl ol,.mw-content-ltr .mw-content-rtl ol{margin:0.3em 3.2em 0 0;padding:0}.mw-content-ltr dd,.mw-content-rtl .mw-content-ltr dd{margin-left:1.6em;margin-right:0}.mw-content-rtl dd,.mw-content-ltr .mw-content-rtl dd{margin-right:1.6em;margin-left:0}.mw-ajax-loader{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/ajax-loader.gif?57f34);background-position:center center;background-repeat:no-repeat;padding:16px;position:relative;top:-16px}.mw-small-spinner{padding:10px !important;margin-right:0.6em;background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/spinner.gif?ca65b);background-position:center center;background-repeat:no-repeat}h1:lang(anp),h1:lang(as),h1:lang(bh),h1:lang(bho),h1:lang(bn),h1:lang(gu),h1:lang(hi),h1:lang(kn),h1:lang(ks),h1:lang(ml),h1:lang(mr),h1:lang(my),h1:lang(mai),h1:lang(ne),h1:lang(new),h1:lang(or),h1:lang(pa),h1:lang(pi),h1:lang(sa),h1:lang(ta),h1:lang(te){line-height:1.6em !important}h2:lang(anp),h3:lang(anp),h4:lang(anp),h5:lang(anp),h6:lang(anp),h2:lang(as),h3:lang(as),h4:lang(as),h5:lang(as),h6:lang(as),h2:lang(bho),h3:lang(bho),h4:lang(bho),h5:lang(bho),h6:lang(bho),h2:lang(bh),h3:lang(bh),h4:lang(bh),h5:lang(bh),h6:lang(bh),h2:lang(bn),h3:lang(bn),h4:lang(bn),h5:lang(bn),h6:lang(bn),h2:lang(gu),h3:lang(gu),h4:lang(gu),h5:lang(gu),h6:lang(gu),h2:lang(hi),h3:lang(hi),h4:lang(hi),h5:lang(hi),h6:lang(hi),h2:lang(kn),h3:lang(kn),h4:lang(kn),h5:lang(kn),h6:lang(kn),h2:lang(ks),h3:lang(ks),h4:lang(ks),h5:lang(ks),h6:lang(ks),h2:lang(ml),h3:lang(ml),h4:lang(ml),h5:lang(ml),h6:lang(ml),h2:lang(mr),h3:lang(mr),h4:lang(mr),h5:lang(mr),h6:lang(mr),h2:lang(my),h3:lang(my),h4:lang(my),h5:lang(my),h6:lang(my),h2:lang(mai),h3:lang(mai),h4:lang(mai),h5:lang(mai),h6:lang(mai),h2:lang(ne),h3:lang(ne),h4:lang(ne),h5:lang(ne),h6:lang(ne),h2:lang(new),h3:lang(new),h4:lang(new),h5:lang(new),h6:lang(new),h2:lang(or),h3:lang(or),h4:lang(or),h5:lang(or),h6:lang(or),h2:lang(pa),h3:lang(pa),h4:lang(pa),h5:lang(pa),h6:lang(pa),h2:lang(pi),h3:lang(pi),h4:lang(pi),h5:lang(pi),h6:lang(pi),h2:lang(sa),h3:lang(sa),h4:lang(sa),h5:lang(sa),h6:lang(sa),h2:lang(ta),h3:lang(ta),h4:lang(ta),h5:lang(ta),h6:lang(ta),h2:lang(te),h3:lang(te),h4:lang(te),h5:lang(te),h6:lang(te){line-height:1.2em}ol:lang(azb) li,ol:lang(bcc) li,ol:lang(bgn) li,ol:lang(bqi) li,ol:lang(fa) li,ol:lang(glk) li,ol:lang(kk-arab) li,ol:lang(lrc) li,ol:lang(luz) li,ol:lang(mzn) li{list-style-type:-moz-persian;list-style-type:persian}ol:lang(ckb) li,ol:lang(sdh) li{list-style-type:-moz-arabic-indic;list-style-type:arabic-indic}ol:lang(hi) li,ol:lang(mr) li{list-style-type:-moz-devanagari;list-style-type:devanagari}ol:lang(as) li,ol:lang(bn) li{list-style-type:-moz-bengali;list-style-type:bengali}ol:lang(or) li{list-style-type:-moz-oriya;list-style-type:oriya}#toc ul,.toc ul{margin:.3em 0}.mw-content-ltr .toc ul,.mw-content-ltr #toc ul,.mw-content-rtl .mw-content-ltr .toc ul,.mw-content-rtl .mw-content-ltr #toc ul{text-align:left}.mw-content-rtl .toc ul,.mw-content-rtl #toc ul,.mw-content-ltr .mw-content-rtl .toc ul,.mw-content-ltr .mw-content-rtl #toc ul{text-align:right}.mw-content-ltr .toc ul ul,.mw-content-ltr #toc ul ul,.mw-content-rtl .mw-content-ltr .toc ul ul,.mw-content-rtl .mw-content-ltr #toc ul ul{margin:0 0 0 2em}.mw-content-rtl .toc ul ul,.mw-content-rtl #toc ul ul,.mw-content-ltr .mw-content-rtl .toc ul ul,.mw-content-ltr .mw-content-rtl #toc ul ul{margin:0 2em 0 0}#toc #toctitle,.toc #toctitle,#toc .toctitle,.toc .toctitle{direction:ltr}.mw-help-field-hint{display:none;margin-left:2px;margin-bottom:-8px;padding:0 0 0 15px;background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/help-question.gif?346d8);background-position:left center;background-repeat:no-repeat;cursor:pointer;font-size:.8em;text-decoration:underline;color:#0645ad}.mw-help-field-hint:hover{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/help-question-hover.gif?53eb5)}.mw-help-field-data{display:block;background-color:#d6f3ff;padding:5px 8px 4px 8px;border:1px solid #5dc9f4;margin-left:20px}#mw-clearyourcache,#mw-sitecsspreview,#mw-sitejspreview,#mw-usercsspreview,#mw-userjspreview{direction:ltr;unicode-bidi:embed}.diff-currentversion-title,.diff{direction:ltr;unicode-bidi:embed}.diff-contentalign-right td{direction:rtl;unicode-bidi:embed}.diff-contentalign-left td{direction:ltr;unicode-bidi:embed}.diff-multi,.diff-otitle,.diff-ntitle,.diff-lineno{direction:ltr !important;unicode-bidi:embed}#mw-revision-info,#mw-revision-info-current,#mw-revision-nav{direction:ltr;display:inline}div.tright,div.floatright,table.floatright{clear:right;float:right}div.tleft,div.floatleft,table.floatleft{float:left;clear:left}div.floatright,table.floatright,div.floatleft,table.floatleft{position:relative}#mw-credits a{unicode-bidi:embed}.mw-jump,#jump-to-nav{overflow:hidden;height:0;zoom:1}.printfooter{display:none}.xdebug-error{position:absolute;z-index:99}.mw-editsection,.toctoggle,.tochidden,#jump-to-nav{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.mw-editsection,.mw-editsection-like{font-size:small;font-weight:normal;margin-left:1em;vertical-align:baseline;line-height:1em;display:inline-block}.mw-content-ltr .mw-editsection,.mw-content-rtl .mw-content-ltr .mw-editsection{margin-left:1em}.mw-content-rtl .mw-editsection,.mw-content-ltr .mw-content-rtl .mw-editsection{margin-right:1em}sup,sub{line-height:1}}.mw-headline-anchor{display:none}@media screen{.mw-headline-anchor{margin-left:-16px;width:16px}.mw-content-ltr .mw-headline-anchor,.mw-content-rtl .mw-content-ltr .mw-headline-anchor{margin-left:-16px;margin-right:0}.mw-content-rtl .mw-headline-anchor,.mw-content-ltr .mw-content-rtl .mw-headline-anchor{margin-left:0;margin-right:-16px}}@media screen and (min-width:982px){.mw-headline-anchor{margin-left:-20px;width:20px}.mw-content-ltr .mw-headline-anchor,.mw-content-rtl .mw-content-ltr .mw-headline-anchor{margin-left:-20px;margin-right:0}.mw-content-rtl .mw-headline-anchor,.mw-content-ltr .mw-content-rtl .mw-headline-anchor{margin-left:0;margin-right:-20px}}@media screen{a{text-decoration:none;color:#0645ad;background:none}a:visited{color:#0b0080}a:active{color:#faa700}a:hover,a:focus{text-decoration:underline}a.stub{color:#772233}a.new,#p-personal a.new{color:#ba0000}a.new:visited,#p-personal a.new:visited{color:#a55858}.mw-body a.extiw,.mw-body a.extiw:active{color:#36b}.mw-body a.extiw:visited{color:#636}.mw-body a.extiw:active{color:#b63}.mw-body a.external{color:#36b}.mw-body a.external:visited{color:#636}.mw-body a.external:active{color:#b63}.mw-body a.external.free{word-wrap:break-word}img{border:none;vertical-align:middle}hr{height:1px;color:#aaa;background-color:#aaa;border:0;margin:.2em 0}h1,h2,h3,h4,h5,h6{color:black;background:none;font-weight:normal;margin:0;overflow:hidden;padding-top:.5em;padding-bottom:.17em;border-bottom:1px solid #aaa}h1{font-size:188%}h2{font-size:150%}h3,h4,h5,h6{border-bottom:none;font-weight:bold}h3{font-size:128%}h4{font-size:116%}h5{font-size:108%}h6{font-size:100%}h1,h2{margin-bottom:.6em}h3,h4,h5{margin-bottom:.3em}p{margin:.4em 0 .5em 0}p img{margin:0}ul{list-style-type:square;margin:.3em 0 0 1.6em;padding:0}ol{margin:.3em 0 0 3.2em;padding:0;list-style-image:none}li{margin-bottom:.1em}dt{font-weight:bold;margin-bottom:.1em}dl{margin-top:.2em;margin-bottom:.5em}dd{margin-left:1.6em;margin-bottom:.1em}pre,code,tt,kbd,samp,.mw-code{font-family:monospace,Courier}code{color:black;background-color:#f9f9f9;border:1px solid #ddd;border-radius:2px;padding:1px 4px}pre,.mw-code{color:black;background-color:#f9f9f9;border:1px solid #ddd;padding:1em;white-space:pre-wrap}table{font-size:100%}fieldset{border:1px solid #2f6fab;margin:1em 0 1em 0;padding:0 1em 1em}fieldset.nested{margin:0 0 0.5em 0;padding:0 0.5em 0.5em}legend{padding:.5em;font-size:95%}form{border:none;margin:0}textarea{width:100%;padding:.1em;display:block;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.center{width:100%;text-align:center}*.center *{margin-left:auto;margin-right:auto}.small{font-size:94%}table.small{font-size:100%}#toc,.toc,.mw-warning,.toccolours{border:1px solid #aaa;background-color:#f9f9f9;padding:5px;font-size:95%}#toc,.toc{display:inline-block;display:table;zoom:1;*display:inline;padding:7px}table#toc,table.toc{border-collapse:collapse}table#toc td,table.toc td{padding:0}#toc h2,.toc h2{display:inline;border:none;padding:0;font-size:100%;font-weight:bold}#toc #toctitle,.toc #toctitle,#toc .toctitle,.toc .toctitle{text-align:center}#toc ul,.toc ul{list-style-type:none;list-style-image:none;margin-left:0;padding:0;text-align:left}#toc ul ul,.toc ul ul{margin:0 0 0 2em}#toc .toctoggle,.toc .toctoggle{font-size:94%}.mw-warning{margin-left:50px;margin-right:50px;text-align:center}div.floatright,table.floatright{margin:0 0 .5em .5em;border:0}div.floatright p{font-style:italic}div.floatleft,table.floatleft{margin:0 .5em .5em 0;border:0}div.floatleft p{font-style:italic}div.thumb{margin-bottom:.5em;width:auto;background-color:transparent}div.thumbinner{border:1px solid #ccc;padding:3px;background-color:#f9f9f9;font-size:94%;text-align:center;overflow:hidden}html .thumbimage{border:1px solid #ccc}html .thumbcaption{border:none;line-height:1.4em;padding:3px;font-size:94%;text-align:left}div.magnify{float:right;margin-left:3px}div.magnify a{display:block;text-indent:15px;white-space:nowrap;overflow:hidden;width:15px;height:11px;background-image:url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.png?b5711);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}img.thumbborder{border:1px solid #dddddd}.mw-content-ltr .thumbcaption{text-align:left}.mw-content-ltr .magnify{float:right;margin-left:3px;margin-right:0}.mw-content-ltr div.magnify a{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.png?b5711);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie}.mw-content-rtl .thumbcaption{text-align:right}.mw-content-rtl .magnify{float:left;margin-left:0;margin-right:3px}.mw-content-rtl div.magnify a{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-rtl.png?27d60);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M9.491%201.865h-10.99v7.919h10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M12.499%206.868h-5.943v4.904h5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-rtl.svg?96de0)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M9.491%201.865h-10.99v7.919h10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M12.499%206.868h-5.943v4.904h5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-rtl.svg?96de0)!ie}div.tright{margin:.5em 0 1.3em 1.4em}div.tleft{margin:.5em 1.4em 1.3em 0}.catlinks{border:1px solid #aaa;background-color:#f9f9f9;padding:5px;margin-top:1em;clear:both}.editOptions{background-color:#F0F0F0;border:1px solid silver;border-top:none;padding:1em 1em 1.5em 1em;margin-bottom:2em}.usermessage{background-color:#ffce7b;border:1px solid #ffa500;color:black;font-weight:bold;margin:2em 0 1em;padding:.5em 1em;vertical-align:middle}#siteNotice{position:relative;text-align:center;margin:0}#localNotice{margin-bottom:0.9em}.firstHeading{margin-bottom:.1em;line-height:1.2em;padding-bottom:0}#siteSub{display:none}#jump-to-nav{margin-top:-1.4em;margin-bottom:1.4em}#contentSub,#contentSub2{font-size:84%;line-height:1.2em;margin:0 0 1.4em 1em;color:#545454;width:auto}span.subpages{display:block}}.mw-wiki-logo{background-image:url(http://www.cnbguatemala.org/images/7/70/logo_cnb.png)}@media screen{html{font-size:100%}html,body{height:100%;margin:0;padding:0;font-family:sans-serif}body{background-color:#FFF}.mw-body{margin-left:10em;padding:1em;border:1px solid #a7d7f9;border-right-width:0;margin-top:-1px;background-color:#ffffff;color:#252525;direction:ltr}.mw-body .mw-editsection,.mw-body .mw-editsection-like{font-family:sans-serif}.mw-body p{line-height:inherit;margin:0.5em 0}.mw-body h1,.mw-body h2{font-family:"Linux Libertine",Georgia,Times,serif;line-height:1.3;margin-bottom:0.25em;padding:0}.mw-body h1{font-size:1.8em}.mw-body .mw-body-content h1{margin-top:1em}.mw-body h2{font-size:1.5em;margin-top:1em}.mw-body h3,.mw-body h4,.mw-body h5,.mw-body h6{line-height:1.6;margin-top:0.3em;margin-bottom:0;padding-bottom:0}.mw-body h3{font-size:1.2em}.mw-body h3,.mw-body h4{font-weight:bold}.mw-body h4,.mw-body h5,.mw-body h6{font-size:100%}.mw-body #toc h2,.mw-body .toc h2{font-size:100%;font-family:sans-serif}.mw-body .firstHeading{overflow:visible}.mw-body .mw-indicators{float:right;line-height:1.6;font-size:0.875em;position:relative;z-index:1}.mw-body .mw-indicator{display:inline-block;zoom:1;*display:inline}div.emptyPortlet{display:none}ul{list-style-type:disc;list-style-image:url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20version%3D%221.1%22%20width%3D%225%22%20height%3D%2213%22%3E%0A%3Ccircle%20cx%3D%222.5%22%20cy%3D%229.5%22%20r%3D%222.5%22%20fill%3D%22%2300528c%22%2F%3E%0A%3C%2Fsvg%3E%0A);list-style-image:url(http://cnbguatemala.org/skins/Vector/images/bullet-icon.svg?90d59)!ie;list-style-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAANAQMAAABb8jbLAAAABlBMVEX///8AUow5QSOjAAAAAXRSTlMAQObYZgAAABNJREFUCB1jYEABBQw/wLCAgQEAGpIDyT0IVcsAAAAASUVORK5CYII=) \9;list-style-image:url(http://cnbguatemala.org/skins/Vector/images/bullet-icon.png?785dd) \9!ie}pre,.mw-code{line-height:1.3em}#siteNotice{font-size:0.8em}.redirectText{font-size:140%}.mw-body-content{position:relative;line-height:1.6;font-size:0.875em;z-index:0}#p-personal{position:absolute;top:0.33em;right:0.75em;z-index:100}#p-personal h3{display:none}#p-personal ul{list-style-type:none;list-style-image:none;margin:0;padding-left:10em}#p-personal li{line-height:1.125em;float:left;margin-left:0.75em;margin-top:0.5em;font-size:0.75em;white-space:nowrap}#pt-userpage,#pt-anonuserpage{background-position:left top;background-repeat:no-repeat;background-image:url(http://cnbguatemala.org/skins/Vector/images/user-icon.png?9e7ea);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3C%21DOCTYPE%20svg%20PUBLIC%20%22-%2F%2FW3C%2F%2FDTD%20SVG%201.1%2F%2FEN%22%20%22http%3A%2F%2Fwww.w3.org%2FGraphics%2FSVG%2F1.1%2FDTD%2Fsvg11.dtd%22%3E%0A%3Csvg%20version%3D%221.1%22%20id%3D%22Layer_1%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20x%3D%220px%22%20y%3D%220px%22%0A%09%20width%3D%2212px%22%20height%3D%2213.836px%22%20viewBox%3D%220%200%2012%2013.836%22%20enable-background%3D%22new%200%200%2012%2013.836%22%20xml%3Aspace%3D%22preserve%22%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M1.938%2C6.656c-1.32%2C1.485-1.47%2C3.15-0.97%2C4.25c0.323%2C0.707%2C0.78%2C1.127%2C1.313%2C1.375%0A%09c0.496%2C0.229%2C1.074%2C0.273%2C1.658%2C0.282c0.023%2C0%2C0.04%2C0.03%2C0.062%2C0.03h4.187c0.61%2C0%2C1.225-0.125%2C1.75-0.405%0A%09c0.527-0.28%2C0.961-0.718%2C1.188-1.376c0.335-0.964%2C0.175-2.529-1.094-4.03C9.094%2C7.954%2C7.68%2C8.719%2C6.065%2C8.719%0A%09c-1.677%2C0-3.182-0.812-4.125-2.063H1.938z%22%2F%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M6.063%2C0c-1.89%2C0-3.595%2C1.674-3.594%2C3.563C2.467%2C5.45%2C4.173%2C7.155%2C6.06%2C7.155%0A%09c1.89%2C0%2C3.564-1.705%2C3.563-3.593C9.625%2C1.673%2C7.95%2C0%2C6.063%2C0L6.063%2C0z%22%2F%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/user-icon.svg?7b5d5)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3C%21DOCTYPE%20svg%20PUBLIC%20%22-%2F%2FW3C%2F%2FDTD%20SVG%201.1%2F%2FEN%22%20%22http%3A%2F%2Fwww.w3.org%2FGraphics%2FSVG%2F1.1%2FDTD%2Fsvg11.dtd%22%3E%0A%3Csvg%20version%3D%221.1%22%20id%3D%22Layer_1%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20x%3D%220px%22%20y%3D%220px%22%0A%09%20width%3D%2212px%22%20height%3D%2213.836px%22%20viewBox%3D%220%200%2012%2013.836%22%20enable-background%3D%22new%200%200%2012%2013.836%22%20xml%3Aspace%3D%22preserve%22%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M1.938%2C6.656c-1.32%2C1.485-1.47%2C3.15-0.97%2C4.25c0.323%2C0.707%2C0.78%2C1.127%2C1.313%2C1.375%0A%09c0.496%2C0.229%2C1.074%2C0.273%2C1.658%2C0.282c0.023%2C0%2C0.04%2C0.03%2C0.062%2C0.03h4.187c0.61%2C0%2C1.225-0.125%2C1.75-0.405%0A%09c0.527-0.28%2C0.961-0.718%2C1.188-1.376c0.335-0.964%2C0.175-2.529-1.094-4.03C9.094%2C7.954%2C7.68%2C8.719%2C6.065%2C8.719%0A%09c-1.677%2C0-3.182-0.812-4.125-2.063H1.938z%22%2F%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M6.063%2C0c-1.89%2C0-3.595%2C1.674-3.594%2C3.563C2.467%2C5.45%2C4.173%2C7.155%2C6.06%2C7.155%0A%09c1.89%2C0%2C3.564-1.705%2C3.563-3.593C9.625%2C1.673%2C7.95%2C0%2C6.063%2C0L6.063%2C0z%22%2F%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/user-icon.svg?7b5d5)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/user-icon.png?9e7ea);padding-left:15px !important}#p-search{float:left;margin-right:0.5em;margin-left:0.5em}#p-search h3{display:none}#p-search form,#p-search input{margin:0;margin-top:0.4em}div#simpleSearch{display:block;width:12.6em;padding-right:1.4em;height:1.4em;margin-top:0.65em;position:relative;min-height:1px;border:solid 1px #aaa;color:black;background-color:white;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAQCAIAAABY/YLgAAAAJUlEQVQIHQXBsQEAAAjDoND/73UWdnerhmHVsDQZJrNWVg3Dqge6bgMe6bejNAAAAABJRU5ErkJggg==);background-image:url(http://cnbguatemala.org/skins/Vector/images/search-fade.png?50f7b)!ie;background-position:top left;background-repeat:repeat-x}div#simpleSearch input{margin:0;padding:0;border:0;background-color:transparent;color:black}div#simpleSearch #searchInput{width:100%;padding:0.2em 0 0.2em 0.2em;font-size:13px;direction:ltr;-webkit-appearance:textfield}div#simpleSearch #searchInput:focus{outline:none}div#simpleSearch #searchInput.placeholder{color:#999}div#simpleSearch #searchInput:-ms-input-placeholder{color:#999}div#simpleSearch #searchInput:-moz-placeholder{color:#999}div#simpleSearch #searchInput::-webkit-search-decoration,div#simpleSearch #searchInput::-webkit-search-cancel-button,div#simpleSearch #searchInput::-webkit-search-results-button,div#simpleSearch #searchInput::-webkit-search-results-decoration{-webkit-appearance:textfield}div#simpleSearch #searchButton,div#simpleSearch #mw-searchButton{position:absolute;top:0;right:0;width:1.65em;height:100%;cursor:pointer;text-indent:-99999px;line-height:1;direction:ltr;white-space:nowrap;overflow:hidden;background-image:url(http://cnbguatemala.org/skins/Vector/images/search-ltr.png?511c1);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2212%22%20height%3D%2213%22%3E%3Cg%20stroke-width%3D%222%22%20stroke%3D%22%236c6c6c%22%20fill%3D%22none%22%3E%3Cpath%20d%3D%22M11.29%2011.71l-4-4%22%2F%3E%3Ccircle%20cx%3D%225%22%20cy%3D%225%22%20r%3D%224%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/search-ltr.svg?07752)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2212%22%20height%3D%2213%22%3E%3Cg%20stroke-width%3D%222%22%20stroke%3D%22%236c6c6c%22%20fill%3D%22none%22%3E%3Cpath%20d%3D%22M11.29%2011.71l-4-4%22%2F%3E%3Ccircle%20cx%3D%225%22%20cy%3D%225%22%20r%3D%224%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/search-ltr.svg?07752)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/search-ltr.png?511c1);background-position:center center;background-repeat:no-repeat}div#simpleSearch #mw-searchButton{z-index:1}div.vectorTabs h3{display:none}div.vectorTabs{float:left;height:2.5em;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-position:bottom left;background-repeat:no-repeat;padding-left:1px}div.vectorTabs ul{float:left;height:100%;list-style-type:none;list-style-image:none;margin:0;padding:0;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-position:right bottom;background-repeat:no-repeat}div.vectorTabs ul li{float:left;line-height:1.125em;display:inline-block;height:100%;margin:0;padding:0;background-color:#f3f3f3;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAABkCAIAAADITs03AAAAPElEQVR4XuWK2xEAIAzCsPvv5DSu0ahX3yv4wQVyGGCSvg2dnJvduT8sz/IwKOIfjCi2z/76FhHeJcslVZQFLUC06LZ/AAAAAElFTkSuQmCC);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-normal-fade.png?ae13b)!ie;background-position:bottom left;background-repeat:repeat-x;white-space:nowrap}div.vectorTabs ul > li{display:block}div.vectorTabs li{}div.vectorTabs li.new a,div.vectorTabs li.new a:visited{color:#a55858}div.vectorTabs li.selected{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAABkAQAAAABvV2fNAAAADUlEQVQIHWNoYBgWEACJ5TIB0K9KcAAAAABJRU5ErkJggg==);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-current-fade.png?98160)!ie}div.vectorTabs li.selected a,div.vectorTabs li.selected a:visited{color:#333;text-decoration:none}div.vectorTabs li.icon a{background-position:bottom right;background-repeat:no-repeat}div.vectorTabs li a{display:inline-block;height:1.9em;padding-left:0.5em;padding-right:0.5em;color:#0645ad;cursor:pointer;font-size:0.8em}div.vectorTabs li > a{display:block}div.vectorTabs span{display:inline-block;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-position:bottom right;background-repeat:no-repeat}div.vectorTabs span a{display:inline-block;padding-top:1.25em}div.vectorTabs span > a{float:left;display:block}div.vectorMenu{direction:ltr;float:left;cursor:pointer;position:relative}body.rtl div.vectorMenu{direction:rtl}div#mw-head div.vectorMenu h3{float:left;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-repeat:no-repeat;background-position:bottom right;font-size:1em;height:2.5em;padding-right:1px;margin-right:-1px}div.vectorMenu h3 span{display:block;font-size:0.8em;padding-left:0.7em;padding-top:1.375em;margin-right:20px;font-weight:normal;color:#4d4d4d}div.vectorMenu h3 a{position:absolute;top:0;right:0;width:20px;height:2.5em;background-image:url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.png?feb5c);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23797979%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.svg?92f5b)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23797979%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.svg?92f5b)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.png?feb5c);background-position:100% 70%;background-repeat:no-repeat;-webkit-transition:background-position 250ms;-moz-transition:background-position 250ms;-o-transition:background-position 250ms;transition:background-position 250ms}div.vectorMenu.menuForceShow h3 a{background-position:100% 100%}div.vectorMenuFocus h3 a{background-image:url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.png?5c03c);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23929292%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.svg?6cc06)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23929292%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.svg?6cc06)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.png?5c03c)}div.vectorMenu div.menu{min-width:100%;position:absolute;top:2.5em;left:-1px;background-color:white;border:solid 1px silver;border-top-width:0;clear:both;text-align:left;display:none;z-index:1}div.vectorMenu:hover div.menu,div.vectorMenu.menuForceShow div.menu{display:block}div.vectorMenu ul{list-style-type:none;list-style-image:none;padding:0;margin:0;text-align:left}div.vectorMenu ul,x:-moz-any-link{min-width:5em}div.vectorMenu ul,x:-moz-any-link,x:default{min-width:0}div.vectorMenu li{padding:0;margin:0;text-align:left;line-height:1em}div.vectorMenu li a{display:inline-block;padding:0.5em;white-space:nowrap;color:#0645ad;cursor:pointer;font-size:0.8em}div.vectorMenu li > a{display:block}div.vectorMenu li.selected a,div.vectorMenu li.selected a:visited{color:#333;text-decoration:none}@-webkit-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-moz-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-o-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}#ca-unwatch.icon a,#ca-watch.icon a{margin:0;padding:0;display:block;width:26px;padding-top:3.1em;margin-top:0;_margin-top:-0.8em;height:0;overflow:hidden;background-position:5px 60%}#ca-unwatch.icon a{background-image:url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.png?c2550);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.svg?95d18)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.svg?95d18)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.png?c2550)}#ca-watch.icon a{background-image:url(http://cnbguatemala.org/skins/Vector/images/watch-icon.png?0c329);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon.svg?200b7)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon.svg?200b7)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon.png?0c329)}#ca-unwatch.icon a:hover,#ca-unwatch.icon a:focus{background-image:url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.png?f1f1e);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.svg?a3932)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.svg?a3932)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.png?f1f1e)}#ca-watch.icon a:hover,#ca-watch.icon a:focus{background-image:url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.png?df008);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.svg?2b77d)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.svg?2b77d)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.png?df008)}#ca-unwatch.icon a.loading,#ca-watch.icon a.loading{background-image:url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.png?cf2c3);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23d1d1d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.svg?6ca63)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23d1d1d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.svg?6ca63)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.png?cf2c3);-webkit-animation:rotate 700ms infinite linear;-moz-animation:rotate 700ms infinite linear;-o-animation:rotate 700ms infinite linear;animation:rotate 700ms infinite linear;outline:none;cursor:default;pointer-events:none;background-position:50% 60%;-webkit-transform-origin:50% 57%;transform-origin:50% 57%}#ca-unwatch.icon a span,#ca-watch.icon a span{display:none}#mw-navigation h2{position:absolute;top:-9999px}#mw-page-base{height:5em;background-position:bottom left;background-repeat:repeat-x;background-image:url(http://cnbguatemala.org/skins/Vector/images/page-fade.png?7c7b7);background-color:#FFF;background-image:-moz-linear-gradient(top,#ffffff 50%,#FFF 100%);background-image:-webkit-gradient(linear,left top,left bottom,color-stop(50%,#ffffff),color-stop(100%,#FFF));background-image:-webkit-linear-gradient(top,#ffffff 50%,#FFF 100%);background-image:linear-gradient(#ffffff 50%,#FFF 100%);background-color:#ffffff}#mw-head-base{margin-top:-5em;margin-left:10em;height:5em}div#mw-head{position:absolute;top:0;right:0;width:100%}div#mw-head h3{margin:0;padding:0}#left-navigation{float:left;margin-left:10em;margin-top:2.5em;margin-bottom:-2.5em;display:inline}#right-navigation{float:right;margin-top:2.5em}#p-logo{position:absolute;top:-160px;left:0;width:10em;height:160px}#p-logo a{display:block;width:10em;height:160px;background-repeat:no-repeat;background-position:center center;text-decoration:none}div#mw-panel{font-size:inherit;position:absolute;top:160px;padding-top:1em;width:10em;left:0}div#mw-panel div.portal{margin:0 0.6em 0 0.7em;padding:0.25em 0;direction:ltr;background-position:top left;background-repeat:no-repeat;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIwAAAABCAAAAAAphRnkAAAAJ0lEQVQIW7XFsQEAIAyAMPD/b7uLWz8wS5youFW1UREfiIpH1Q2VBz7fGPS1dOGeAAAAAElFTkSuQmCC);background-image:url(http://cnbguatemala.org/skins/Vector/images/portal-break.png?3ea1b)!ie}div#mw-panel div.portal h3{font-size:0.75em;color:#4d4d4d;font-weight:normal;margin:0;padding:0.25em 0 0.25em 0.25em;cursor:default;border:none}div#mw-panel div.portal div.body{margin:0 0 0 1.25em;padding-top:0}div#mw-panel div.portal div.body ul{list-style-type:none;list-style-image:none;margin:0;padding:0}div#mw-panel div.portal div.body ul li{line-height:1.125em;margin:0;padding:0.25em 0;font-size:0.75em;word-wrap:break-word}div#mw-panel div.portal div.body ul li a{color:#0645ad}div#mw-panel div.portal div.body ul li a:visited{color:#0b0080}div#mw-panel #p-logo + div.portal{background-image:none;margin-top:0}div#mw-panel #p-logo + div.portal h3{display:none}div#mw-panel #p-logo + div.portal div.body{margin-left:0.5em}div#footer{margin-left:10em;margin-top:0;padding:0.75em;direction:ltr}div#footer ul{list-style-type:none;list-style-image:none;margin:0;padding:0}div#footer ul li{margin:0;padding:0;padding-top:0.5em;padding-bottom:0.5em;color:#333;font-size:0.7em}div#footer #footer-icons{float:right}div#footer #footer-icons li{float:left;margin-left:0.5em;line-height:2em;text-align:right}div#footer #footer-info li{line-height:1.4em}div#footer #footer-places li{float:left;margin-right:1em;line-height:2em}body.ltr div#footer #footer-places{float:left}.mw-body .external{background-position:center right;background-repeat:no-repeat;background-image:url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.png?948bf);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2210%22%20height%3D%2210%22%3E%3Cg%20transform%3D%22translate%28-826.429%20-698.791%29%22%3E%3Crect%20width%3D%225.982%22%20height%3D%225.982%22%20x%3D%22826.929%22%20y%3D%22702.309%22%20fill%3D%22%23fff%22%20stroke%3D%22%2306c%22%2F%3E%3Cg%3E%3Cpath%20d%3D%22M831.194%20698.791h5.234v5.391l-1.571%201.545-1.31-1.31-2.725%202.725-2.689-2.689%202.808-2.808-1.311-1.311z%22%20fill%3D%22%2306f%22%2F%3E%3Cpath%20d%3D%22M835.424%20699.795l.022%204.885-1.817-1.817-2.881%202.881-1.228-1.228%202.881-2.881-1.851-1.851z%22%20fill%3D%22%23fff%22%2F%3E%3C%2Fg%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.svg?445a3)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2210%22%20height%3D%2210%22%3E%3Cg%20transform%3D%22translate%28-826.429%20-698.791%29%22%3E%3Crect%20width%3D%225.982%22%20height%3D%225.982%22%20x%3D%22826.929%22%20y%3D%22702.309%22%20fill%3D%22%23fff%22%20stroke%3D%22%2306c%22%2F%3E%3Cg%3E%3Cpath%20d%3D%22M831.194%20698.791h5.234v5.391l-1.571%201.545-1.31-1.31-2.725%202.725-2.689-2.689%202.808-2.808-1.311-1.311z%22%20fill%3D%22%2306f%22%2F%3E%3Cpath%20d%3D%22M835.424%20699.795l.022%204.885-1.817-1.817-2.881%202.881-1.228-1.228%202.881-2.881-1.851-1.851z%22%20fill%3D%22%23fff%22%2F%3E%3C%2Fg%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.svg?445a3)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.png?948bf);padding-right:13px}}@media screen and (min-width:982px){.mw-body{margin-left:11em;padding:1.25em 1.5em 1.5em 1.5em}#p-logo{left:0.5em}div#footer{margin-left:11em;padding:1.25em}#mw-panel{padding-left:0.5em}#p-search{margin-right:1em}#left-navigation{margin-left:11em}#p-personal{right:1em}#mw-head-base{margin-left:11em}}
 
</style>
 
</style>

Revisión actual del 15:49 8 jul 2016

<script> /**

* ***** BEGIN LICENSE BLOCK *****
* This file is part of Quiz.
* Copyright © 2007 Louis-Rémi Babe. All rights reserved.
*
* Quiz is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* Quiz is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Quiz; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
*
* ***** END LICENSE BLOCK *****
*
* Quiz is a quiz tool for mediawiki.
*
* To activate this extension :
* * Create a new directory named Quiz into the "extensions" directory of MediaWiki.
* * Place this file and the files Quiz.i18n.php and Quiz.php there.
* * Add this line at the end of your LocalSettings.php file :
* require_once 'extensions/Quiz/Quiz.php';
*
* @file
* @version 1.0
* @link http://www.mediawiki.org/wiki/Extension:Quiz Documentation
* @author Louis-Rémi Babe <[email protected]>
*/

(function() { 'use strict';

// Shuffle questions function shuffle( area ) { var div = area.childNodes; for( var i = 0, questions = []; i < div.length; ++i ) { if( div[i].className ) { if( questions.length === 0 && div[i].className === 'quizText' ) { var quizText = div[i]; } else { questions.push( div[i] ); if( div[i].className === 'shuffle' || div[i].className === 'noshuffle' ) { shuffle( div[i] ); } } } } if( area.className !== 'noshuffle' ) { for( var l, x, m = questions.length; m; l = parseInt( Math.random() * m ), x = questions[--m], questions[m] = questions[l], questions[l] = x ); } if( quizText ) { questions.unshift( quizText ); } for( var j = 0, areaHTML = ; j < questions.length; ++j ) {

areaHTML += '

' + questions[j].innerHTML + '

';

} area.innerHTML = areaHTML; }

// Prepare the quiz for "javascriptable" browsers function prepareQuiz() { var bodyContentDiv = document.getElementById( 'bodyContent' ).getElementsByTagName( 'div' ); for( var i = 0; i < bodyContentDiv.length; ++i ) { if( bodyContentDiv[i].className === 'quiz' ) { var input = bodyContentDiv[i].getElementsByTagName( 'input' ); for( var j = 0; j < input.length; ++j ) { // Add the possibility of unchecking radio buttons if( input[j].type === 'radio' ) { input[j].ondblclick = function() { this.checked = false; }; } // Displays the shuffle buttons. else if( input[j].className === 'shuffle' ) { input[j].style.display = 'inline'; input[j].onclick = function() { shuffle( this.form.getElementsByTagName( 'div' )[0] ); var sh_input = this.form.getElementsByTagName( 'input' ); for( var k = 0; k < sh_input.length; ++k ) { // Add the possibility of unchecking radio buttons if( input[k].type === 'radio' ) { input[k].ondblclick = function() { this.checked = false; }; } } }; } // Display the reset button else if( input[j].className === 'reset' ) { input[j].style.display = 'inline'; input[j].onclick = function() { this.form.quizId.value = ; this.form.submit(); }; } // Correct the bug of ie6 on textfields else if( input[j].className === 'numbers' || input[j].className === 'words' ) { if( typeof document.body.style.maxHeight === 'undefined' ) { input[j].parentNode.onclick = function() { this.parentNode.firstChild.style.display = 'inline'; this.parentNode.firstChild.style.position = 'absolute'; this.parentNode.firstChild.style.marginTop = '1.7em'; }; input[j].parentNode.onmouseout = function() { this.parentNode.firstChild.style.display = 'none'; }; } input[j].onkeydown = function() { if( this.form.shuffleButton ) { this.form.shuffleButton.disabled = true; } }; } if( input[j].className === 'check' ) { input[j].onclick = function() { if( this.form.shuffleButton ) { this.form.shuffleButton.disabled = true; } }; } // Disable the submit button if the page is in preview mode if( input[j].type === 'submit' && document.editform ) { input[j].disabled = true; } } } } }

function addLoadListener( func ) { if ( window.addEventListener ) { window.addEventListener( 'load', func, false ); } else if ( document.addEventListener ) { document.addEventListener( 'load', func, false ); } else if ( window.attachEvent ) { window.attachEvent( 'onload', func ); } }

if ( document.getElementById && document.createTextNode ) { addLoadListener( prepareQuiz ); } })(); /*

* qTip2 - Pretty powerful tooltips - v2.2.0
* http://qtip2.com
*
* Copyright (c) 2013 Craig Michael Thompson
* Released under the MIT, GPL licenses
* http://jquery.org/license
*
* Date: Thu Nov 21 2013 08:34 GMT+0000
* Plugins: tips modal viewport svg imagemap ie6
* Styles: basic css3
*/

/*global window: false, jQuery: false, console: false, define: false */

/* Cache window, document, undefined */ (function( window, document, undefined ) {

// Uses AMD or browser globals to create a jQuery plugin. (function( factory ) { "use strict"; if(typeof define === 'function' && define.amd) { define(['jquery'], factory); } else if(jQuery && !jQuery.fn.qtip) { factory(jQuery); } } (function($) { "use strict"; // Enable ECMAScript "strict" operation for this function. See more: http://ejohn.org/blog/ecmascript-5-strict-mode-json-and-more/

// Munge the primitives - Paul Irish tip

var TRUE = true, FALSE = false, NULL = null,

// Common variables X = 'x', Y = 'y', WIDTH = 'width', HEIGHT = 'height',

// Positioning sides TOP = 'top', LEFT = 'left', BOTTOM = 'bottom', RIGHT = 'right', CENTER = 'center',

// Position adjustment types FLIP = 'flip', FLIPINVERT = 'flipinvert', SHIFT = 'shift',

// Shortcut vars QTIP, PROTOTYPE, CORNER, CHECKS, PLUGINS = {}, NAMESPACE = 'qtip', ATTR_HAS = 'data-hasqtip', ATTR_ID = 'data-qtip-id', WIDGET = ['ui-widget', 'ui-tooltip'], SELECTOR = '.'+NAMESPACE, INACTIVE_EVENTS = 'click dblclick mousedown mouseup mousemove mouseleave mouseenter'.split(' '),

CLASS_FIXED = NAMESPACE+'-fixed', CLASS_DEFAULT = NAMESPACE + '-default', CLASS_FOCUS = NAMESPACE + '-focus', CLASS_HOVER = NAMESPACE + '-hover', CLASS_DISABLED = NAMESPACE+'-disabled',

replaceSuffix = '_replacedByqTip', oldtitle = 'oldtitle', trackingBound,

// Browser detection BROWSER = { /* * IE version detection * * Adapted from: http://ajaxian.com/archives/attack-of-the-ie-conditional-comment * Credit to James Padolsey for the original implemntation! */ ie: (function(){ var v = 3, div = document.createElement('div'); while ((div.innerHTML = )) { if(!div.getElementsByTagName('i')[0]) { break; } } return v > 4 ? v : NaN; }()),

/* * iOS version detection */ iOS: parseFloat( ( + (/CPU.*OS ([0-9_]{1,5})|(CPU like).*AppleWebKit.*Mobile/i.exec(navigator.userAgent) || [0,])[1]) .replace('undefined', '3_2').replace('_', '.').replace('_', ) ) || FALSE };

function QTip(target, options, id, attr) {

// Elements and ID this.id = id; this.target = target; this.tooltip = NULL; this.elements = { target: target };

// Internal constructs this._id = NAMESPACE + '-' + id; this.timers = { img: {} }; this.options = options; this.plugins = {};

// Cache object this.cache = { event: {}, target: $(), disabled: FALSE, attr: attr, onTooltip: FALSE, lastClass: };

// Set the initial flags this.rendered = this.destroyed = this.disabled = this.waiting = this.hiddenDuringWait = this.positioning = this.triggering = FALSE; } PROTOTYPE = QTip.prototype;

PROTOTYPE._when = function(deferreds) { return $.when.apply($, deferreds); };

PROTOTYPE.render = function(show) { if(this.rendered || this.destroyed) { return this; } // If tooltip has already been rendered, exit

var self = this, options = this.options, cache = this.cache, elements = this.elements, text = options.content.text, title = options.content.title, button = options.content.button, posOptions = options.position, namespace = '.'+this._id+' ', deferreds = [], tooltip;

// Add ARIA attributes to target $.attr(this.target[0], 'aria-describedby', this._id);

// Create tooltip element

this.tooltip = elements.tooltip = tooltip = $('

', {

'id': this._id, 'class': [ NAMESPACE, CLASS_DEFAULT, options.style.classes, NAMESPACE + '-pos-' + options.position.my.abbrev() ].join(' '), 'width': options.style.width || , 'height': options.style.height || , 'tracking': posOptions.target === 'mouse' && posOptions.adjust.mouse,

/* ARIA specific attributes */ 'role': 'alert', 'aria-live': 'polite', 'aria-atomic': FALSE, 'aria-describedby': this._id + '-content', 'aria-hidden': TRUE }) .toggleClass(CLASS_DISABLED, this.disabled) .attr(ATTR_ID, this.id) .data(NAMESPACE, this) .appendTo(posOptions.container) .append( // Create content element

elements.content = $('
', {

'class': NAMESPACE + '-content', 'id': this._id + '-content', 'aria-atomic': TRUE }) );

// Set rendered flag and prevent redundant reposition calls for now this.rendered = -1; this.positioning = TRUE;

// Create title... if(title) { this._createTitle();

// Update title only if its not a callback (called in toggle if so) if(!$.isFunction(title)) { deferreds.push( this._updateTitle(title, FALSE) ); } }

// Create button if(button) { this._createButton(); }

// Set proper rendered flag and update content if not a callback function (called in toggle) if(!$.isFunction(text)) { deferreds.push( this._updateContent(text, FALSE) ); } this.rendered = TRUE;

// Setup widget classes this._setWidget();

// Initialize 'render' plugins $.each(PLUGINS, function(name) { var instance; if(this.initialize === 'render' && (instance = this(self))) { self.plugins[name] = instance; } });

// Unassign initial events and assign proper events this._unassignEvents(); this._assignEvents();

// When deferreds have completed this._when(deferreds).then(function() { // tooltiprender event self._trigger('render');

// Reset flags self.positioning = FALSE;

// Show tooltip if not hidden during wait period if(!self.hiddenDuringWait && (options.show.ready || show)) { self.toggle(TRUE, cache.event, FALSE); } self.hiddenDuringWait = FALSE; });

// Expose API QTIP.api[this.id] = this;

return this; };

PROTOTYPE.destroy = function(immediate) { // Set flag the signify destroy is taking place to plugins // and ensure it only gets destroyed once! if(this.destroyed) { return this.target; }

function process() { if(this.destroyed) { return; } this.destroyed = TRUE;

var target = this.target, title = target.attr(oldtitle);

// Destroy tooltip if rendered if(this.rendered) { this.tooltip.stop(1,0).find('*').remove().end().remove(); }

// Destroy all plugins $.each(this.plugins, function(name) { this.destroy && this.destroy(); });

// Clear timers and remove bound events clearTimeout(this.timers.show); clearTimeout(this.timers.hide); this._unassignEvents();

// Remove api object and ARIA attributes target.removeData(NAMESPACE) .removeAttr(ATTR_ID) .removeAttr(ATTR_HAS) .removeAttr('aria-describedby');

// Reset old title attribute if removed if(this.options.suppress && title) { target.attr('title', title).removeAttr(oldtitle); }

// Remove qTip events associated with this API this._unbind(target);

// Remove ID from used id objects, and delete object references // for better garbage collection and leak protection this.options = this.elements = this.cache = this.timers = this.plugins = this.mouse = NULL;

// Delete epoxsed API object delete QTIP.api[this.id]; }

// If an immediate destory is needed if((immediate !== TRUE || this.triggering === 'hide') && this.rendered) { this.tooltip.one('tooltiphidden', $.proxy(process, this)); !this.triggering && this.hide(); }

// If we're not in the process of hiding... process else { process.call(this); }

return this.target; };

function invalidOpt(a) {

return a === NULL || $.type(a) !== 'object'; }

function invalidContent(c) { return !( $.isFunction(c) || (c && c.attr) || c.length || ($.type(c) === 'object' && (c.jquery || c.then) )); }

// Option object sanitizer function sanitizeOptions(opts) { var content, text, ajax, once;

if(invalidOpt(opts)) { return FALSE; }

if(invalidOpt(opts.metadata)) { opts.metadata = { type: opts.metadata }; }

if('content' in opts) { content = opts.content;

if(invalidOpt(content) || content.jquery || content.done) { content = opts.content = { text: (text = invalidContent(content) ? FALSE : content) }; } else { text = content.text; }

// DEPRECATED - Old content.ajax plugin functionality // Converts it into the proper Deferred syntax if('ajax' in content) { ajax = content.ajax; once = ajax && ajax.once !== FALSE; delete content.ajax;

content.text = function(event, api) { var loading = text || $(this).attr(api.options.content.attr) || 'Loading...',

deferred = $.ajax( $.extend({}, ajax, { context: api }) ) .then(ajax.success, NULL, ajax.error) .then(function(content) { if(content && once) { api.set('content.text', content); } return content; }, function(xhr, status, error) { if(api.destroyed || xhr.status === 0) { return; } api.set('content.text', status + ': ' + error); });

return !once ? (api.set('content.text', loading), deferred) : loading; }; }

if('title' in content) { if(!invalidOpt(content.title)) { content.button = content.title.button; content.title = content.title.text; }

if(invalidContent(content.title || FALSE)) { content.title = FALSE; } } }

if('position' in opts && invalidOpt(opts.position)) { opts.position = { my: opts.position, at: opts.position }; }

if('show' in opts && invalidOpt(opts.show)) { opts.show = opts.show.jquery ? { target: opts.show } : opts.show === TRUE ? { ready: TRUE } : { event: opts.show }; }

if('hide' in opts && invalidOpt(opts.hide)) { opts.hide = opts.hide.jquery ? { target: opts.hide } : { event: opts.hide }; }

if('style' in opts && invalidOpt(opts.style)) { opts.style = { classes: opts.style }; }

// Sanitize plugin options $.each(PLUGINS, function() { this.sanitize && this.sanitize(opts); });

return opts; }

// Setup builtin .set() option checks CHECKS = PROTOTYPE.checks = { builtin: { // Core checks '^id$': function(obj, o, v, prev) { var id = v === TRUE ? QTIP.nextid : v, new_id = NAMESPACE + '-' + id;

if(id !== FALSE && id.length > 0 && !$('#'+new_id).length) { this._id = new_id;

if(this.rendered) { this.tooltip[0].id = this._id; this.elements.content[0].id = this._id + '-content'; this.elements.title[0].id = this._id + '-title'; } } else { obj[o] = prev; } }, '^prerender': function(obj, o, v) { v && !this.rendered && this.render(this.options.show.ready); },

// Content checks '^content.text$': function(obj, o, v) { this._updateContent(v); }, '^content.attr$': function(obj, o, v, prev) { if(this.options.content.text === this.target.attr(prev)) { this._updateContent( this.target.attr(v) ); } }, '^content.title$': function(obj, o, v) { // Remove title if content is null if(!v) { return this._removeTitle(); }

// If title isn't already created, create it now and update v && !this.elements.title && this._createTitle(); this._updateTitle(v); }, '^content.button$': function(obj, o, v) { this._updateButton(v); }, '^content.title.(text|button)$': function(obj, o, v) { this.set('content.'+o, v); // Backwards title.text/button compat },

// Position checks '^position.(my|at)$': function(obj, o, v){ 'string' === typeof v && (obj[o] = new CORNER(v, o === 'at')); }, '^position.container$': function(obj, o, v){ this.rendered && this.tooltip.appendTo(v); },

// Show checks '^show.ready$': function(obj, o, v) { v && (!this.rendered && this.render(TRUE) || this.toggle(TRUE)); },

// Style checks '^style.classes$': function(obj, o, v, p) { this.rendered && this.tooltip.removeClass(p).addClass(v); }, '^style.(width|height)': function(obj, o, v) { this.rendered && this.tooltip.css(o, v); }, '^style.widget|content.title': function() { this.rendered && this._setWidget(); }, '^style.def': function(obj, o, v) { this.rendered && this.tooltip.toggleClass(CLASS_DEFAULT, !!v); },

// Events check '^events.(render|show|move|hide|focus|blur)$': function(obj, o, v) { this.rendered && this.tooltip[($.isFunction(v) ?  : 'un') + 'bind']('tooltip'+o, v); },

// Properties which require event reassignment '^(show|hide|position).(event|target|fixed|inactive|leave|distance|viewport|adjust)': function() { if(!this.rendered) { return; }

// Set tracking flag var posOptions = this.options.position; this.tooltip.attr('tracking', posOptions.target === 'mouse' && posOptions.adjust.mouse);

// Reassign events this._unassignEvents(); this._assignEvents(); } } };

// Dot notation converter function convertNotation(options, notation) { var i = 0, obj, option = options,

// Split notation into array levels = notation.split('.');

// Loop through while( option = option[ levels[i++] ] ) { if(i < levels.length) { obj = option; } }

return [obj || options, levels.pop()]; }

PROTOTYPE.get = function(notation) { if(this.destroyed) { return this; }

var o = convertNotation(this.options, notation.toLowerCase()), result = o[0][ o[1] ];

return result.precedance ? result.string() : result; };

function setCallback(notation, args) { var category, rule, match;

for(category in this.checks) { for(rule in this.checks[category]) { if(match = (new RegExp(rule, 'i')).exec(notation)) { args.push(match);

if(category === 'builtin' || this.plugins[category]) { this.checks[category][rule].apply( this.plugins[category] || this, args ); } } } } }

var rmove = /^position\.(my|at|adjust|target|container|viewport)|style|content|show\.ready/i, rrender = /^prerender|show\.ready/i;

PROTOTYPE.set = function(option, value) { if(this.destroyed) { return this; }

var rendered = this.rendered, reposition = FALSE, options = this.options, checks = this.checks, name;

// Convert singular option/value pair into object form if('string' === typeof option) { name = option; option = {}; option[name] = value; } else { option = $.extend({}, option); }

// Set all of the defined options to their new values $.each(option, function(notation, value) { if(rendered && rrender.test(notation)) { delete option[notation]; return; }

// Set new obj value var obj = convertNotation(options, notation.toLowerCase()), previous; previous = obj[0][ obj[1] ]; obj[0][ obj[1] ] = value && value.nodeType ? $(value) : value;

// Also check if we need to reposition reposition = rmove.test(notation) || reposition;

// Set the new params for the callback option[notation] = [obj[0], obj[1], value, previous]; });

// Re-sanitize options sanitizeOptions(options);

/* * Execute any valid callbacks for the set options * Also set positioning flag so we don't get loads of redundant repositioning calls. */ this.positioning = TRUE; $.each(option, $.proxy(setCallback, this)); this.positioning = FALSE;

// Update position if needed if(this.rendered && this.tooltip[0].offsetWidth > 0 && reposition) { this.reposition( options.position.target === 'mouse' ? NULL : this.cache.event ); }

return this; };

PROTOTYPE._update = function(content, element, reposition) {

var self = this, cache = this.cache;

// Make sure tooltip is rendered and content is defined. If not return if(!this.rendered || !content) { return FALSE; }

// Use function to parse content if($.isFunction(content)) { content = content.call(this.elements.target, cache.event, this) || ; }

// Handle deferred content if($.isFunction(content.then)) { cache.waiting = TRUE; return content.then(function(c) { cache.waiting = FALSE; return self._update(c, element); }, NULL, function(e) { return self._update(e, element); }); }

// If content is null... return false if(content === FALSE || (!content && content !== )) { return FALSE; }

// Append new content if its a DOM array and show it if hidden if(content.jquery && content.length > 0) { element.empty().append( content.css({ display: 'block', visibility: 'visible' }) ); }

// Content is a regular string, insert the new content else { element.html(content); }

// Wait for content to be loaded, and reposition return this._waitForContent(element).then(function(images) { if(images.images && images.images.length && self.rendered && self.tooltip[0].offsetWidth > 0) { self.reposition(cache.event, !images.length); } }); };

PROTOTYPE._waitForContent = function(element) { var cache = this.cache;

// Set flag cache.waiting = TRUE;

// If imagesLoaded is included, ensure images have loaded and return promise return ( $.fn.imagesLoaded ? element.imagesLoaded() : $.Deferred().resolve([]) ) .done(function() { cache.waiting = FALSE; }) .promise(); };

PROTOTYPE._updateContent = function(content, reposition) { this._update(content, this.elements.content, reposition); };

PROTOTYPE._updateTitle = function(content, reposition) { if(this._update(content, this.elements.title, reposition) === FALSE) { this._removeTitle(FALSE); } };

PROTOTYPE._createTitle = function() { var elements = this.elements, id = this._id+'-title';

// Destroy previous title element, if present if(elements.titlebar) { this._removeTitle(); }

// Create title bar and title elements

elements.titlebar = $('
', {

'class': NAMESPACE + '-titlebar ' + (this.options.style.widget ? createWidgetClass('header') : ) }) .append(

elements.title = $('
', {

'id': id, 'class': NAMESPACE + '-title', 'aria-atomic': TRUE }) ) .insertBefore(elements.content)

// Button-specific events .delegate('.qtip-close', 'mousedown keydown mouseup keyup mouseout', function(event) { $(this).toggleClass('ui-state-active ui-state-focus', event.type.substr(-4) === 'down'); }) .delegate('.qtip-close', 'mouseover mouseout', function(event){ $(this).toggleClass('ui-state-hover', event.type === 'mouseover'); });

// Create button if enabled if(this.options.content.button) { this._createButton(); } };

PROTOTYPE._removeTitle = function(reposition) { var elements = this.elements;

if(elements.title) { elements.titlebar.remove(); elements.titlebar = elements.title = elements.button = NULL;

// Reposition if enabled if(reposition !== FALSE) { this.reposition(); } } };

PROTOTYPE.reposition = function(event, effect) {

if(!this.rendered || this.positioning || this.destroyed) { return this; }

// Set positioning flag this.positioning = TRUE;

var cache = this.cache, tooltip = this.tooltip, posOptions = this.options.position, target = posOptions.target, my = posOptions.my, at = posOptions.at, viewport = posOptions.viewport, container = posOptions.container, adjust = posOptions.adjust, method = adjust.method.split(' '), tooltipWidth = tooltip.outerWidth(FALSE), tooltipHeight = tooltip.outerHeight(FALSE), targetWidth = 0, targetHeight = 0, type = tooltip.css('position'), position = { left: 0, top: 0 }, visible = tooltip[0].offsetWidth > 0, isScroll = event && event.type === 'scroll', win = $(window), doc = container[0].ownerDocument, mouse = this.mouse, pluginCalculations, offset;

// Check if absolute position was passed if($.isArray(target) && target.length === 2) { // Force left top and set position at = { x: LEFT, y: TOP }; position = { left: target[0], top: target[1] }; }

// Check if mouse was the target else if(target === 'mouse') { // Force left top to allow flipping at = { x: LEFT, y: TOP };

// Use the cached mouse coordinates if available, or passed event has no coordinates if(mouse && mouse.pageX && (adjust.mouse || !event || !event.pageX) ) { event = mouse; }

// If the passed event has no coordinates (such as a scroll event) else if(!event || !event.pageX) { // Use the mouse origin that caused the show event, if distance hiding is enabled if((!adjust.mouse || this.options.show.distance) && cache.origin && cache.origin.pageX) { event = cache.origin; }

// Use cached event for resize/scroll events else if(!event || (event && (event.type === 'resize' || event.type === 'scroll'))) { event = cache.event; } }

// Calculate body and container offset and take them into account below if(type !== 'static') { position = container.offset(); } if(doc.body.offsetWidth !== (window.innerWidth || doc.documentElement.clientWidth)) { offset = $(document.body).offset(); }

// Use event coordinates for position position = { left: event.pageX - position.left + (offset && offset.left || 0), top: event.pageY - position.top + (offset && offset.top || 0) };

// Scroll events are a pain, some browsers if(adjust.mouse && isScroll && mouse) { position.left -= (mouse.scrollX || 0) - win.scrollLeft(); position.top -= (mouse.scrollY || 0) - win.scrollTop(); } }

// Target wasn't mouse or absolute... else { // Check if event targetting is being used if(target === 'event') { if(event && event.target && event.type !== 'scroll' && event.type !== 'resize') { cache.target = $(event.target); } else if(!event.target) { cache.target = this.elements.target; } } else if(target !== 'event'){ cache.target = $(target.jquery ? target : this.elements.target); } target = cache.target;

// Parse the target into a jQuery object and make sure there's an element present target = $(target).eq(0); if(target.length === 0) { return this; }

// Check if window or document is the target else if(target[0] === document || target[0] === window) { targetWidth = BROWSER.iOS ? window.innerWidth : target.width(); targetHeight = BROWSER.iOS ? window.innerHeight : target.height();

if(target[0] === window) { position = { top: (viewport || target).scrollTop(), left: (viewport || target).scrollLeft() }; } }

// Check if the target is an <AREA> element else if(PLUGINS.imagemap && target.is('area')) { pluginCalculations = PLUGINS.imagemap(this, target, at, PLUGINS.viewport ? method : FALSE); }

// Check if the target is an SVG element else if(PLUGINS.svg && target && target[0].ownerSVGElement) { pluginCalculations = PLUGINS.svg(this, target, at, PLUGINS.viewport ? method : FALSE); }

// Otherwise use regular jQuery methods else { targetWidth = target.outerWidth(FALSE); targetHeight = target.outerHeight(FALSE); position = target.offset(); }

// Parse returned plugin values into proper variables if(pluginCalculations) { targetWidth = pluginCalculations.width; targetHeight = pluginCalculations.height; offset = pluginCalculations.offset; position = pluginCalculations.position; }

// Adjust position to take into account offset parents position = this.reposition.offset(target, position, container);

// Adjust for position.fixed tooltips (and also iOS scroll bug in v3.2-4.0 & v4.3-4.3.2) if((BROWSER.iOS > 3.1 && BROWSER.iOS < 4.1) || (BROWSER.iOS >= 4.3 && BROWSER.iOS < 4.33) || (!BROWSER.iOS && type === 'fixed') ){ position.left -= win.scrollLeft(); position.top -= win.scrollTop(); }

// Adjust position relative to target if(!pluginCalculations || (pluginCalculations && pluginCalculations.adjustable !== FALSE)) { position.left += at.x === RIGHT ? targetWidth : at.x === CENTER ? targetWidth / 2 : 0; position.top += at.y === BOTTOM ? targetHeight : at.y === CENTER ? targetHeight / 2 : 0; } }

// Adjust position relative to tooltip position.left += adjust.x + (my.x === RIGHT ? -tooltipWidth : my.x === CENTER ? -tooltipWidth / 2 : 0); position.top += adjust.y + (my.y === BOTTOM ? -tooltipHeight : my.y === CENTER ? -tooltipHeight / 2 : 0);

// Use viewport adjustment plugin if enabled if(PLUGINS.viewport) { position.adjusted = PLUGINS.viewport( this, position, posOptions, targetWidth, targetHeight, tooltipWidth, tooltipHeight );

// Apply offsets supplied by positioning plugin (if used) if(offset && position.adjusted.left) { position.left += offset.left; } if(offset && position.adjusted.top) { position.top += offset.top; } }

// Viewport adjustment is disabled, set values to zero else { position.adjusted = { left: 0, top: 0 }; }

// tooltipmove event if(!this._trigger('move', [position, viewport.elem || viewport], event)) { return this; } delete position.adjusted;

// If effect is disabled, target it mouse, no animation is defined or positioning gives NaN out, set CSS directly if(effect === FALSE || !visible || isNaN(position.left) || isNaN(position.top) || target === 'mouse' || !$.isFunction(posOptions.effect)) { tooltip.css(position); }

// Use custom function if provided else if($.isFunction(posOptions.effect)) { posOptions.effect.call(tooltip, this, $.extend({}, position)); tooltip.queue(function(next) { // Reset attributes to avoid cross-browser rendering bugs $(this).css({ opacity: , height: }); if(BROWSER.ie) { this.style.removeAttribute('filter'); }

next(); }); }

// Set positioning flag this.positioning = FALSE;

return this; };

// Custom (more correct for qTip!) offset calculator PROTOTYPE.reposition.offset = function(elem, pos, container) { if(!container[0]) { return pos; }

var ownerDocument = $(elem[0].ownerDocument), quirks = !!BROWSER.ie && document.compatMode !== 'CSS1Compat', parent = container[0], scrolled, position, parentOffset, overflow;

function scroll(e, i) { pos.left += i * e.scrollLeft(); pos.top += i * e.scrollTop(); }

// Compensate for non-static containers offset do { if((position = $.css(parent, 'position')) !== 'static') { if(position === 'fixed') { parentOffset = parent.getBoundingClientRect(); scroll(ownerDocument, -1); } else { parentOffset = $(parent).position(); parentOffset.left += (parseFloat($.css(parent, 'borderLeftWidth')) || 0); parentOffset.top += (parseFloat($.css(parent, 'borderTopWidth')) || 0); }

pos.left -= parentOffset.left + (parseFloat($.css(parent, 'marginLeft')) || 0); pos.top -= parentOffset.top + (parseFloat($.css(parent, 'marginTop')) || 0);

// If this is the first parent element with an overflow of "scroll" or "auto", store it if(!scrolled && (overflow = $.css(parent, 'overflow')) !== 'hidden' && overflow !== 'visible') { scrolled = $(parent); } } } while((parent = parent.offsetParent));

// Compensate for containers scroll if it also has an offsetParent (or in IE quirks mode) if(scrolled && (scrolled[0] !== ownerDocument[0] || quirks)) { scroll(scrolled, 1); }

return pos; };

// Corner class var C = (CORNER = PROTOTYPE.reposition.Corner = function(corner, forceY) { corner = ( + corner).replace(/([A-Z])/, ' $1').replace(/middle/gi, CENTER).toLowerCase(); this.x = (corner.match(/left|right/i) || corner.match(/center/) || ['inherit'])[0].toLowerCase(); this.y = (corner.match(/top|bottom|center/i) || ['inherit'])[0].toLowerCase(); this.forceY = !!forceY;

var f = corner.charAt(0); this.precedance = (f === 't' || f === 'b' ? Y : X); }).prototype;

C.invert = function(z, center) { this[z] = this[z] === LEFT ? RIGHT : this[z] === RIGHT ? LEFT : center || this[z]; };

C.string = function() { var x = this.x, y = this.y; return x === y ? x : this.precedance === Y || (this.forceY && y !== 'center') ? y+' '+x : x+' '+y; };

C.abbrev = function() { var result = this.string().split(' '); return result[0].charAt(0) + (result[1] && result[1].charAt(0) || ); };

C.clone = function() { return new CORNER( this.string(), this.forceY ); };; PROTOTYPE.toggle = function(state, event) { var cache = this.cache, options = this.options, tooltip = this.tooltip;

// Try to prevent flickering when tooltip overlaps show element if(event) { if((/over|enter/).test(event.type) && (/out|leave/).test(cache.event.type) && options.show.target.add(event.target).length === options.show.target.length && tooltip.has(event.relatedTarget).length) { return this; }

// Cache event cache.event = cloneEvent(event); }

// If we're currently waiting and we've just hidden... stop it this.waiting && !state && (this.hiddenDuringWait = TRUE);

// Render the tooltip if showing and it isn't already if(!this.rendered) { return state ? this.render(1) : this; } else if(this.destroyed || this.disabled) { return this; }

var type = state ? 'show' : 'hide', opts = this.options[type], otherOpts = this.options[ !state ? 'show' : 'hide' ], posOptions = this.options.position, contentOptions = this.options.content, width = this.tooltip.css('width'), visible = this.tooltip.is(':visible'), animate = state || opts.target.length === 1, sameTarget = !event || opts.target.length < 2 || cache.target[0] === event.target, identicalState, allow, showEvent, delay, after;

// Detect state if valid one isn't provided if((typeof state).search('boolean|number')) { state = !visible; }

// Check if the tooltip is in an identical state to the new would-be state identicalState = !tooltip.is(':animated') && visible === state && sameTarget;

// Fire tooltip(show/hide) event and check if destroyed allow = !identicalState ? !!this._trigger(type, [90]) : NULL;

// Check to make sure the tooltip wasn't destroyed in the callback if(this.destroyed) { return this; }

// If the user didn't stop the method prematurely and we're showing the tooltip, focus it if(allow !== FALSE && state) { this.focus(event); }

// If the state hasn't changed or the user stopped it, return early if(!allow || identicalState) { return this; }

// Set ARIA hidden attribute $.attr(tooltip[0], 'aria-hidden', !!!state);

// Execute state specific properties if(state) { // Store show origin coordinates cache.origin = cloneEvent(this.mouse);

// Update tooltip content & title if it's a dynamic function if($.isFunction(contentOptions.text)) { this._updateContent(contentOptions.text, FALSE); } if($.isFunction(contentOptions.title)) { this._updateTitle(contentOptions.title, FALSE); }

// Cache mousemove events for positioning purposes (if not already tracking) if(!trackingBound && posOptions.target === 'mouse' && posOptions.adjust.mouse) { $(document).bind('mousemove.'+NAMESPACE, this._storeMouse); trackingBound = TRUE; }

// Update the tooltip position (set width first to prevent viewport/max-width issues) if(!width) { tooltip.css('width', tooltip.outerWidth(FALSE)); } this.reposition(event, arguments[2]); if(!width) { tooltip.css('width', ); }

// Hide other tooltips if tooltip is solo if(!!opts.solo) { (typeof opts.solo === 'string' ? $(opts.solo) : $(SELECTOR, opts.solo)) .not(tooltip).not(opts.target).qtip('hide', $.Event('tooltipsolo')); } } else { // Clear show timer if we're hiding clearTimeout(this.timers.show);

// Remove cached origin on hide delete cache.origin;

// Remove mouse tracking event if not needed (all tracking qTips are hidden) if(trackingBound && !$(SELECTOR+'[tracking="true"]:visible', opts.solo).not(tooltip).length) { $(document).unbind('mousemove.'+NAMESPACE); trackingBound = FALSE; }

// Blur the tooltip this.blur(event); }

// Define post-animation, state specific properties after = $.proxy(function() { if(state) { // Prevent antialias from disappearing in IE by removing filter if(BROWSER.ie) { tooltip[0].style.removeAttribute('filter'); }

// Remove overflow setting to prevent tip bugs tooltip.css('overflow', );

// Autofocus elements if enabled if('string' === typeof opts.autofocus) { $(this.options.show.autofocus, tooltip).focus(); }

// If set, hide tooltip when inactive for delay period this.options.show.target.trigger('qtip-'+this.id+'-inactive'); } else { // Reset CSS states tooltip.css({ display: , visibility: , opacity: , left: , top: }); }

// tooltipvisible/tooltiphidden events this._trigger(state ? 'visible' : 'hidden'); }, this);

// If no effect type is supplied, use a simple toggle if(opts.effect === FALSE || animate === FALSE) { tooltip[ type ](); after(); }

// Use custom function if provided else if($.isFunction(opts.effect)) { tooltip.stop(1, 1); opts.effect.call(tooltip, this); tooltip.queue('fx', function(n) { after(); n(); }); }

// Use basic fade function by default else { tooltip.fadeTo(90, state ? 1 : 0, after); }

// If inactive hide method is set, active it if(state) { opts.target.trigger('qtip-'+this.id+'-inactive'); }

return this; };

PROTOTYPE.show = function(event) { return this.toggle(TRUE, event); };

PROTOTYPE.hide = function(event) { return this.toggle(FALSE, event); };

PROTOTYPE.focus = function(event) {

if(!this.rendered || this.destroyed) { return this; }

var qtips = $(SELECTOR), tooltip = this.tooltip, curIndex = parseInt(tooltip[0].style.zIndex, 10), newIndex = QTIP.zindex + qtips.length, focusedElem;

// Only update the z-index if it has changed and tooltip is not already focused if(!tooltip.hasClass(CLASS_FOCUS)) { // tooltipfocus event if(this._trigger('focus', [newIndex], event)) { // Only update z-index's if they've changed if(curIndex !== newIndex) { // Reduce our z-index's and keep them properly ordered qtips.each(function() { if(this.style.zIndex > curIndex) { this.style.zIndex = this.style.zIndex - 1; } });

// Fire blur event for focused tooltip qtips.filter('.' + CLASS_FOCUS).qtip('blur', event); }

// Set the new z-index tooltip.addClass(CLASS_FOCUS)[0].style.zIndex = newIndex; } }

return this; };

PROTOTYPE.blur = function(event) { if(!this.rendered || this.destroyed) { return this; }

// Set focused status to FALSE this.tooltip.removeClass(CLASS_FOCUS);

// tooltipblur event this._trigger('blur', [ this.tooltip.css('zIndex') ], event);

return this; };

PROTOTYPE.disable = function(state) {

if(this.destroyed) { return this; }

// If 'toggle' is passed, toggle the current state if(state === 'toggle') { state = !(this.rendered ? this.tooltip.hasClass(CLASS_DISABLED) : this.disabled); }

// Disable if no state passed else if('boolean' !== typeof state) { state = TRUE; }

if(this.rendered) { this.tooltip.toggleClass(CLASS_DISABLED, state) .attr('aria-disabled', state); }

this.disabled = !!state;

return this; };

PROTOTYPE.enable = function() { return this.disable(FALSE); };

PROTOTYPE._createButton = function()

{ var self = this, elements = this.elements, tooltip = elements.tooltip, button = this.options.content.button, isString = typeof button === 'string', close = isString ? button : 'Close tooltip';

if(elements.button) { elements.button.remove(); }

// Use custom button if one was supplied by user, else use default if(button.jquery) { elements.button = button; } else { elements.button = $('<a />', { 'class': 'qtip-close ' + (this.options.style.widget ?  : NAMESPACE+'-icon'), 'title': close, 'aria-label': close }) .prepend( $('', { 'class': 'ui-icon ui-icon-close', 'html': '×' }) ); }

// Create button and setup attributes elements.button.appendTo(elements.titlebar || tooltip) .attr('role', 'button') .click(function(event) { if(!tooltip.hasClass(CLASS_DISABLED)) { self.hide(event); } return FALSE; }); };

PROTOTYPE._updateButton = function(button) { // Make sure tooltip is rendered and if not, return if(!this.rendered) { return FALSE; }

var elem = this.elements.button; if(button) { this._createButton(); } else { elem.remove(); } };

// Widget class creator

function createWidgetClass(cls) { return WIDGET.concat().join(cls ? '-'+cls+' ' : ' '); }

// Widget class setter method PROTOTYPE._setWidget = function() { var on = this.options.style.widget, elements = this.elements, tooltip = elements.tooltip, disabled = tooltip.hasClass(CLASS_DISABLED);

tooltip.removeClass(CLASS_DISABLED); CLASS_DISABLED = on ? 'ui-state-disabled' : 'qtip-disabled'; tooltip.toggleClass(CLASS_DISABLED, disabled);

tooltip.toggleClass('ui-helper-reset '+createWidgetClass(), on).toggleClass(CLASS_DEFAULT, this.options.style.def && !on);

if(elements.content) { elements.content.toggleClass( createWidgetClass('content'), on); } if(elements.titlebar) { elements.titlebar.toggleClass( createWidgetClass('header'), on); } if(elements.button) { elements.button.toggleClass(NAMESPACE+'-icon', !on); } };;function cloneEvent(event) { return event && { type: event.type, pageX: event.pageX, pageY: event.pageY, target: event.target, relatedTarget: event.relatedTarget, scrollX: event.scrollX || window.pageXOffset || document.body.scrollLeft || document.documentElement.scrollLeft, scrollY: event.scrollY || window.pageYOffset || document.body.scrollTop || document.documentElement.scrollTop } || {}; }

function delay(callback, duration) { // If tooltip has displayed, start hide timer if(duration > 0) { return setTimeout( $.proxy(callback, this), duration ); } else{ callback.call(this); } }

function showMethod(event) { if(this.tooltip.hasClass(CLASS_DISABLED)) { return FALSE; }

// Clear hide timers clearTimeout(this.timers.show); clearTimeout(this.timers.hide);

// Start show timer this.timers.show = delay.call(this, function() { this.toggle(TRUE, event); }, this.options.show.delay ); }

function hideMethod(event) { if(this.tooltip.hasClass(CLASS_DISABLED)) { return FALSE; }

// Check if new target was actually the tooltip element var relatedTarget = $(event.relatedTarget), ontoTooltip = relatedTarget.closest(SELECTOR)[0] === this.tooltip[0], ontoTarget = relatedTarget[0] === this.options.show.target[0];

// Clear timers and stop animation queue clearTimeout(this.timers.show); clearTimeout(this.timers.hide);

// Prevent hiding if tooltip is fixed and event target is the tooltip. // Or if mouse positioning is enabled and cursor momentarily overlaps if(this !== relatedTarget[0] && (this.options.position.target === 'mouse' && ontoTooltip) || (this.options.hide.fixed && ( (/mouse(out|leave|move)/).test(event.type) && (ontoTooltip || ontoTarget)) )) { try { event.preventDefault(); event.stopImmediatePropagation(); } catch(e) {}

return; }

// If tooltip has displayed, start hide timer this.timers.hide = delay.call(this, function() { this.toggle(FALSE, event); }, this.options.hide.delay, this ); }

function inactiveMethod(event) { if(this.tooltip.hasClass(CLASS_DISABLED) || !this.options.hide.inactive) { return FALSE; }

// Clear timer clearTimeout(this.timers.inactive);

this.timers.inactive = delay.call(this, function(){ this.hide(event); }, this.options.hide.inactive ); }

function repositionMethod(event) { if(this.rendered && this.tooltip[0].offsetWidth > 0) { this.reposition(event); } }

// Store mouse coordinates PROTOTYPE._storeMouse = function(event) { (this.mouse = cloneEvent(event)).type = 'mousemove'; };

// Bind events PROTOTYPE._bind = function(targets, events, method, suffix, context) { var ns = '.' + this._id + (suffix ? '-'+suffix : ); events.length && $(targets).bind( (events.split ? events : events.join(ns + ' ')) + ns, $.proxy(method, context || this) ); }; PROTOTYPE._unbind = function(targets, suffix) { $(targets).unbind('.' + this._id + (suffix ? '-'+suffix : )); };

// Apply common event handlers using delegate (avoids excessive .bind calls!) var ns = '.'+NAMESPACE; function delegate(selector, events, method) { $(document.body).delegate(selector, (events.split ? events : events.join(ns + ' ')) + ns, function() { var api = QTIP.api[ $.attr(this, ATTR_ID) ]; api && !api.disabled && method.apply(api, arguments); } ); }

$(function() { delegate(SELECTOR, ['mouseenter', 'mouseleave'], function(event) { var state = event.type === 'mouseenter', tooltip = $(event.currentTarget), target = $(event.relatedTarget || event.target), options = this.options;

// On mouseenter... if(state) { // Focus the tooltip on mouseenter (z-index stacking) this.focus(event);

// Clear hide timer on tooltip hover to prevent it from closing tooltip.hasClass(CLASS_FIXED) && !tooltip.hasClass(CLASS_DISABLED) && clearTimeout(this.timers.hide); }

// On mouseleave... else { // Hide when we leave the tooltip and not onto the show target (if a hide event is set) if(options.position.target === 'mouse' && options.hide.event && options.show.target && !target.closest(options.show.target[0]).length) { this.hide(event); } }

// Add hover class tooltip.toggleClass(CLASS_HOVER, state); });

// Define events which reset the 'inactive' event handler delegate('['+ATTR_ID+']', INACTIVE_EVENTS, inactiveMethod); });

// Event trigger PROTOTYPE._trigger = function(type, args, event) { var callback = $.Event('tooltip'+type); callback.originalEvent = (event && $.extend({}, event)) || this.cache.event || NULL;

this.triggering = type; this.tooltip.trigger(callback, [this].concat(args || [])); this.triggering = FALSE;

return !callback.isDefaultPrevented(); };

PROTOTYPE._bindEvents = function(showEvents, hideEvents, showTarget, hideTarget, showMethod, hideMethod) { // If hide and show targets are the same... if(hideTarget.add(showTarget).length === hideTarget.length) { var toggleEvents = [];

// Filter identical show/hide events hideEvents = $.map(hideEvents, function(type) { var showIndex = $.inArray(type, showEvents);

// Both events are identical, remove from both hide and show events // and append to toggleEvents if(showIndex > -1) { toggleEvents.push( showEvents.splice( showIndex, 1 )[0] ); return; }

return type; });

// Toggle events are special case of identical show/hide events, which happen in sequence toggleEvents.length && this._bind(showTarget, toggleEvents, function(event) { var state = this.rendered ? this.tooltip[0].offsetWidth > 0 : false; (state ? hideMethod : showMethod).call(this, event); }); }

// Apply show/hide/toggle events this._bind(showTarget, showEvents, showMethod); this._bind(hideTarget, hideEvents, hideMethod); };

PROTOTYPE._assignInitialEvents = function(event) { var options = this.options, showTarget = options.show.target, hideTarget = options.hide.target, showEvents = options.show.event ? $.trim( + options.show.event).split(' ') : [], hideEvents = options.hide.event ? $.trim( + options.hide.event).split(' ') : [];

/* * Make sure hoverIntent functions properly by using mouseleave as a hide event if * mouseenter/mouseout is used for show.event, even if it isn't in the users options. */ if(/mouse(over|enter)/i.test(options.show.event) && !/mouse(out|leave)/i.test(options.hide.event)) { hideEvents.push('mouseleave'); }

/* * Also make sure initial mouse targetting works correctly by caching mousemove coords * on show targets before the tooltip has rendered. Also set onTarget when triggered to * keep mouse tracking working. */ this._bind(showTarget, 'mousemove', function(event) { this._storeMouse(event); this.cache.onTarget = TRUE; });

// Define hoverIntent function function hoverIntent(event) { // Only continue if tooltip isn't disabled if(this.disabled || this.destroyed) { return FALSE; }

// Cache the event data this.cache.event = cloneEvent(event); this.cache.target = event ? $(event.target) : [undefined];

// Start the event sequence clearTimeout(this.timers.show); this.timers.show = delay.call(this, function() { this.render(typeof event === 'object' || options.show.ready); }, options.show.delay ); }

// Filter and bind events this._bindEvents(showEvents, hideEvents, showTarget, hideTarget, hoverIntent, function() { clearTimeout(this.timers.show); });

// Prerendering is enabled, create tooltip now if(options.show.ready || options.prerender) { hoverIntent.call(this, event); } };

// Event assignment method PROTOTYPE._assignEvents = function() { var self = this, options = this.options, posOptions = options.position,

tooltip = this.tooltip, showTarget = options.show.target, hideTarget = options.hide.target, containerTarget = posOptions.container, viewportTarget = posOptions.viewport, documentTarget = $(document), bodyTarget = $(document.body), windowTarget = $(window),

showEvents = options.show.event ? $.trim( + options.show.event).split(' ') : [], hideEvents = options.hide.event ? $.trim( + options.hide.event).split(' ') : [];


// Assign passed event callbacks $.each(options.events, function(name, callback) { self._bind(tooltip, name === 'toggle' ? ['tooltipshow','tooltiphide'] : ['tooltip'+name], callback, null, tooltip); });

// Hide tooltips when leaving current window/frame (but not select/option elements) if(/mouse(out|leave)/i.test(options.hide.event) && options.hide.leave === 'window') { this._bind(documentTarget, ['mouseout', 'blur'], function(event) { if(!/select|option/.test(event.target.nodeName) && !event.relatedTarget) { this.hide(event); } }); }

// Enable hide.fixed by adding appropriate class if(options.hide.fixed) { hideTarget = hideTarget.add( tooltip.addClass(CLASS_FIXED) ); }

/* * Make sure hoverIntent functions properly by using mouseleave to clear show timer if * mouseenter/mouseout is used for show.event, even if it isn't in the users options. */ else if(/mouse(over|enter)/i.test(options.show.event)) { this._bind(hideTarget, 'mouseleave', function() { clearTimeout(this.timers.show); }); }

// Hide tooltip on document mousedown if unfocus events are enabled if(( + options.hide.event).indexOf('unfocus') > -1) { this._bind(containerTarget.closest('html'), ['mousedown', 'touchstart'], function(event) { var elem = $(event.target), enabled = this.rendered && !this.tooltip.hasClass(CLASS_DISABLED) && this.tooltip[0].offsetWidth > 0, isAncestor = elem.parents(SELECTOR).filter(this.tooltip[0]).length > 0;

if(elem[0] !== this.target[0] && elem[0] !== this.tooltip[0] && !isAncestor && !this.target.has(elem[0]).length && enabled ) { this.hide(event); } }); }

// Check if the tooltip hides when inactive if('number' === typeof options.hide.inactive) { // Bind inactive method to show target(s) as a custom event this._bind(showTarget, 'qtip-'+this.id+'-inactive', inactiveMethod);

// Define events which reset the 'inactive' event handler this._bind(hideTarget.add(tooltip), QTIP.inactiveEvents, inactiveMethod, '-inactive'); }

// Filter and bind events this._bindEvents(showEvents, hideEvents, showTarget, hideTarget, showMethod, hideMethod);

// Mouse movement bindings this._bind(showTarget.add(tooltip), 'mousemove', function(event) { // Check if the tooltip hides when mouse is moved a certain distance if('number' === typeof options.hide.distance) { var origin = this.cache.origin || {}, limit = this.options.hide.distance, abs = Math.abs;

// Check if the movement has gone beyond the limit, and hide it if so if(abs(event.pageX - origin.pageX) >= limit || abs(event.pageY - origin.pageY) >= limit) { this.hide(event); } }

// Cache mousemove coords on show targets this._storeMouse(event); });

// Mouse positioning events if(posOptions.target === 'mouse') { // If mouse adjustment is on... if(posOptions.adjust.mouse) { // Apply a mouseleave event so we don't get problems with overlapping if(options.hide.event) { // Track if we're on the target or not this._bind(showTarget, ['mouseenter', 'mouseleave'], function(event) { this.cache.onTarget = event.type === 'mouseenter'; }); }

// Update tooltip position on mousemove this._bind(documentTarget, 'mousemove', function(event) { // Update the tooltip position only if the tooltip is visible and adjustment is enabled if(this.rendered && this.cache.onTarget && !this.tooltip.hasClass(CLASS_DISABLED) && this.tooltip[0].offsetWidth > 0) { this.reposition(event); } }); } }

// Adjust positions of the tooltip on window resize if enabled if(posOptions.adjust.resize || viewportTarget.length) { this._bind( $.event.special.resize ? viewportTarget : windowTarget, 'resize', repositionMethod ); }

// Adjust tooltip position on scroll of the window or viewport element if present if(posOptions.adjust.scroll) { this._bind( windowTarget.add(posOptions.container), 'scroll', repositionMethod ); } };

// Un-assignment method PROTOTYPE._unassignEvents = function() { var targets = [ this.options.show.target[0], this.options.hide.target[0], this.rendered && this.tooltip[0], this.options.position.container[0], this.options.position.viewport[0], this.options.position.container.closest('html')[0], // unfocus window, document ];

this._unbind($([]).pushStack( $.grep(targets, function(i) { return typeof i === 'object'; }))); };

// Initialization method

function init(elem, id, opts) { var obj, posOptions, attr, config, title,

// Setup element references docBody = $(document.body),

// Use document body instead of document element if needed newTarget = elem[0] === document ? docBody : elem,

// Grab metadata from element if plugin is present metadata = (elem.metadata) ? elem.metadata(opts.metadata) : NULL,

// If metadata type if HTML5, grab 'name' from the object instead, or use the regular data object otherwise metadata5 = opts.metadata.type === 'html5' && metadata ? metadata[opts.metadata.name] : NULL,

// Grab data from metadata.name (or data-qtipopts as fallback) using .data() method, html5 = elem.data(opts.metadata.name || 'qtipopts');

// If we don't get an object returned attempt to parse it manualyl without parseJSON try { html5 = typeof html5 === 'string' ? $.parseJSON(html5) : html5; } catch(e) {}

// Merge in and sanitize metadata config = $.extend(TRUE, {}, QTIP.defaults, opts, typeof html5 === 'object' ? sanitizeOptions(html5) : NULL, sanitizeOptions(metadata5 || metadata));

// Re-grab our positioning options now we've merged our metadata and set id to passed value posOptions = config.position; config.id = id;

// Setup missing content if none is detected if('boolean' === typeof config.content.text) { attr = elem.attr(config.content.attr);

// Grab from supplied attribute if available if(config.content.attr !== FALSE && attr) { config.content.text = attr; }

// No valid content was found, abort render else { return FALSE; } }

// Setup target options if(!posOptions.container.length) { posOptions.container = docBody; } if(posOptions.target === FALSE) { posOptions.target = newTarget; } if(config.show.target === FALSE) { config.show.target = newTarget; } if(config.show.solo === TRUE) { config.show.solo = posOptions.container.closest('body'); } if(config.hide.target === FALSE) { config.hide.target = newTarget; } if(config.position.viewport === TRUE) { config.position.viewport = posOptions.container; }

// Ensure we only use a single container posOptions.container = posOptions.container.eq(0);

// Convert position corner values into x and y strings posOptions.at = new CORNER(posOptions.at, TRUE); posOptions.my = new CORNER(posOptions.my);

// Destroy previous tooltip if overwrite is enabled, or skip element if not if(elem.data(NAMESPACE)) { if(config.overwrite) { elem.qtip('destroy', true); } else if(config.overwrite === FALSE) { return FALSE; } }

// Add has-qtip attribute elem.attr(ATTR_HAS, id);

// Remove title attribute and store it if present if(config.suppress && (title = elem.attr('title'))) { // Final attr call fixes event delegatiom and IE default tooltip showing problem elem.removeAttr('title').attr(oldtitle, title).attr('title', ); }

// Initialize the tooltip and add API reference obj = new QTip(elem, config, id, !!attr); elem.data(NAMESPACE, obj);

// Catch remove/removeqtip events on target element to destroy redundant tooltip elem.one('remove.qtip-'+id+' removeqtip.qtip-'+id, function() { var api; if((api = $(this).data(NAMESPACE))) { api.destroy(true); } });

return obj; }

// jQuery $.fn extension method QTIP = $.fn.qtip = function(options, notation, newValue) { var command = ( + options).toLowerCase(), // Parse command returned = NULL, args = $.makeArray(arguments).slice(1), event = args[args.length - 1], opts = this[0] ? $.data(this[0], NAMESPACE) : NULL;

// Check for API request if((!arguments.length && opts) || command === 'api') { return opts; }

// Execute API command if present else if('string' === typeof options) { this.each(function() { var api = $.data(this, NAMESPACE); if(!api) { return TRUE; }

// Cache the event if possible if(event && event.timeStamp) { api.cache.event = event; }

// Check for specific API commands if(notation && (command === 'option' || command === 'options')) { if(newValue !== undefined || $.isPlainObject(notation)) { api.set(notation, newValue); } else { returned = api.get(notation); return FALSE; } }

// Execute API command else if(api[command]) { api[command].apply(api, args); } });

return returned !== NULL ? returned : this; }

// No API commands. validate provided options and setup qTips else if('object' === typeof options || !arguments.length) { // Sanitize options first opts = sanitizeOptions($.extend(TRUE, {}, options));

return this.each(function(i) { var api, id;

// Find next available ID, or use custom ID if provided id = $.isArray(opts.id) ? opts.id[i] : opts.id; id = !id || id === FALSE || id.length < 1 || QTIP.api[id] ? QTIP.nextid++ : id;

// Initialize the qTip and re-grab newly sanitized options api = init($(this), id, opts); if(api === FALSE) { return TRUE; } else { QTIP.api[id] = api; }

// Initialize plugins $.each(PLUGINS, function() { if(this.initialize === 'initialize') { this(api); } });

// Assign initial pre-render events api._assignInitialEvents(event); }); } };

// Expose class $.qtip = QTip;

// Populated in render method QTIP.api = {};

$.each({

/* Allow other plugins to successfully retrieve the title of an element with a qTip applied */ attr: function(attr, val) { if(this.length) { var self = this[0], title = 'title', api = $.data(self, 'qtip');

if(attr === title && api && 'object' === typeof api && api.options.suppress) { if(arguments.length < 2) { return $.attr(self, oldtitle); }

// If qTip is rendered and title was originally used as content, update it if(api && api.options.content.attr === title && api.cache.attr) { api.set('content.text', val); }

// Use the regular attr method to set, then cache the result return this.attr(oldtitle, val); } }

return $.fn['attr'+replaceSuffix].apply(this, arguments); },

/* Allow clone to correctly retrieve cached title attributes */ clone: function(keepData) { var titles = $([]), title = 'title',

// Clone our element using the real clone method elems = $.fn['clone'+replaceSuffix].apply(this, arguments);

// Grab all elements with an oldtitle set, and change it to regular title attribute, if keepData is false if(!keepData) { elems.filter('['+oldtitle+']').attr('title', function() { return $.attr(this, oldtitle); }) .removeAttr(oldtitle); }

return elems; } }, function(name, func) { if(!func || $.fn[name+replaceSuffix]) { return TRUE; }

var old = $.fn[name+replaceSuffix] = $.fn[name]; $.fn[name] = function() { return func.apply(this, arguments) || old.apply(this, arguments); }; });

/* Fire off 'removeqtip' handler in $.cleanData if jQuery UI not present (it already does similar).

* This snippet is taken directly from jQuery UI source code found here:
*     http://code.jquery.com/ui/jquery-ui-git.js
*/

if(!$.ui) { $['cleanData'+replaceSuffix] = $.cleanData; $.cleanData = function( elems ) { for(var i = 0, elem; (elem = $( elems[i] )).length; i++) { if(elem.attr(ATTR_HAS)) { try { elem.triggerHandler('removeqtip'); } catch( e ) {} } } $['cleanData'+replaceSuffix].apply(this, arguments); }; }

// qTip version

QTIP.version = '2.2.0';

// Base ID for all qTips QTIP.nextid = 0;

// Inactive events array QTIP.inactiveEvents = INACTIVE_EVENTS;

// Base z-index for all qTips QTIP.zindex = 15000;

// Define configuration defaults QTIP.defaults = { prerender: FALSE, id: FALSE, overwrite: TRUE, suppress: TRUE, content: { text: TRUE, attr: 'title', title: FALSE, button: FALSE }, position: { my: 'top left', at: 'bottom right', target: FALSE, container: FALSE, viewport: FALSE, adjust: { x: 0, y: 0, mouse: TRUE, scroll: TRUE, resize: TRUE, method: 'flipinvert flipinvert' }, effect: function(api, pos, viewport) { $(this).animate(pos, { duration: 200, queue: FALSE }); } }, show: { target: FALSE, event: 'mouseenter', effect: TRUE, delay: 90, solo: FALSE, ready: FALSE, autofocus: FALSE }, hide: { target: FALSE, event: 'mouseleave', effect: TRUE, delay: 0, fixed: FALSE, inactive: FALSE, leave: 'window', distance: FALSE }, style: { classes: , widget: FALSE, width: FALSE, height: FALSE, def: TRUE }, events: { render: NULL, move: NULL, show: NULL, hide: NULL, toggle: NULL, visible: NULL, hidden: NULL, focus: NULL, blur: NULL } };

var TIP,

// .bind()/.on() namespace TIPNS = '.qtip-tip',

// Common CSS strings MARGIN = 'margin', BORDER = 'border', COLOR = 'color', BG_COLOR = 'background-color', TRANSPARENT = 'transparent', IMPORTANT = ' !important',

// Check if the browser supports <canvas/> elements HASCANVAS = !!document.createElement('canvas').getContext,

// Invalid colour values used in parseColours() INVALID = /rgba?\(0, 0, 0(, 0)?\)|transparent|#123456/i;

// Camel-case method, taken from jQuery source // http://code.jquery.com/jquery-1.8.0.js function camel(s) { return s.charAt(0).toUpperCase() + s.slice(1); }

/*

* Modified from Modernizr's testPropsAll()
* http://modernizr.com/downloads/modernizr-latest.js
*/

var cssProps = {}, cssPrefixes = ["Webkit", "O", "Moz", "ms"]; function vendorCss(elem, prop) { var ucProp = prop.charAt(0).toUpperCase() + prop.slice(1), props = (prop + ' ' + cssPrefixes.join(ucProp + ' ') + ucProp).split(' '), cur, val, i = 0;

// If the property has already been mapped... if(cssProps[prop]) { return elem.css(cssProps[prop]); }

while((cur = props[i++])) { if((val = elem.css(cur)) !== undefined) { return cssProps[prop] = cur, val; } } }

// Parse a given elements CSS property into an int function intCss(elem, prop) { return Math.ceil(parseFloat(vendorCss(elem, prop))); }


// VML creation (for IE only) if(!HASCANVAS) { var createVML = function(tag, props, style) { return '<qtipvml:'+tag+' xmlns="urn:schemas-microsoft.com:vml" class="qtip-vml" '+(props||)+ ' style="behavior: url(#default#VML); '+(style||)+ '" />'; }; }

// Canvas only definitions else { var PIXEL_RATIO = window.devicePixelRatio || 1, BACKING_STORE_RATIO = (function() { var context = document.createElement('canvas').getContext('2d'); return context.backingStorePixelRatio || context.webkitBackingStorePixelRatio || context.mozBackingStorePixelRatio || context.msBackingStorePixelRatio || context.oBackingStorePixelRatio || 1; }()), SCALE = PIXEL_RATIO / BACKING_STORE_RATIO; }


function Tip(qtip, options) { this._ns = 'tip'; this.options = options; this.offset = options.offset; this.size = [ options.width, options.height ];

// Initialize this.init( (this.qtip = qtip) ); }

$.extend(Tip.prototype, { init: function(qtip) { var context, tip;

// Create tip element and prepend to the tooltip

tip = this.element = qtip.elements.tip = $('
', { 'class': NAMESPACE+'-tip' }).prependTo(qtip.tooltip);

// Create tip drawing element(s) if(HASCANVAS) { // save() as soon as we create the canvas element so FF2 doesn't bork on our first restore()! context = $('<canvas />').appendTo(this.element)[0].getContext('2d');

// Setup constant parameters context.lineJoin = 'miter'; context.miterLimit = 100000; context.save(); } else { context = createVML('shape', 'coordorigin="0,0"', 'position:absolute;'); this.element.html(context + context);

// Prevent mousing down on the tip since it causes problems with .live() handling in IE due to VML qtip._bind( $('*', tip).add(tip), ['click', 'mousedown'], function(event) { event.stopPropagation(); }, this._ns); }

// Bind update events qtip._bind(qtip.tooltip, 'tooltipmove', this.reposition, this._ns, this);

// Create it this.create(); },

_swapDimensions: function() { this.size[0] = this.options.height; this.size[1] = this.options.width; }, _resetDimensions: function() { this.size[0] = this.options.width; this.size[1] = this.options.height; },

_useTitle: function(corner) { var titlebar = this.qtip.elements.titlebar; return titlebar && ( corner.y === TOP || (corner.y === CENTER && this.element.position().top + (this.size[1] / 2) + this.options.offset < titlebar.outerHeight(TRUE)) ); },

_parseCorner: function(corner) { var my = this.qtip.options.position.my;

// Detect corner and mimic properties if(corner === FALSE || my === FALSE) { corner = FALSE; } else if(corner === TRUE) { corner = new CORNER( my.string() ); } else if(!corner.string) { corner = new CORNER(corner); corner.fixed = TRUE; }

return corner; },

_parseWidth: function(corner, side, use) { var elements = this.qtip.elements, prop = BORDER + camel(side) + 'Width';

return (use ? intCss(use, prop) : ( intCss(elements.content, prop) || intCss(this._useTitle(corner) && elements.titlebar || elements.content, prop) || intCss(elements.tooltip, prop) )) || 0; },

_parseRadius: function(corner) { var elements = this.qtip.elements, prop = BORDER + camel(corner.y) + camel(corner.x) + 'Radius';

return BROWSER.ie < 9 ? 0 : intCss(this._useTitle(corner) && elements.titlebar || elements.content, prop) || intCss(elements.tooltip, prop) || 0; },

_invalidColour: function(elem, prop, compare) { var val = elem.css(prop); return !val || (compare && val === elem.css(compare)) || INVALID.test(val) ? FALSE : val; },

_parseColours: function(corner) { var elements = this.qtip.elements, tip = this.element.css('cssText', ), borderSide = BORDER + camel(corner[ corner.precedance ]) + camel(COLOR), colorElem = this._useTitle(corner) && elements.titlebar || elements.content, css = this._invalidColour, color = [];

// Attempt to detect the background colour from various elements, left-to-right precedance color[0] = css(tip, BG_COLOR) || css(colorElem, BG_COLOR) || css(elements.content, BG_COLOR) || css(elements.tooltip, BG_COLOR) || tip.css(BG_COLOR);

// Attempt to detect the correct border side colour from various elements, left-to-right precedance color[1] = css(tip, borderSide, COLOR) || css(colorElem, borderSide, COLOR) || css(elements.content, borderSide, COLOR) || css(elements.tooltip, borderSide, COLOR) || elements.tooltip.css(borderSide);

// Reset background and border colours $('*', tip).add(tip).css('cssText', BG_COLOR+':'+TRANSPARENT+IMPORTANT+';'+BORDER+':0'+IMPORTANT+';');

return color; },

_calculateSize: function(corner) { var y = corner.precedance === Y, width = this.options['width'], height = this.options['height'], isCenter = corner.abbrev() === 'c', base = (y ? width: height) * (isCenter ? 0.5 : 1), pow = Math.pow, round = Math.round, bigHyp, ratio, result,

smallHyp = Math.sqrt( pow(base, 2) + pow(height, 2) ), hyp = [ (this.border / base) * smallHyp, (this.border / height) * smallHyp ];

hyp[2] = Math.sqrt( pow(hyp[0], 2) - pow(this.border, 2) ); hyp[3] = Math.sqrt( pow(hyp[1], 2) - pow(this.border, 2) );

bigHyp = smallHyp + hyp[2] + hyp[3] + (isCenter ? 0 : hyp[0]); ratio = bigHyp / smallHyp;

result = [ round(ratio * width), round(ratio * height) ]; return y ? result : result.reverse(); },

// Tip coordinates calculator _calculateTip: function(corner, size, scale) { scale = scale || 1; size = size || this.size;

var width = size[0] * scale, height = size[1] * scale, width2 = Math.ceil(width / 2), height2 = Math.ceil(height / 2),

// Define tip coordinates in terms of height and width values tips = { br: [0,0, width,height, width,0], bl: [0,0, width,0, 0,height], tr: [0,height, width,0, width,height], tl: [0,0, 0,height, width,height], tc: [0,height, width2,0, width,height], bc: [0,0, width,0, width2,height], rc: [0,0, width,height2, 0,height], lc: [width,0, width,height, 0,height2] };

// Set common side shapes tips.lt = tips.br; tips.rt = tips.bl; tips.lb = tips.tr; tips.rb = tips.tl;

return tips[ corner.abbrev() ]; },

// Tip coordinates drawer (canvas) _drawCoords: function(context, coords) { context.beginPath(); context.moveTo(coords[0], coords[1]); context.lineTo(coords[2], coords[3]); context.lineTo(coords[4], coords[5]); context.closePath(); },

create: function() { // Determine tip corner var c = this.corner = (HASCANVAS || BROWSER.ie) && this._parseCorner(this.options.corner);

// If we have a tip corner... if( (this.enabled = !!this.corner && this.corner.abbrev() !== 'c') ) { // Cache it this.qtip.cache.corner = c.clone();

// Create it this.update(); }

// Toggle tip element this.element.toggle(this.enabled);

return this.corner; },

update: function(corner, position) { if(!this.enabled) { return this; }

var elements = this.qtip.elements, tip = this.element, inner = tip.children(), options = this.options, curSize = this.size, mimic = options.mimic, round = Math.round, color, precedance, context, coords, bigCoords, translate, newSize, border, BACKING_STORE_RATIO;

// Re-determine tip if not already set if(!corner) { corner = this.qtip.cache.corner || this.corner; }

// Use corner property if we detect an invalid mimic value if(mimic === FALSE) { mimic = corner; }

// Otherwise inherit mimic properties from the corner object as necessary else { mimic = new CORNER(mimic); mimic.precedance = corner.precedance;

if(mimic.x === 'inherit') { mimic.x = corner.x; } else if(mimic.y === 'inherit') { mimic.y = corner.y; } else if(mimic.x === mimic.y) { mimic[ corner.precedance ] = corner[ corner.precedance ]; } } precedance = mimic.precedance;

// Ensure the tip width.height are relative to the tip position if(corner.precedance === X) { this._swapDimensions(); } else { this._resetDimensions(); }

// Update our colours color = this.color = this._parseColours(corner);

// Detect border width, taking into account colours if(color[1] !== TRANSPARENT) { // Grab border width border = this.border = this._parseWidth(corner, corner[corner.precedance]);

// If border width isn't zero, use border color as fill if it's not invalid (1.0 style tips) if(options.border && border < 1 && !INVALID.test(color[1])) { color[0] = color[1]; }

// Set border width (use detected border width if options.border is true) this.border = border = options.border !== TRUE ? options.border : border; }

// Border colour was invalid, set border to zero else { this.border = border = 0; }

// Determine tip size newSize = this.size = this._calculateSize(corner); tip.css({ width: newSize[0], height: newSize[1], lineHeight: newSize[1]+'px' });

// Calculate tip translation if(corner.precedance === Y) { translate = [ round(mimic.x === LEFT ? border : mimic.x === RIGHT ? newSize[0] - curSize[0] - border : (newSize[0] - curSize[0]) / 2), round(mimic.y === TOP ? newSize[1] - curSize[1] : 0) ]; } else { translate = [ round(mimic.x === LEFT ? newSize[0] - curSize[0] : 0), round(mimic.y === TOP ? border : mimic.y === BOTTOM ? newSize[1] - curSize[1] - border : (newSize[1] - curSize[1]) / 2) ]; }

// Canvas drawing implementation if(HASCANVAS) { // Grab canvas context and clear/save it context = inner[0].getContext('2d'); context.restore(); context.save(); context.clearRect(0,0,6000,6000);

// Calculate coordinates coords = this._calculateTip(mimic, curSize, SCALE); bigCoords = this._calculateTip(mimic, this.size, SCALE);

// Set the canvas size using calculated size inner.attr(WIDTH, newSize[0] * SCALE).attr(HEIGHT, newSize[1] * SCALE); inner.css(WIDTH, newSize[0]).css(HEIGHT, newSize[1]);

// Draw the outer-stroke tip this._drawCoords(context, bigCoords); context.fillStyle = color[1]; context.fill();

// Draw the actual tip context.translate(translate[0] * SCALE, translate[1] * SCALE); this._drawCoords(context, coords); context.fillStyle = color[0]; context.fill(); }

// VML (IE Proprietary implementation) else { // Calculate coordinates coords = this._calculateTip(mimic);

// Setup coordinates string coords = 'm' + coords[0] + ',' + coords[1] + ' l' + coords[2] + ',' + coords[3] + ' ' + coords[4] + ',' + coords[5] + ' xe';

// Setup VML-specific offset for pixel-perfection translate[2] = border && /^(r|b)/i.test(corner.string()) ? BROWSER.ie === 8 ? 2 : 1 : 0;

// Set initial CSS inner.css({ coordsize: (newSize[0]+border) + ' ' + (newSize[1]+border), antialias: +(mimic.string().indexOf(CENTER) > -1), left: translate[0] - (translate[2] * Number(precedance === X)), top: translate[1] - (translate[2] * Number(precedance === Y)), width: newSize[0] + border, height: newSize[1] + border }) .each(function(i) { var $this = $(this);

// Set shape specific attributes $this[ $this.prop ? 'prop' : 'attr' ]({ coordsize: (newSize[0]+border) + ' ' + (newSize[1]+border), path: coords, fillcolor: color[0], filled: !!i, stroked: !i }) .toggle(!!(border || i));

// Check if border is enabled and add stroke element !i && $this.html( createVML( 'stroke', 'weight="'+(border*2)+'px" color="'+color[1]+'" miterlimit="1000" joinstyle="miter"' ) ); }); }

// Opera bug #357 - Incorrect tip position // https://github.com/Craga89/qTip2/issues/367 window.opera && setTimeout(function() { elements.tip.css({ display: 'inline-block', visibility: 'visible' }); }, 1);

// Position if needed if(position !== FALSE) { this.calculate(corner, newSize); } },

calculate: function(corner, size) { if(!this.enabled) { return FALSE; }

var self = this, elements = this.qtip.elements, tip = this.element, userOffset = this.options.offset, isWidget = elements.tooltip.hasClass('ui-widget'), position = { }, precedance, corners;

// Inherit corner if not provided corner = corner || this.corner; precedance = corner.precedance;

// Determine which tip dimension to use for adjustment size = size || this._calculateSize(corner);

// Setup corners and offset array corners = [ corner.x, corner.y ]; if(precedance === X) { corners.reverse(); }

// Calculate tip position $.each(corners, function(i, side) { var b, bc, br;

if(side === CENTER) { b = precedance === Y ? LEFT : TOP; position[ b ] = '50%'; position[MARGIN+'-' + b] = -Math.round(size[ precedance === Y ? 0 : 1 ] / 2) + userOffset; } else { b = self._parseWidth(corner, side, elements.tooltip); bc = self._parseWidth(corner, side, elements.content); br = self._parseRadius(corner);

position[ side ] = Math.max(-self.border, i ? bc : (userOffset + (br > b ? br : -b))); } });

// Adjust for tip size position[ corner[precedance] ] -= size[ precedance === X ? 0 : 1 ];

// Set and return new position tip.css({ margin: , top: , bottom: , left: , right: }).css(position); return position; },

reposition: function(event, api, pos, viewport) { if(!this.enabled) { return; }

var cache = api.cache, newCorner = this.corner.clone(), adjust = pos.adjusted, method = api.options.position.adjust.method.split(' '), horizontal = method[0], vertical = method[1] || method[0], shift = { left: FALSE, top: FALSE, x: 0, y: 0 }, offset, css = {}, props;

function shiftflip(direction, precedance, popposite, side, opposite) { // Horizontal - Shift or flip method if(direction === SHIFT && newCorner.precedance === precedance && adjust[side] && newCorner[popposite] !== CENTER) { newCorner.precedance = newCorner.precedance === X ? Y : X; } else if(direction !== SHIFT && adjust[side]){ newCorner[precedance] = newCorner[precedance] === CENTER ? (adjust[side] > 0 ? side : opposite) : (newCorner[precedance] === side ? opposite : side); } }

function shiftonly(xy, side, opposite) { if(newCorner[xy] === CENTER) { css[MARGIN+'-'+side] = shift[xy] = offset[MARGIN+'-'+side] - adjust[side]; } else { props = offset[opposite] !== undefined ? [ adjust[side], -offset[side] ] : [ -adjust[side], offset[side] ];

if( (shift[xy] = Math.max(props[0], props[1])) > props[0] ) { pos[side] -= adjust[side]; shift[side] = FALSE; }

css[ offset[opposite] !== undefined ? opposite : side ] = shift[xy]; } }

// If our tip position isn't fixed e.g. doesn't adjust with viewport... if(this.corner.fixed !== TRUE) { // Perform shift/flip adjustments shiftflip(horizontal, X, Y, LEFT, RIGHT); shiftflip(vertical, Y, X, TOP, BOTTOM);

// Update and redraw the tip if needed (check cached details of last drawn tip) if(newCorner.string() !== cache.corner.string() && (cache.cornerTop !== adjust.top || cache.cornerLeft !== adjust.left)) { this.update(newCorner, FALSE); } }

// Setup tip offset properties offset = this.calculate(newCorner);

// Readjust offset object to make it left/top if(offset.right !== undefined) { offset.left = -offset.right; } if(offset.bottom !== undefined) { offset.top = -offset.bottom; } offset.user = this.offset;

// Perform shift adjustments if(shift.left = (horizontal === SHIFT && !!adjust.left)) { shiftonly(X, LEFT, RIGHT); } if(shift.top = (vertical === SHIFT && !!adjust.top)) { shiftonly(Y, TOP, BOTTOM); }

/* * If the tip is adjusted in both dimensions, or in a * direction that would cause it to be anywhere but the * outer border, hide it! */ this.element.css(css).toggle( !((shift.x && shift.y) || (newCorner.x === CENTER && shift.y) || (newCorner.y === CENTER && shift.x)) );

// Adjust position to accomodate tip dimensions pos.left -= offset.left.charAt ? offset.user : horizontal !== SHIFT || shift.top || !shift.left && !shift.top ? offset.left + this.border : 0; pos.top -= offset.top.charAt ? offset.user : vertical !== SHIFT || shift.left || !shift.left && !shift.top ? offset.top + this.border : 0;

// Cache details cache.cornerLeft = adjust.left; cache.cornerTop = adjust.top; cache.corner = newCorner.clone(); },

destroy: function() { // Unbind events this.qtip._unbind(this.qtip.tooltip, this._ns);

// Remove the tip element(s) if(this.qtip.elements.tip) { this.qtip.elements.tip.find('*') .remove().end().remove(); } } });

TIP = PLUGINS.tip = function(api) { return new Tip(api, api.options.style.tip); };

// Initialize tip on render TIP.initialize = 'render';

// Setup plugin sanitization options TIP.sanitize = function(options) { if(options.style && 'tip' in options.style) { var opts = options.style.tip; if(typeof opts !== 'object') { opts = options.style.tip = { corner: opts }; } if(!(/string|boolean/i).test(typeof opts.corner)) { opts.corner = TRUE; } } };

// Add new option checks for the plugin CHECKS.tip = { '^position.my|style.tip.(corner|mimic|border)$': function() { // Make sure a tip can be drawn this.create();

// Reposition the tooltip this.qtip.reposition(); }, '^style.tip.(height|width)$': function(obj) { // Re-set dimensions and redraw the tip this.size = [ obj.width, obj.height ]; this.update();

// Reposition the tooltip this.qtip.reposition(); }, '^content.title|style.(classes|widget)$': function() { this.update(); } };

// Extend original qTip defaults $.extend(TRUE, QTIP.defaults, { style: { tip: { corner: TRUE, mimic: FALSE, width: 6, height: 6, border: TRUE, offset: 0 } } });

var MODAL, OVERLAY,

MODALCLASS = 'qtip-modal', MODALSELECTOR = '.'+MODALCLASS;

OVERLAY = function() { var self = this, focusableElems = {}, current, onLast, prevState, elem;

// Modified code from jQuery UI 1.10.0 source // http://code.jquery.com/ui/1.10.0/jquery-ui.js function focusable(element) { // Use the defined focusable checker when possible if($.expr[':'].focusable) { return $.expr[':'].focusable; }

var isTabIndexNotNaN = !isNaN($.attr(element, 'tabindex')), nodeName = element.nodeName && element.nodeName.toLowerCase(), map, mapName, img;

if('area' === nodeName) { map = element.parentNode; mapName = map.name; if(!element.href || !mapName || map.nodeName.toLowerCase() !== 'map') { return false; } img = $('img[usemap=#' + mapName + ']')[0]; return !!img && img.is(':visible'); } return (/input|select|textarea|button|object/.test( nodeName ) ? !element.disabled : 'a' === nodeName ? element.href || isTabIndexNotNaN : isTabIndexNotNaN ); }

// Focus inputs using cached focusable elements (see update()) function focusInputs(blurElems) { // Blurring body element in IE causes window.open windows to unfocus! if(focusableElems.length < 1 && blurElems.length) { blurElems.not('body').blur(); }

// Focus the inputs else { focusableElems.first().focus(); } }

// Steal focus from elements outside tooltip function stealFocus(event) { if(!elem.is(':visible')) { return; }

var target = $(event.target), tooltip = current.tooltip, container = target.closest(SELECTOR), targetOnTop;

// Determine if input container target is above this targetOnTop = container.length < 1 ? FALSE : (parseInt(container[0].style.zIndex, 10) > parseInt(tooltip[0].style.zIndex, 10));

// If we're showing a modal, but focus has landed on an input below // this modal, divert focus to the first visible input in this modal // or if we can't find one... the tooltip itself if(!targetOnTop && target.closest(SELECTOR)[0] !== tooltip[0]) { focusInputs(target); }

// Detect when we leave the last focusable element... onLast = event.target === focusableElems[focusableElems.length - 1]; }

$.extend(self, { init: function() { // Create document overlay

elem = self.elem = $('
', {

id: 'qtip-overlay',

html: '
',

mousedown: function() { return FALSE; } }) .hide();

// Make sure we can't focus anything outside the tooltip $(document.body).bind('focusin'+MODALSELECTOR, stealFocus);

// Apply keyboard "Escape key" close handler $(document).bind('keydown'+MODALSELECTOR, function(event) { if(current && current.options.show.modal.escape && event.keyCode === 27) { current.hide(event); } });

// Apply click handler for blur option elem.bind('click'+MODALSELECTOR, function(event) { if(current && current.options.show.modal.blur) { current.hide(event); } });

return self; },

update: function(api) { // Update current API reference current = api;

// Update focusable elements if enabled if(api.options.show.modal.stealfocus !== FALSE) { focusableElems = api.tooltip.find('*').filter(function() { return focusable(this); }); } else { focusableElems = []; } },

toggle: function(api, state, duration) { var docBody = $(document.body), tooltip = api.tooltip, options = api.options.show.modal, effect = options.effect, type = state ? 'show': 'hide', visible = elem.is(':visible'), visibleModals = $(MODALSELECTOR).filter(':visible:not(:animated)').not(tooltip), zindex;

// Set active tooltip API reference self.update(api);

// If the modal can steal the focus... // Blur the current item and focus anything in the modal we an if(state && options.stealfocus !== FALSE) { focusInputs( $(':focus') ); }

// Toggle backdrop cursor style on show elem.toggleClass('blurs', options.blur);

// Append to body on show if(state) { elem.appendTo(document.body); }

// Prevent modal from conflicting with show.solo, and don't hide backdrop is other modals are visible if((elem.is(':animated') && visible === state && prevState !== FALSE) || (!state && visibleModals.length)) { return self; }

// Stop all animations elem.stop(TRUE, FALSE);

// Use custom function if provided if($.isFunction(effect)) { effect.call(elem, state); }

// If no effect type is supplied, use a simple toggle else if(effect === FALSE) { elem[ type ](); }

// Use basic fade function else { elem.fadeTo( parseInt(duration, 10) || 90, state ? 1 : 0, function() { if(!state) { elem.hide(); } }); }

// Reset position and detach from body on hide if(!state) { elem.queue(function(next) { elem.css({ left: , top: }); if(!$(MODALSELECTOR).length) { elem.detach(); } next(); }); }

// Cache the state prevState = state;

// If the tooltip is destroyed, set reference to null if(current.destroyed) { current = NULL; }

return self; } });

self.init(); }; OVERLAY = new OVERLAY();

function Modal(api, options) { this.options = options; this._ns = '-modal';

this.init( (this.qtip = api) ); }

$.extend(Modal.prototype, { init: function(qtip) { var tooltip = qtip.tooltip;

// If modal is disabled... return if(!this.options.on) { return this; }

// Set overlay reference qtip.elements.overlay = OVERLAY.elem;

// Add unique attribute so we can grab modal tooltips easily via a SELECTOR, and set z-index tooltip.addClass(MODALCLASS).css('z-index', QTIP.modal_zindex + $(MODALSELECTOR).length);

// Apply our show/hide/focus modal events qtip._bind(tooltip, ['tooltipshow', 'tooltiphide'], function(event, api, duration) { var oEvent = event.originalEvent;

// Make sure mouseout doesn't trigger a hide when showing the modal and mousing onto backdrop if(event.target === tooltip[0]) { if(oEvent && event.type === 'tooltiphide' && /mouse(leave|enter)/.test(oEvent.type) && $(oEvent.relatedTarget).closest(OVERLAY.elem[0]).length) { try { event.preventDefault(); } catch(e) {} } else if(!oEvent || (oEvent && oEvent.type !== 'tooltipsolo')) { this.toggle(event, event.type === 'tooltipshow', duration); } } }, this._ns, this);

// Adjust modal z-index on tooltip focus qtip._bind(tooltip, 'tooltipfocus', function(event, api) { // If focus was cancelled before it reached us, don't do anything if(event.isDefaultPrevented() || event.target !== tooltip[0]) { return; }

var qtips = $(MODALSELECTOR),

// Keep the modal's lower than other, regular qtips newIndex = QTIP.modal_zindex + qtips.length, curIndex = parseInt(tooltip[0].style.zIndex, 10);

// Set overlay z-index OVERLAY.elem[0].style.zIndex = newIndex - 1;

// Reduce modal z-index's and keep them properly ordered qtips.each(function() { if(this.style.zIndex > curIndex) { this.style.zIndex -= 1; } });

// Fire blur event for focused tooltip qtips.filter('.' + CLASS_FOCUS).qtip('blur', event.originalEvent);

// Set the new z-index tooltip.addClass(CLASS_FOCUS)[0].style.zIndex = newIndex;

// Set current OVERLAY.update(api);

// Prevent default handling try { event.preventDefault(); } catch(e) {} }, this._ns, this);

// Focus any other visible modals when this one hides qtip._bind(tooltip, 'tooltiphide', function(event) { if(event.target === tooltip[0]) { $(MODALSELECTOR).filter(':visible').not(tooltip).last().qtip('focus', event); } }, this._ns, this); },

toggle: function(event, state, duration) { // Make sure default event hasn't been prevented if(event && event.isDefaultPrevented()) { return this; }

// Toggle it OVERLAY.toggle(this.qtip, !!state, duration); },

destroy: function() { // Remove modal class this.qtip.tooltip.removeClass(MODALCLASS);

// Remove bound events this.qtip._unbind(this.qtip.tooltip, this._ns);

// Delete element reference OVERLAY.toggle(this.qtip, FALSE); delete this.qtip.elements.overlay; } });


MODAL = PLUGINS.modal = function(api) { return new Modal(api, api.options.show.modal); };

// Setup sanitiztion rules MODAL.sanitize = function(opts) { if(opts.show) { if(typeof opts.show.modal !== 'object') { opts.show.modal = { on: !!opts.show.modal }; } else if(typeof opts.show.modal.on === 'undefined') { opts.show.modal.on = TRUE; } } };

// Base z-index for all modal tooltips (use qTip core z-index as a base) QTIP.modal_zindex = QTIP.zindex - 200;

// Plugin needs to be initialized on render MODAL.initialize = 'render';

// Setup option set checks CHECKS.modal = { '^show.modal.(on|blur)$': function() { // Initialise this.destroy(); this.init();

// Show the modal if not visible already and tooltip is visible this.qtip.elems.overlay.toggle( this.qtip.tooltip[0].offsetWidth > 0 ); } };

// Extend original api defaults $.extend(TRUE, QTIP.defaults, { show: { modal: { on: FALSE, effect: TRUE, blur: TRUE, stealfocus: TRUE, escape: TRUE } } });

PLUGINS.viewport = function(api, position, posOptions, targetWidth, targetHeight, elemWidth, elemHeight)

{ var target = posOptions.target, tooltip = api.elements.tooltip, my = posOptions.my, at = posOptions.at, adjust = posOptions.adjust, method = adjust.method.split(' '), methodX = method[0], methodY = method[1] || method[0], viewport = posOptions.viewport, container = posOptions.container, cache = api.cache, adjusted = { left: 0, top: 0 }, fixed, newMy, newClass, containerOffset, containerStatic, viewportWidth, viewportHeight, viewportScroll, viewportOffset;

// If viewport is not a jQuery element, or it's the window/document, or no adjustment method is used... return if(!viewport.jquery || target[0] === window || target[0] === document.body || adjust.method === 'none') { return adjusted; }

// Cach container details containerOffset = container.offset() || adjusted; containerStatic = container.css('position') === 'static';

// Cache our viewport details fixed = tooltip.css('position') === 'fixed'; viewportWidth = viewport[0] === window ? viewport.width() : viewport.outerWidth(FALSE); viewportHeight = viewport[0] === window ? viewport.height() : viewport.outerHeight(FALSE); viewportScroll = { left: fixed ? 0 : viewport.scrollLeft(), top: fixed ? 0 : viewport.scrollTop() }; viewportOffset = viewport.offset() || adjusted;

// Generic calculation method function calculate(side, otherSide, type, adjust, side1, side2, lengthName, targetLength, elemLength) { var initialPos = position[side1], mySide = my[side], atSide = at[side], isShift = type === SHIFT, myLength = mySide === side1 ? elemLength : mySide === side2 ? -elemLength : -elemLength / 2, atLength = atSide === side1 ? targetLength : atSide === side2 ? -targetLength : -targetLength / 2, sideOffset = viewportScroll[side1] + viewportOffset[side1] - (containerStatic ? 0 : containerOffset[side1]), overflow1 = sideOffset - initialPos, overflow2 = initialPos + elemLength - (lengthName === WIDTH ? viewportWidth : viewportHeight) - sideOffset, offset = myLength - (my.precedance === side || mySide === my[otherSide] ? atLength : 0) - (atSide === CENTER ? targetLength / 2 : 0);

// shift if(isShift) { offset = (mySide === side1 ? 1 : -1) * myLength;

// Adjust position but keep it within viewport dimensions position[side1] += overflow1 > 0 ? overflow1 : overflow2 > 0 ? -overflow2 : 0; position[side1] = Math.max( -containerOffset[side1] + viewportOffset[side1], initialPos - offset, Math.min( Math.max( -containerOffset[side1] + viewportOffset[side1] + (lengthName === WIDTH ? viewportWidth : viewportHeight), initialPos + offset ), position[side1],

// Make sure we don't adjust complete off the element when using 'center' mySide === 'center' ? initialPos - myLength : 1E9 ) );

}

// flip/flipinvert else { // Update adjustment amount depending on if using flipinvert or flip adjust *= (type === FLIPINVERT ? 2 : 0);

// Check for overflow on the left/top if(overflow1 > 0 && (mySide !== side1 || overflow2 > 0)) { position[side1] -= offset + adjust; newMy.invert(side, side1); }

// Check for overflow on the bottom/right else if(overflow2 > 0 && (mySide !== side2 || overflow1 > 0) ) { position[side1] -= (mySide === CENTER ? -offset : offset) + adjust; newMy.invert(side, side2); }

// Make sure we haven't made things worse with the adjustment and reset if so if(position[side1] < viewportScroll && -position[side1] > overflow2) { position[side1] = initialPos; newMy = my.clone(); } }

return position[side1] - initialPos; }

// Set newMy if using flip or flipinvert methods if(methodX !== 'shift' || methodY !== 'shift') { newMy = my.clone(); }

// Adjust position based onviewport and adjustment options adjusted = { left: methodX !== 'none' ? calculate( X, Y, methodX, adjust.x, LEFT, RIGHT, WIDTH, targetWidth, elemWidth ) : 0, top: methodY !== 'none' ? calculate( Y, X, methodY, adjust.y, TOP, BOTTOM, HEIGHT, targetHeight, elemHeight ) : 0 };

// Set tooltip position class if it's changed if(newMy && cache.lastClass !== (newClass = NAMESPACE + '-pos-' + newMy.abbrev())) { tooltip.removeClass(api.cache.lastClass).addClass( (api.cache.lastClass = newClass) ); }

return adjusted; };

PLUGINS.polys = {

// POLY area coordinate calculator // Special thanks to Ed Cradock for helping out with this. // Uses a binary search algorithm to find suitable coordinates. polygon: function(baseCoords, corner) { var result = { width: 0, height: 0, position: { top: 1e10, right: 0, bottom: 0, left: 1e10 }, adjustable: FALSE }, i = 0, next, coords = [], compareX = 1, compareY = 1, realX = 0, realY = 0, newWidth, newHeight;

// First pass, sanitize coords and determine outer edges i = baseCoords.length; while(i--) { next = [ parseInt(baseCoords[--i], 10), parseInt(baseCoords[i+1], 10) ];

if(next[0] > result.position.right){ result.position.right = next[0]; } if(next[0] < result.position.left){ result.position.left = next[0]; } if(next[1] > result.position.bottom){ result.position.bottom = next[1]; } if(next[1] < result.position.top){ result.position.top = next[1]; }

coords.push(next); }

// Calculate height and width from outer edges newWidth = result.width = Math.abs(result.position.right - result.position.left); newHeight = result.height = Math.abs(result.position.bottom - result.position.top);

// If it's the center corner... if(corner.abbrev() === 'c') { result.position = { left: result.position.left + (result.width / 2), top: result.position.top + (result.height / 2) }; } else { // Second pass, use a binary search algorithm to locate most suitable coordinate while(newWidth > 0 && newHeight > 0 && compareX > 0 && compareY > 0) { newWidth = Math.floor(newWidth / 2); newHeight = Math.floor(newHeight / 2);

if(corner.x === LEFT){ compareX = newWidth; } else if(corner.x === RIGHT){ compareX = result.width - newWidth; } else{ compareX += Math.floor(newWidth / 2); }

if(corner.y === TOP){ compareY = newHeight; } else if(corner.y === BOTTOM){ compareY = result.height - newHeight; } else{ compareY += Math.floor(newHeight / 2); }

i = coords.length; while(i--) { if(coords.length < 2){ break; }

realX = coords[i][0] - result.position.left; realY = coords[i][1] - result.position.top;

if((corner.x === LEFT && realX >= compareX) || (corner.x === RIGHT && realX <= compareX) || (corner.x === CENTER && (realX < compareX || realX > (result.width - compareX))) || (corner.y === TOP && realY >= compareY) || (corner.y === BOTTOM && realY <= compareY) || (corner.y === CENTER && (realY < compareY || realY > (result.height - compareY)))) { coords.splice(i, 1); } } } result.position = { left: coords[0][0], top: coords[0][1] }; }

return result; },

rect: function(ax, ay, bx, by) { return { width: Math.abs(bx - ax), height: Math.abs(by - ay), position: { left: Math.min(ax, bx), top: Math.min(ay, by) } }; },

_angles: { tc: 3 / 2, tr: 7 / 4, tl: 5 / 4, bc: 1 / 2, br: 1 / 4, bl: 3 / 4, rc: 2, lc: 1, c: 0 }, ellipse: function(cx, cy, rx, ry, corner) { var c = PLUGINS.polys._angles[ corner.abbrev() ], rxc = c === 0 ? 0 : rx * Math.cos( c * Math.PI ), rys = ry * Math.sin( c * Math.PI );

return { width: (rx * 2) - Math.abs(rxc), height: (ry * 2) - Math.abs(rys), position: { left: cx + rxc, top: cy + rys }, adjustable: FALSE }; }, circle: function(cx, cy, r, corner) { return PLUGINS.polys.ellipse(cx, cy, r, r, corner); } };;PLUGINS.svg = function(api, svg, corner) { var doc = $(document), elem = svg[0], root = $(elem.ownerSVGElement), xScale = 1, yScale = 1, complex = true, rootWidth, rootHeight, mtx, transformed, viewBox, len, next, i, points, result, position, dimensions;

// Ascend the parentNode chain until we find an element with getBBox() while(!elem.getBBox) { elem = elem.parentNode; } if(!elem.getBBox || !elem.parentNode) { return FALSE; }

// Determine dimensions where possible rootWidth = root.attr('width') || root.width() || parseInt(root.css('width'), 10); rootHeight = root.attr('height') || root.height() || parseInt(root.css('height'), 10);

// Add stroke characteristics to scaling var strokeWidth2 = (parseInt(svg.css('stroke-width'), 10) || 0) / 2; if(strokeWidth2) { xScale += strokeWidth2 / rootWidth; yScale += strokeWidth2 / rootHeight; }

// Determine which shape calculation to use switch(elem.nodeName) { case 'ellipse': case 'circle': result = PLUGINS.polys.ellipse( elem.cx.baseVal.value, elem.cy.baseVal.value, (elem.rx || elem.r).baseVal.value + strokeWidth2, (elem.ry || elem.r).baseVal.value + strokeWidth2, corner ); break;

case 'line': case 'polygon': case 'polyline': // Determine points object (line has none, so mimic using array) points = elem.points || [ { x: elem.x1.baseVal.value, y: elem.y1.baseVal.value }, { x: elem.x2.baseVal.value, y: elem.y2.baseVal.value } ];

for(result = [], i = -1, len = points.numberOfItems || points.length; ++i < len;) { next = points.getItem ? points.getItem(i) : points[i]; result.push.apply(result, [next.x, next.y]); }

result = PLUGINS.polys.polygon(result, corner); break;

// Unknown shape or rectangle? Use bounding box default: result = elem.getBoundingClientRect(); result = { width: result.width, height: result.height, position: { left: result.left, top: result.top } }; complex = false; break; }

// Shortcut assignments position = result.position; root = root[0];

// If the shape was complex (i.e. not using bounding box calculations) if(complex) { // Convert position into a pixel value if(root.createSVGPoint) { mtx = elem.getScreenCTM(); points = root.createSVGPoint();

points.x = position.left; points.y = position.top; transformed = points.matrixTransform( mtx ); position.left = transformed.x; position.top = transformed.y; }

// Calculate viewBox characteristics if(root.viewBox && (viewBox = root.viewBox.baseVal) && viewBox.width && viewBox.height) { xScale *= rootWidth / viewBox.width; yScale *= rootHeight / viewBox.height; } }

// Adjust by scroll offset position.left += doc.scrollLeft(); position.top += doc.scrollTop();

return result; };;PLUGINS.imagemap = function(api, area, corner, adjustMethod) { if(!area.jquery) { area = $(area); }

var shape = area.attr('shape').toLowerCase().replace('poly', 'polygon'), image = $('img[usemap="#'+area.parent('map').attr('name')+'"]'), coordsString = $.trim(area.attr('coords')), coordsArray = coordsString.replace(/,$/, ).split(','), imageOffset, coords, i, next, result, len;

// If we can't find the image using the map... if(!image.length) { return FALSE; }

// Pass coordinates string if polygon if(shape === 'polygon') { result = PLUGINS.polys.polygon(coordsArray, corner); }

// Otherwise parse the coordinates and pass them as arguments else if(PLUGINS.polys[shape]) { for(i = -1, len = coordsArray.length, coords = []; ++i < len;) { coords.push( parseInt(coordsArray[i], 10) ); }

result = PLUGINS.polys[shape].apply( this, coords.concat(corner) ); }

// If no shapre calculation method was found, return false else { return FALSE; }

// Make sure we account for padding and borders on the image imageOffset = image.offset(); imageOffset.left += Math.ceil((image.outerWidth(FALSE) - image.width()) / 2); imageOffset.top += Math.ceil((image.outerHeight(FALSE) - image.height()) / 2);

// Add image position to offset coordinates result.position.left += imageOffset.left; result.position.top += imageOffset.top;

return result; };;var IE6,

/*

* BGIFrame adaption (http://plugins.jquery.com/project/bgiframe)
* Special thanks to Brandon Aaron
*/

BGIFRAME = '<iframe class="qtip-bgiframe" frameborder="0" tabindex="-1" src="javascript:\'\';" ' + ' style="display:block; position:absolute; z-index:-1; filter:alpha(opacity=0); ' + '-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";"></iframe>';

function Ie6(api, qtip) { this._ns = 'ie6'; this.init( (this.qtip = api) ); }

$.extend(Ie6.prototype, { _scroll : function() { var overlay = this.qtip.elements.overlay; overlay && (overlay[0].style.top = $(window).scrollTop() + 'px'); },

init: function(qtip) { var tooltip = qtip.tooltip, scroll;

// Create the BGIFrame element if needed if($('select, object').length < 1) { this.bgiframe = qtip.elements.bgiframe = $(BGIFRAME).appendTo(tooltip);

// Update BGIFrame on tooltip move qtip._bind(tooltip, 'tooltipmove', this.adjustBGIFrame, this._ns, this); }

// redraw() container for width/height calculations

this.redrawContainer = $('
', { id: NAMESPACE+'-rcontainer' })

.appendTo(document.body);

// Fixup modal plugin if present too if( qtip.elements.overlay && qtip.elements.overlay.addClass('qtipmodal-ie6fix') ) { qtip._bind(window, ['scroll', 'resize'], this._scroll, this._ns, this); qtip._bind(tooltip, ['tooltipshow'], this._scroll, this._ns, this); }

// Set dimensions this.redraw(); },

adjustBGIFrame: function() { var tooltip = this.qtip.tooltip, dimensions = { height: tooltip.outerHeight(FALSE), width: tooltip.outerWidth(FALSE) }, plugin = this.qtip.plugins.tip, tip = this.qtip.elements.tip, tipAdjust, offset;

// Adjust border offset offset = parseInt(tooltip.css('borderLeftWidth'), 10) || 0; offset = { left: -offset, top: -offset };

// Adjust for tips plugin if(plugin && tip) { tipAdjust = (plugin.corner.precedance === 'x') ? [WIDTH, LEFT] : [HEIGHT, TOP]; offset[ tipAdjust[1] ] -= tip[ tipAdjust[0] ](); }

// Update bgiframe this.bgiframe.css(offset).css(dimensions); },

// Max/min width simulator function redraw: function() { if(this.qtip.rendered < 1 || this.drawing) { return this; }

var tooltip = this.qtip.tooltip, style = this.qtip.options.style, container = this.qtip.options.position.container, perc, width, max, min;

// Set drawing flag this.qtip.drawing = 1;

// If tooltip has a set height/width, just set it... like a boss! if(style.height) { tooltip.css(HEIGHT, style.height); } if(style.width) { tooltip.css(WIDTH, style.width); }

// Simulate max/min width if not set width present... else { // Reset width and add fluid class tooltip.css(WIDTH, ).appendTo(this.redrawContainer);

// Grab our tooltip width (add 1 if odd so we don't get wrapping problems.. huzzah!) width = tooltip.width(); if(width % 2 < 1) { width += 1; }

// Grab our max/min properties max = tooltip.css('maxWidth') || ; min = tooltip.css('minWidth') || ;

// Parse into proper pixel values perc = (max + min).indexOf('%') > -1 ? container.width() / 100 : 0; max = ((max.indexOf('%') > -1 ? perc : 1) * parseInt(max, 10)) || width; min = ((min.indexOf('%') > -1 ? perc : 1) * parseInt(min, 10)) || 0;

// Determine new dimension size based on max/min/current values width = max + min ? Math.min(Math.max(width, min), max) : width;

// Set the newly calculated width and remvoe fluid class tooltip.css(WIDTH, Math.round(width)).appendTo(container); }

// Set drawing flag this.drawing = 0;

return this; },

destroy: function() { // Remove iframe this.bgiframe && this.bgiframe.remove();

// Remove bound events this.qtip._unbind([window, this.qtip.tooltip], this._ns); } });

IE6 = PLUGINS.ie6 = function(api) { // Proceed only if the browser is IE6 return BROWSER.ie === 6 ? new Ie6(api) : FALSE; };

IE6.initialize = 'render';

CHECKS.ie6 = { '^content|style$': function() { this.redraw(); } };;})); }( window, document ));


/**

* Javascript handler for the Lingo extension
*
* @author Stephan Gambke
*/

/*global jQuery, mediaWiki */ /*global confirm */

( function ( $, mw ) {

'use strict';

$( function ( $ ) {

$( '.mw-lingo-tooltip' ).each( function ( index ) {

var tooltip = $( this ).find( '.mw-lingo-tooltip-tip' );

$( this ).qtip( { content : tooltip.html(), position: { my: 'top left', // Position tooltip's top left... at: 'bottom left' // at the bottom left of target }, hide : { fixed: true, delay: 300 }, style : { classes: tooltip.attr( 'class' ) + ' qtip-shadow', def : false }

} );

tooltip.remove();

} );

} ); }( jQuery, mediaWiki ) );

</script> <style> .quiz .settings input.numerical { width: 2em; }

  • >.quiz .header .questionId {

text-indent: -1.5em; }

.quiz table.object, .quiz table.correction { background-color: transparent; }

.quiz .hideCorrection .correction { display: none; }

.quiz .settings td { padding: 0.1em 0.4em 0.1em 0.4em; }

.quiz table.settings { background-color: transparent; }

.quiz .sign { text-align: center; }

.quiz a.input, .quiz a.input:hover, .quiz a.input:active, .quiz a.input:visited { text-decoration: none; color: black; outline: 0; }

.quiz a.input span { outline: #7F9DB9 solid 1px; *border: 1px solid #7F9DB9; }

.quiz a.input:active span.correction, .quiz a.input:focus span.correction { display: inline; position: absolute; margin: 1.8em 0 0 0.1em; } /*

* qTip2 - Pretty powerful tooltips - v2.2.0
* http://qtip2.com
*
* Copyright (c) 2013 Craig Michael Thompson
* Released under the MIT, GPL licenses
* http://jquery.org/license
*
* Date: Thu Nov 21 2013 08:34 GMT+0000
* Plugins: tips modal viewport svg imagemap ie6
* Styles: basic css3
*/

.qtip{ position: absolute; left: -28000px; top: -28000px; display: none;

max-width: 280px; min-width: 50px;

font-size: 10.5px; line-height: 12px;

direction: ltr;

box-shadow: none; padding: 0; }

.qtip-content{ position: relative; padding: 5px 9px; overflow: hidden;

text-align: left; word-wrap: break-word; }

.qtip-titlebar{ position: relative; padding: 5px 35px 5px 10px; overflow: hidden;

border-width: 0 0 1px; font-weight: bold; }

.qtip-titlebar + .qtip-content{ border-top-width: 0 !important; }

/* Default close button class */ .qtip-close{ position: absolute; right: -9px; top: -9px;

cursor: pointer; outline: medium none;

border-width: 1px; border-style: solid; border-color: transparent; }

.qtip-titlebar .qtip-close{ right: 4px; top: 50%; margin-top: -9px; }

* html .qtip-titlebar .qtip-close{ top: 16px; } /* IE fix */

.qtip-titlebar .ui-icon, .qtip-icon .ui-icon{ display: block; text-indent: -1000em; direction: ltr; }

.qtip-icon, .qtip-icon .ui-icon{ -moz-border-radius: 3px; -webkit-border-radius: 3px; border-radius: 3px; text-decoration: none; }

.qtip-icon .ui-icon{ width: 18px; height: 14px;

line-height: 14px; text-align: center; text-indent: 0; font: normal bold 10px/13px Tahoma,sans-serif;

color: inherit; background: transparent none no-repeat -100em -100em; }

/* Applied to 'focused' tooltips e.g. most recently displayed/interacted with */ .qtip-focus{}

/* Applied on hover of tooltips i.e. added/removed on mouseenter/mouseleave respectively */ .qtip-hover{}

/* Default tooltip style */ .qtip-default{ border-width: 1px; border-style: solid; border-color: #F1D031;

background-color: #FFFFA3; color: #555; }

.qtip-default .qtip-titlebar{ background-color: #FFEF93; }

.qtip-default .qtip-icon{ border-color: #CCC; background: #F1F1F1; color: #777; }

.qtip-default .qtip-titlebar .qtip-close{ border-color: #AAA; color: #111; }


/*! Light tooltip style */ .qtip-light{ background-color: white; border-color: #E2E2E2; color: #454545; }

.qtip-light .qtip-titlebar{ background-color: #f1f1f1; }


/*! Dark tooltip style */ .qtip-dark{ background-color: #505050; border-color: #303030; color: #f3f3f3; }

.qtip-dark .qtip-titlebar{ background-color: #404040; }

.qtip-dark .qtip-icon{ border-color: #444; }

.qtip-dark .qtip-titlebar .ui-state-hover{ border-color: #303030; }


/*! Cream tooltip style */ .qtip-cream{ background-color: #FBF7AA; border-color: #F9E98E; color: #A27D35; }

.qtip-cream .qtip-titlebar{ background-color: #F0DE7D; }

.qtip-cream .qtip-close .qtip-icon{ background-position: -82px 0; }


/*! Red tooltip style */ .qtip-red{ background-color: #F78B83; border-color: #D95252; color: #912323; }

.qtip-red .qtip-titlebar{ background-color: #F06D65; }

.qtip-red .qtip-close .qtip-icon{ background-position: -102px 0; }

.qtip-red .qtip-icon{ border-color: #D95252; }

.qtip-red .qtip-titlebar .ui-state-hover{ border-color: #D95252; }


/*! Green tooltip style */ .qtip-green{ background-color: #CAED9E; border-color: #90D93F; color: #3F6219; }

.qtip-green .qtip-titlebar{ background-color: #B0DE78; }

.qtip-green .qtip-close .qtip-icon{ background-position: -42px 0; }


/*! Blue tooltip style */ .qtip-blue{ background-color: #E5F6FE; border-color: #ADD9ED; color: #5E99BD; }

.qtip-blue .qtip-titlebar{ background-color: #D0E9F5; }

.qtip-blue .qtip-close .qtip-icon{ background-position: -2px 0; }


.qtip-shadow{ -webkit-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15); -moz-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15); box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15); }

/* Add rounded corners to your tooltips in: FF3+, Chrome 2+, Opera 10.6+, IE9+, Safari 2+ */ .qtip-rounded, .qtip-tipsy, .qtip-bootstrap{ -moz-border-radius: 5px; -webkit-border-radius: 5px; border-radius: 5px; }

.qtip-rounded .qtip-titlebar{ -moz-border-radius: 4px 4px 0 0; -webkit-border-radius: 4px 4px 0 0; border-radius: 4px 4px 0 0; }

/* Youtube tooltip style */ .qtip-youtube{ -moz-border-radius: 2px; -webkit-border-radius: 2px; border-radius: 2px;

-webkit-box-shadow: 0 0 3px #333; -moz-box-shadow: 0 0 3px #333; box-shadow: 0 0 3px #333;

color: white; border-width: 0;

background: #4A4A4A; background-image: -webkit-gradient(linear,left top,left bottom,color-stop(0,#4A4A4A),color-stop(100%,black)); background-image: -webkit-linear-gradient(top,#4A4A4A 0,black 100%); background-image: -moz-linear-gradient(top,#4A4A4A 0,black 100%); background-image: -ms-linear-gradient(top,#4A4A4A 0,black 100%); background-image: -o-linear-gradient(top,#4A4A4A 0,black 100%); }

.qtip-youtube .qtip-titlebar{ background-color: #4A4A4A; background-color: rgba(0,0,0,0); }

.qtip-youtube .qtip-content{ padding: .75em; font: 12px arial,sans-serif;

filter: progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#4a4a4a,EndColorStr=#000000); -ms-filter: "progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr=#4a4a4a,EndColorStr=#000000);"; }

.qtip-youtube .qtip-icon{ border-color: #222; }

.qtip-youtube .qtip-titlebar .ui-state-hover{ border-color: #303030; }


/* jQuery TOOLS Tooltip style */ .qtip-jtools{ background: #232323; background: rgba(0, 0, 0, 0.7); background-image: -webkit-gradient(linear, left top, left bottom, from(#717171), to(#232323)); background-image: -moz-linear-gradient(top, #717171, #232323); background-image: -webkit-linear-gradient(top, #717171, #232323); background-image: -ms-linear-gradient(top, #717171, #232323); background-image: -o-linear-gradient(top, #717171, #232323);

border: 2px solid #ddd; border: 2px solid rgba(241,241,241,1);

-moz-border-radius: 2px; -webkit-border-radius: 2px; border-radius: 2px;

-webkit-box-shadow: 0 0 12px #333; -moz-box-shadow: 0 0 12px #333; box-shadow: 0 0 12px #333; }

/* IE Specific */ .qtip-jtools .qtip-titlebar{ background-color: transparent; filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#717171,endColorstr=#4A4A4A); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#717171,endColorstr=#4A4A4A)"; } .qtip-jtools .qtip-content{ filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#4A4A4A,endColorstr=#232323); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#4A4A4A,endColorstr=#232323)"; }

.qtip-jtools .qtip-titlebar, .qtip-jtools .qtip-content{ background: transparent; color: white; border: 0 dashed transparent; }

.qtip-jtools .qtip-icon{ border-color: #555; }

.qtip-jtools .qtip-titlebar .ui-state-hover{ border-color: #333; }


/* Cluetip style */ .qtip-cluetip{ -webkit-box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4); -moz-box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4); box-shadow: 4px 4px 5px rgba(0, 0, 0, 0.4);

background-color: #D9D9C2; color: #111; border: 0 dashed transparent; }

.qtip-cluetip .qtip-titlebar{ background-color: #87876A; color: white; border: 0 dashed transparent; }

.qtip-cluetip .qtip-icon{ border-color: #808064; }

.qtip-cluetip .qtip-titlebar .ui-state-hover{ border-color: #696952; color: #696952; }


/* Tipsy style */ .qtip-tipsy{ background: black; background: rgba(0, 0, 0, .87);

color: white; border: 0 solid transparent;

font-size: 11px; font-family: 'Lucida Grande', sans-serif; font-weight: bold; line-height: 16px; text-shadow: 0 1px black; }

.qtip-tipsy .qtip-titlebar{ padding: 6px 35px 0 10px; background-color: transparent; }

.qtip-tipsy .qtip-content{ padding: 6px 10px; }

.qtip-tipsy .qtip-icon{ border-color: #222; text-shadow: none; }

.qtip-tipsy .qtip-titlebar .ui-state-hover{ border-color: #303030; }


/* Tipped style */ .qtip-tipped{ border: 3px solid #959FA9;

-moz-border-radius: 3px; -webkit-border-radius: 3px; border-radius: 3px;

background-color: #F9F9F9; color: #454545;

font-weight: normal; font-family: serif; }

.qtip-tipped .qtip-titlebar{ border-bottom-width: 0;

color: white; background: #3A79B8; background-image: -webkit-gradient(linear, left top, left bottom, from(#3A79B8), to(#2E629D)); background-image: -webkit-linear-gradient(top, #3A79B8, #2E629D); background-image: -moz-linear-gradient(top, #3A79B8, #2E629D); background-image: -ms-linear-gradient(top, #3A79B8, #2E629D); background-image: -o-linear-gradient(top, #3A79B8, #2E629D); filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#3A79B8,endColorstr=#2E629D); -ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#3A79B8,endColorstr=#2E629D)"; }

.qtip-tipped .qtip-icon{ border: 2px solid #285589; background: #285589; }

.qtip-tipped .qtip-icon .ui-icon{ background-color: #FBFBFB; color: #555; }


/**

* Twitter Bootstrap style.
*
* Tested with IE 8, IE 9, Chrome 18, Firefox 9, Opera 11.
* Does not work with IE 7.
*/

.qtip-bootstrap{ /** Taken from Bootstrap body */ font-size: 14px; line-height: 20px; color: #333333;

/** Taken from Bootstrap .popover */ padding: 1px; background-color: #ffffff; border: 1px solid #ccc; border: 1px solid rgba(0, 0, 0, 0.2); -webkit-border-radius: 6px; -moz-border-radius: 6px; border-radius: 6px; -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); -moz-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); -webkit-background-clip: padding-box; -moz-background-clip: padding; background-clip: padding-box; }

.qtip-bootstrap .qtip-titlebar{ /** Taken from Bootstrap .popover-title */ padding: 8px 14px; margin: 0; font-size: 14px; font-weight: normal; line-height: 18px; background-color: #f7f7f7; border-bottom: 1px solid #ebebeb; -webkit-border-radius: 5px 5px 0 0; -moz-border-radius: 5px 5px 0 0; border-radius: 5px 5px 0 0; }

.qtip-bootstrap .qtip-titlebar .qtip-close{ /** * Overrides qTip2: * .qtip-titlebar .qtip-close{ * [...] * right: 4px; * top: 50%; * [...] * border-style: solid; * } */ right: 11px; top: 45%; border-style: none; }

.qtip-bootstrap .qtip-content{ /** Taken from Bootstrap .popover-content */ padding: 9px 14px; }

.qtip-bootstrap .qtip-icon{ /** * Overrides qTip2: * .qtip-default .qtip-icon { * border-color: #CCC; * background: #F1F1F1; * color: #777; * } */ background: transparent; }

.qtip-bootstrap .qtip-icon .ui-icon{ /** * Overrides qTip2: * .qtip-icon .ui-icon{ * width: 18px; * height: 14px; * } */ width: auto; height: auto;

/* Taken from Bootstrap .close */ float: right; font-size: 20px; font-weight: bold; line-height: 18px; color: #000000; text-shadow: 0 1px 0 #ffffff; opacity: 0.2; filter: alpha(opacity=20); }

.qtip-bootstrap .qtip-icon .ui-icon:hover{ /* Taken from Bootstrap .close:hover */ color: #000000; text-decoration: none; cursor: pointer; opacity: 0.4; filter: alpha(opacity=40); }


/* IE9 fix - removes all filters */ .qtip:not(.ie9haxors) div.qtip-content, .qtip:not(.ie9haxors) div.qtip-titlebar{ filter: none; -ms-filter: none; }


.qtip .qtip-tip{ margin: 0 auto; overflow: hidden; z-index: 10;

}

/* Opera bug #357 - Incorrect tip position https://github.com/Craga89/qTip2/issues/367 */ x:-o-prefocus, .qtip .qtip-tip{ visibility: hidden; }

.qtip .qtip-tip, .qtip .qtip-tip .qtip-vml, .qtip .qtip-tip canvas{ position: absolute;

color: #123456; background: transparent; border: 0 dashed transparent; }

.qtip .qtip-tip canvas{ top: 0; left: 0; }

.qtip .qtip-tip .qtip-vml{ behavior: url(#default#VML); display: inline-block; visibility: visible; }

  1. qtip-overlay{

position: fixed; left: 0; top: 0; width: 100%; height: 100%; }

/* Applied to modals with show.modal.blur set to true */ #qtip-overlay.blurs{ cursor: pointer; }

/* Change opacity of overlay here */ #qtip-overlay div{ position: absolute; left: 0; top: 0; width: 100%; height: 100%;

background-color: black;

opacity: 0.7; filter:alpha(opacity=70); -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=70)"; }


.qtipmodal-ie6fix{ position: absolute !important; } /*

* Stylesheet for the markup of glossary terms in wiki pages.
*/

.mw-lingo-tooltip { /*display: inline;*/ position: relative; /*cursor: help;*/ }

.mw-lingo-tooltip-abbr { border-bottom: 1px dotted #bbbbff; cursor: default; }

.mw-lingo-tooltip-abbr:hover { background-color: rgba(0, 0, 0, 0.1); }

.mw-lingo-tooltip-tip { display: none;

/* qtip-default */ border-width: 1px; border-style: solid;

/* qtip shadow */ -webkit-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15); -moz-box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15); box-shadow: 1px 1px 3px 1px rgba(0, 0, 0, 0.15);

/* qtip light */ background-color: white; border-color: #e2e2e2; color: #454545;

/* qtip rounded */ -moz-border-radius: 5px; -webkit-border-radius: 5px; border-radius: 5px; }

.mw-lingo-tooltip-definition { display: block; padding: .5ex 0; }

/* Style for JS disabled browsers*/ .mw-lingo-tooltip:hover .mw-lingo-tooltip-tip { display: block;

position: absolute; top: 1.5em; left: 0;

padding: 5px 9px; z-index: 15000; font-size: smaller; } .mw-lingo-tooltip{position:relative}.mw-lingo-tooltip-abbr{border-bottom:1px dotted #bbbbff;cursor:default}.mw-lingo-tooltip-abbr:hover{background-color:rgba(0,0,0,0.1)}.mw-lingo-tooltip-tip{display:none;border-width:1px;border-style:solid;-webkit-box-shadow:1px 1px 3px 1px rgba(0,0,0,0.15);-moz-box-shadow:1px 1px 3px 1px rgba(0,0,0,0.15);box-shadow:1px 1px 3px 1px rgba(0,0,0,0.15);background-color:white;border-color:#e2e2e2;color:#454545;-moz-border-radius:5px;-webkit-border-radius:5px;border-radius:5px}.mw-lingo-tooltip-definition{display:block;padding:.5ex 0}.mw-lingo-tooltip:hover .mw-lingo-tooltip-tip{display:block;position:absolute;top:1.5em;left:0;padding:5px 9px;z-index:15000;font-size:smaller}.client-nojs #ca-ve-edit,.client-nojs .mw-editsection-divider,.client-nojs .mw-editsection-visualeditor,.ve-not-available #ca-ve-edit,.ve-not-available .mw-editsection-divider,.ve-not-available .mw-editsection-visualeditor{display:none}.client-js .mw-content-ltr .mw-editsection-bracket:first-of-type,.client-js .mw-content-rtl .mw-editsection-bracket:not(:first-of-type){margin-right:0.25em;color:#555}.client-js .mw-content-rtl .mw-editsection-bracket:first-of-type,.client-js .mw-content-ltr .mw-editsection-bracket:not(:first-of-type){margin-left:0.25em;color:#555}@media print{.noprint,div#jump-to-nav,.mw-jump,div.top,div#column-one,.mw-editsection,.mw-editsection-like,.toctoggle,#toc.tochidden,div#f-poweredbyico,div#f-copyrightico,li#about,li#disclaimer,li#mobileview,li#privacy,#footer-places,.mw-hidden-catlinks,.usermessage,.patrollink,.ns-0 .mw-redirectedfrom,#mw-navigation,#siteNotice{display:none}.wikitable,.thumb,img{page-break-inside:avoid}h2,h3,h4,h5,h6{page-break-after:avoid}p{widows:3;orphans:3}body{background:white;color:black;margin:0;padding:0}ul{list-style-type:square}h1,h2,h3,h4,h5,h6{font-weight:bold}dt{font-weight:bold}p{margin:1em 0;line-height:1.2em}pre,.mw-code{border:1pt dashed black;white-space:pre;font-size:8pt;overflow:auto;padding:1em 0;background:white;color:black}#globalWrapper{width:100% !important;min-width:0 !important}.mw-body{background:white;border:none !important;padding:0 !important;margin:0 !important;direction:ltr;color:black}#column-content{margin:0 !important}#column-content .mw-body{padding:1em;margin:0 !important}#toc{border:1px solid #aaaaaa;background-color:#f9f9f9;padding:5px;display:inline-block;display:table;zoom:1;*display:inline}#footer{background:white;color:black;margin-top:1em;border-top:1px solid #AAA;direction:ltr}img{border:none;vertical-align:middle}span.texhtml{font-family:serif}a.stub,a.new{color:#ba0000;text-decoration:none}a{color:black !important;background:none !important;padding:0 !important}a:link,a:visited{color:#520;background:transparent;text-decoration:underline}.mw-body a.external.text:after,.mw-body a.external.autonumber:after{content:" (" attr(href) ")"}.mw-body a.external.text[href^='//']:after,.mw-body a.external.autonumber[href^='//']:after{content:" (https:" attr(href) ")"}a,a.external,a.new,a.stub{color:black !important;text-decoration:none !important}a,a.external,a.new,a.stub{color:inherit !important;text-decoration:inherit !important}div.floatright{float:right;clear:right;position:relative;margin:0.5em 0 0.8em 1.4em}div.floatright p{font-style:italic}div.floatleft{float:left;clear:left;position:relative;margin:0.5em 1.4em 0.8em 0}div.floatleft p{font-style:italic}div.center{text-align:center}div.thumb{border:none;width:auto;margin-top:0.5em;margin-bottom:0.8em;background-color:transparent}div.thumbinner{border:1px solid #cccccc;padding:3px !important;background-color:White;font-size:94%;text-align:center;overflow:hidden}html .thumbimage{border:1px solid #cccccc}html .thumbcaption{border:none;text-align:left;line-height:1.4em;padding:3px !important;font-size:94%}div.magnify{display:none}div.tright{float:right;clear:right;margin:0.5em 0 0.8em 1.4em}div.tleft{float:left;clear:left;margin:0.5em 1.4em 0.8em 0}img.thumbborder{border:1px solid #dddddd}table.wikitable,table.mw_metadata{margin:1em 0;border:1px #aaa solid;background:white;border-collapse:collapse}table.wikitable > tr > th,table.wikitable > tr > td,table.wikitable > * > tr > th,table.wikitable > * > tr > td,.mw_metadata th,.mw_metadata td{border:1px #aaa solid;padding:0.2em}table.wikitable > tr > th,table.wikitable > * > tr > th,.mw_metadata th{text-align:center;background:white;font-weight:bold}table.wikitable > caption,.mw_metadata caption{font-weight:bold}table.listing,table.listing td{border:1pt solid black;border-collapse:collapse}a.sortheader{margin:0 0.3em}.catlinks ul{display:inline;margin:0;padding:0;list-style:none;list-style-type:none;list-style-image:none;vertical-align:middle !ie}.catlinks li{display:inline-block;line-height:1.15em;padding:0 .4em;border-left:1px solid #AAA;margin:0.1em 0;zoom:1;display:inline !ie}.catlinks li:first-child{padding-left:.2em;border-left:none}.printfooter{padding:1em 0 1em 0}}@media screen{.mw-content-ltr{direction:ltr}.mw-content-rtl{direction:rtl}.sitedir-ltr textarea,.sitedir-ltr input{direction:ltr}.sitedir-rtl textarea,.sitedir-rtl input{direction:rtl}.mw-userlink{unicode-bidi:embed}mark{background-color:yellow;color:black}wbr{display:inline-block}input[type="submit"],input[type="button"],input[type="reset"],input[type="file"]{direction:ltr}textarea[dir="ltr"],input[dir="ltr"]{direction:ltr}textarea[dir="rtl"],input[dir="rtl"]{direction:rtl}abbr[title],.explain[title]{border-bottom:1px dotted;cursor:help}@supports (text-decoration:underline dotted){abbr[title],.explain[title]{border-bottom:none;text-decoration:underline dotted}}.mw-plusminus-pos{color:#006400}.mw-plusminus-neg{color:#8b0000}.mw-plusminus-null{color:#aaa}.mw-plusminus-pos,.mw-plusminus-neg,.mw-plusminus-null{unicode-bidi:-moz-isolate;unicode-bidi:-webkit-isolate;unicode-bidi:isolate}.allpagesredirect,.redirect-in-category,.watchlistredir{font-style:italic}span.comment{font-style:italic}.texvc{direction:ltr;unicode-bidi:embed}img.tex{vertical-align:middle}span.texhtml{font-family:serif}#wikiPreview.ontop{margin-bottom:1em}#editform,#toolbar,#wpTextbox1{clear:both}li span.deleted,span.history-deleted{text-decoration:line-through;color:#888;font-style:italic}.not-patrolled{background-color:#ffa}.unpatrolled{font-weight:bold;color:red}div.patrollink{font-size:75%;text-align:right}td.mw-label{text-align:right}td.mw-input{text-align:left}td.mw-submit{text-align:left}td.mw-label{vertical-align:middle}td.mw-submit{white-space:nowrap}input#wpSummary{width:80%;margin-bottom:1em}.mw-content-ltr .thumbcaption{text-align:left}.mw-content-ltr .magnify{float:right}.mw-content-rtl .thumbcaption{text-align:right}.mw-content-rtl .magnify{float:left}#catlinks{text-align:left}.catlinks ul{display:inline;margin:0;padding:0;list-style:none;list-style-type:none;list-style-image:none;vertical-align:middle !ie}.catlinks li{display:inline-block;line-height:1.25em;border-left:1px solid #AAA;margin:0.125em 0;padding:0 0.5em;zoom:1;display:inline !ie}.catlinks li:first-child{padding-left:0.25em;border-left:none}.catlinks li a.mw-redirect{font-style:italic}.mw-hidden-cats-hidden{display:none}.catlinks-allhidden{display:none}p.mw-ipb-conveniencelinks,p.mw-protect-editreasons,p.mw-filedelete-editreasons,p.mw-delete-editreasons,p.mw-revdel-editreasons,p.mw-upload-editlicenses{font-size:90%;text-align:right}.autocomment{color:gray}#pagehistory .history-user{margin-left:0.4em;margin-right:0.2em}#pagehistory span.minor{font-weight:bold}#pagehistory li{border:1px solid white}#pagehistory li.selected{background-color:#f9f9f9;border:1px dashed #aaa}.mw-history-revisionactions,#mw-fileduplicatesearch-icon{float:right}.newpage,.minoredit,.botedit{font-weight:bold}div.mw-warning-with-logexcerpt{padding:3px;margin-bottom:3px;border:2px solid #2F6FAB;clear:both}div.mw-warning-with-logexcerpt ul li{font-size:90%}span.mw-revdelundel-link,strong.mw-revdelundel-link{font-size:90%}span.mw-revdelundel-hidden,input.mw-revdelundel-hidden{visibility:hidden}td.mw-revdel-checkbox,th.mw-revdel-checkbox{padding-right:10px;text-align:center}a.new{color:#BA0000}.plainlinks a.external{background:none !important;padding:0 !important}.rtl a.external.free,.rtl a.external.autonumber{direction:ltr;unicode-bidi:embed}table.wikitable{margin:1em 0;background-color:#f9f9f9;border:1px solid #aaa;border-collapse:collapse;color:black}table.wikitable > tr > th,table.wikitable > tr > td,table.wikitable > * > tr > th,table.wikitable > * > tr > td{border:1px solid #aaa;padding:0.2em 0.4em}table.wikitable > tr > th,table.wikitable > * > tr > th{background-color:#f2f2f2;text-align:center}table.wikitable > caption{font-weight:bold}.error,.warning,.success{font-size:larger}.error{color:#cc0000}.warning{color:#705000}.success{color:#009000}.errorbox,.warningbox,.successbox{border:1px solid;padding:.5em 1em;margin-bottom:1em;display:inline-block;zoom:1;*display:inline}.errorbox h2,.warningbox h2,.successbox h2{font-size:1em;color:inherit;font-weight:bold;display:inline;margin:0 .5em 0 0;border:none}.errorbox{color:#cc0000;border-color:#fac5c5;background-color:#fae3e3}.warningbox{color:#705000;border-color:#fde29b;background-color:#fdf1d1}.successbox{color:#008000;border-color:#b7fdb5;background-color:#e1fddf}.mw-infobox{border:2px solid #ff7f00;margin:0.5em;clear:left;overflow:hidden}.mw-infobox-left{margin:7px;float:left;width:35px}.mw-infobox-right{margin:0.5em 0.5em 0.5em 49px}.previewnote{color:#c00;margin-bottom:1em}.previewnote p{text-indent:3em;margin:0.8em 0}.visualClear{clear:both}.mw-datatable{border-collapse:collapse}.mw-datatable,.mw-datatable td,.mw-datatable th{border:1px solid #aaaaaa;padding:0 0.15em 0 0.15em}.mw-datatable th{background-color:#ddddff}.mw-datatable td{background-color:#ffffff}.mw-datatable tr:hover td{background-color:#eeeeff}table.mw_metadata{font-size:0.8em;margin-left:0.5em;margin-bottom:0.5em;width:400px}table.mw_metadata caption{font-weight:bold}table.mw_metadata th{font-weight:normal}table.mw_metadata td{padding:0.1em}table.mw_metadata{border:none;border-collapse:collapse}table.mw_metadata td,table.mw_metadata th{text-align:center;border:1px solid #aaaaaa;padding-left:5px;padding-right:5px}table.mw_metadata th{background-color:#f9f9f9}table.mw_metadata td{background-color:#fcfcfc}table.mw_metadata ul.metadata-langlist{list-style-type:none;list-style-image:none;padding-right:5px;padding-left:5px;margin:0}.mw-content-ltr ul,.mw-content-rtl .mw-content-ltr ul{margin:0.3em 0 0 1.6em;padding:0}.mw-content-rtl ul,.mw-content-ltr .mw-content-rtl ul{margin:0.3em 1.6em 0 0;padding:0}.mw-content-ltr ol,.mw-content-rtl .mw-content-ltr ol{margin:0.3em 0 0 3.2em;padding:0}.mw-content-rtl ol,.mw-content-ltr .mw-content-rtl ol{margin:0.3em 3.2em 0 0;padding:0}.mw-content-ltr dd,.mw-content-rtl .mw-content-ltr dd{margin-left:1.6em;margin-right:0}.mw-content-rtl dd,.mw-content-ltr .mw-content-rtl dd{margin-right:1.6em;margin-left:0}.mw-ajax-loader{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/ajax-loader.gif?57f34);background-position:center center;background-repeat:no-repeat;padding:16px;position:relative;top:-16px}.mw-small-spinner{padding:10px !important;margin-right:0.6em;background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/spinner.gif?ca65b);background-position:center center;background-repeat:no-repeat}h1:lang(anp),h1:lang(as),h1:lang(bh),h1:lang(bho),h1:lang(bn),h1:lang(gu),h1:lang(hi),h1:lang(kn),h1:lang(ks),h1:lang(ml),h1:lang(mr),h1:lang(my),h1:lang(mai),h1:lang(ne),h1:lang(new),h1:lang(or),h1:lang(pa),h1:lang(pi),h1:lang(sa),h1:lang(ta),h1:lang(te){line-height:1.6em !important}h2:lang(anp),h3:lang(anp),h4:lang(anp),h5:lang(anp),h6:lang(anp),h2:lang(as),h3:lang(as),h4:lang(as),h5:lang(as),h6:lang(as),h2:lang(bho),h3:lang(bho),h4:lang(bho),h5:lang(bho),h6:lang(bho),h2:lang(bh),h3:lang(bh),h4:lang(bh),h5:lang(bh),h6:lang(bh),h2:lang(bn),h3:lang(bn),h4:lang(bn),h5:lang(bn),h6:lang(bn),h2:lang(gu),h3:lang(gu),h4:lang(gu),h5:lang(gu),h6:lang(gu),h2:lang(hi),h3:lang(hi),h4:lang(hi),h5:lang(hi),h6:lang(hi),h2:lang(kn),h3:lang(kn),h4:lang(kn),h5:lang(kn),h6:lang(kn),h2:lang(ks),h3:lang(ks),h4:lang(ks),h5:lang(ks),h6:lang(ks),h2:lang(ml),h3:lang(ml),h4:lang(ml),h5:lang(ml),h6:lang(ml),h2:lang(mr),h3:lang(mr),h4:lang(mr),h5:lang(mr),h6:lang(mr),h2:lang(my),h3:lang(my),h4:lang(my),h5:lang(my),h6:lang(my),h2:lang(mai),h3:lang(mai),h4:lang(mai),h5:lang(mai),h6:lang(mai),h2:lang(ne),h3:lang(ne),h4:lang(ne),h5:lang(ne),h6:lang(ne),h2:lang(new),h3:lang(new),h4:lang(new),h5:lang(new),h6:lang(new),h2:lang(or),h3:lang(or),h4:lang(or),h5:lang(or),h6:lang(or),h2:lang(pa),h3:lang(pa),h4:lang(pa),h5:lang(pa),h6:lang(pa),h2:lang(pi),h3:lang(pi),h4:lang(pi),h5:lang(pi),h6:lang(pi),h2:lang(sa),h3:lang(sa),h4:lang(sa),h5:lang(sa),h6:lang(sa),h2:lang(ta),h3:lang(ta),h4:lang(ta),h5:lang(ta),h6:lang(ta),h2:lang(te),h3:lang(te),h4:lang(te),h5:lang(te),h6:lang(te){line-height:1.2em}ol:lang(azb) li,ol:lang(bcc) li,ol:lang(bgn) li,ol:lang(bqi) li,ol:lang(fa) li,ol:lang(glk) li,ol:lang(kk-arab) li,ol:lang(lrc) li,ol:lang(luz) li,ol:lang(mzn) li{list-style-type:-moz-persian;list-style-type:persian}ol:lang(ckb) li,ol:lang(sdh) li{list-style-type:-moz-arabic-indic;list-style-type:arabic-indic}ol:lang(hi) li,ol:lang(mr) li{list-style-type:-moz-devanagari;list-style-type:devanagari}ol:lang(as) li,ol:lang(bn) li{list-style-type:-moz-bengali;list-style-type:bengali}ol:lang(or) li{list-style-type:-moz-oriya;list-style-type:oriya}#toc ul,.toc ul{margin:.3em 0}.mw-content-ltr .toc ul,.mw-content-ltr #toc ul,.mw-content-rtl .mw-content-ltr .toc ul,.mw-content-rtl .mw-content-ltr #toc ul{text-align:left}.mw-content-rtl .toc ul,.mw-content-rtl #toc ul,.mw-content-ltr .mw-content-rtl .toc ul,.mw-content-ltr .mw-content-rtl #toc ul{text-align:right}.mw-content-ltr .toc ul ul,.mw-content-ltr #toc ul ul,.mw-content-rtl .mw-content-ltr .toc ul ul,.mw-content-rtl .mw-content-ltr #toc ul ul{margin:0 0 0 2em}.mw-content-rtl .toc ul ul,.mw-content-rtl #toc ul ul,.mw-content-ltr .mw-content-rtl .toc ul ul,.mw-content-ltr .mw-content-rtl #toc ul ul{margin:0 2em 0 0}#toc #toctitle,.toc #toctitle,#toc .toctitle,.toc .toctitle{direction:ltr}.mw-help-field-hint{display:none;margin-left:2px;margin-bottom:-8px;padding:0 0 0 15px;background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/help-question.gif?346d8);background-position:left center;background-repeat:no-repeat;cursor:pointer;font-size:.8em;text-decoration:underline;color:#0645ad}.mw-help-field-hint:hover{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.legacy/images/help-question-hover.gif?53eb5)}.mw-help-field-data{display:block;background-color:#d6f3ff;padding:5px 8px 4px 8px;border:1px solid #5dc9f4;margin-left:20px}#mw-clearyourcache,#mw-sitecsspreview,#mw-sitejspreview,#mw-usercsspreview,#mw-userjspreview{direction:ltr;unicode-bidi:embed}.diff-currentversion-title,.diff{direction:ltr;unicode-bidi:embed}.diff-contentalign-right td{direction:rtl;unicode-bidi:embed}.diff-contentalign-left td{direction:ltr;unicode-bidi:embed}.diff-multi,.diff-otitle,.diff-ntitle,.diff-lineno{direction:ltr !important;unicode-bidi:embed}#mw-revision-info,#mw-revision-info-current,#mw-revision-nav{direction:ltr;display:inline}div.tright,div.floatright,table.floatright{clear:right;float:right}div.tleft,div.floatleft,table.floatleft{float:left;clear:left}div.floatright,table.floatright,div.floatleft,table.floatleft{position:relative}#mw-credits a{unicode-bidi:embed}.mw-jump,#jump-to-nav{overflow:hidden;height:0;zoom:1}.printfooter{display:none}.xdebug-error{position:absolute;z-index:99}.mw-editsection,.toctoggle,.tochidden,#jump-to-nav{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.mw-editsection,.mw-editsection-like{font-size:small;font-weight:normal;margin-left:1em;vertical-align:baseline;line-height:1em;display:inline-block}.mw-content-ltr .mw-editsection,.mw-content-rtl .mw-content-ltr .mw-editsection{margin-left:1em}.mw-content-rtl .mw-editsection,.mw-content-ltr .mw-content-rtl .mw-editsection{margin-right:1em}sup,sub{line-height:1}}.mw-headline-anchor{display:none}@media screen{.mw-headline-anchor{margin-left:-16px;width:16px}.mw-content-ltr .mw-headline-anchor,.mw-content-rtl .mw-content-ltr .mw-headline-anchor{margin-left:-16px;margin-right:0}.mw-content-rtl .mw-headline-anchor,.mw-content-ltr .mw-content-rtl .mw-headline-anchor{margin-left:0;margin-right:-16px}}@media screen and (min-width:982px){.mw-headline-anchor{margin-left:-20px;width:20px}.mw-content-ltr .mw-headline-anchor,.mw-content-rtl .mw-content-ltr .mw-headline-anchor{margin-left:-20px;margin-right:0}.mw-content-rtl .mw-headline-anchor,.mw-content-ltr .mw-content-rtl .mw-headline-anchor{margin-left:0;margin-right:-20px}}@media screen{a{text-decoration:none;color:#0645ad;background:none}a:visited{color:#0b0080}a:active{color:#faa700}a:hover,a:focus{text-decoration:underline}a.stub{color:#772233}a.new,#p-personal a.new{color:#ba0000}a.new:visited,#p-personal a.new:visited{color:#a55858}.mw-body a.extiw,.mw-body a.extiw:active{color:#36b}.mw-body a.extiw:visited{color:#636}.mw-body a.extiw:active{color:#b63}.mw-body a.external{color:#36b}.mw-body a.external:visited{color:#636}.mw-body a.external:active{color:#b63}.mw-body a.external.free{word-wrap:break-word}img{border:none;vertical-align:middle}hr{height:1px;color:#aaa;background-color:#aaa;border:0;margin:.2em 0}h1,h2,h3,h4,h5,h6{color:black;background:none;font-weight:normal;margin:0;overflow:hidden;padding-top:.5em;padding-bottom:.17em;border-bottom:1px solid #aaa}h1{font-size:188%}h2{font-size:150%}h3,h4,h5,h6{border-bottom:none;font-weight:bold}h3{font-size:128%}h4{font-size:116%}h5{font-size:108%}h6{font-size:100%}h1,h2{margin-bottom:.6em}h3,h4,h5{margin-bottom:.3em}p{margin:.4em 0 .5em 0}p img{margin:0}ul{list-style-type:square;margin:.3em 0 0 1.6em;padding:0}ol{margin:.3em 0 0 3.2em;padding:0;list-style-image:none}li{margin-bottom:.1em}dt{font-weight:bold;margin-bottom:.1em}dl{margin-top:.2em;margin-bottom:.5em}dd{margin-left:1.6em;margin-bottom:.1em}pre,code,tt,kbd,samp,.mw-code{font-family:monospace,Courier}code{color:black;background-color:#f9f9f9;border:1px solid #ddd;border-radius:2px;padding:1px 4px}pre,.mw-code{color:black;background-color:#f9f9f9;border:1px solid #ddd;padding:1em;white-space:pre-wrap}table{font-size:100%}fieldset{border:1px solid #2f6fab;margin:1em 0 1em 0;padding:0 1em 1em}fieldset.nested{margin:0 0 0.5em 0;padding:0 0.5em 0.5em}legend{padding:.5em;font-size:95%}form{border:none;margin:0}textarea{width:100%;padding:.1em;display:block;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.center{width:100%;text-align:center}*.center *{margin-left:auto;margin-right:auto}.small{font-size:94%}table.small{font-size:100%}#toc,.toc,.mw-warning,.toccolours{border:1px solid #aaa;background-color:#f9f9f9;padding:5px;font-size:95%}#toc,.toc{display:inline-block;display:table;zoom:1;*display:inline;padding:7px}table#toc,table.toc{border-collapse:collapse}table#toc td,table.toc td{padding:0}#toc h2,.toc h2{display:inline;border:none;padding:0;font-size:100%;font-weight:bold}#toc #toctitle,.toc #toctitle,#toc .toctitle,.toc .toctitle{text-align:center}#toc ul,.toc ul{list-style-type:none;list-style-image:none;margin-left:0;padding:0;text-align:left}#toc ul ul,.toc ul ul{margin:0 0 0 2em}#toc .toctoggle,.toc .toctoggle{font-size:94%}.mw-warning{margin-left:50px;margin-right:50px;text-align:center}div.floatright,table.floatright{margin:0 0 .5em .5em;border:0}div.floatright p{font-style:italic}div.floatleft,table.floatleft{margin:0 .5em .5em 0;border:0}div.floatleft p{font-style:italic}div.thumb{margin-bottom:.5em;width:auto;background-color:transparent}div.thumbinner{border:1px solid #ccc;padding:3px;background-color:#f9f9f9;font-size:94%;text-align:center;overflow:hidden}html .thumbimage{border:1px solid #ccc}html .thumbcaption{border:none;line-height:1.4em;padding:3px;font-size:94%;text-align:left}div.magnify{float:right;margin-left:3px}div.magnify a{display:block;text-indent:15px;white-space:nowrap;overflow:hidden;width:15px;height:11px;background-image:url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.png?b5711);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}img.thumbborder{border:1px solid #dddddd}.mw-content-ltr .thumbcaption{text-align:left}.mw-content-ltr .magnify{float:right;margin-left:3px;margin-right:0}.mw-content-ltr div.magnify a{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.png?b5711);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M1.509%201.865h10.99v7.919h-10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M-1.499%206.868h5.943v4.904h-5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-ltr.svg?7fa0a)!ie}.mw-content-rtl .thumbcaption{text-align:right}.mw-content-rtl .magnify{float:left;margin-left:0;margin-right:3px}.mw-content-rtl div.magnify a{background-image:url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-rtl.png?27d60);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M9.491%201.865h-10.99v7.919h10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M12.499%206.868h-5.943v4.904h5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-rtl.svg?96de0)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%20standalone%3D%22no%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2011%2015%22%20width%3D%2215%22%20height%3D%2211%22%3E%0A%20%20%20%20%3Cg%20id%3D%22magnify-clip%22%20fill%3D%22%23fff%22%20stroke%3D%22%23000%22%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22bigbox%22%20d%3D%22M9.491%201.865h-10.99v7.919h10.99z%22%2F%3E%0A%20%20%20%20%20%20%20%20%3Cpath%20id%3D%22smallbox%22%20d%3D%22M12.499%206.868h-5.943v4.904h5.943z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/resources/src/mediawiki.skinning/images/magnify-clip-rtl.svg?96de0)!ie}div.tright{margin:.5em 0 1.3em 1.4em}div.tleft{margin:.5em 1.4em 1.3em 0}.catlinks{border:1px solid #aaa;background-color:#f9f9f9;padding:5px;margin-top:1em;clear:both}.editOptions{background-color:#F0F0F0;border:1px solid silver;border-top:none;padding:1em 1em 1.5em 1em;margin-bottom:2em}.usermessage{background-color:#ffce7b;border:1px solid #ffa500;color:black;font-weight:bold;margin:2em 0 1em;padding:.5em 1em;vertical-align:middle}#siteNotice{position:relative;text-align:center;margin:0}#localNotice{margin-bottom:0.9em}.firstHeading{margin-bottom:.1em;line-height:1.2em;padding-bottom:0}#siteSub{display:none}#jump-to-nav{margin-top:-1.4em;margin-bottom:1.4em}#contentSub,#contentSub2{font-size:84%;line-height:1.2em;margin:0 0 1.4em 1em;color:#545454;width:auto}span.subpages{display:block}}.mw-wiki-logo{background-image:url(http://www.cnbguatemala.org/images/7/70/logo_cnb.png)}@media screen{html{font-size:100%}html,body{height:100%;margin:0;padding:0;font-family:sans-serif}body{background-color:#FFF}.mw-body{margin-left:10em;padding:1em;border:1px solid #a7d7f9;border-right-width:0;margin-top:-1px;background-color:#ffffff;color:#252525;direction:ltr}.mw-body .mw-editsection,.mw-body .mw-editsection-like{font-family:sans-serif}.mw-body p{line-height:inherit;margin:0.5em 0}.mw-body h1,.mw-body h2{font-family:"Linux Libertine",Georgia,Times,serif;line-height:1.3;margin-bottom:0.25em;padding:0}.mw-body h1{font-size:1.8em}.mw-body .mw-body-content h1{margin-top:1em}.mw-body h2{font-size:1.5em;margin-top:1em}.mw-body h3,.mw-body h4,.mw-body h5,.mw-body h6{line-height:1.6;margin-top:0.3em;margin-bottom:0;padding-bottom:0}.mw-body h3{font-size:1.2em}.mw-body h3,.mw-body h4{font-weight:bold}.mw-body h4,.mw-body h5,.mw-body h6{font-size:100%}.mw-body #toc h2,.mw-body .toc h2{font-size:100%;font-family:sans-serif}.mw-body .firstHeading{overflow:visible}.mw-body .mw-indicators{float:right;line-height:1.6;font-size:0.875em;position:relative;z-index:1}.mw-body .mw-indicator{display:inline-block;zoom:1;*display:inline}div.emptyPortlet{display:none}ul{list-style-type:disc;list-style-image:url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%0A%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20version%3D%221.1%22%20width%3D%225%22%20height%3D%2213%22%3E%0A%3Ccircle%20cx%3D%222.5%22%20cy%3D%229.5%22%20r%3D%222.5%22%20fill%3D%22%2300528c%22%2F%3E%0A%3C%2Fsvg%3E%0A);list-style-image:url(http://cnbguatemala.org/skins/Vector/images/bullet-icon.svg?90d59)!ie;list-style-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAANAQMAAABb8jbLAAAABlBMVEX///8AUow5QSOjAAAAAXRSTlMAQObYZgAAABNJREFUCB1jYEABBQw/wLCAgQEAGpIDyT0IVcsAAAAASUVORK5CYII=) \9;list-style-image:url(http://cnbguatemala.org/skins/Vector/images/bullet-icon.png?785dd) \9!ie}pre,.mw-code{line-height:1.3em}#siteNotice{font-size:0.8em}.redirectText{font-size:140%}.mw-body-content{position:relative;line-height:1.6;font-size:0.875em;z-index:0}#p-personal{position:absolute;top:0.33em;right:0.75em;z-index:100}#p-personal h3{display:none}#p-personal ul{list-style-type:none;list-style-image:none;margin:0;padding-left:10em}#p-personal li{line-height:1.125em;float:left;margin-left:0.75em;margin-top:0.5em;font-size:0.75em;white-space:nowrap}#pt-userpage,#pt-anonuserpage{background-position:left top;background-repeat:no-repeat;background-image:url(http://cnbguatemala.org/skins/Vector/images/user-icon.png?9e7ea);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3C%21DOCTYPE%20svg%20PUBLIC%20%22-%2F%2FW3C%2F%2FDTD%20SVG%201.1%2F%2FEN%22%20%22http%3A%2F%2Fwww.w3.org%2FGraphics%2FSVG%2F1.1%2FDTD%2Fsvg11.dtd%22%3E%0A%3Csvg%20version%3D%221.1%22%20id%3D%22Layer_1%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20x%3D%220px%22%20y%3D%220px%22%0A%09%20width%3D%2212px%22%20height%3D%2213.836px%22%20viewBox%3D%220%200%2012%2013.836%22%20enable-background%3D%22new%200%200%2012%2013.836%22%20xml%3Aspace%3D%22preserve%22%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M1.938%2C6.656c-1.32%2C1.485-1.47%2C3.15-0.97%2C4.25c0.323%2C0.707%2C0.78%2C1.127%2C1.313%2C1.375%0A%09c0.496%2C0.229%2C1.074%2C0.273%2C1.658%2C0.282c0.023%2C0%2C0.04%2C0.03%2C0.062%2C0.03h4.187c0.61%2C0%2C1.225-0.125%2C1.75-0.405%0A%09c0.527-0.28%2C0.961-0.718%2C1.188-1.376c0.335-0.964%2C0.175-2.529-1.094-4.03C9.094%2C7.954%2C7.68%2C8.719%2C6.065%2C8.719%0A%09c-1.677%2C0-3.182-0.812-4.125-2.063H1.938z%22%2F%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M6.063%2C0c-1.89%2C0-3.595%2C1.674-3.594%2C3.563C2.467%2C5.45%2C4.173%2C7.155%2C6.06%2C7.155%0A%09c1.89%2C0%2C3.564-1.705%2C3.563-3.593C9.625%2C1.673%2C7.95%2C0%2C6.063%2C0L6.063%2C0z%22%2F%3E%0A%3C%2Fsvg%3E%0A);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/user-icon.svg?7b5d5)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3C%21DOCTYPE%20svg%20PUBLIC%20%22-%2F%2FW3C%2F%2FDTD%20SVG%201.1%2F%2FEN%22%20%22http%3A%2F%2Fwww.w3.org%2FGraphics%2FSVG%2F1.1%2FDTD%2Fsvg11.dtd%22%3E%0A%3Csvg%20version%3D%221.1%22%20id%3D%22Layer_1%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20x%3D%220px%22%20y%3D%220px%22%0A%09%20width%3D%2212px%22%20height%3D%2213.836px%22%20viewBox%3D%220%200%2012%2013.836%22%20enable-background%3D%22new%200%200%2012%2013.836%22%20xml%3Aspace%3D%22preserve%22%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M1.938%2C6.656c-1.32%2C1.485-1.47%2C3.15-0.97%2C4.25c0.323%2C0.707%2C0.78%2C1.127%2C1.313%2C1.375%0A%09c0.496%2C0.229%2C1.074%2C0.273%2C1.658%2C0.282c0.023%2C0%2C0.04%2C0.03%2C0.062%2C0.03h4.187c0.61%2C0%2C1.225-0.125%2C1.75-0.405%0A%09c0.527-0.28%2C0.961-0.718%2C1.188-1.376c0.335-0.964%2C0.175-2.529-1.094-4.03C9.094%2C7.954%2C7.68%2C8.719%2C6.065%2C8.719%0A%09c-1.677%2C0-3.182-0.812-4.125-2.063H1.938z%22%2F%3E%0A%3Cpath%20fill%3D%22%23777777%22%20d%3D%22M6.063%2C0c-1.89%2C0-3.595%2C1.674-3.594%2C3.563C2.467%2C5.45%2C4.173%2C7.155%2C6.06%2C7.155%0A%09c1.89%2C0%2C3.564-1.705%2C3.563-3.593C9.625%2C1.673%2C7.95%2C0%2C6.063%2C0L6.063%2C0z%22%2F%3E%0A%3C%2Fsvg%3E%0A);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/user-icon.svg?7b5d5)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/user-icon.png?9e7ea);padding-left:15px !important}#p-search{float:left;margin-right:0.5em;margin-left:0.5em}#p-search h3{display:none}#p-search form,#p-search input{margin:0;margin-top:0.4em}div#simpleSearch{display:block;width:12.6em;padding-right:1.4em;height:1.4em;margin-top:0.65em;position:relative;min-height:1px;border:solid 1px #aaa;color:black;background-color:white;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAQCAIAAABY/YLgAAAAJUlEQVQIHQXBsQEAAAjDoND/73UWdnerhmHVsDQZJrNWVg3Dqge6bgMe6bejNAAAAABJRU5ErkJggg==);background-image:url(http://cnbguatemala.org/skins/Vector/images/search-fade.png?50f7b)!ie;background-position:top left;background-repeat:repeat-x}div#simpleSearch input{margin:0;padding:0;border:0;background-color:transparent;color:black}div#simpleSearch #searchInput{width:100%;padding:0.2em 0 0.2em 0.2em;font-size:13px;direction:ltr;-webkit-appearance:textfield}div#simpleSearch #searchInput:focus{outline:none}div#simpleSearch #searchInput.placeholder{color:#999}div#simpleSearch #searchInput:-ms-input-placeholder{color:#999}div#simpleSearch #searchInput:-moz-placeholder{color:#999}div#simpleSearch #searchInput::-webkit-search-decoration,div#simpleSearch #searchInput::-webkit-search-cancel-button,div#simpleSearch #searchInput::-webkit-search-results-button,div#simpleSearch #searchInput::-webkit-search-results-decoration{-webkit-appearance:textfield}div#simpleSearch #searchButton,div#simpleSearch #mw-searchButton{position:absolute;top:0;right:0;width:1.65em;height:100%;cursor:pointer;text-indent:-99999px;line-height:1;direction:ltr;white-space:nowrap;overflow:hidden;background-image:url(http://cnbguatemala.org/skins/Vector/images/search-ltr.png?511c1);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2212%22%20height%3D%2213%22%3E%3Cg%20stroke-width%3D%222%22%20stroke%3D%22%236c6c6c%22%20fill%3D%22none%22%3E%3Cpath%20d%3D%22M11.29%2011.71l-4-4%22%2F%3E%3Ccircle%20cx%3D%225%22%20cy%3D%225%22%20r%3D%224%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/search-ltr.svg?07752)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2212%22%20height%3D%2213%22%3E%3Cg%20stroke-width%3D%222%22%20stroke%3D%22%236c6c6c%22%20fill%3D%22none%22%3E%3Cpath%20d%3D%22M11.29%2011.71l-4-4%22%2F%3E%3Ccircle%20cx%3D%225%22%20cy%3D%225%22%20r%3D%224%22%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/search-ltr.svg?07752)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/search-ltr.png?511c1);background-position:center center;background-repeat:no-repeat}div#simpleSearch #mw-searchButton{z-index:1}div.vectorTabs h3{display:none}div.vectorTabs{float:left;height:2.5em;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-position:bottom left;background-repeat:no-repeat;padding-left:1px}div.vectorTabs ul{float:left;height:100%;list-style-type:none;list-style-image:none;margin:0;padding:0;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-position:right bottom;background-repeat:no-repeat}div.vectorTabs ul li{float:left;line-height:1.125em;display:inline-block;height:100%;margin:0;padding:0;background-color:#f3f3f3;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAABkCAIAAADITs03AAAAPElEQVR4XuWK2xEAIAzCsPvv5DSu0ahX3yv4wQVyGGCSvg2dnJvduT8sz/IwKOIfjCi2z/76FhHeJcslVZQFLUC06LZ/AAAAAElFTkSuQmCC);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-normal-fade.png?ae13b)!ie;background-position:bottom left;background-repeat:repeat-x;white-space:nowrap}div.vectorTabs ul > li{display:block}div.vectorTabs li{}div.vectorTabs li.new a,div.vectorTabs li.new a:visited{color:#a55858}div.vectorTabs li.selected{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAABkAQAAAABvV2fNAAAADUlEQVQIHWNoYBgWEACJ5TIB0K9KcAAAAABJRU5ErkJggg==);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-current-fade.png?98160)!ie}div.vectorTabs li.selected a,div.vectorTabs li.selected a:visited{color:#333;text-decoration:none}div.vectorTabs li.icon a{background-position:bottom right;background-repeat:no-repeat}div.vectorTabs li a{display:inline-block;height:1.9em;padding-left:0.5em;padding-right:0.5em;color:#0645ad;cursor:pointer;font-size:0.8em}div.vectorTabs li > a{display:block}div.vectorTabs span{display:inline-block;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-position:bottom right;background-repeat:no-repeat}div.vectorTabs span a{display:inline-block;padding-top:1.25em}div.vectorTabs span > a{float:left;display:block}div.vectorMenu{direction:ltr;float:left;cursor:pointer;position:relative}body.rtl div.vectorMenu{direction:rtl}div#mw-head div.vectorMenu h3{float:left;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAAuCAIAAABmjeQ9AAAARElEQVR42mVO2wrAUAhy/f8fz+niVMTYQ3hLKkgGgN/IPvgIhUYYV/qogdP75J01V+JwrKZr/5YPcnzN3e6t7l+2K+EFX91B1daOi7sAAAAASUVORK5CYII=);background-image:url(http://cnbguatemala.org/skins/Vector/images/tab-break.png?2df0f)!ie;background-repeat:no-repeat;background-position:bottom right;font-size:1em;height:2.5em;padding-right:1px;margin-right:-1px}div.vectorMenu h3 span{display:block;font-size:0.8em;padding-left:0.7em;padding-top:1.375em;margin-right:20px;font-weight:normal;color:#4d4d4d}div.vectorMenu h3 a{position:absolute;top:0;right:0;width:20px;height:2.5em;background-image:url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.png?feb5c);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23797979%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.svg?92f5b)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23797979%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.svg?92f5b)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-icon.png?feb5c);background-position:100% 70%;background-repeat:no-repeat;-webkit-transition:background-position 250ms;-moz-transition:background-position 250ms;-o-transition:background-position 250ms;transition:background-position 250ms}div.vectorMenu.menuForceShow h3 a{background-position:100% 100%}div.vectorMenuFocus h3 a{background-image:url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.png?5c03c);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23929292%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.svg?6cc06)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2222%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M15.502%206.001l-5%205.001-5-5.001z%22%20fill%3D%22%23929292%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.svg?6cc06)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/arrow-down-focus-icon.png?5c03c)}div.vectorMenu div.menu{min-width:100%;position:absolute;top:2.5em;left:-1px;background-color:white;border:solid 1px silver;border-top-width:0;clear:both;text-align:left;display:none;z-index:1}div.vectorMenu:hover div.menu,div.vectorMenu.menuForceShow div.menu{display:block}div.vectorMenu ul{list-style-type:none;list-style-image:none;padding:0;margin:0;text-align:left}div.vectorMenu ul,x:-moz-any-link{min-width:5em}div.vectorMenu ul,x:-moz-any-link,x:default{min-width:0}div.vectorMenu li{padding:0;margin:0;text-align:left;line-height:1em}div.vectorMenu li a{display:inline-block;padding:0.5em;white-space:nowrap;color:#0645ad;cursor:pointer;font-size:0.8em}div.vectorMenu li > a{display:block}div.vectorMenu li.selected a,div.vectorMenu li.selected a:visited{color:#333;text-decoration:none}@-webkit-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-moz-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@-o-keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes rotate{from{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);transform:rotate(360deg)}}#ca-unwatch.icon a,#ca-watch.icon a{margin:0;padding:0;display:block;width:26px;padding-top:3.1em;margin-top:0;_margin-top:-0.8em;height:0;overflow:hidden;background-position:5px 60%}#ca-unwatch.icon a{background-image:url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.png?c2550);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.svg?95d18)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.svg?95d18)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon.png?c2550)}#ca-watch.icon a{background-image:url(http://cnbguatemala.org/skins/Vector/images/watch-icon.png?0c329);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon.svg?200b7)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%237cb5d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon.svg?200b7)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon.png?0c329)}#ca-unwatch.icon a:hover,#ca-unwatch.icon a:focus{background-image:url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.png?f1f1e);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.svg?a3932)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cdefs%3E%3ClinearGradient%20id%3D%22a%22%3E%3Cstop%20offset%3D%220%22%20stop-color%3D%22%23c2edff%22%2F%3E%3Cstop%20offset%3D%22.5%22%20stop-color%3D%22%2368bdff%22%2F%3E%3Cstop%20offset%3D%221%22%20stop-color%3D%22%23fff%22%2F%3E%3C%2FlinearGradient%3E%3ClinearGradient%20x1%3D%2213.47%22%20y1%3D%2214.363%22%20x2%3D%224.596%22%20y2%3D%223.397%22%20id%3D%22b%22%20xlink%3Ahref%3D%22%23a%22%20gradientUnits%3D%22userSpaceOnUse%22%2F%3E%3C%2Fdefs%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22url%28%23b%29%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.svg?a3932)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/unwatch-icon-hl.png?f1f1e)}#ca-watch.icon a:hover,#ca-watch.icon a:focus{background-image:url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.png?df008);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.svg?2b77d)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23c8b250%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.svg?2b77d)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-hl.png?df008)}#ca-unwatch.icon a.loading,#ca-watch.icon a.loading{background-image:url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.png?cf2c3);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23d1d1d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.svg?6ca63)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2216%22%20height%3D%2216%22%3E%3Cpath%20d%3D%22M8.103%201.146l2.175%204.408%204.864.707-3.52%203.431.831%204.845-4.351-2.287-4.351%202.287.831-4.845-3.52-3.431%204.864-.707z%22%20fill%3D%22%23fff%22%20stroke%3D%22%23d1d1d1%22%20stroke-width%3D%220.9999199999999999%22%2F%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.svg?6ca63)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/watch-icon-loading.png?cf2c3);-webkit-animation:rotate 700ms infinite linear;-moz-animation:rotate 700ms infinite linear;-o-animation:rotate 700ms infinite linear;animation:rotate 700ms infinite linear;outline:none;cursor:default;pointer-events:none;background-position:50% 60%;-webkit-transform-origin:50% 57%;transform-origin:50% 57%}#ca-unwatch.icon a span,#ca-watch.icon a span{display:none}#mw-navigation h2{position:absolute;top:-9999px}#mw-page-base{height:5em;background-position:bottom left;background-repeat:repeat-x;background-image:url(http://cnbguatemala.org/skins/Vector/images/page-fade.png?7c7b7);background-color:#FFF;background-image:-moz-linear-gradient(top,#ffffff 50%,#FFF 100%);background-image:-webkit-gradient(linear,left top,left bottom,color-stop(50%,#ffffff),color-stop(100%,#FFF));background-image:-webkit-linear-gradient(top,#ffffff 50%,#FFF 100%);background-image:linear-gradient(#ffffff 50%,#FFF 100%);background-color:#ffffff}#mw-head-base{margin-top:-5em;margin-left:10em;height:5em}div#mw-head{position:absolute;top:0;right:0;width:100%}div#mw-head h3{margin:0;padding:0}#left-navigation{float:left;margin-left:10em;margin-top:2.5em;margin-bottom:-2.5em;display:inline}#right-navigation{float:right;margin-top:2.5em}#p-logo{position:absolute;top:-160px;left:0;width:10em;height:160px}#p-logo a{display:block;width:10em;height:160px;background-repeat:no-repeat;background-position:center center;text-decoration:none}div#mw-panel{font-size:inherit;position:absolute;top:160px;padding-top:1em;width:10em;left:0}div#mw-panel div.portal{margin:0 0.6em 0 0.7em;padding:0.25em 0;direction:ltr;background-position:top left;background-repeat:no-repeat;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIwAAAABCAAAAAAphRnkAAAAJ0lEQVQIW7XFsQEAIAyAMPD/b7uLWz8wS5youFW1UREfiIpH1Q2VBz7fGPS1dOGeAAAAAElFTkSuQmCC);background-image:url(http://cnbguatemala.org/skins/Vector/images/portal-break.png?3ea1b)!ie}div#mw-panel div.portal h3{font-size:0.75em;color:#4d4d4d;font-weight:normal;margin:0;padding:0.25em 0 0.25em 0.25em;cursor:default;border:none}div#mw-panel div.portal div.body{margin:0 0 0 1.25em;padding-top:0}div#mw-panel div.portal div.body ul{list-style-type:none;list-style-image:none;margin:0;padding:0}div#mw-panel div.portal div.body ul li{line-height:1.125em;margin:0;padding:0.25em 0;font-size:0.75em;word-wrap:break-word}div#mw-panel div.portal div.body ul li a{color:#0645ad}div#mw-panel div.portal div.body ul li a:visited{color:#0b0080}div#mw-panel #p-logo + div.portal{background-image:none;margin-top:0}div#mw-panel #p-logo + div.portal h3{display:none}div#mw-panel #p-logo + div.portal div.body{margin-left:0.5em}div#footer{margin-left:10em;margin-top:0;padding:0.75em;direction:ltr}div#footer ul{list-style-type:none;list-style-image:none;margin:0;padding:0}div#footer ul li{margin:0;padding:0;padding-top:0.5em;padding-bottom:0.5em;color:#333;font-size:0.7em}div#footer #footer-icons{float:right}div#footer #footer-icons li{float:left;margin-left:0.5em;line-height:2em;text-align:right}div#footer #footer-info li{line-height:1.4em}div#footer #footer-places li{float:left;margin-right:1em;line-height:2em}body.ltr div#footer #footer-places{float:left}.mw-body .external{background-position:center right;background-repeat:no-repeat;background-image:url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.png?948bf);background-image:-webkit-linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2210%22%20height%3D%2210%22%3E%3Cg%20transform%3D%22translate%28-826.429%20-698.791%29%22%3E%3Crect%20width%3D%225.982%22%20height%3D%225.982%22%20x%3D%22826.929%22%20y%3D%22702.309%22%20fill%3D%22%23fff%22%20stroke%3D%22%2306c%22%2F%3E%3Cg%3E%3Cpath%20d%3D%22M831.194%20698.791h5.234v5.391l-1.571%201.545-1.31-1.31-2.725%202.725-2.689-2.689%202.808-2.808-1.311-1.311z%22%20fill%3D%22%2306f%22%2F%3E%3Cpath%20d%3D%22M835.424%20699.795l.022%204.885-1.817-1.817-2.881%202.881-1.228-1.228%202.881-2.881-1.851-1.851z%22%20fill%3D%22%23fff%22%2F%3E%3C%2Fg%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:-webkit-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.svg?445a3)!ie;background-image:linear-gradient(transparent,transparent),url(data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2210%22%20height%3D%2210%22%3E%3Cg%20transform%3D%22translate%28-826.429%20-698.791%29%22%3E%3Crect%20width%3D%225.982%22%20height%3D%225.982%22%20x%3D%22826.929%22%20y%3D%22702.309%22%20fill%3D%22%23fff%22%20stroke%3D%22%2306c%22%2F%3E%3Cg%3E%3Cpath%20d%3D%22M831.194%20698.791h5.234v5.391l-1.571%201.545-1.31-1.31-2.725%202.725-2.689-2.689%202.808-2.808-1.311-1.311z%22%20fill%3D%22%2306f%22%2F%3E%3Cpath%20d%3D%22M835.424%20699.795l.022%204.885-1.817-1.817-2.881%202.881-1.228-1.228%202.881-2.881-1.851-1.851z%22%20fill%3D%22%23fff%22%2F%3E%3C%2Fg%3E%3C%2Fg%3E%3C%2Fsvg%3E);background-image:linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.svg?445a3)!ie;background-image:-o-linear-gradient(transparent,transparent),url(http://cnbguatemala.org/skins/Vector/images/external-link-ltr-icon.png?948bf);padding-right:13px}}@media screen and (min-width:982px){.mw-body{margin-left:11em;padding:1.25em 1.5em 1.5em 1.5em}#p-logo{left:0.5em}div#footer{margin-left:11em;padding:1.25em}#mw-panel{padding-left:0.5em}#p-search{margin-right:1em}#left-navigation{margin-left:11em}#p-personal{right:1em}#mw-head-base{margin-left:11em}} </style>