Merge branch 'develop' into feature/realtime.video
This commit is contained in:
commit
8202fb38f3
27 changed files with 28876 additions and 28876 deletions
|
@ -1,31 +1,31 @@
|
||||||
// This is a manifest file that'll be compiled into application.js, which will include all the files
|
// This is a manifest file that'll be compiled into application.js, which will include all the files
|
||||||
// listed below.
|
// listed below.
|
||||||
//
|
//
|
||||||
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
|
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
|
||||||
// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
|
// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
|
||||||
//
|
//
|
||||||
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
|
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
|
||||||
// the compiled file.
|
// the compiled file.
|
||||||
//
|
//
|
||||||
// WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD
|
// WARNING: THE FIRST BLANK LINE MARKS THE END OF WHAT'S TO BE PROCESSED, ANY BLANK LINE SHOULD
|
||||||
// GO AFTER THE REQUIRES BELOW.
|
// GO AFTER THE REQUIRES BELOW.
|
||||||
//
|
//
|
||||||
//= require jquery
|
//= require jquery
|
||||||
//= require jquery-ui
|
//= require jquery-ui
|
||||||
//= require jquery_ujs
|
//= require jquery_ujs
|
||||||
//= require ./orderedLibraries/underscore
|
//= require ./orderedLibraries/underscore
|
||||||
//= require ./orderedLibraries/backbone
|
//= require ./orderedLibraries/backbone
|
||||||
//= require_directory ./lib
|
//= require_directory ./lib
|
||||||
//= require ./src/Metamaps.GlobalUI
|
//= require ./src/Metamaps.GlobalUI
|
||||||
//= require ./src/Metamaps.Router
|
//= require ./src/Metamaps.Router
|
||||||
//= require ./src/Metamaps.Backbone
|
//= require ./src/Metamaps.Backbone
|
||||||
//= require ./src/Metamaps.Views
|
//= require ./src/Metamaps.Views
|
||||||
//= require ./src/views/chatView
|
//= require ./src/views/chatView
|
||||||
//= require ./src/views/videoView
|
//= require ./src/views/videoView
|
||||||
//= require ./src/views/room
|
//= require ./src/views/room
|
||||||
//= require ./src/JIT
|
//= require ./src/JIT
|
||||||
//= require ./src/Metamaps
|
//= require ./src/Metamaps
|
||||||
//= require ./src/Metamaps.JIT
|
//= require ./src/Metamaps.JIT
|
||||||
//= require_directory ./shims
|
//= require_directory ./shims
|
||||||
//= require_directory ./require
|
//= require_directory ./require
|
||||||
//= require_directory ./famous
|
//= require_directory ./famous
|
||||||
|
|
|
@ -1,426 +1,426 @@
|
||||||
//////////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////////
|
||||||
// CloudCarousel V1.0.5
|
// CloudCarousel V1.0.5
|
||||||
// (c) 2011 by R Cecco. <http://www.professorcloud.com>
|
// (c) 2011 by R Cecco. <http://www.professorcloud.com>
|
||||||
// MIT License
|
// MIT License
|
||||||
//
|
//
|
||||||
// Reflection code based on plugin by Christophe Beyls <http://www.digitalia.be>
|
// Reflection code based on plugin by Christophe Beyls <http://www.digitalia.be>
|
||||||
//
|
//
|
||||||
// Please retain this copyright header in all versions of the software
|
// Please retain this copyright header in all versions of the software
|
||||||
//////////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////////
|
||||||
var matched, browser;
|
var matched, browser;
|
||||||
|
|
||||||
jQuery.uaMatch = function( ua ) {
|
jQuery.uaMatch = function( ua ) {
|
||||||
ua = ua.toLowerCase();
|
ua = ua.toLowerCase();
|
||||||
|
|
||||||
var match = /(chrome)[ \/]([\w.]+)/.exec( ua ) ||
|
var match = /(chrome)[ \/]([\w.]+)/.exec( ua ) ||
|
||||||
/(webkit)[ \/]([\w.]+)/.exec( ua ) ||
|
/(webkit)[ \/]([\w.]+)/.exec( ua ) ||
|
||||||
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec( ua ) ||
|
/(opera)(?:.*version|)[ \/]([\w.]+)/.exec( ua ) ||
|
||||||
/(msie) ([\w.]+)/.exec( ua ) ||
|
/(msie) ([\w.]+)/.exec( ua ) ||
|
||||||
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec( ua ) ||
|
ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec( ua ) ||
|
||||||
[];
|
[];
|
||||||
|
|
||||||
return {
|
return {
|
||||||
browser: match[ 1 ] || "",
|
browser: match[ 1 ] || "",
|
||||||
version: match[ 2 ] || "0"
|
version: match[ 2 ] || "0"
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
matched = jQuery.uaMatch( navigator.userAgent );
|
matched = jQuery.uaMatch( navigator.userAgent );
|
||||||
browser = {};
|
browser = {};
|
||||||
|
|
||||||
if ( matched.browser ) {
|
if ( matched.browser ) {
|
||||||
browser[ matched.browser ] = true;
|
browser[ matched.browser ] = true;
|
||||||
browser.version = matched.version;
|
browser.version = matched.version;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Chrome is Webkit, but Webkit is also Safari.
|
// Chrome is Webkit, but Webkit is also Safari.
|
||||||
if ( browser.chrome ) {
|
if ( browser.chrome ) {
|
||||||
browser.webkit = true;
|
browser.webkit = true;
|
||||||
} else if ( browser.webkit ) {
|
} else if ( browser.webkit ) {
|
||||||
browser.safari = true;
|
browser.safari = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
jQuery.browser = browser;
|
jQuery.browser = browser;
|
||||||
|
|
||||||
(function($) {
|
(function($) {
|
||||||
|
|
||||||
// START Reflection object.
|
// START Reflection object.
|
||||||
// Creates a reflection for underneath an image.
|
// Creates a reflection for underneath an image.
|
||||||
// IE uses an image with IE specific filter properties, other browsers use the Canvas tag.
|
// IE uses an image with IE specific filter properties, other browsers use the Canvas tag.
|
||||||
// The position and size of the reflection gets updated by updateAll() in Controller.
|
// The position and size of the reflection gets updated by updateAll() in Controller.
|
||||||
function Reflection(img, reflHeight, opacity) {
|
function Reflection(img, reflHeight, opacity) {
|
||||||
|
|
||||||
var reflection, cntx, imageWidth = img.width, imageHeight = img.width, gradient, parent;
|
var reflection, cntx, imageWidth = img.width, imageHeight = img.width, gradient, parent;
|
||||||
|
|
||||||
parent = $(img.parentNode);
|
parent = $(img.parentNode);
|
||||||
this.element = reflection = parent.append("<canvas class='reflection' style='position:absolute'/>").find(':last')[0];
|
this.element = reflection = parent.append("<canvas class='reflection' style='position:absolute'/>").find(':last')[0];
|
||||||
if ( !reflection.getContext && $.browser.msie) {
|
if ( !reflection.getContext && $.browser.msie) {
|
||||||
this.element = reflection = parent.append("<img class='reflection' style='position:absolute'/>").find(':last')[0];
|
this.element = reflection = parent.append("<img class='reflection' style='position:absolute'/>").find(':last')[0];
|
||||||
reflection.src = img.src;
|
reflection.src = img.src;
|
||||||
reflection.style.filter = "flipv progid:DXImageTransform.Microsoft.Alpha(opacity=" + (opacity * 100) + ", style=1, finishOpacity=0, startx=0, starty=0, finishx=0, finishy=" + (reflHeight / imageHeight * 100) + ")";
|
reflection.style.filter = "flipv progid:DXImageTransform.Microsoft.Alpha(opacity=" + (opacity * 100) + ", style=1, finishOpacity=0, startx=0, starty=0, finishx=0, finishy=" + (reflHeight / imageHeight * 100) + ")";
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
cntx = reflection.getContext("2d");
|
cntx = reflection.getContext("2d");
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|
||||||
$(reflection).attr({width: imageWidth, height: reflHeight});
|
$(reflection).attr({width: imageWidth, height: reflHeight});
|
||||||
cntx.save();
|
cntx.save();
|
||||||
cntx.translate(0, imageHeight-1);
|
cntx.translate(0, imageHeight-1);
|
||||||
cntx.scale(1, -1);
|
cntx.scale(1, -1);
|
||||||
cntx.drawImage(img, 0, 0, imageWidth, imageHeight);
|
cntx.drawImage(img, 0, 0, imageWidth, imageHeight);
|
||||||
cntx.restore();
|
cntx.restore();
|
||||||
cntx.globalCompositeOperation = "destination-out";
|
cntx.globalCompositeOperation = "destination-out";
|
||||||
gradient = cntx.createLinearGradient(0, 0, 0, reflHeight);
|
gradient = cntx.createLinearGradient(0, 0, 0, reflHeight);
|
||||||
gradient.addColorStop(0, "rgba(255, 255, 255, " + (1 - opacity) + ")");
|
gradient.addColorStop(0, "rgba(255, 255, 255, " + (1 - opacity) + ")");
|
||||||
gradient.addColorStop(1, "rgba(255, 255, 255, 1.0)");
|
gradient.addColorStop(1, "rgba(255, 255, 255, 1.0)");
|
||||||
cntx.fillStyle = gradient;
|
cntx.fillStyle = gradient;
|
||||||
cntx.fillRect(0, 0, imageWidth, reflHeight);
|
cntx.fillRect(0, 0, imageWidth, reflHeight);
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Store a copy of the alt and title attrs into the reflection
|
// Store a copy of the alt and title attrs into the reflection
|
||||||
$(reflection).attr({ 'alt': $(img).attr('alt'), title: $(img).attr('title')} );
|
$(reflection).attr({ 'alt': $(img).attr('alt'), title: $(img).attr('title')} );
|
||||||
|
|
||||||
} //END Reflection object
|
} //END Reflection object
|
||||||
|
|
||||||
// START Item object.
|
// START Item object.
|
||||||
// A wrapper object for items within the carousel.
|
// A wrapper object for items within the carousel.
|
||||||
var Item = function(imgIn, options)
|
var Item = function(imgIn, options)
|
||||||
{
|
{
|
||||||
this.orgWidth = imgIn.width;
|
this.orgWidth = imgIn.width;
|
||||||
this.orgHeight = imgIn.height;
|
this.orgHeight = imgIn.height;
|
||||||
this.image = imgIn;
|
this.image = imgIn;
|
||||||
this.reflection = null;
|
this.reflection = null;
|
||||||
this.alt = imgIn.alt;
|
this.alt = imgIn.alt;
|
||||||
this.title = imgIn.title;
|
this.title = imgIn.title;
|
||||||
this.imageOK = false;
|
this.imageOK = false;
|
||||||
this.options = options;
|
this.options = options;
|
||||||
|
|
||||||
this.imageOK = true;
|
this.imageOK = true;
|
||||||
|
|
||||||
if (this.options.reflHeight > 0)
|
if (this.options.reflHeight > 0)
|
||||||
{
|
{
|
||||||
this.reflection = new Reflection(this.image, this.options.reflHeight, this.options.reflOpacity);
|
this.reflection = new Reflection(this.image, this.options.reflHeight, this.options.reflOpacity);
|
||||||
}
|
}
|
||||||
$(this.image).css('position','absolute'); // Bizarre. This seems to reset image width to 0 on webkit!
|
$(this.image).css('position','absolute'); // Bizarre. This seems to reset image width to 0 on webkit!
|
||||||
};// END Item object
|
};// END Item object
|
||||||
|
|
||||||
|
|
||||||
// Controller object.
|
// Controller object.
|
||||||
// This handles moving all the items, dealing with mouse clicks etc.
|
// This handles moving all the items, dealing with mouse clicks etc.
|
||||||
var Controller = function(container, images, options)
|
var Controller = function(container, images, options)
|
||||||
{
|
{
|
||||||
var items = [], funcSin = Math.sin, funcCos = Math.cos, ctx=this;
|
var items = [], funcSin = Math.sin, funcCos = Math.cos, ctx=this;
|
||||||
this.controlTimer = 0;
|
this.controlTimer = 0;
|
||||||
this.stopped = false;
|
this.stopped = false;
|
||||||
//this.imagesLoaded = 0;
|
//this.imagesLoaded = 0;
|
||||||
this.container = container;
|
this.container = container;
|
||||||
this.xRadius = options.xRadius;
|
this.xRadius = options.xRadius;
|
||||||
this.yRadius = options.yRadius;
|
this.yRadius = options.yRadius;
|
||||||
this.showFrontTextTimer = 0;
|
this.showFrontTextTimer = 0;
|
||||||
this.autoRotateTimer = 0;
|
this.autoRotateTimer = 0;
|
||||||
if (options.xRadius === 0)
|
if (options.xRadius === 0)
|
||||||
{
|
{
|
||||||
this.xRadius = ($(container).width()/2.3);
|
this.xRadius = ($(container).width()/2.3);
|
||||||
}
|
}
|
||||||
if (options.yRadius === 0)
|
if (options.yRadius === 0)
|
||||||
{
|
{
|
||||||
this.yRadius = ($(container).height()/6);
|
this.yRadius = ($(container).height()/6);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.xCentre = options.xPos;
|
this.xCentre = options.xPos;
|
||||||
this.yCentre = options.yPos;
|
this.yCentre = options.yPos;
|
||||||
this.frontIndex = 0; // Index of the item at the front
|
this.frontIndex = 0; // Index of the item at the front
|
||||||
|
|
||||||
// Start with the first item at the front.
|
// Start with the first item at the front.
|
||||||
this.rotation = this.destRotation = Math.PI/2;
|
this.rotation = this.destRotation = Math.PI/2;
|
||||||
this.timeDelay = 1000/options.FPS;
|
this.timeDelay = 1000/options.FPS;
|
||||||
|
|
||||||
// Turn on the infoBox
|
// Turn on the infoBox
|
||||||
if(options.altBox !== null)
|
if(options.altBox !== null)
|
||||||
{
|
{
|
||||||
$(options.altBox).css('display','block');
|
$(options.altBox).css('display','block');
|
||||||
$(options.titleBox).css('display','block');
|
$(options.titleBox).css('display','block');
|
||||||
}
|
}
|
||||||
// Turn on relative position for container to allow absolutely positioned elements
|
// Turn on relative position for container to allow absolutely positioned elements
|
||||||
// within it to work.
|
// within it to work.
|
||||||
$(container).css({ position:'relative', overflow:'hidden'} );
|
$(container).css({ position:'relative', overflow:'hidden'} );
|
||||||
|
|
||||||
$(options.buttonLeft).css('display','inline');
|
$(options.buttonLeft).css('display','inline');
|
||||||
$(options.buttonRight).css('display','inline');
|
$(options.buttonRight).css('display','inline');
|
||||||
|
|
||||||
// Setup the buttons.
|
// Setup the buttons.
|
||||||
$(options.buttonLeft).bind('mouseup',this,function(event){
|
$(options.buttonLeft).bind('mouseup',this,function(event){
|
||||||
event.data.rotate(-1);
|
event.data.rotate(-1);
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
$(options.buttonRight).bind('mouseup',this,function(event){
|
$(options.buttonRight).bind('mouseup',this,function(event){
|
||||||
event.data.rotate(1);
|
event.data.rotate(1);
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
// Add code that makes tab and shift+tab scroll through metacodes
|
// Add code that makes tab and shift+tab scroll through metacodes
|
||||||
$('.new_topic').bind('keydown',this,function(event){
|
$('.new_topic').bind('keydown',this,function(event){
|
||||||
if (event.keyCode == 9 && event.shiftKey) {
|
if (event.keyCode == 9 && event.shiftKey) {
|
||||||
event.data.rotate(-1);
|
event.data.rotate(-1);
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
} else if (event.keyCode == 9) {
|
} else if (event.keyCode == 9) {
|
||||||
event.data.rotate(1);
|
event.data.rotate(1);
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// You will need this plugin for the mousewheel to work: http://plugins.jquery.com/project/mousewheel
|
// You will need this plugin for the mousewheel to work: http://plugins.jquery.com/project/mousewheel
|
||||||
if (options.mouseWheel)
|
if (options.mouseWheel)
|
||||||
{
|
{
|
||||||
// START METAMAPS CODE
|
// START METAMAPS CODE
|
||||||
$('body').bind('mousewheel',this,function(event, delta) {
|
$('body').bind('mousewheel',this,function(event, delta) {
|
||||||
if (Metamaps.Create.newTopic.beingCreated && !Metamaps.Create.isSwitchingSet) {
|
if (Metamaps.Create.newTopic.beingCreated && !Metamaps.Create.isSwitchingSet) {
|
||||||
event.data.rotate(delta);
|
event.data.rotate(delta);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// END METAMAPS CODE
|
// END METAMAPS CODE
|
||||||
/* ORIGINAL CODE
|
/* ORIGINAL CODE
|
||||||
$(container).bind('mousewheel',this,function(event, delta) {
|
$(container).bind('mousewheel',this,function(event, delta) {
|
||||||
event.data.rotate(delta);
|
event.data.rotate(delta);
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
*/
|
*/
|
||||||
}
|
}
|
||||||
$(container).bind('mouseover click',this,function(event){
|
$(container).bind('mouseover click',this,function(event){
|
||||||
|
|
||||||
clearInterval(event.data.autoRotateTimer); // Stop auto rotation if mouse over.
|
clearInterval(event.data.autoRotateTimer); // Stop auto rotation if mouse over.
|
||||||
var text = $(event.target).attr('alt');
|
var text = $(event.target).attr('alt');
|
||||||
// If we have moved over a carousel item, then show the alt and title text.
|
// If we have moved over a carousel item, then show the alt and title text.
|
||||||
|
|
||||||
if ( text !== undefined && text !== null )
|
if ( text !== undefined && text !== null )
|
||||||
{
|
{
|
||||||
|
|
||||||
clearTimeout(event.data.showFrontTextTimer);
|
clearTimeout(event.data.showFrontTextTimer);
|
||||||
$(options.altBox).html( ($(event.target).attr('alt') ));
|
$(options.altBox).html( ($(event.target).attr('alt') ));
|
||||||
//$(options.titleBox).html( ($(event.target).attr('title') ));
|
//$(options.titleBox).html( ($(event.target).attr('title') ));
|
||||||
if ( options.bringToFront && event.type == 'click' )
|
if ( options.bringToFront && event.type == 'click' )
|
||||||
{
|
{
|
||||||
$(options.titleBox).html( ($(event.target).attr('title') ));
|
$(options.titleBox).html( ($(event.target).attr('title') ));
|
||||||
// METAMAPS CODE
|
// METAMAPS CODE
|
||||||
Metamaps.Create.newTopic.metacode = $(event.target).attr('data-id');
|
Metamaps.Create.newTopic.metacode = $(event.target).attr('data-id');
|
||||||
// NOT METAMAPS CODE
|
// NOT METAMAPS CODE
|
||||||
var idx = $(event.target).data('itemIndex');
|
var idx = $(event.target).data('itemIndex');
|
||||||
var frontIndex = event.data.frontIndex;
|
var frontIndex = event.data.frontIndex;
|
||||||
//var diff = idx - frontIndex;
|
//var diff = idx - frontIndex;
|
||||||
var diff = (idx - frontIndex) % images.length;
|
var diff = (idx - frontIndex) % images.length;
|
||||||
if (Math.abs(diff) > images.length / 2) {
|
if (Math.abs(diff) > images.length / 2) {
|
||||||
diff += (diff > 0 ? -images.length : images.length);
|
diff += (diff > 0 ? -images.length : images.length);
|
||||||
}
|
}
|
||||||
|
|
||||||
event.data.rotate(-diff);
|
event.data.rotate(-diff);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
// If we have moved out of a carousel item (or the container itself),
|
// If we have moved out of a carousel item (or the container itself),
|
||||||
// restore the text of the front item in 1 second.
|
// restore the text of the front item in 1 second.
|
||||||
$(container).bind('mouseout',this,function(event){
|
$(container).bind('mouseout',this,function(event){
|
||||||
var context = event.data;
|
var context = event.data;
|
||||||
clearTimeout(context.showFrontTextTimer);
|
clearTimeout(context.showFrontTextTimer);
|
||||||
context.showFrontTextTimer = setTimeout( function(){context.showFrontText();},1000);
|
context.showFrontTextTimer = setTimeout( function(){context.showFrontText();},1000);
|
||||||
context.autoRotate(); // Start auto rotation.
|
context.autoRotate(); // Start auto rotation.
|
||||||
});
|
});
|
||||||
|
|
||||||
// Prevent items from being selected as mouse is moved and clicked in the container.
|
// Prevent items from being selected as mouse is moved and clicked in the container.
|
||||||
$(container).bind('mousedown',this,function(event){
|
$(container).bind('mousedown',this,function(event){
|
||||||
|
|
||||||
event.data.container.focus();
|
event.data.container.focus();
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
container.onselectstart = function () { return false; }; // For IE.
|
container.onselectstart = function () { return false; }; // For IE.
|
||||||
|
|
||||||
this.innerWrapper = $(container).wrapInner('<div style="position:absolute;width:100%;height:100%;"/>').children()[0];
|
this.innerWrapper = $(container).wrapInner('<div style="position:absolute;width:100%;height:100%;"/>').children()[0];
|
||||||
|
|
||||||
// Shows the text from the front most item.
|
// Shows the text from the front most item.
|
||||||
this.showFrontText = function()
|
this.showFrontText = function()
|
||||||
{
|
{
|
||||||
if ( items[this.frontIndex] === undefined ) { return; } // Images might not have loaded yet.
|
if ( items[this.frontIndex] === undefined ) { return; } // Images might not have loaded yet.
|
||||||
// METAMAPS CODE
|
// METAMAPS CODE
|
||||||
Metamaps.Create.newTopic.metacode = $(items[this.frontIndex].image).attr('data-id');
|
Metamaps.Create.newTopic.metacode = $(items[this.frontIndex].image).attr('data-id');
|
||||||
//$('img.cloudcarousel').css({"background":"none", "width":"","height":""});
|
//$('img.cloudcarousel').css({"background":"none", "width":"","height":""});
|
||||||
//$(items[this.frontIndex].image).css({"width":"45px","height":"45px"});
|
//$(items[this.frontIndex].image).css({"width":"45px","height":"45px"});
|
||||||
// NOT METAMAPS CODE
|
// NOT METAMAPS CODE
|
||||||
$(options.titleBox).html( $(items[this.frontIndex].image).attr('title'));
|
$(options.titleBox).html( $(items[this.frontIndex].image).attr('title'));
|
||||||
$(options.altBox).html( $(items[this.frontIndex].image).attr('alt'));
|
$(options.altBox).html( $(items[this.frontIndex].image).attr('alt'));
|
||||||
};
|
};
|
||||||
|
|
||||||
this.go = function()
|
this.go = function()
|
||||||
{
|
{
|
||||||
if(this.controlTimer !== 0) { return; }
|
if(this.controlTimer !== 0) { return; }
|
||||||
var context = this;
|
var context = this;
|
||||||
this.controlTimer = setTimeout( function(){context.updateAll();},this.timeDelay);
|
this.controlTimer = setTimeout( function(){context.updateAll();},this.timeDelay);
|
||||||
};
|
};
|
||||||
|
|
||||||
this.stop = function()
|
this.stop = function()
|
||||||
{
|
{
|
||||||
clearTimeout(this.controlTimer);
|
clearTimeout(this.controlTimer);
|
||||||
this.controlTimer = 0;
|
this.controlTimer = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
// Starts the rotation of the carousel. Direction is the number (+-) of carousel items to rotate by.
|
// Starts the rotation of the carousel. Direction is the number (+-) of carousel items to rotate by.
|
||||||
this.rotate = function(direction)
|
this.rotate = function(direction)
|
||||||
{
|
{
|
||||||
this.frontIndex -= direction;
|
this.frontIndex -= direction;
|
||||||
if (this.frontIndex == -1) this.frontIndex = items.length - 1;
|
if (this.frontIndex == -1) this.frontIndex = items.length - 1;
|
||||||
this.frontIndex %= items.length;
|
this.frontIndex %= items.length;
|
||||||
this.destRotation += ( Math.PI / items.length ) * ( 2*direction );
|
this.destRotation += ( Math.PI / items.length ) * ( 2*direction );
|
||||||
this.showFrontText();
|
this.showFrontText();
|
||||||
this.go();
|
this.go();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
this.autoRotate = function()
|
this.autoRotate = function()
|
||||||
{
|
{
|
||||||
if ( options.autoRotate !== 'no' )
|
if ( options.autoRotate !== 'no' )
|
||||||
{
|
{
|
||||||
var dir = (options.autoRotate === 'right')? 1 : -1;
|
var dir = (options.autoRotate === 'right')? 1 : -1;
|
||||||
this.autoRotateTimer = setInterval( function(){ctx.rotate(dir); }, options.autoRotateDelay );
|
this.autoRotateTimer = setInterval( function(){ctx.rotate(dir); }, options.autoRotateDelay );
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// This is the main loop function that moves everything.
|
// This is the main loop function that moves everything.
|
||||||
this.updateAll = function()
|
this.updateAll = function()
|
||||||
{
|
{
|
||||||
var minScale = options.minScale; // This is the smallest scale applied to the furthest item.
|
var minScale = options.minScale; // This is the smallest scale applied to the furthest item.
|
||||||
var smallRange = (1-minScale) * 0.5;
|
var smallRange = (1-minScale) * 0.5;
|
||||||
var w,h,x,y,scale,item,sinVal;
|
var w,h,x,y,scale,item,sinVal;
|
||||||
|
|
||||||
var change = (this.destRotation - this.rotation);
|
var change = (this.destRotation - this.rotation);
|
||||||
var absChange = Math.abs(change);
|
var absChange = Math.abs(change);
|
||||||
|
|
||||||
this.rotation += change * options.speed;
|
this.rotation += change * options.speed;
|
||||||
if ( absChange < 0.001 ) { this.rotation = this.destRotation; }
|
if ( absChange < 0.001 ) { this.rotation = this.destRotation; }
|
||||||
var itemsLen = items.length;
|
var itemsLen = items.length;
|
||||||
var spacing = (Math.PI / itemsLen) * 2;
|
var spacing = (Math.PI / itemsLen) * 2;
|
||||||
//var wrapStyle = null;
|
//var wrapStyle = null;
|
||||||
var radians = this.rotation;
|
var radians = this.rotation;
|
||||||
var isMSIE = $.browser.msie;
|
var isMSIE = $.browser.msie;
|
||||||
|
|
||||||
// Turn off display. This can reduce repaints/reflows when making style and position changes in the loop.
|
// Turn off display. This can reduce repaints/reflows when making style and position changes in the loop.
|
||||||
// See http://dev.opera.com/articles/view/efficient-javascript/?page=3
|
// See http://dev.opera.com/articles/view/efficient-javascript/?page=3
|
||||||
this.innerWrapper.style.display = 'none';
|
this.innerWrapper.style.display = 'none';
|
||||||
|
|
||||||
var style;
|
var style;
|
||||||
var px = 'px', reflHeight;
|
var px = 'px', reflHeight;
|
||||||
var context = this;
|
var context = this;
|
||||||
for (var i = 0; i<itemsLen ;i++)
|
for (var i = 0; i<itemsLen ;i++)
|
||||||
{
|
{
|
||||||
item = items[i];
|
item = items[i];
|
||||||
|
|
||||||
sinVal = funcSin(radians);
|
sinVal = funcSin(radians);
|
||||||
|
|
||||||
scale = ((sinVal+1) * smallRange) + minScale;
|
scale = ((sinVal+1) * smallRange) + minScale;
|
||||||
|
|
||||||
x = this.xCentre + (( (funcCos(radians) * this.xRadius) - (item.orgWidth*0.5)) * scale);
|
x = this.xCentre + (( (funcCos(radians) * this.xRadius) - (item.orgWidth*0.5)) * scale);
|
||||||
y = this.yCentre + (( (sinVal * this.yRadius) ) * scale);
|
y = this.yCentre + (( (sinVal * this.yRadius) ) * scale);
|
||||||
|
|
||||||
if (item.imageOK)
|
if (item.imageOK)
|
||||||
{
|
{
|
||||||
var img = item.image;
|
var img = item.image;
|
||||||
|
|
||||||
img.style.zIndex = "" + (scale * 100)>>0; // >>0 = Math.foor(). Firefox doesn't like fractional decimals in z-index.
|
img.style.zIndex = "" + (scale * 100)>>0; // >>0 = Math.foor(). Firefox doesn't like fractional decimals in z-index.
|
||||||
w = img.width = item.orgWidth * scale;
|
w = img.width = item.orgWidth * scale;
|
||||||
h = img.height = item.orgHeight * scale;
|
h = img.height = item.orgHeight * scale;
|
||||||
img.style.left = x + px ;
|
img.style.left = x + px ;
|
||||||
img.style.top = y + px;
|
img.style.top = y + px;
|
||||||
if (item.reflection !== null)
|
if (item.reflection !== null)
|
||||||
{
|
{
|
||||||
reflHeight = options.reflHeight * scale;
|
reflHeight = options.reflHeight * scale;
|
||||||
style = item.reflection.element.style;
|
style = item.reflection.element.style;
|
||||||
style.left = x + px;
|
style.left = x + px;
|
||||||
style.top = y + h + options.reflGap * scale + px;
|
style.top = y + h + options.reflGap * scale + px;
|
||||||
style.width = w + px;
|
style.width = w + px;
|
||||||
if (isMSIE)
|
if (isMSIE)
|
||||||
{
|
{
|
||||||
style.filter.finishy = (reflHeight / h * 100);
|
style.filter.finishy = (reflHeight / h * 100);
|
||||||
}else
|
}else
|
||||||
{
|
{
|
||||||
style.height = reflHeight + px;
|
style.height = reflHeight + px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
radians += spacing;
|
radians += spacing;
|
||||||
}
|
}
|
||||||
// Turn display back on.
|
// Turn display back on.
|
||||||
this.innerWrapper.style.display = 'block';
|
this.innerWrapper.style.display = 'block';
|
||||||
|
|
||||||
// If we have a preceptable change in rotation then loop again next frame.
|
// If we have a preceptable change in rotation then loop again next frame.
|
||||||
if ( absChange >= 0.001 )
|
if ( absChange >= 0.001 )
|
||||||
{
|
{
|
||||||
this.controlTimer = setTimeout( function(){context.updateAll();},this.timeDelay);
|
this.controlTimer = setTimeout( function(){context.updateAll();},this.timeDelay);
|
||||||
}else
|
}else
|
||||||
{
|
{
|
||||||
// Otherwise just stop completely.
|
// Otherwise just stop completely.
|
||||||
this.stop();
|
this.stop();
|
||||||
}
|
}
|
||||||
}; // END updateAll
|
}; // END updateAll
|
||||||
|
|
||||||
// Create an Item object for each image
|
// Create an Item object for each image
|
||||||
// func = function(){return;ctx.updateAll();} ;
|
// func = function(){return;ctx.updateAll();} ;
|
||||||
|
|
||||||
// Check if images have loaded. We need valid widths and heights for the reflections.
|
// Check if images have loaded. We need valid widths and heights for the reflections.
|
||||||
this.checkImagesLoaded = function()
|
this.checkImagesLoaded = function()
|
||||||
{
|
{
|
||||||
var i;
|
var i;
|
||||||
for(i=0;i<images.length;i++) {
|
for(i=0;i<images.length;i++) {
|
||||||
if ( (images[i].width === undefined) || ( (images[i].complete !== undefined) && (!images[i].complete) ))
|
if ( (images[i].width === undefined) || ( (images[i].complete !== undefined) && (!images[i].complete) ))
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for(i=0;i<images.length;i++) {
|
for(i=0;i<images.length;i++) {
|
||||||
items.push( new Item( images[i], options ) );
|
items.push( new Item( images[i], options ) );
|
||||||
$(images[i]).data('itemIndex',i);
|
$(images[i]).data('itemIndex',i);
|
||||||
}
|
}
|
||||||
// If all images have valid widths and heights, we can stop checking.
|
// If all images have valid widths and heights, we can stop checking.
|
||||||
clearInterval(this.tt);
|
clearInterval(this.tt);
|
||||||
this.showFrontText();
|
this.showFrontText();
|
||||||
this.autoRotate();
|
this.autoRotate();
|
||||||
this.updateAll();
|
this.updateAll();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
this.tt = setInterval( function(){ctx.checkImagesLoaded();},50);
|
this.tt = setInterval( function(){ctx.checkImagesLoaded();},50);
|
||||||
}; // END Controller object
|
}; // END Controller object
|
||||||
|
|
||||||
// The jQuery plugin part. Iterates through items specified in selector and inits a Controller class for each one.
|
// The jQuery plugin part. Iterates through items specified in selector and inits a Controller class for each one.
|
||||||
$.fn.CloudCarousel = function(options) {
|
$.fn.CloudCarousel = function(options) {
|
||||||
|
|
||||||
this.each( function() {
|
this.each( function() {
|
||||||
|
|
||||||
options = $.extend({}, {
|
options = $.extend({}, {
|
||||||
reflHeight:0,
|
reflHeight:0,
|
||||||
reflOpacity:0.5,
|
reflOpacity:0.5,
|
||||||
reflGap:0,
|
reflGap:0,
|
||||||
minScale:0.5,
|
minScale:0.5,
|
||||||
xPos:0,
|
xPos:0,
|
||||||
yPos:0,
|
yPos:0,
|
||||||
xRadius:0,
|
xRadius:0,
|
||||||
yRadius:0,
|
yRadius:0,
|
||||||
altBox:null,
|
altBox:null,
|
||||||
titleBox:null,
|
titleBox:null,
|
||||||
FPS: 30,
|
FPS: 30,
|
||||||
autoRotate: 'no',
|
autoRotate: 'no',
|
||||||
autoRotateDelay: 1500,
|
autoRotateDelay: 1500,
|
||||||
speed:0.2,
|
speed:0.2,
|
||||||
mouseWheel: false,
|
mouseWheel: false,
|
||||||
bringToFront: false
|
bringToFront: false
|
||||||
},options );
|
},options );
|
||||||
// Create a Controller for each carousel.
|
// Create a Controller for each carousel.
|
||||||
$(this).data('cloudcarousel', new Controller( this, $('.cloudcarousel',$(this)), options) );
|
$(this).data('cloudcarousel', new Controller( this, $('.cloudcarousel',$(this)), options) );
|
||||||
});
|
});
|
||||||
return this;
|
return this;
|
||||||
};
|
};
|
||||||
|
|
||||||
})(jQuery);
|
})(jQuery);
|
|
@ -1,180 +1,180 @@
|
||||||
/**
|
/**
|
||||||
* jquery.purr.js
|
* jquery.purr.js
|
||||||
* Copyright (c) 2008 Net Perspective (net-perspective.com)
|
* Copyright (c) 2008 Net Perspective (net-perspective.com)
|
||||||
* Licensed under the MIT License (http://www.opensource.org/licenses/mit-license.php)
|
* Licensed under the MIT License (http://www.opensource.org/licenses/mit-license.php)
|
||||||
*
|
*
|
||||||
* @author R.A. Ray
|
* @author R.A. Ray
|
||||||
* @projectDescription jQuery plugin for dynamically displaying unobtrusive messages in the browser. Mimics the behavior of the MacOS program "Growl."
|
* @projectDescription jQuery plugin for dynamically displaying unobtrusive messages in the browser. Mimics the behavior of the MacOS program "Growl."
|
||||||
* @version 0.1.0
|
* @version 0.1.0
|
||||||
*
|
*
|
||||||
* @requires jquery.js (tested with 1.2.6)
|
* @requires jquery.js (tested with 1.2.6)
|
||||||
*
|
*
|
||||||
* @param fadeInSpeed int - Duration of fade in animation in miliseconds
|
* @param fadeInSpeed int - Duration of fade in animation in miliseconds
|
||||||
* default: 500
|
* default: 500
|
||||||
* @param fadeOutSpeed int - Duration of fade out animationin miliseconds
|
* @param fadeOutSpeed int - Duration of fade out animationin miliseconds
|
||||||
default: 500
|
default: 500
|
||||||
* @param removeTimer int - Timeout, in miliseconds, before notice is removed once it is the top non-sticky notice in the list
|
* @param removeTimer int - Timeout, in miliseconds, before notice is removed once it is the top non-sticky notice in the list
|
||||||
default: 4000
|
default: 4000
|
||||||
* @param isSticky bool - Whether the notice should fade out on its own or wait to be manually closed
|
* @param isSticky bool - Whether the notice should fade out on its own or wait to be manually closed
|
||||||
default: false
|
default: false
|
||||||
* @param usingTransparentPNG bool - Whether or not the notice is using transparent .png images in its styling
|
* @param usingTransparentPNG bool - Whether or not the notice is using transparent .png images in its styling
|
||||||
default: false
|
default: false
|
||||||
*/
|
*/
|
||||||
|
|
||||||
( function( $ ) {
|
( function( $ ) {
|
||||||
|
|
||||||
$.purr = function ( notice, options )
|
$.purr = function ( notice, options )
|
||||||
{
|
{
|
||||||
// Convert notice to a jQuery object
|
// Convert notice to a jQuery object
|
||||||
notice = $( notice );
|
notice = $( notice );
|
||||||
|
|
||||||
// Add a class to denote the notice as not sticky
|
// Add a class to denote the notice as not sticky
|
||||||
if ( !options.isSticky )
|
if ( !options.isSticky )
|
||||||
{
|
{
|
||||||
notice.addClass( 'not-sticky' );
|
notice.addClass( 'not-sticky' );
|
||||||
};
|
};
|
||||||
|
|
||||||
// Get the container element from the page
|
// Get the container element from the page
|
||||||
var cont = document.getElementById( 'purr-container' );
|
var cont = document.getElementById( 'purr-container' );
|
||||||
|
|
||||||
// If the container doesn't yet exist, we need to create it
|
// If the container doesn't yet exist, we need to create it
|
||||||
if ( !cont )
|
if ( !cont )
|
||||||
{
|
{
|
||||||
cont = '<div id="purr-container"></div>';
|
cont = '<div id="purr-container"></div>';
|
||||||
}
|
}
|
||||||
|
|
||||||
// Convert cont to a jQuery object
|
// Convert cont to a jQuery object
|
||||||
cont = $( cont );
|
cont = $( cont );
|
||||||
|
|
||||||
// Add the container to the page
|
// Add the container to the page
|
||||||
$( 'body' ).append( cont );
|
$( 'body' ).append( cont );
|
||||||
|
|
||||||
notify();
|
notify();
|
||||||
|
|
||||||
function notify ()
|
function notify ()
|
||||||
{
|
{
|
||||||
// Set up the close button
|
// Set up the close button
|
||||||
var close = document.createElement( 'a' );
|
var close = document.createElement( 'a' );
|
||||||
$( close ).attr(
|
$( close ).attr(
|
||||||
{
|
{
|
||||||
className: 'close',
|
className: 'close',
|
||||||
href: '#close',
|
href: '#close',
|
||||||
innerHTML: 'Close'
|
innerHTML: 'Close'
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
.appendTo( notice )
|
.appendTo( notice )
|
||||||
.click( function ()
|
.click( function ()
|
||||||
{
|
{
|
||||||
removeNotice();
|
removeNotice();
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
// Add the notice to the page and keep it hidden initially
|
// Add the notice to the page and keep it hidden initially
|
||||||
notice.appendTo( cont )
|
notice.appendTo( cont )
|
||||||
.hide();
|
.hide();
|
||||||
|
|
||||||
if ( jQuery.browser.msie && options.usingTransparentPNG )
|
if ( jQuery.browser.msie && options.usingTransparentPNG )
|
||||||
{
|
{
|
||||||
// IE7 and earlier can't handle the combination of opacity and transparent pngs, so if we're using transparent pngs in our
|
// IE7 and earlier can't handle the combination of opacity and transparent pngs, so if we're using transparent pngs in our
|
||||||
// notice style, we'll just skip the fading in.
|
// notice style, we'll just skip the fading in.
|
||||||
notice.show();
|
notice.show();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//Fade in the notice we just added
|
//Fade in the notice we just added
|
||||||
notice.fadeIn( options.fadeInSpeed );
|
notice.fadeIn( options.fadeInSpeed );
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set up the removal interval for the added notice if that notice is not a sticky
|
// Set up the removal interval for the added notice if that notice is not a sticky
|
||||||
if ( !options.isSticky )
|
if ( !options.isSticky )
|
||||||
{
|
{
|
||||||
var topSpotInt = setInterval( function ()
|
var topSpotInt = setInterval( function ()
|
||||||
{
|
{
|
||||||
// Check to see if our notice is the first non-sticky notice in the list
|
// Check to see if our notice is the first non-sticky notice in the list
|
||||||
if ( notice.prevAll( '.not-sticky' ).length == 0 )
|
if ( notice.prevAll( '.not-sticky' ).length == 0 )
|
||||||
{
|
{
|
||||||
// Stop checking once the condition is met
|
// Stop checking once the condition is met
|
||||||
clearInterval( topSpotInt );
|
clearInterval( topSpotInt );
|
||||||
|
|
||||||
// Call the close action after the timeout set in options
|
// Call the close action after the timeout set in options
|
||||||
setTimeout( function ()
|
setTimeout( function ()
|
||||||
{
|
{
|
||||||
removeNotice();
|
removeNotice();
|
||||||
}, options.removeTimer
|
}, options.removeTimer
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}, 200 );
|
}, 200 );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function removeNotice ()
|
function removeNotice ()
|
||||||
{
|
{
|
||||||
// IE7 and earlier can't handle the combination of opacity and transparent pngs, so if we're using transparent pngs in our
|
// IE7 and earlier can't handle the combination of opacity and transparent pngs, so if we're using transparent pngs in our
|
||||||
// notice style, we'll just skip the fading out.
|
// notice style, we'll just skip the fading out.
|
||||||
if ( jQuery.browser.msie && options.usingTransparentPNG )
|
if ( jQuery.browser.msie && options.usingTransparentPNG )
|
||||||
{
|
{
|
||||||
notice.css( { opacity: 0 } )
|
notice.css( { opacity: 0 } )
|
||||||
.animate(
|
.animate(
|
||||||
{
|
{
|
||||||
height: '0px'
|
height: '0px'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
duration: options.fadeOutSpeed,
|
duration: options.fadeOutSpeed,
|
||||||
complete: function ()
|
complete: function ()
|
||||||
{
|
{
|
||||||
notice.remove();
|
notice.remove();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// Fade the object out before reducing its height to produce the sliding effect
|
// Fade the object out before reducing its height to produce the sliding effect
|
||||||
notice.animate(
|
notice.animate(
|
||||||
{
|
{
|
||||||
opacity: '0'
|
opacity: '0'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
duration: options.fadeOutSpeed,
|
duration: options.fadeOutSpeed,
|
||||||
complete: function ()
|
complete: function ()
|
||||||
{
|
{
|
||||||
notice.animate(
|
notice.animate(
|
||||||
{
|
{
|
||||||
height: '0px'
|
height: '0px'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
duration: options.fadeOutSpeed,
|
duration: options.fadeOutSpeed,
|
||||||
complete: function ()
|
complete: function ()
|
||||||
{
|
{
|
||||||
notice.remove();
|
notice.remove();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
$.fn.purr = function ( options )
|
$.fn.purr = function ( options )
|
||||||
{
|
{
|
||||||
options = options || {};
|
options = options || {};
|
||||||
options.fadeInSpeed = options.fadeInSpeed || 500;
|
options.fadeInSpeed = options.fadeInSpeed || 500;
|
||||||
options.fadeOutSpeed = options.fadeOutSpeed || 500;
|
options.fadeOutSpeed = options.fadeOutSpeed || 500;
|
||||||
options.removeTimer = options.removeTimer || 4000;
|
options.removeTimer = options.removeTimer || 4000;
|
||||||
options.isSticky = options.isSticky || false;
|
options.isSticky = options.isSticky || false;
|
||||||
options.usingTransparentPNG = options.usingTransparentPNG || false;
|
options.usingTransparentPNG = options.usingTransparentPNG || false;
|
||||||
|
|
||||||
this.each( function()
|
this.each( function()
|
||||||
{
|
{
|
||||||
new $.purr( this, options );
|
new $.purr( this, options );
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
};
|
};
|
||||||
})( jQuery );
|
})( jQuery );
|
||||||
|
|
||||||
|
|
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
@ -1,247 +1,247 @@
|
||||||
Metamaps.Backbone = {};
|
Metamaps.Backbone = {};
|
||||||
Metamaps.Backbone.Map = Backbone.Model.extend({
|
Metamaps.Backbone.Map = Backbone.Model.extend({
|
||||||
urlRoot: '/maps',
|
urlRoot: '/maps',
|
||||||
blacklist: ['created_at', 'updated_at', 'created_at_clean', 'updated_at_clean', 'user_name', 'contributor_count', 'topic_count', 'synapse_count', 'topics', 'synapses', 'mappings', 'mappers'],
|
blacklist: ['created_at', 'updated_at', 'created_at_clean', 'updated_at_clean', 'user_name', 'contributor_count', 'topic_count', 'synapse_count', 'topics', 'synapses', 'mappings', 'mappers'],
|
||||||
toJSON: function (options) {
|
toJSON: function (options) {
|
||||||
return _.omit(this.attributes, this.blacklist);
|
return _.omit(this.attributes, this.blacklist);
|
||||||
},
|
},
|
||||||
save: function (key, val, options) {
|
save: function (key, val, options) {
|
||||||
|
|
||||||
var attrs;
|
var attrs;
|
||||||
|
|
||||||
// Handle both `"key", value` and `{key: value}` -style arguments.
|
// Handle both `"key", value` and `{key: value}` -style arguments.
|
||||||
if (key == null || typeof key === 'object') {
|
if (key == null || typeof key === 'object') {
|
||||||
attrs = key;
|
attrs = key;
|
||||||
options = val;
|
options = val;
|
||||||
} else {
|
} else {
|
||||||
(attrs = {})[key] = val;
|
(attrs = {})[key] = val;
|
||||||
}
|
}
|
||||||
|
|
||||||
var newOptions = options || {};
|
var newOptions = options || {};
|
||||||
var s = newOptions.success;
|
var s = newOptions.success;
|
||||||
|
|
||||||
newOptions.success = function (model, response, opt) {
|
newOptions.success = function (model, response, opt) {
|
||||||
if (s) s(model, response, opt);
|
if (s) s(model, response, opt);
|
||||||
model.trigger('saved');
|
model.trigger('saved');
|
||||||
};
|
};
|
||||||
return Backbone.Model.prototype.save.call(this, attrs, newOptions);
|
return Backbone.Model.prototype.save.call(this, attrs, newOptions);
|
||||||
},
|
},
|
||||||
initialize: function () {
|
initialize: function () {
|
||||||
this.on('changeByOther', this.updateView);
|
this.on('changeByOther', this.updateView);
|
||||||
this.on('saved', this.savedEvent);
|
this.on('saved', this.savedEvent);
|
||||||
},
|
},
|
||||||
savedEvent: function() {
|
savedEvent: function() {
|
||||||
Metamaps.Realtime.sendMapChange(this);
|
Metamaps.Realtime.sendMapChange(this);
|
||||||
},
|
},
|
||||||
authorizeToEdit: function (mapper) {
|
authorizeToEdit: function (mapper) {
|
||||||
if (mapper && (this.get('permission') === "commons" || this.get('user_id') === mapper.get('id'))) return true;
|
if (mapper && (this.get('permission') === "commons" || this.get('user_id') === mapper.get('id'))) return true;
|
||||||
else return false;
|
else return false;
|
||||||
},
|
},
|
||||||
authorizePermissionChange: function (mapper) {
|
authorizePermissionChange: function (mapper) {
|
||||||
if (mapper && this.get('user_id') === mapper.get('id')) return true;
|
if (mapper && this.get('user_id') === mapper.get('id')) return true;
|
||||||
else return false;
|
else return false;
|
||||||
},
|
},
|
||||||
getUser: function () {
|
getUser: function () {
|
||||||
return Metamaps.Mapper.get(this.get('user_id'));
|
return Metamaps.Mapper.get(this.get('user_id'));
|
||||||
},
|
},
|
||||||
fetchContained: function () {
|
fetchContained: function () {
|
||||||
var bb = Metamaps.Backbone;
|
var bb = Metamaps.Backbone;
|
||||||
var that = this;
|
var that = this;
|
||||||
var start = function (data) {
|
var start = function (data) {
|
||||||
that.set('mappers', new bb.MapperCollection(data.mappers));
|
that.set('mappers', new bb.MapperCollection(data.mappers));
|
||||||
that.set('topics', new bb.TopicCollection(data.topics));
|
that.set('topics', new bb.TopicCollection(data.topics));
|
||||||
that.set('synapses', new bb.SynapseCollection(data.synapses));
|
that.set('synapses', new bb.SynapseCollection(data.synapses));
|
||||||
that.set('mappings', new bb.MappingCollection(data.mappings));
|
that.set('mappings', new bb.MappingCollection(data.mappings));
|
||||||
};
|
};
|
||||||
|
|
||||||
var e = $.ajax({
|
var e = $.ajax({
|
||||||
url: "/maps/" + this.id + "/contains.json",
|
url: "/maps/" + this.id + "/contains.json",
|
||||||
success: start,
|
success: start,
|
||||||
error: errorFunc,
|
error: errorFunc,
|
||||||
async: false
|
async: false
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
getTopics: function () {
|
getTopics: function () {
|
||||||
if (!this.get('topics')) {
|
if (!this.get('topics')) {
|
||||||
this.fetchContained();
|
this.fetchContained();
|
||||||
}
|
}
|
||||||
return this.get('topics');
|
return this.get('topics');
|
||||||
},
|
},
|
||||||
getSynapses: function () {
|
getSynapses: function () {
|
||||||
if (!this.get('synapses')) {
|
if (!this.get('synapses')) {
|
||||||
this.fetchContained();
|
this.fetchContained();
|
||||||
}
|
}
|
||||||
return this.get('synapses');
|
return this.get('synapses');
|
||||||
},
|
},
|
||||||
getMappings: function () {
|
getMappings: function () {
|
||||||
if (!this.get('mappings')) {
|
if (!this.get('mappings')) {
|
||||||
this.fetchContained();
|
this.fetchContained();
|
||||||
}
|
}
|
||||||
return this.get('mappings');
|
return this.get('mappings');
|
||||||
},
|
},
|
||||||
getMappers: function () {
|
getMappers: function () {
|
||||||
if (!this.get('mappers')) {
|
if (!this.get('mappers')) {
|
||||||
this.fetchContained();
|
this.fetchContained();
|
||||||
}
|
}
|
||||||
return this.get('mappers');
|
return this.get('mappers');
|
||||||
},
|
},
|
||||||
attrForCards: function () {
|
attrForCards: function () {
|
||||||
function capitalize(string) {
|
function capitalize(string) {
|
||||||
return string.charAt(0).toUpperCase() + string.slice(1);
|
return string.charAt(0).toUpperCase() + string.slice(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
var n = this.get('name');
|
var n = this.get('name');
|
||||||
var d = this.get('desc');
|
var d = this.get('desc');
|
||||||
|
|
||||||
var maxNameLength = 32;
|
var maxNameLength = 32;
|
||||||
var maxDescLength = 118;
|
var maxDescLength = 118;
|
||||||
var truncatedName = n ? (n.length > maxNameLength ? n.substring(0, maxNameLength) + "..." : n) : "";
|
var truncatedName = n ? (n.length > maxNameLength ? n.substring(0, maxNameLength) + "..." : n) : "";
|
||||||
var truncatedDesc = d ? (d.length > maxDescLength ? d.substring(0, maxDescLength) + "..." : d) : "";
|
var truncatedDesc = d ? (d.length > maxDescLength ? d.substring(0, maxDescLength) + "..." : d) : "";
|
||||||
|
|
||||||
var obj = {
|
var obj = {
|
||||||
id: this.id,
|
id: this.id,
|
||||||
name: truncatedName,
|
name: truncatedName,
|
||||||
fullName: n,
|
fullName: n,
|
||||||
desc: truncatedDesc,
|
desc: truncatedDesc,
|
||||||
permission: this.get("permission") ? capitalize(this.get("permission")) : "Commons",
|
permission: this.get("permission") ? capitalize(this.get("permission")) : "Commons",
|
||||||
editPermission: this.authorizeToEdit(Metamaps.Active.Mapper) ? 'canEdit' : 'cannotEdit',
|
editPermission: this.authorizeToEdit(Metamaps.Active.Mapper) ? 'canEdit' : 'cannotEdit',
|
||||||
contributor_count_number: '<span class="cCountColor">' + this.get('contributor_count') + '</span>',
|
contributor_count_number: '<span class="cCountColor">' + this.get('contributor_count') + '</span>',
|
||||||
contributor_count_string: this.get('contributor_count') == 1 ? ' contributor' : ' contributors',
|
contributor_count_string: this.get('contributor_count') == 1 ? ' contributor' : ' contributors',
|
||||||
topic_count_number: '<span class="tCountColor">' + this.get('topic_count') + '</span>',
|
topic_count_number: '<span class="tCountColor">' + this.get('topic_count') + '</span>',
|
||||||
topic_count_string: this.get('topic_count') == 1 ? ' topic' : ' topics',
|
topic_count_string: this.get('topic_count') == 1 ? ' topic' : ' topics',
|
||||||
synapse_count_number: '<span class="sCountColor">' + this.get('synapse_count') + '</span>',
|
synapse_count_number: '<span class="sCountColor">' + this.get('synapse_count') + '</span>',
|
||||||
synapse_count_string: this.get('synapse_count') == 1 ? ' synapse' : ' synapses',
|
synapse_count_string: this.get('synapse_count') == 1 ? ' synapse' : ' synapses',
|
||||||
screenshot: '<img src="' + this.get('screenshot_url') + '" />'
|
screenshot: '<img src="' + this.get('screenshot_url') + '" />'
|
||||||
};
|
};
|
||||||
return obj;
|
return obj;
|
||||||
},
|
},
|
||||||
updateView: function() {
|
updateView: function() {
|
||||||
var map = Metamaps.Active.Map;
|
var map = Metamaps.Active.Map;
|
||||||
var isActiveMap = this.id === map.id;
|
var isActiveMap = this.id === map.id;
|
||||||
var authorized = map && map.authorizeToEdit(Metamaps.Active.Mapper) ? 'canEditMap' : '';
|
var authorized = map && map.authorizeToEdit(Metamaps.Active.Mapper) ? 'canEditMap' : '';
|
||||||
var commonsMap = map && map.get('permission') === 'commons' ? 'commonsMap' : '';
|
var commonsMap = map && map.get('permission') === 'commons' ? 'commonsMap' : '';
|
||||||
if (isActiveMap) {
|
if (isActiveMap) {
|
||||||
Metamaps.Map.InfoBox.updateNameDescPerm(this.get('name'), this.get('desc'), this.get('permission'));
|
Metamaps.Map.InfoBox.updateNameDescPerm(this.get('name'), this.get('desc'), this.get('permission'));
|
||||||
this.updateMapWrapper();
|
this.updateMapWrapper();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
updateMapWrapper: function() {
|
updateMapWrapper: function() {
|
||||||
var map = Metamaps.Active.Map;
|
var map = Metamaps.Active.Map;
|
||||||
var isActiveMap = this.id === map.id;
|
var isActiveMap = this.id === map.id;
|
||||||
var authorized = map && map.authorizeToEdit(Metamaps.Active.Mapper) ? 'canEditMap' : '';
|
var authorized = map && map.authorizeToEdit(Metamaps.Active.Mapper) ? 'canEditMap' : '';
|
||||||
var commonsMap = map && map.get('permission') === 'commons' ? 'commonsMap' : '';
|
var commonsMap = map && map.get('permission') === 'commons' ? 'commonsMap' : '';
|
||||||
if (isActiveMap) {
|
if (isActiveMap) {
|
||||||
$('.wrapper').removeClass('canEditMap commonsMap').addClass(authorized + ' ' + commonsMap);
|
$('.wrapper').removeClass('canEditMap commonsMap').addClass(authorized + ' ' + commonsMap);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Metamaps.Backbone.MapsCollection = Backbone.Collection.extend({
|
Metamaps.Backbone.MapsCollection = Backbone.Collection.extend({
|
||||||
model: Metamaps.Backbone.Map,
|
model: Metamaps.Backbone.Map,
|
||||||
initialize: function(models, options) {
|
initialize: function(models, options) {
|
||||||
this.id = options.id;
|
this.id = options.id;
|
||||||
this.sortBy = options.sortBy;
|
this.sortBy = options.sortBy;
|
||||||
|
|
||||||
if (options.mapperId) {
|
if (options.mapperId) {
|
||||||
this.mapperId = options.mapperId;
|
this.mapperId = options.mapperId;
|
||||||
}
|
}
|
||||||
|
|
||||||
// this.page represents the NEXT page to fetch
|
// this.page represents the NEXT page to fetch
|
||||||
this.page = models.length > 0 ? (models.length < 20 ? "loadedAll" : 2) : 1;
|
this.page = models.length > 0 ? (models.length < 20 ? "loadedAll" : 2) : 1;
|
||||||
},
|
},
|
||||||
url: function() {
|
url: function() {
|
||||||
if (!this.mapperId) {
|
if (!this.mapperId) {
|
||||||
return '/explore/' + this.id + '.json';
|
return '/explore/' + this.id + '.json';
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return '/explore/mapper/' + this.mapperId + '.json';
|
return '/explore/mapper/' + this.mapperId + '.json';
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
comparator: function (a, b) {
|
comparator: function (a, b) {
|
||||||
a = a.get(this.sortBy);
|
a = a.get(this.sortBy);
|
||||||
b = b.get(this.sortBy);
|
b = b.get(this.sortBy);
|
||||||
var temp;
|
var temp;
|
||||||
if (this.sortBy === 'name') {
|
if (this.sortBy === 'name') {
|
||||||
a = a ? a.toLowerCase() : "";
|
a = a ? a.toLowerCase() : "";
|
||||||
b = b ? b.toLowerCase() : "";
|
b = b ? b.toLowerCase() : "";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
// this is for updated_at and created_at
|
// this is for updated_at and created_at
|
||||||
temp = a;
|
temp = a;
|
||||||
a = b;
|
a = b;
|
||||||
b = temp;
|
b = temp;
|
||||||
a = (new Date(a)).getTime();
|
a = (new Date(a)).getTime();
|
||||||
b = (new Date(b)).getTime();
|
b = (new Date(b)).getTime();
|
||||||
}
|
}
|
||||||
return a > b ? 1 : a < b ? -1 : 0;
|
return a > b ? 1 : a < b ? -1 : 0;
|
||||||
},
|
},
|
||||||
getMaps: function (cb) {
|
getMaps: function (cb) {
|
||||||
|
|
||||||
var self = this;
|
var self = this;
|
||||||
|
|
||||||
Metamaps.Loading.show();
|
Metamaps.Loading.show();
|
||||||
|
|
||||||
if (this.page != "loadedAll") {
|
if (this.page != "loadedAll") {
|
||||||
var numBefore = this.length;
|
var numBefore = this.length;
|
||||||
this.fetch({
|
this.fetch({
|
||||||
remove: false,
|
remove: false,
|
||||||
silent: true,
|
silent: true,
|
||||||
data: { page: this.page },
|
data: { page: this.page },
|
||||||
success: function (collection, response, options) {
|
success: function (collection, response, options) {
|
||||||
// you can pass additional options to the event you trigger here as well
|
// you can pass additional options to the event you trigger here as well
|
||||||
if (collection.length - numBefore < 20) {
|
if (collection.length - numBefore < 20) {
|
||||||
self.page = "loadedAll";
|
self.page = "loadedAll";
|
||||||
}
|
}
|
||||||
else self.page += 1;
|
else self.page += 1;
|
||||||
self.trigger('successOnFetch', cb);
|
self.trigger('successOnFetch', cb);
|
||||||
},
|
},
|
||||||
error: function (collection, response, options) {
|
error: function (collection, response, options) {
|
||||||
// you can pass additional options to the event you trigger here as well
|
// you can pass additional options to the event you trigger here as well
|
||||||
self.trigger('errorOnFetch');
|
self.trigger('errorOnFetch');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
self.trigger('successOnFetch', cb);
|
self.trigger('successOnFetch', cb);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
Metamaps.Backbone.Message = Backbone.Model.extend({
|
Metamaps.Backbone.Message = Backbone.Model.extend({
|
||||||
urlRoot: '/messages',
|
urlRoot: '/messages',
|
||||||
blacklist: ['created_at', 'updated_at'],
|
blacklist: ['created_at', 'updated_at'],
|
||||||
toJSON: function (options) {
|
toJSON: function (options) {
|
||||||
return _.omit(this.attributes, this.blacklist);
|
return _.omit(this.attributes, this.blacklist);
|
||||||
},
|
},
|
||||||
prepareLiForFilter: function () {
|
prepareLiForFilter: function () {
|
||||||
/*var li = '';
|
/*var li = '';
|
||||||
li += '<li data-id="' + this.id.toString() + '">';
|
li += '<li data-id="' + this.id.toString() + '">';
|
||||||
li += '<img src="' + this.get("image") + '" data-id="' + this.id.toString() + '"';
|
li += '<img src="' + this.get("image") + '" data-id="' + this.id.toString() + '"';
|
||||||
li += ' alt="' + this.get('name') + '" />';
|
li += ' alt="' + this.get('name') + '" />';
|
||||||
li += '<p>' + this.get('name') + '</p></li>';
|
li += '<p>' + this.get('name') + '</p></li>';
|
||||||
return li;*/
|
return li;*/
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Metamaps.Backbone.MessageCollection = Backbone.Collection.extend({
|
Metamaps.Backbone.MessageCollection = Backbone.Collection.extend({
|
||||||
model: Metamaps.Backbone.Message,
|
model: Metamaps.Backbone.Message,
|
||||||
url: '/messages'
|
url: '/messages'
|
||||||
});
|
});
|
||||||
|
|
||||||
Metamaps.Backbone.Mapper = Backbone.Model.extend({
|
Metamaps.Backbone.Mapper = Backbone.Model.extend({
|
||||||
urlRoot: '/users',
|
urlRoot: '/users',
|
||||||
blacklist: ['created_at', 'updated_at'],
|
blacklist: ['created_at', 'updated_at'],
|
||||||
toJSON: function (options) {
|
toJSON: function (options) {
|
||||||
return _.omit(this.attributes, this.blacklist);
|
return _.omit(this.attributes, this.blacklist);
|
||||||
},
|
},
|
||||||
prepareLiForFilter: function () {
|
prepareLiForFilter: function () {
|
||||||
var li = '';
|
var li = '';
|
||||||
li += '<li data-id="' + this.id.toString() + '">';
|
li += '<li data-id="' + this.id.toString() + '">';
|
||||||
li += '<img src="' + this.get("image") + '" data-id="' + this.id.toString() + '"';
|
li += '<img src="' + this.get("image") + '" data-id="' + this.id.toString() + '"';
|
||||||
li += ' alt="' + this.get('name') + '" />';
|
li += ' alt="' + this.get('name') + '" />';
|
||||||
li += '<p>' + this.get('name') + '</p></li>';
|
li += '<p>' + this.get('name') + '</p></li>';
|
||||||
return li;
|
return li;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Metamaps.Backbone.MapperCollection = Backbone.Collection.extend({
|
Metamaps.Backbone.MapperCollection = Backbone.Collection.extend({
|
||||||
model: Metamaps.Backbone.Mapper,
|
model: Metamaps.Backbone.Mapper,
|
||||||
url: '/users'
|
url: '/users'
|
||||||
});
|
});
|
||||||
|
|
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
@ -1,262 +1,262 @@
|
||||||
(function () {
|
(function () {
|
||||||
|
|
||||||
Metamaps.currentPage = "";
|
Metamaps.currentPage = "";
|
||||||
|
|
||||||
var Router = Backbone.Router.extend({
|
var Router = Backbone.Router.extend({
|
||||||
routes: {
|
routes: {
|
||||||
"": "home", // #home
|
"": "home", // #home
|
||||||
"explore/:section": "explore", // #explore/active
|
"explore/:section": "explore", // #explore/active
|
||||||
"explore/:section/:id": "explore", // #explore/mapper/1234
|
"explore/:section/:id": "explore", // #explore/mapper/1234
|
||||||
"maps/:id": "maps" // #maps/7
|
"maps/:id": "maps" // #maps/7
|
||||||
},
|
},
|
||||||
home: function () {
|
home: function () {
|
||||||
clearTimeout(Metamaps.routerTimeoutId);
|
clearTimeout(Metamaps.routerTimeoutId);
|
||||||
|
|
||||||
if (Metamaps.Active.Mapper) document.title = 'Explore Active Maps | Metamaps';
|
if (Metamaps.Active.Mapper) document.title = 'Explore Active Maps | Metamaps';
|
||||||
else document.title = 'Home | Metamaps';
|
else document.title = 'Home | Metamaps';
|
||||||
|
|
||||||
Metamaps.currentSection = "";
|
Metamaps.currentSection = "";
|
||||||
Metamaps.currentPage = "";
|
Metamaps.currentPage = "";
|
||||||
$('.wrapper').removeClass('mapPage topicPage');
|
$('.wrapper').removeClass('mapPage topicPage');
|
||||||
|
|
||||||
var classes = Metamaps.Active.Mapper ? "homePage explorePage" : "homePage";
|
var classes = Metamaps.Active.Mapper ? "homePage explorePage" : "homePage";
|
||||||
$('.wrapper').addClass(classes);
|
$('.wrapper').addClass(classes);
|
||||||
|
|
||||||
var navigate = function() {
|
var navigate = function() {
|
||||||
Metamaps.routerTimeoutId = setTimeout(function() {
|
Metamaps.routerTimeoutId = setTimeout(function() {
|
||||||
Metamaps.Router.navigate("");
|
Metamaps.Router.navigate("");
|
||||||
}, 300);
|
}, 300);
|
||||||
};
|
};
|
||||||
// all this only for the logged in home page
|
// all this only for the logged in home page
|
||||||
if (Metamaps.Active.Mapper) {
|
if (Metamaps.Active.Mapper) {
|
||||||
|
|
||||||
Metamaps.Famous.yield.hide();
|
Metamaps.Famous.yield.hide();
|
||||||
|
|
||||||
Metamaps.Famous.explore.set('active');
|
Metamaps.Famous.explore.set('active');
|
||||||
Metamaps.Famous.maps.resetScroll(); // sets the scroll back to the top
|
Metamaps.Famous.maps.resetScroll(); // sets the scroll back to the top
|
||||||
Metamaps.Famous.explore.show();
|
Metamaps.Famous.explore.show();
|
||||||
|
|
||||||
Metamaps.Famous.maps.show();
|
Metamaps.Famous.maps.show();
|
||||||
|
|
||||||
Metamaps.GlobalUI.Search.open();
|
Metamaps.GlobalUI.Search.open();
|
||||||
Metamaps.GlobalUI.Search.lock();
|
Metamaps.GlobalUI.Search.lock();
|
||||||
|
|
||||||
Metamaps.Views.exploreMaps.setCollection( Metamaps.Maps.Active );
|
Metamaps.Views.exploreMaps.setCollection( Metamaps.Maps.Active );
|
||||||
if (Metamaps.Maps.Active.length === 0) {
|
if (Metamaps.Maps.Active.length === 0) {
|
||||||
Metamaps.Maps.Active.getMaps(navigate); // this will trigger an explore maps render
|
Metamaps.Maps.Active.getMaps(navigate); // this will trigger an explore maps render
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
Metamaps.Views.exploreMaps.render(navigate);
|
Metamaps.Views.exploreMaps.render(navigate);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// logged out home page
|
// logged out home page
|
||||||
else {
|
else {
|
||||||
|
|
||||||
Metamaps.Famous.yield.show();
|
Metamaps.Famous.yield.show();
|
||||||
|
|
||||||
Metamaps.Famous.explore.hide();
|
Metamaps.Famous.explore.hide();
|
||||||
|
|
||||||
Metamaps.GlobalUI.Search.unlock();
|
Metamaps.GlobalUI.Search.unlock();
|
||||||
Metamaps.GlobalUI.Search.close(0, true);
|
Metamaps.GlobalUI.Search.close(0, true);
|
||||||
|
|
||||||
Metamaps.Famous.maps.hide();
|
Metamaps.Famous.maps.hide();
|
||||||
Metamaps.routerTimeoutId = setTimeout(navigate, 500);
|
Metamaps.routerTimeoutId = setTimeout(navigate, 500);
|
||||||
}
|
}
|
||||||
|
|
||||||
Metamaps.Famous.viz.hide();
|
Metamaps.Famous.viz.hide();
|
||||||
Metamaps.Map.end();
|
Metamaps.Map.end();
|
||||||
Metamaps.Topic.end();
|
Metamaps.Topic.end();
|
||||||
Metamaps.Active.Map = null;
|
Metamaps.Active.Map = null;
|
||||||
Metamaps.Active.Topic = null;
|
Metamaps.Active.Topic = null;
|
||||||
},
|
},
|
||||||
explore: function (section, id) {
|
explore: function (section, id) {
|
||||||
clearTimeout(Metamaps.routerTimeoutId);
|
clearTimeout(Metamaps.routerTimeoutId);
|
||||||
|
|
||||||
// just capitalize the variable section
|
// just capitalize the variable section
|
||||||
// either 'featured', 'mapper', or 'active'
|
// either 'featured', 'mapper', or 'active'
|
||||||
var capitalize = section.charAt(0).toUpperCase() + section.slice(1);
|
var capitalize = section.charAt(0).toUpperCase() + section.slice(1);
|
||||||
|
|
||||||
if (section === "featured" || section === "active") {
|
if (section === "featured" || section === "active") {
|
||||||
document.title = 'Explore ' + capitalize + ' Maps | Metamaps';
|
document.title = 'Explore ' + capitalize + ' Maps | Metamaps';
|
||||||
}
|
}
|
||||||
else if (section === "mapper") {
|
else if (section === "mapper") {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: "/users/" + id + ".json",
|
url: "/users/" + id + ".json",
|
||||||
success: function (response) {
|
success: function (response) {
|
||||||
document.title = response.name + ' | Metamaps';
|
document.title = response.name + ' | Metamaps';
|
||||||
},
|
},
|
||||||
error: function () {
|
error: function () {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
else if (section === "mine") {
|
else if (section === "mine") {
|
||||||
document.title = 'Explore My Maps | Metamaps';
|
document.title = 'Explore My Maps | Metamaps';
|
||||||
}
|
}
|
||||||
|
|
||||||
$('.wrapper').removeClass('homePage mapPage topicPage');
|
$('.wrapper').removeClass('homePage mapPage topicPage');
|
||||||
$('.wrapper').addClass('explorePage');
|
$('.wrapper').addClass('explorePage');
|
||||||
|
|
||||||
Metamaps.currentSection = "explore";
|
Metamaps.currentSection = "explore";
|
||||||
Metamaps.currentPage = section;
|
Metamaps.currentPage = section;
|
||||||
|
|
||||||
// this will mean it's a mapper page being loaded
|
// this will mean it's a mapper page being loaded
|
||||||
if (id) {
|
if (id) {
|
||||||
if (Metamaps.Maps.Mapper.mapperId !== id) {
|
if (Metamaps.Maps.Mapper.mapperId !== id) {
|
||||||
// empty the collection if we are trying to load the maps
|
// empty the collection if we are trying to load the maps
|
||||||
// collection of a different mapper than we had previously
|
// collection of a different mapper than we had previously
|
||||||
Metamaps.Maps.Mapper.reset();
|
Metamaps.Maps.Mapper.reset();
|
||||||
Metamaps.Maps.Mapper.page = 1;
|
Metamaps.Maps.Mapper.page = 1;
|
||||||
}
|
}
|
||||||
Metamaps.Maps.Mapper.mapperId = id;
|
Metamaps.Maps.Mapper.mapperId = id;
|
||||||
}
|
}
|
||||||
|
|
||||||
Metamaps.Views.exploreMaps.setCollection( Metamaps.Maps[capitalize] );
|
Metamaps.Views.exploreMaps.setCollection( Metamaps.Maps[capitalize] );
|
||||||
|
|
||||||
var navigate = function(){
|
var navigate = function(){
|
||||||
var path = "/explore/" + Metamaps.currentPage;
|
var path = "/explore/" + Metamaps.currentPage;
|
||||||
|
|
||||||
// alter url if for mapper profile page
|
// alter url if for mapper profile page
|
||||||
if (Metamaps.currentPage == "mapper") {
|
if (Metamaps.currentPage == "mapper") {
|
||||||
path += "/" + Metamaps.Maps.Mapper.mapperId;
|
path += "/" + Metamaps.Maps.Mapper.mapperId;
|
||||||
}
|
}
|
||||||
|
|
||||||
Metamaps.Router.navigate(path);
|
Metamaps.Router.navigate(path);
|
||||||
};
|
};
|
||||||
var navigateTimeout = function() {
|
var navigateTimeout = function() {
|
||||||
Metamaps.routerTimeoutId = setTimeout(navigate, 300);
|
Metamaps.routerTimeoutId = setTimeout(navigate, 300);
|
||||||
};
|
};
|
||||||
if (Metamaps.Maps[capitalize].length === 0) {
|
if (Metamaps.Maps[capitalize].length === 0) {
|
||||||
Metamaps.Loading.show();
|
Metamaps.Loading.show();
|
||||||
setTimeout(function(){
|
setTimeout(function(){
|
||||||
Metamaps.Maps[capitalize].getMaps(navigate); // this will trigger an explore maps render
|
Metamaps.Maps[capitalize].getMaps(navigate); // this will trigger an explore maps render
|
||||||
}, 300); // wait 300 milliseconds till the other animations are done to do the fetch
|
}, 300); // wait 300 milliseconds till the other animations are done to do the fetch
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (id) {
|
if (id) {
|
||||||
Metamaps.Views.exploreMaps.fetchUserThenRender(navigateTimeout);
|
Metamaps.Views.exploreMaps.fetchUserThenRender(navigateTimeout);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
Metamaps.Views.exploreMaps.render(navigateTimeout);
|
Metamaps.Views.exploreMaps.render(navigateTimeout);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Metamaps.GlobalUI.Search.open();
|
Metamaps.GlobalUI.Search.open();
|
||||||
Metamaps.GlobalUI.Search.lock();
|
Metamaps.GlobalUI.Search.lock();
|
||||||
|
|
||||||
Metamaps.Famous.yield.hide();
|
Metamaps.Famous.yield.hide();
|
||||||
|
|
||||||
Metamaps.Famous.maps.resetScroll(); // sets the scroll back to the top
|
Metamaps.Famous.maps.resetScroll(); // sets the scroll back to the top
|
||||||
Metamaps.Famous.maps.show();
|
Metamaps.Famous.maps.show();
|
||||||
Metamaps.Famous.explore.set(section, id);
|
Metamaps.Famous.explore.set(section, id);
|
||||||
Metamaps.Famous.explore.show();
|
Metamaps.Famous.explore.show();
|
||||||
|
|
||||||
Metamaps.Famous.viz.hide();
|
Metamaps.Famous.viz.hide();
|
||||||
Metamaps.Map.end();
|
Metamaps.Map.end();
|
||||||
Metamaps.Topic.end();
|
Metamaps.Topic.end();
|
||||||
Metamaps.Active.Map = null;
|
Metamaps.Active.Map = null;
|
||||||
Metamaps.Active.Topic = null;
|
Metamaps.Active.Topic = null;
|
||||||
},
|
},
|
||||||
maps: function (id) {
|
maps: function (id) {
|
||||||
clearTimeout(Metamaps.routerTimeoutId);
|
clearTimeout(Metamaps.routerTimeoutId);
|
||||||
|
|
||||||
document.title = 'Map ' + id + ' | Metamaps';
|
document.title = 'Map ' + id + ' | Metamaps';
|
||||||
|
|
||||||
Metamaps.currentSection = "map";
|
Metamaps.currentSection = "map";
|
||||||
Metamaps.currentPage = id;
|
Metamaps.currentPage = id;
|
||||||
|
|
||||||
$('.wrapper').removeClass('homePage explorePage topicPage');
|
$('.wrapper').removeClass('homePage explorePage topicPage');
|
||||||
$('.wrapper').addClass('mapPage');
|
$('.wrapper').addClass('mapPage');
|
||||||
// another class will be added to wrapper if you
|
// another class will be added to wrapper if you
|
||||||
// can edit this map '.canEditMap'
|
// can edit this map '.canEditMap'
|
||||||
|
|
||||||
Metamaps.Famous.yield.hide();
|
Metamaps.Famous.yield.hide();
|
||||||
Metamaps.Famous.maps.hide();
|
Metamaps.Famous.maps.hide();
|
||||||
Metamaps.Famous.explore.hide();
|
Metamaps.Famous.explore.hide();
|
||||||
|
|
||||||
// clear the visualization, if there was one, before showing its div again
|
// clear the visualization, if there was one, before showing its div again
|
||||||
if (Metamaps.Visualize.mGraph) {
|
if (Metamaps.Visualize.mGraph) {
|
||||||
Metamaps.Visualize.mGraph.graph.empty();
|
Metamaps.Visualize.mGraph.graph.empty();
|
||||||
Metamaps.Visualize.mGraph.plot();
|
Metamaps.Visualize.mGraph.plot();
|
||||||
Metamaps.JIT.centerMap(Metamaps.Visualize.mGraph.canvas);
|
Metamaps.JIT.centerMap(Metamaps.Visualize.mGraph.canvas);
|
||||||
}
|
}
|
||||||
Metamaps.Famous.viz.show();
|
Metamaps.Famous.viz.show();
|
||||||
Metamaps.Topic.end();
|
Metamaps.Topic.end();
|
||||||
Metamaps.Active.Topic = null;
|
Metamaps.Active.Topic = null;
|
||||||
|
|
||||||
Metamaps.GlobalUI.Search.unlock();
|
Metamaps.GlobalUI.Search.unlock();
|
||||||
Metamaps.GlobalUI.Search.close(0, true);
|
Metamaps.GlobalUI.Search.close(0, true);
|
||||||
|
|
||||||
Metamaps.Loading.show();
|
Metamaps.Loading.show();
|
||||||
Metamaps.Map.end();
|
Metamaps.Map.end();
|
||||||
Metamaps.Map.launch(id);
|
Metamaps.Map.launch(id);
|
||||||
},
|
},
|
||||||
topics: function (id) {
|
topics: function (id) {
|
||||||
clearTimeout(Metamaps.routerTimeoutId);
|
clearTimeout(Metamaps.routerTimeoutId);
|
||||||
|
|
||||||
document.title = 'Topic ' + id + ' | Metamaps';
|
document.title = 'Topic ' + id + ' | Metamaps';
|
||||||
|
|
||||||
Metamaps.currentSection = "topic";
|
Metamaps.currentSection = "topic";
|
||||||
Metamaps.currentPage = id;
|
Metamaps.currentPage = id;
|
||||||
|
|
||||||
$('.wrapper').removeClass('homePage explorePage mapPage');
|
$('.wrapper').removeClass('homePage explorePage mapPage');
|
||||||
$('.wrapper').addClass('topicPage');
|
$('.wrapper').addClass('topicPage');
|
||||||
|
|
||||||
Metamaps.Famous.yield.hide();
|
Metamaps.Famous.yield.hide();
|
||||||
Metamaps.Famous.maps.hide();
|
Metamaps.Famous.maps.hide();
|
||||||
Metamaps.Famous.explore.hide();
|
Metamaps.Famous.explore.hide();
|
||||||
|
|
||||||
// clear the visualization, if there was one, before showing its div again
|
// clear the visualization, if there was one, before showing its div again
|
||||||
if (Metamaps.Visualize.mGraph) {
|
if (Metamaps.Visualize.mGraph) {
|
||||||
Metamaps.Visualize.mGraph.graph.empty();
|
Metamaps.Visualize.mGraph.graph.empty();
|
||||||
Metamaps.Visualize.mGraph.plot();
|
Metamaps.Visualize.mGraph.plot();
|
||||||
Metamaps.JIT.centerMap(Metamaps.Visualize.mGraph.canvas);
|
Metamaps.JIT.centerMap(Metamaps.Visualize.mGraph.canvas);
|
||||||
}
|
}
|
||||||
Metamaps.Famous.viz.show();
|
Metamaps.Famous.viz.show();
|
||||||
Metamaps.Map.end();
|
Metamaps.Map.end();
|
||||||
Metamaps.Active.Map = null;
|
Metamaps.Active.Map = null;
|
||||||
|
|
||||||
Metamaps.GlobalUI.Search.unlock();
|
Metamaps.GlobalUI.Search.unlock();
|
||||||
Metamaps.GlobalUI.Search.close(0, true);
|
Metamaps.GlobalUI.Search.close(0, true);
|
||||||
|
|
||||||
Metamaps.Topic.end();
|
Metamaps.Topic.end();
|
||||||
Metamaps.Topic.launch(id);
|
Metamaps.Topic.launch(id);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
Metamaps.Router = new Router();
|
Metamaps.Router = new Router();
|
||||||
|
|
||||||
|
|
||||||
Metamaps.Router.intercept = function (evt) {
|
Metamaps.Router.intercept = function (evt) {
|
||||||
var segments;
|
var segments;
|
||||||
|
|
||||||
var href = {
|
var href = {
|
||||||
prop: $(this).prop("href"),
|
prop: $(this).prop("href"),
|
||||||
attr: $(this).attr("href")
|
attr: $(this).attr("href")
|
||||||
};
|
};
|
||||||
var root = location.protocol + "//" + location.host + Backbone.history.options.root;
|
var root = location.protocol + "//" + location.host + Backbone.history.options.root;
|
||||||
|
|
||||||
if (href.prop && href.prop === root) href.attr = "";
|
if (href.prop && href.prop === root) href.attr = "";
|
||||||
|
|
||||||
if (href.prop && href.prop.slice(0, root.length) === root) {
|
if (href.prop && href.prop.slice(0, root.length) === root) {
|
||||||
evt.preventDefault();
|
evt.preventDefault();
|
||||||
|
|
||||||
segments = href.attr.split('/');
|
segments = href.attr.split('/');
|
||||||
segments.splice(0,1); // pop off the element created by the first /
|
segments.splice(0,1); // pop off the element created by the first /
|
||||||
|
|
||||||
if (href.attr === "") Metamaps.Router.home();
|
if (href.attr === "") Metamaps.Router.home();
|
||||||
else {
|
else {
|
||||||
Metamaps.Router[segments[0]](segments[1], segments[2]);
|
Metamaps.Router[segments[0]](segments[1], segments[2]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
Metamaps.Router.init = function () {
|
Metamaps.Router.init = function () {
|
||||||
Backbone.history.start({
|
Backbone.history.start({
|
||||||
silent: true,
|
silent: true,
|
||||||
pushState: true,
|
pushState: true,
|
||||||
root: '/'
|
root: '/'
|
||||||
});
|
});
|
||||||
$(document).on("click", "a:not([data-bypass])", Metamaps.Router.intercept);
|
$(document).on("click", "a:not([data-bypass])", Metamaps.Router.intercept);
|
||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
|
@ -1,133 +1,133 @@
|
||||||
(function () {
|
(function () {
|
||||||
Metamaps.Views = {};
|
Metamaps.Views = {};
|
||||||
|
|
||||||
var initialized = false;
|
var initialized = false;
|
||||||
|
|
||||||
Metamaps.Views.init = function () {
|
Metamaps.Views.init = function () {
|
||||||
|
|
||||||
Metamaps.Views.MapperCard = Backbone.View.extend({
|
Metamaps.Views.MapperCard = Backbone.View.extend({
|
||||||
|
|
||||||
template: Hogan.compile( $('#mapperCardTemplate').html() ),
|
template: Hogan.compile( $('#mapperCardTemplate').html() ),
|
||||||
|
|
||||||
tagNamea: "div",
|
tagNamea: "div",
|
||||||
|
|
||||||
className: "mapper",
|
className: "mapper",
|
||||||
|
|
||||||
render: function () {
|
render: function () {
|
||||||
this.$el.html( this.template.render(this.model) );
|
this.$el.html( this.template.render(this.model) );
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
Metamaps.Views.MapCard = Backbone.View.extend({
|
Metamaps.Views.MapCard = Backbone.View.extend({
|
||||||
|
|
||||||
template: Hogan.compile( $('#mapCardTemplate').html() ),
|
template: Hogan.compile( $('#mapCardTemplate').html() ),
|
||||||
|
|
||||||
tagName: "div",
|
tagName: "div",
|
||||||
|
|
||||||
className: "map",
|
className: "map",
|
||||||
|
|
||||||
id: function() {
|
id: function() {
|
||||||
return this.model.id;
|
return this.model.id;
|
||||||
},
|
},
|
||||||
|
|
||||||
initialize: function () {
|
initialize: function () {
|
||||||
this.listenTo(this.model, "change", this.render);
|
this.listenTo(this.model, "change", this.render);
|
||||||
},
|
},
|
||||||
|
|
||||||
render: function () {
|
render: function () {
|
||||||
this.$el.html( this.template.render(this.model.attrForCards()) );
|
this.$el.html( this.template.render(this.model.attrForCards()) );
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
var mapsWrapper = Backbone.View.extend({
|
var mapsWrapper = Backbone.View.extend({
|
||||||
|
|
||||||
initialize: function (opts) {
|
initialize: function (opts) {
|
||||||
|
|
||||||
},
|
},
|
||||||
setCollection: function (collection) {
|
setCollection: function (collection) {
|
||||||
if (this.collection) this.stopListening(this.collection);
|
if (this.collection) this.stopListening(this.collection);
|
||||||
this.collection = collection;
|
this.collection = collection;
|
||||||
this.listenTo(this.collection, 'add', this.render);
|
this.listenTo(this.collection, 'add', this.render);
|
||||||
this.listenTo(this.collection, 'successOnFetch', this.handleSuccess);
|
this.listenTo(this.collection, 'successOnFetch', this.handleSuccess);
|
||||||
this.listenTo(this.collection, 'errorOnFetch', this.handleError);
|
this.listenTo(this.collection, 'errorOnFetch', this.handleError);
|
||||||
},
|
},
|
||||||
render: function (mapperObj, cb) {
|
render: function (mapperObj, cb) {
|
||||||
|
|
||||||
var that = this;
|
var that = this;
|
||||||
|
|
||||||
if (typeof mapperObj === "function") {
|
if (typeof mapperObj === "function") {
|
||||||
var cb = mapperObj;
|
var cb = mapperObj;
|
||||||
mapperObj = null;
|
mapperObj = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.el.innerHTML = "";
|
this.el.innerHTML = "";
|
||||||
|
|
||||||
// in case it is a page where we have to display the mapper card
|
// in case it is a page where we have to display the mapper card
|
||||||
if (mapperObj) {
|
if (mapperObj) {
|
||||||
var view = new Metamaps.Views.MapperCard({ model: mapperObj });
|
var view = new Metamaps.Views.MapperCard({ model: mapperObj });
|
||||||
|
|
||||||
that.el.appendChild( view.render().el );
|
that.el.appendChild( view.render().el );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
this.collection.each(function (map) {
|
this.collection.each(function (map) {
|
||||||
var view = new Metamaps.Views.MapCard({ model: map });
|
var view = new Metamaps.Views.MapCard({ model: map });
|
||||||
|
|
||||||
that.el.appendChild( view.render().el );
|
that.el.appendChild( view.render().el );
|
||||||
});
|
});
|
||||||
this.$el.append('<div class="clearfloat"></div>');
|
this.$el.append('<div class="clearfloat"></div>');
|
||||||
var m = Metamaps.Famous.maps.surf;
|
var m = Metamaps.Famous.maps.surf;
|
||||||
m.setContent(this.el);
|
m.setContent(this.el);
|
||||||
|
|
||||||
var updateHeight = function(){
|
var updateHeight = function(){
|
||||||
var height = $(that.el).height() + 32 + 56;
|
var height = $(that.el).height() + 32 + 56;
|
||||||
m.setSize([undefined, height]);
|
m.setSize([undefined, height]);
|
||||||
Metamaps.Famous.maps.lock = false;
|
Metamaps.Famous.maps.lock = false;
|
||||||
if (cb) cb();
|
if (cb) cb();
|
||||||
};
|
};
|
||||||
|
|
||||||
if (!initialized) {
|
if (!initialized) {
|
||||||
m.deploy(m._currTarget);
|
m.deploy(m._currTarget);
|
||||||
initialized = true;
|
initialized = true;
|
||||||
setTimeout(updateHeight, 100);
|
setTimeout(updateHeight, 100);
|
||||||
} else {
|
} else {
|
||||||
setTimeout(updateHeight, 100);
|
setTimeout(updateHeight, 100);
|
||||||
}
|
}
|
||||||
|
|
||||||
Metamaps.Loading.hide();
|
Metamaps.Loading.hide();
|
||||||
},
|
},
|
||||||
handleSuccess: function (cb) {
|
handleSuccess: function (cb) {
|
||||||
var that = this;
|
var that = this;
|
||||||
|
|
||||||
if (this.collection && this.collection.id === "mapper") {
|
if (this.collection && this.collection.id === "mapper") {
|
||||||
this.fetchUserThenRender(cb);
|
this.fetchUserThenRender(cb);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
this.render(cb);
|
this.render(cb);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
handleError: function () {
|
handleError: function () {
|
||||||
console.log('error loading maps!'); //TODO
|
console.log('error loading maps!'); //TODO
|
||||||
},
|
},
|
||||||
fetchUserThenRender: function (cb) {
|
fetchUserThenRender: function (cb) {
|
||||||
var that = this;
|
var that = this;
|
||||||
// first load the mapper object and then call the render function
|
// first load the mapper object and then call the render function
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: "/users/" + this.collection.mapperId + "/details.json",
|
url: "/users/" + this.collection.mapperId + "/details.json",
|
||||||
success: function (response) {
|
success: function (response) {
|
||||||
that.render(response, cb);
|
that.render(response, cb);
|
||||||
},
|
},
|
||||||
error: function () {
|
error: function () {
|
||||||
that.render(cb);
|
that.render(cb);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
Metamaps.Views.exploreMaps = new mapsWrapper();
|
Metamaps.Views.exploreMaps = new mapsWrapper();
|
||||||
};
|
};
|
||||||
|
|
||||||
})();
|
})();
|
||||||
|
|
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
@ -1,474 +1,474 @@
|
||||||
/*! jQuery UI - v1.9.2 - 2012-11-23
|
/*! jQuery UI - v1.9.2 - 2012-11-23
|
||||||
* http://jqueryui.com
|
* http://jqueryui.com
|
||||||
* Includes: jquery.ui.core.css, jquery.ui.accordion.css, jquery.ui.autocomplete.css, jquery.ui.button.css, jquery.ui.datepicker.css, jquery.ui.dialog.css, jquery.ui.menu.css, jquery.ui.progressbar.css, jquery.ui.resizable.css, jquery.ui.selectable.css, jquery.ui.slider.css, jquery.ui.spinner.css, jquery.ui.tabs.css, jquery.ui.tooltip.css, jquery.ui.theme.css
|
* Includes: jquery.ui.core.css, jquery.ui.accordion.css, jquery.ui.autocomplete.css, jquery.ui.button.css, jquery.ui.datepicker.css, jquery.ui.dialog.css, jquery.ui.menu.css, jquery.ui.progressbar.css, jquery.ui.resizable.css, jquery.ui.selectable.css, jquery.ui.slider.css, jquery.ui.spinner.css, jquery.ui.tabs.css, jquery.ui.tooltip.css, jquery.ui.theme.css
|
||||||
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
* Copyright 2012 jQuery Foundation and other contributors; Licensed MIT */
|
||||||
|
|
||||||
/* Layout helpers
|
/* Layout helpers
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
.ui-helper-hidden { display: none; }
|
.ui-helper-hidden { display: none; }
|
||||||
.ui-helper-hidden-accessible { border: 0; clip: rect(0 0 0 0); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; }
|
.ui-helper-hidden-accessible { border: 0; clip: rect(0 0 0 0); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; }
|
||||||
.ui-helper-reset { margin: 0; padding: 0; border: 0; outline: 0; line-height: 1.3; text-decoration: none; font-size: 100%; list-style: none; }
|
.ui-helper-reset { margin: 0; padding: 0; border: 0; outline: 0; line-height: 1.3; text-decoration: none; font-size: 100%; list-style: none; }
|
||||||
.ui-helper-clearfix:before, .ui-helper-clearfix:after { content: ""; display: table; }
|
.ui-helper-clearfix:before, .ui-helper-clearfix:after { content: ""; display: table; }
|
||||||
.ui-helper-clearfix:after { clear: both; }
|
.ui-helper-clearfix:after { clear: both; }
|
||||||
.ui-helper-clearfix { zoom: 1; }
|
.ui-helper-clearfix { zoom: 1; }
|
||||||
.ui-helper-zfix { width: 100%; height: 100%; top: 0; left: 0; position: absolute; opacity: 0; filter:Alpha(Opacity=0); }
|
.ui-helper-zfix { width: 100%; height: 100%; top: 0; left: 0; position: absolute; opacity: 0; filter:Alpha(Opacity=0); }
|
||||||
|
|
||||||
|
|
||||||
/* Interaction Cues
|
/* Interaction Cues
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
.ui-state-disabled { cursor: default !important; }
|
.ui-state-disabled { cursor: default !important; }
|
||||||
|
|
||||||
|
|
||||||
/* Icons
|
/* Icons
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
|
|
||||||
/* states and images */
|
/* states and images */
|
||||||
.ui-icon { display: block; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat; }
|
.ui-icon { display: block; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat; }
|
||||||
|
|
||||||
|
|
||||||
/* Misc visuals
|
/* Misc visuals
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
|
|
||||||
/* Overlays */
|
/* Overlays */
|
||||||
.ui-widget-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
|
.ui-widget-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
|
||||||
|
|
||||||
.ui-accordion .ui-accordion-header { display: block; cursor: pointer; position: relative; margin-top: 2px; padding: .5em .5em .5em .7em; zoom: 1; }
|
.ui-accordion .ui-accordion-header { display: block; cursor: pointer; position: relative; margin-top: 2px; padding: .5em .5em .5em .7em; zoom: 1; }
|
||||||
.ui-accordion .ui-accordion-icons { padding-left: 2.2em; }
|
.ui-accordion .ui-accordion-icons { padding-left: 2.2em; }
|
||||||
.ui-accordion .ui-accordion-noicons { padding-left: .7em; }
|
.ui-accordion .ui-accordion-noicons { padding-left: .7em; }
|
||||||
.ui-accordion .ui-accordion-icons .ui-accordion-icons { padding-left: 2.2em; }
|
.ui-accordion .ui-accordion-icons .ui-accordion-icons { padding-left: 2.2em; }
|
||||||
.ui-accordion .ui-accordion-header .ui-accordion-header-icon { position: absolute; left: .5em; top: 50%; margin-top: -8px; }
|
.ui-accordion .ui-accordion-header .ui-accordion-header-icon { position: absolute; left: .5em; top: 50%; margin-top: -8px; }
|
||||||
.ui-accordion .ui-accordion-content { padding: 1em 2.2em; border-top: 0; overflow: auto; zoom: 1; }
|
.ui-accordion .ui-accordion-content { padding: 1em 2.2em; border-top: 0; overflow: auto; zoom: 1; }
|
||||||
|
|
||||||
.ui-autocomplete {
|
.ui-autocomplete {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
cursor: default;
|
cursor: default;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* workarounds */
|
/* workarounds */
|
||||||
* html .ui-autocomplete { width:1px; } /* without this, the menu expands to 100% in IE6 */
|
* html .ui-autocomplete { width:1px; } /* without this, the menu expands to 100% in IE6 */
|
||||||
|
|
||||||
.ui-button { display: inline-block; position: relative; padding: 0; margin-right: .1em; cursor: pointer; text-align: center; zoom: 1; overflow: visible; } /* the overflow property removes extra width in IE */
|
.ui-button { display: inline-block; position: relative; padding: 0; margin-right: .1em; cursor: pointer; text-align: center; zoom: 1; overflow: visible; } /* the overflow property removes extra width in IE */
|
||||||
.ui-button, .ui-button:link, .ui-button:visited, .ui-button:hover, .ui-button:active { text-decoration: none; }
|
.ui-button, .ui-button:link, .ui-button:visited, .ui-button:hover, .ui-button:active { text-decoration: none; }
|
||||||
.ui-button-icon-only { width: 2.2em; } /* to make room for the icon, a width needs to be set here */
|
.ui-button-icon-only { width: 2.2em; } /* to make room for the icon, a width needs to be set here */
|
||||||
button.ui-button-icon-only { width: 2.4em; } /* button elements seem to need a little more width */
|
button.ui-button-icon-only { width: 2.4em; } /* button elements seem to need a little more width */
|
||||||
.ui-button-icons-only { width: 3.4em; }
|
.ui-button-icons-only { width: 3.4em; }
|
||||||
button.ui-button-icons-only { width: 3.7em; }
|
button.ui-button-icons-only { width: 3.7em; }
|
||||||
|
|
||||||
/*button text element */
|
/*button text element */
|
||||||
.ui-button .ui-button-text { display: block; line-height: 1.4; }
|
.ui-button .ui-button-text { display: block; line-height: 1.4; }
|
||||||
.ui-button-text-only .ui-button-text { padding: .4em 1em; }
|
.ui-button-text-only .ui-button-text { padding: .4em 1em; }
|
||||||
.ui-button-icon-only .ui-button-text, .ui-button-icons-only .ui-button-text { padding: .4em; text-indent: -9999999px; }
|
.ui-button-icon-only .ui-button-text, .ui-button-icons-only .ui-button-text { padding: .4em; text-indent: -9999999px; }
|
||||||
.ui-button-text-icon-primary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 1em .4em 2.1em; }
|
.ui-button-text-icon-primary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 1em .4em 2.1em; }
|
||||||
.ui-button-text-icon-secondary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 2.1em .4em 1em; }
|
.ui-button-text-icon-secondary .ui-button-text, .ui-button-text-icons .ui-button-text { padding: .4em 2.1em .4em 1em; }
|
||||||
.ui-button-text-icons .ui-button-text { padding-left: 2.1em; padding-right: 2.1em; }
|
.ui-button-text-icons .ui-button-text { padding-left: 2.1em; padding-right: 2.1em; }
|
||||||
/* no icon support for input elements, provide padding by default */
|
/* no icon support for input elements, provide padding by default */
|
||||||
input.ui-button { padding: .4em 1em; }
|
input.ui-button { padding: .4em 1em; }
|
||||||
|
|
||||||
/*button icon element(s) */
|
/*button icon element(s) */
|
||||||
.ui-button-icon-only .ui-icon, .ui-button-text-icon-primary .ui-icon, .ui-button-text-icon-secondary .ui-icon, .ui-button-text-icons .ui-icon, .ui-button-icons-only .ui-icon { position: absolute; top: 50%; margin-top: -8px; }
|
.ui-button-icon-only .ui-icon, .ui-button-text-icon-primary .ui-icon, .ui-button-text-icon-secondary .ui-icon, .ui-button-text-icons .ui-icon, .ui-button-icons-only .ui-icon { position: absolute; top: 50%; margin-top: -8px; }
|
||||||
.ui-button-icon-only .ui-icon { left: 50%; margin-left: -8px; }
|
.ui-button-icon-only .ui-icon { left: 50%; margin-left: -8px; }
|
||||||
.ui-button-text-icon-primary .ui-button-icon-primary, .ui-button-text-icons .ui-button-icon-primary, .ui-button-icons-only .ui-button-icon-primary { left: .5em; }
|
.ui-button-text-icon-primary .ui-button-icon-primary, .ui-button-text-icons .ui-button-icon-primary, .ui-button-icons-only .ui-button-icon-primary { left: .5em; }
|
||||||
.ui-button-text-icon-secondary .ui-button-icon-secondary, .ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
|
.ui-button-text-icon-secondary .ui-button-icon-secondary, .ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
|
||||||
.ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
|
.ui-button-text-icons .ui-button-icon-secondary, .ui-button-icons-only .ui-button-icon-secondary { right: .5em; }
|
||||||
|
|
||||||
/*button sets*/
|
/*button sets*/
|
||||||
.ui-buttonset { margin-right: 7px; }
|
.ui-buttonset { margin-right: 7px; }
|
||||||
.ui-buttonset .ui-button { margin-left: 0; margin-right: -.3em; }
|
.ui-buttonset .ui-button { margin-left: 0; margin-right: -.3em; }
|
||||||
|
|
||||||
/* workarounds */
|
/* workarounds */
|
||||||
button.ui-button::-moz-focus-inner { border: 0; padding: 0; } /* reset extra padding in Firefox */
|
button.ui-button::-moz-focus-inner { border: 0; padding: 0; } /* reset extra padding in Firefox */
|
||||||
|
|
||||||
.ui-datepicker { width: 17em; padding: .2em .2em 0; display: none; }
|
.ui-datepicker { width: 17em; padding: .2em .2em 0; display: none; }
|
||||||
.ui-datepicker .ui-datepicker-header { position:relative; padding:.2em 0; }
|
.ui-datepicker .ui-datepicker-header { position:relative; padding:.2em 0; }
|
||||||
.ui-datepicker .ui-datepicker-prev, .ui-datepicker .ui-datepicker-next { position:absolute; top: 2px; width: 1.8em; height: 1.8em; }
|
.ui-datepicker .ui-datepicker-prev, .ui-datepicker .ui-datepicker-next { position:absolute; top: 2px; width: 1.8em; height: 1.8em; }
|
||||||
.ui-datepicker .ui-datepicker-prev-hover, .ui-datepicker .ui-datepicker-next-hover { top: 1px; }
|
.ui-datepicker .ui-datepicker-prev-hover, .ui-datepicker .ui-datepicker-next-hover { top: 1px; }
|
||||||
.ui-datepicker .ui-datepicker-prev { left:2px; }
|
.ui-datepicker .ui-datepicker-prev { left:2px; }
|
||||||
.ui-datepicker .ui-datepicker-next { right:2px; }
|
.ui-datepicker .ui-datepicker-next { right:2px; }
|
||||||
.ui-datepicker .ui-datepicker-prev-hover { left:1px; }
|
.ui-datepicker .ui-datepicker-prev-hover { left:1px; }
|
||||||
.ui-datepicker .ui-datepicker-next-hover { right:1px; }
|
.ui-datepicker .ui-datepicker-next-hover { right:1px; }
|
||||||
.ui-datepicker .ui-datepicker-prev span, .ui-datepicker .ui-datepicker-next span { display: block; position: absolute; left: 50%; margin-left: -8px; top: 50%; margin-top: -8px; }
|
.ui-datepicker .ui-datepicker-prev span, .ui-datepicker .ui-datepicker-next span { display: block; position: absolute; left: 50%; margin-left: -8px; top: 50%; margin-top: -8px; }
|
||||||
.ui-datepicker .ui-datepicker-title { margin: 0 2.3em; line-height: 1.8em; text-align: center; }
|
.ui-datepicker .ui-datepicker-title { margin: 0 2.3em; line-height: 1.8em; text-align: center; }
|
||||||
.ui-datepicker .ui-datepicker-title select { font-size:1em; margin:1px 0; }
|
.ui-datepicker .ui-datepicker-title select { font-size:1em; margin:1px 0; }
|
||||||
.ui-datepicker select.ui-datepicker-month-year {width: 100%;}
|
.ui-datepicker select.ui-datepicker-month-year {width: 100%;}
|
||||||
.ui-datepicker select.ui-datepicker-month,
|
.ui-datepicker select.ui-datepicker-month,
|
||||||
.ui-datepicker select.ui-datepicker-year { width: 49%;}
|
.ui-datepicker select.ui-datepicker-year { width: 49%;}
|
||||||
.ui-datepicker table {width: 100%; font-size: .9em; border-collapse: collapse; margin:0 0 .4em; }
|
.ui-datepicker table {width: 100%; font-size: .9em; border-collapse: collapse; margin:0 0 .4em; }
|
||||||
.ui-datepicker th { padding: .7em .3em; text-align: center; font-weight: bold; border: 0; }
|
.ui-datepicker th { padding: .7em .3em; text-align: center; font-weight: bold; border: 0; }
|
||||||
.ui-datepicker td { border: 0; padding: 1px; }
|
.ui-datepicker td { border: 0; padding: 1px; }
|
||||||
.ui-datepicker td span, .ui-datepicker td a { display: block; padding: .2em; text-align: right; text-decoration: none; }
|
.ui-datepicker td span, .ui-datepicker td a { display: block; padding: .2em; text-align: right; text-decoration: none; }
|
||||||
.ui-datepicker .ui-datepicker-buttonpane { background-image: none; margin: .7em 0 0 0; padding:0 .2em; border-left: 0; border-right: 0; border-bottom: 0; }
|
.ui-datepicker .ui-datepicker-buttonpane { background-image: none; margin: .7em 0 0 0; padding:0 .2em; border-left: 0; border-right: 0; border-bottom: 0; }
|
||||||
.ui-datepicker .ui-datepicker-buttonpane button { float: right; margin: .5em .2em .4em; cursor: pointer; padding: .2em .6em .3em .6em; width:auto; overflow:visible; }
|
.ui-datepicker .ui-datepicker-buttonpane button { float: right; margin: .5em .2em .4em; cursor: pointer; padding: .2em .6em .3em .6em; width:auto; overflow:visible; }
|
||||||
.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current { float:left; }
|
.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current { float:left; }
|
||||||
|
|
||||||
/* with multiple calendars */
|
/* with multiple calendars */
|
||||||
.ui-datepicker.ui-datepicker-multi { width:auto; }
|
.ui-datepicker.ui-datepicker-multi { width:auto; }
|
||||||
.ui-datepicker-multi .ui-datepicker-group { float:left; }
|
.ui-datepicker-multi .ui-datepicker-group { float:left; }
|
||||||
.ui-datepicker-multi .ui-datepicker-group table { width:95%; margin:0 auto .4em; }
|
.ui-datepicker-multi .ui-datepicker-group table { width:95%; margin:0 auto .4em; }
|
||||||
.ui-datepicker-multi-2 .ui-datepicker-group { width:50%; }
|
.ui-datepicker-multi-2 .ui-datepicker-group { width:50%; }
|
||||||
.ui-datepicker-multi-3 .ui-datepicker-group { width:33.3%; }
|
.ui-datepicker-multi-3 .ui-datepicker-group { width:33.3%; }
|
||||||
.ui-datepicker-multi-4 .ui-datepicker-group { width:25%; }
|
.ui-datepicker-multi-4 .ui-datepicker-group { width:25%; }
|
||||||
.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header { border-left-width:0; }
|
.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header { border-left-width:0; }
|
||||||
.ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header { border-left-width:0; }
|
.ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header { border-left-width:0; }
|
||||||
.ui-datepicker-multi .ui-datepicker-buttonpane { clear:left; }
|
.ui-datepicker-multi .ui-datepicker-buttonpane { clear:left; }
|
||||||
.ui-datepicker-row-break { clear:both; width:100%; font-size:0em; }
|
.ui-datepicker-row-break { clear:both; width:100%; font-size:0em; }
|
||||||
|
|
||||||
/* RTL support */
|
/* RTL support */
|
||||||
.ui-datepicker-rtl { direction: rtl; }
|
.ui-datepicker-rtl { direction: rtl; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-prev { right: 2px; left: auto; }
|
.ui-datepicker-rtl .ui-datepicker-prev { right: 2px; left: auto; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-next { left: 2px; right: auto; }
|
.ui-datepicker-rtl .ui-datepicker-next { left: 2px; right: auto; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-prev:hover { right: 1px; left: auto; }
|
.ui-datepicker-rtl .ui-datepicker-prev:hover { right: 1px; left: auto; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-next:hover { left: 1px; right: auto; }
|
.ui-datepicker-rtl .ui-datepicker-next:hover { left: 1px; right: auto; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-buttonpane { clear:right; }
|
.ui-datepicker-rtl .ui-datepicker-buttonpane { clear:right; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-buttonpane button { float: left; }
|
.ui-datepicker-rtl .ui-datepicker-buttonpane button { float: left; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current { float:right; }
|
.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current { float:right; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-group { float:right; }
|
.ui-datepicker-rtl .ui-datepicker-group { float:right; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
|
.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
|
||||||
.ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
|
.ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header { border-right-width:0; border-left-width:1px; }
|
||||||
|
|
||||||
/* IE6 IFRAME FIX (taken from datepicker 1.5.3 */
|
/* IE6 IFRAME FIX (taken from datepicker 1.5.3 */
|
||||||
.ui-datepicker-cover {
|
.ui-datepicker-cover {
|
||||||
position: absolute; /*must have*/
|
position: absolute; /*must have*/
|
||||||
z-index: -1; /*must have*/
|
z-index: -1; /*must have*/
|
||||||
filter: mask(); /*must have*/
|
filter: mask(); /*must have*/
|
||||||
top: -4px; /*must have*/
|
top: -4px; /*must have*/
|
||||||
left: -4px; /*must have*/
|
left: -4px; /*must have*/
|
||||||
width: 200px; /*must have*/
|
width: 200px; /*must have*/
|
||||||
height: 200px; /*must have*/
|
height: 200px; /*must have*/
|
||||||
}
|
}
|
||||||
.ui-dialog { position: absolute; top: 0; left: 0; padding: .2em; width: 300px; overflow: hidden; }
|
.ui-dialog { position: absolute; top: 0; left: 0; padding: .2em; width: 300px; overflow: hidden; }
|
||||||
.ui-dialog .ui-dialog-titlebar { padding: .4em 1em; position: relative; }
|
.ui-dialog .ui-dialog-titlebar { padding: .4em 1em; position: relative; }
|
||||||
.ui-dialog .ui-dialog-title { float: left; margin: .1em 16px .1em 0; }
|
.ui-dialog .ui-dialog-title { float: left; margin: .1em 16px .1em 0; }
|
||||||
.ui-dialog .ui-dialog-titlebar-close { position: absolute; right: .3em; top: 50%; width: 19px; margin: -10px 0 0 0; padding: 1px; height: 18px; }
|
.ui-dialog .ui-dialog-titlebar-close { position: absolute; right: .3em; top: 50%; width: 19px; margin: -10px 0 0 0; padding: 1px; height: 18px; }
|
||||||
.ui-dialog .ui-dialog-titlebar-close span { display: block; margin: 1px; }
|
.ui-dialog .ui-dialog-titlebar-close span { display: block; margin: 1px; }
|
||||||
.ui-dialog .ui-dialog-titlebar-close:hover, .ui-dialog .ui-dialog-titlebar-close:focus { padding: 0; }
|
.ui-dialog .ui-dialog-titlebar-close:hover, .ui-dialog .ui-dialog-titlebar-close:focus { padding: 0; }
|
||||||
.ui-dialog .ui-dialog-content { position: relative; border: 0; padding: .5em 1em; background: none; overflow: auto; zoom: 1; }
|
.ui-dialog .ui-dialog-content { position: relative; border: 0; padding: .5em 1em; background: none; overflow: auto; zoom: 1; }
|
||||||
.ui-dialog .ui-dialog-buttonpane { text-align: left; border-width: 1px 0 0 0; background-image: none; margin: .5em 0 0 0; padding: .3em 1em .5em .4em; }
|
.ui-dialog .ui-dialog-buttonpane { text-align: left; border-width: 1px 0 0 0; background-image: none; margin: .5em 0 0 0; padding: .3em 1em .5em .4em; }
|
||||||
.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset { float: right; }
|
.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset { float: right; }
|
||||||
.ui-dialog .ui-dialog-buttonpane button { margin: .5em .4em .5em 0; cursor: pointer; }
|
.ui-dialog .ui-dialog-buttonpane button { margin: .5em .4em .5em 0; cursor: pointer; }
|
||||||
.ui-dialog .ui-resizable-se { width: 14px; height: 14px; right: 3px; bottom: 3px; }
|
.ui-dialog .ui-resizable-se { width: 14px; height: 14px; right: 3px; bottom: 3px; }
|
||||||
.ui-draggable .ui-dialog-titlebar { cursor: move; }
|
.ui-draggable .ui-dialog-titlebar { cursor: move; }
|
||||||
|
|
||||||
.ui-menu { list-style:none; padding: 2px; margin: 0; display:block; outline: none; }
|
.ui-menu { list-style:none; padding: 2px; margin: 0; display:block; outline: none; }
|
||||||
.ui-menu .ui-menu { margin-top: -3px; position: absolute; }
|
.ui-menu .ui-menu { margin-top: -3px; position: absolute; }
|
||||||
.ui-menu .ui-menu-topic { margin: 0; padding: 0; zoom: 1; width: 100%; }
|
.ui-menu .ui-menu-topic { margin: 0; padding: 0; zoom: 1; width: 100%; }
|
||||||
.ui-menu .ui-menu-divider { margin: 5px -2px 5px -2px; height: 0; font-size: 0; line-height: 0; border-width: 1px 0 0 0; }
|
.ui-menu .ui-menu-divider { margin: 5px -2px 5px -2px; height: 0; font-size: 0; line-height: 0; border-width: 1px 0 0 0; }
|
||||||
.ui-menu .ui-menu-topic a { text-decoration: none; display: block; padding: 2px .4em; line-height: 1.5; zoom: 1; font-weight: normal; }
|
.ui-menu .ui-menu-topic a { text-decoration: none; display: block; padding: 2px .4em; line-height: 1.5; zoom: 1; font-weight: normal; }
|
||||||
.ui-menu .ui-menu-topic a.ui-state-focus,
|
.ui-menu .ui-menu-topic a.ui-state-focus,
|
||||||
.ui-menu .ui-menu-topic a.ui-state-active { font-weight: normal; margin: -1px; }
|
.ui-menu .ui-menu-topic a.ui-state-active { font-weight: normal; margin: -1px; }
|
||||||
|
|
||||||
.ui-menu .ui-state-disabled { font-weight: normal; margin: .4em 0 .2em; line-height: 1.5; }
|
.ui-menu .ui-state-disabled { font-weight: normal; margin: .4em 0 .2em; line-height: 1.5; }
|
||||||
.ui-menu .ui-state-disabled a { cursor: default; }
|
.ui-menu .ui-state-disabled a { cursor: default; }
|
||||||
|
|
||||||
/* icon support */
|
/* icon support */
|
||||||
.ui-menu-icons { position: relative; }
|
.ui-menu-icons { position: relative; }
|
||||||
.ui-menu-icons .ui-menu-topic a { position: relative; padding-left: 2em; }
|
.ui-menu-icons .ui-menu-topic a { position: relative; padding-left: 2em; }
|
||||||
|
|
||||||
/* left-aligned */
|
/* left-aligned */
|
||||||
.ui-menu .ui-icon { position: absolute; top: .2em; left: .2em; }
|
.ui-menu .ui-icon { position: absolute; top: .2em; left: .2em; }
|
||||||
|
|
||||||
/* right-aligned */
|
/* right-aligned */
|
||||||
.ui-menu .ui-menu-icon { position: static; float: right; }
|
.ui-menu .ui-menu-icon { position: static; float: right; }
|
||||||
|
|
||||||
.ui-progressbar { height:2em; text-align: left; overflow: hidden; }
|
.ui-progressbar { height:2em; text-align: left; overflow: hidden; }
|
||||||
.ui-progressbar .ui-progressbar-value {margin: -1px; height:100%; }
|
.ui-progressbar .ui-progressbar-value {margin: -1px; height:100%; }
|
||||||
.ui-resizable { position: relative;}
|
.ui-resizable { position: relative;}
|
||||||
.ui-resizable-handle { position: absolute;font-size: 0.1px; display: block; }
|
.ui-resizable-handle { position: absolute;font-size: 0.1px; display: block; }
|
||||||
.ui-resizable-disabled .ui-resizable-handle, .ui-resizable-autohide .ui-resizable-handle { display: none; }
|
.ui-resizable-disabled .ui-resizable-handle, .ui-resizable-autohide .ui-resizable-handle { display: none; }
|
||||||
.ui-resizable-n { cursor: n-resize; height: 7px; width: 100%; top: -5px; left: 0; }
|
.ui-resizable-n { cursor: n-resize; height: 7px; width: 100%; top: -5px; left: 0; }
|
||||||
.ui-resizable-s { cursor: s-resize; height: 7px; width: 100%; bottom: -5px; left: 0; }
|
.ui-resizable-s { cursor: s-resize; height: 7px; width: 100%; bottom: -5px; left: 0; }
|
||||||
.ui-resizable-e { cursor: e-resize; width: 7px; right: -5px; top: 0; height: 100%; }
|
.ui-resizable-e { cursor: e-resize; width: 7px; right: -5px; top: 0; height: 100%; }
|
||||||
.ui-resizable-w { cursor: w-resize; width: 7px; left: -5px; top: 0; height: 100%; }
|
.ui-resizable-w { cursor: w-resize; width: 7px; left: -5px; top: 0; height: 100%; }
|
||||||
.ui-resizable-se { cursor: se-resize; width: 12px; height: 12px; right: 1px; bottom: 1px; }
|
.ui-resizable-se { cursor: se-resize; width: 12px; height: 12px; right: 1px; bottom: 1px; }
|
||||||
.ui-resizable-sw { cursor: sw-resize; width: 9px; height: 9px; left: -5px; bottom: -5px; }
|
.ui-resizable-sw { cursor: sw-resize; width: 9px; height: 9px; left: -5px; bottom: -5px; }
|
||||||
.ui-resizable-nw { cursor: nw-resize; width: 9px; height: 9px; left: -5px; top: -5px; }
|
.ui-resizable-nw { cursor: nw-resize; width: 9px; height: 9px; left: -5px; top: -5px; }
|
||||||
.ui-resizable-ne { cursor: ne-resize; width: 9px; height: 9px; right: -5px; top: -5px;}
|
.ui-resizable-ne { cursor: ne-resize; width: 9px; height: 9px; right: -5px; top: -5px;}
|
||||||
.ui-selectable-helper { position: absolute; z-index: 100; border:1px dotted black; }
|
.ui-selectable-helper { position: absolute; z-index: 100; border:1px dotted black; }
|
||||||
|
|
||||||
.ui-slider { position: relative; text-align: left; }
|
.ui-slider { position: relative; text-align: left; }
|
||||||
.ui-slider .ui-slider-handle { position: absolute; z-index: 2; width: 1.2em; height: 1.2em; cursor: default; }
|
.ui-slider .ui-slider-handle { position: absolute; z-index: 2; width: 1.2em; height: 1.2em; cursor: default; }
|
||||||
.ui-slider .ui-slider-range { position: absolute; z-index: 1; font-size: .7em; display: block; border: 0; background-position: 0 0; }
|
.ui-slider .ui-slider-range { position: absolute; z-index: 1; font-size: .7em; display: block; border: 0; background-position: 0 0; }
|
||||||
|
|
||||||
.ui-slider-horizontal { height: .8em; }
|
.ui-slider-horizontal { height: .8em; }
|
||||||
.ui-slider-horizontal .ui-slider-handle { top: -.3em; margin-left: -.6em; }
|
.ui-slider-horizontal .ui-slider-handle { top: -.3em; margin-left: -.6em; }
|
||||||
.ui-slider-horizontal .ui-slider-range { top: 0; height: 100%; }
|
.ui-slider-horizontal .ui-slider-range { top: 0; height: 100%; }
|
||||||
.ui-slider-horizontal .ui-slider-range-min { left: 0; }
|
.ui-slider-horizontal .ui-slider-range-min { left: 0; }
|
||||||
.ui-slider-horizontal .ui-slider-range-max { right: 0; }
|
.ui-slider-horizontal .ui-slider-range-max { right: 0; }
|
||||||
|
|
||||||
.ui-slider-vertical { width: .8em; height: 100px; }
|
.ui-slider-vertical { width: .8em; height: 100px; }
|
||||||
.ui-slider-vertical .ui-slider-handle { left: -.3em; margin-left: 0; margin-bottom: -.6em; }
|
.ui-slider-vertical .ui-slider-handle { left: -.3em; margin-left: 0; margin-bottom: -.6em; }
|
||||||
.ui-slider-vertical .ui-slider-range { left: 0; width: 100%; }
|
.ui-slider-vertical .ui-slider-range { left: 0; width: 100%; }
|
||||||
.ui-slider-vertical .ui-slider-range-min { bottom: 0; }
|
.ui-slider-vertical .ui-slider-range-min { bottom: 0; }
|
||||||
.ui-slider-vertical .ui-slider-range-max { top: 0; }
|
.ui-slider-vertical .ui-slider-range-max { top: 0; }
|
||||||
.ui-spinner { position:relative; display: inline-block; overflow: hidden; padding: 0; vertical-align: middle; }
|
.ui-spinner { position:relative; display: inline-block; overflow: hidden; padding: 0; vertical-align: middle; }
|
||||||
.ui-spinner-input { border: none; background: none; padding: 0; margin: .2em 0; vertical-align: middle; margin-left: .4em; margin-right: 22px; }
|
.ui-spinner-input { border: none; background: none; padding: 0; margin: .2em 0; vertical-align: middle; margin-left: .4em; margin-right: 22px; }
|
||||||
.ui-spinner-button { width: 16px; height: 50%; font-size: .5em; padding: 0; margin: 0; text-align: center; position: absolute; cursor: default; display: block; overflow: hidden; right: 0; }
|
.ui-spinner-button { width: 16px; height: 50%; font-size: .5em; padding: 0; margin: 0; text-align: center; position: absolute; cursor: default; display: block; overflow: hidden; right: 0; }
|
||||||
.ui-spinner a.ui-spinner-button { border-top: none; border-bottom: none; border-right: none; } /* more specificity required here to overide default borders */
|
.ui-spinner a.ui-spinner-button { border-top: none; border-bottom: none; border-right: none; } /* more specificity required here to overide default borders */
|
||||||
.ui-spinner .ui-icon { position: absolute; margin-top: -8px; top: 50%; left: 0; } /* vertical centre icon */
|
.ui-spinner .ui-icon { position: absolute; margin-top: -8px; top: 50%; left: 0; } /* vertical centre icon */
|
||||||
.ui-spinner-up { top: 0; }
|
.ui-spinner-up { top: 0; }
|
||||||
.ui-spinner-down { bottom: 0; }
|
.ui-spinner-down { bottom: 0; }
|
||||||
|
|
||||||
/* TR overrides */
|
/* TR overrides */
|
||||||
.ui-spinner .ui-icon-triangle-1-s {
|
.ui-spinner .ui-icon-triangle-1-s {
|
||||||
/* need to fix icons sprite */
|
/* need to fix icons sprite */
|
||||||
background-position:-65px -16px;
|
background-position:-65px -16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ui-tabs { position: relative; padding: .2em; zoom: 1; } /* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */
|
.ui-tabs { position: relative; padding: .2em; zoom: 1; } /* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */
|
||||||
.ui-tabs .ui-tabs-nav { margin: 0; padding: .2em .2em 0; }
|
.ui-tabs .ui-tabs-nav { margin: 0; padding: .2em .2em 0; }
|
||||||
.ui-tabs .ui-tabs-nav li { list-style: none; float: left; position: relative; top: 0; margin: 1px .2em 0 0; border-bottom: 0; padding: 0; white-space: nowrap; }
|
.ui-tabs .ui-tabs-nav li { list-style: none; float: left; position: relative; top: 0; margin: 1px .2em 0 0; border-bottom: 0; padding: 0; white-space: nowrap; }
|
||||||
.ui-tabs .ui-tabs-nav li a { float: left; padding: .5em 1em; text-decoration: none; }
|
.ui-tabs .ui-tabs-nav li a { float: left; padding: .5em 1em; text-decoration: none; }
|
||||||
.ui-tabs .ui-tabs-nav li.ui-tabs-active { margin-bottom: -1px; padding-bottom: 1px; }
|
.ui-tabs .ui-tabs-nav li.ui-tabs-active { margin-bottom: -1px; padding-bottom: 1px; }
|
||||||
.ui-tabs .ui-tabs-nav li.ui-tabs-active a, .ui-tabs .ui-tabs-nav li.ui-state-disabled a, .ui-tabs .ui-tabs-nav li.ui-tabs-loading a { cursor: text; }
|
.ui-tabs .ui-tabs-nav li.ui-tabs-active a, .ui-tabs .ui-tabs-nav li.ui-state-disabled a, .ui-tabs .ui-tabs-nav li.ui-tabs-loading a { cursor: text; }
|
||||||
.ui-tabs .ui-tabs-nav li a, .ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active a { cursor: pointer; } /* first selector in group seems obsolete, but required to overcome bug in Opera applying cursor: text overall if defined elsewhere... */
|
.ui-tabs .ui-tabs-nav li a, .ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active a { cursor: pointer; } /* first selector in group seems obsolete, but required to overcome bug in Opera applying cursor: text overall if defined elsewhere... */
|
||||||
.ui-tabs .ui-tabs-panel { display: block; border-width: 0; padding: 1em 1.4em; background: none; }
|
.ui-tabs .ui-tabs-panel { display: block; border-width: 0; padding: 1em 1.4em; background: none; }
|
||||||
|
|
||||||
.ui-tooltip {
|
.ui-tooltip {
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
z-index: 9999;
|
z-index: 9999;
|
||||||
max-width: 300px;
|
max-width: 300px;
|
||||||
-webkit-box-shadow: 0 0 5px #aaa;
|
-webkit-box-shadow: 0 0 5px #aaa;
|
||||||
box-shadow: 0 0 5px #aaa;
|
box-shadow: 0 0 5px #aaa;
|
||||||
}
|
}
|
||||||
/* Fades and background-images don't work well together in IE6, drop the image */
|
/* Fades and background-images don't work well together in IE6, drop the image */
|
||||||
* html .ui-tooltip {
|
* html .ui-tooltip {
|
||||||
background-image: none;
|
background-image: none;
|
||||||
}
|
}
|
||||||
body .ui-tooltip { border-width: 2px; }
|
body .ui-tooltip { border-width: 2px; }
|
||||||
|
|
||||||
/* Component containers
|
/* Component containers
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
.ui-widget { font-family: Verdana,Arial,sans-serif/*{ffDefault}*/; font-size: 1.1em/*{fsDefault}*/; }
|
.ui-widget { font-family: Verdana,Arial,sans-serif/*{ffDefault}*/; font-size: 1.1em/*{fsDefault}*/; }
|
||||||
.ui-widget .ui-widget { font-size: 1em; }
|
.ui-widget .ui-widget { font-size: 1em; }
|
||||||
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button { font-family: Verdana,Arial,sans-serif/*{ffDefault}*/; font-size: 1em; }
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button { font-family: Verdana,Arial,sans-serif/*{ffDefault}*/; font-size: 1em; }
|
||||||
.ui-widget-content { border: 1px solid #aaaaaa/*{borderColorContent}*/; background: #ffffff/*{bgColorContent}*/ url(<%= asset_data_uri('ui-bg_flat_75_ffffff_40x100.png') %>)/*{bgImgUrlContent}*/ 50%/*{bgContentXPos}*/ 50%/*{bgContentYPos}*/ repeat-x/*{bgContentRepeat}*/; color: #222222/*{fcContent}*/; }
|
.ui-widget-content { border: 1px solid #aaaaaa/*{borderColorContent}*/; background: #ffffff/*{bgColorContent}*/ url(<%= asset_data_uri('ui-bg_flat_75_ffffff_40x100.png') %>)/*{bgImgUrlContent}*/ 50%/*{bgContentXPos}*/ 50%/*{bgContentYPos}*/ repeat-x/*{bgContentRepeat}*/; color: #222222/*{fcContent}*/; }
|
||||||
.ui-widget-content a { color: #222222/*{fcContent}*/; }
|
.ui-widget-content a { color: #222222/*{fcContent}*/; }
|
||||||
.ui-widget-header { border: 1px solid #aaaaaa/*{borderColorHeader}*/; background: #cccccc/*{bgColorHeader}*/ url(<%= asset_data_uri('images/ui-bg_highlight-soft_75_cccccc_1x100.png') %>)/*{bgImgUrlHeader}*/ 50%/*{bgHeaderXPos}*/ 50%/*{bgHeaderYPos}*/ repeat-x/*{bgHeaderRepeat}*/; color: #222222/*{fcHeader}*/; font-weight: bold; }
|
.ui-widget-header { border: 1px solid #aaaaaa/*{borderColorHeader}*/; background: #cccccc/*{bgColorHeader}*/ url(<%= asset_data_uri('images/ui-bg_highlight-soft_75_cccccc_1x100.png') %>)/*{bgImgUrlHeader}*/ 50%/*{bgHeaderXPos}*/ 50%/*{bgHeaderYPos}*/ repeat-x/*{bgHeaderRepeat}*/; color: #222222/*{fcHeader}*/; font-weight: bold; }
|
||||||
.ui-widget-header a { color: #222222/*{fcHeader}*/; }
|
.ui-widget-header a { color: #222222/*{fcHeader}*/; }
|
||||||
|
|
||||||
/* Interaction states
|
/* Interaction states
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
.ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default { border: 1px solid #d3d3d3/*{borderColorDefault}*/; background: #e6e6e6/*{bgColorDefault}*/ url(<%= asset_data_uri('images/ui-bg_glass_75_e6e6e6_1x400.png') %>)/*{bgImgUrlDefault}*/ 50%/*{bgDefaultXPos}*/ 50%/*{bgDefaultYPos}*/ repeat-x/*{bgDefaultRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #555555/*{fcDefault}*/; }
|
.ui-state-default, .ui-widget-content .ui-state-default, .ui-widget-header .ui-state-default { border: 1px solid #d3d3d3/*{borderColorDefault}*/; background: #e6e6e6/*{bgColorDefault}*/ url(<%= asset_data_uri('images/ui-bg_glass_75_e6e6e6_1x400.png') %>)/*{bgImgUrlDefault}*/ 50%/*{bgDefaultXPos}*/ 50%/*{bgDefaultYPos}*/ repeat-x/*{bgDefaultRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #555555/*{fcDefault}*/; }
|
||||||
.ui-state-default a, .ui-state-default a:link, .ui-state-default a:visited { color: #555555/*{fcDefault}*/; text-decoration: none; }
|
.ui-state-default a, .ui-state-default a:link, .ui-state-default a:visited { color: #555555/*{fcDefault}*/; text-decoration: none; }
|
||||||
.ui-state-hover, .ui-widget-content .ui-state-hover, .ui-widget-header .ui-state-hover, .ui-state-focus, .ui-widget-content .ui-state-focus, .ui-widget-header .ui-state-focus { border: 0px solid #999999/*{borderColorHover}*/; background: #dadada/*{bgColorHover}*/ url(<%= asset_data_uri('images/ui-bg_glass_75_dadada_1x400.png') %>)/*{bgImgUrlHover}*/ 50%/*{bgHoverXPos}*/ 50%/*{bgHoverYPos}*/ repeat-x/*{bgHoverRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcHover}*/; }
|
.ui-state-hover, .ui-widget-content .ui-state-hover, .ui-widget-header .ui-state-hover, .ui-state-focus, .ui-widget-content .ui-state-focus, .ui-widget-header .ui-state-focus { border: 0px solid #999999/*{borderColorHover}*/; background: #dadada/*{bgColorHover}*/ url(<%= asset_data_uri('images/ui-bg_glass_75_dadada_1x400.png') %>)/*{bgImgUrlHover}*/ 50%/*{bgHoverXPos}*/ 50%/*{bgHoverYPos}*/ repeat-x/*{bgHoverRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcHover}*/; }
|
||||||
.ui-state-hover a, .ui-state-hover a:hover, .ui-state-hover a:link, .ui-state-hover a:visited { color: #212121/*{fcHover}*/; text-decoration: none; }
|
.ui-state-hover a, .ui-state-hover a:hover, .ui-state-hover a:link, .ui-state-hover a:visited { color: #212121/*{fcHover}*/; text-decoration: none; }
|
||||||
.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active { border: 1px solid #aaaaaa/*{borderColorActive}*/; background: #ffffff/*{bgColorActive}*/ url(<%= asset_data_uri('images/ui-bg_glass_65_ffffff_1x400.png') %>)/*{bgImgUrlActive}*/ 50%/*{bgActiveXPos}*/ 50%/*{bgActiveYPos}*/ repeat-x/*{bgActiveRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcActive}*/; }
|
.ui-state-active, .ui-widget-content .ui-state-active, .ui-widget-header .ui-state-active { border: 1px solid #aaaaaa/*{borderColorActive}*/; background: #ffffff/*{bgColorActive}*/ url(<%= asset_data_uri('images/ui-bg_glass_65_ffffff_1x400.png') %>)/*{bgImgUrlActive}*/ 50%/*{bgActiveXPos}*/ 50%/*{bgActiveYPos}*/ repeat-x/*{bgActiveRepeat}*/; font-weight: normal/*{fwDefault}*/; color: #212121/*{fcActive}*/; }
|
||||||
.ui-state-active a, .ui-state-active a:link, .ui-state-active a:visited { color: #212121/*{fcActive}*/; text-decoration: none; }
|
.ui-state-active a, .ui-state-active a:link, .ui-state-active a:visited { color: #212121/*{fcActive}*/; text-decoration: none; }
|
||||||
|
|
||||||
/* Interaction Cues
|
/* Interaction Cues
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
.ui-state-highlight, .ui-widget-content .ui-state-highlight, .ui-widget-header .ui-state-highlight {border: 1px solid #fcefa1/*{borderColorHighlight}*/; background: #fbf9ee/*{bgColorHighlight}*/ url(<%= asset_data_uri('images/ui-bg_glass_55_fbf9ee_1x400.png') %>)/*{bgImgUrlHighlight}*/ 50%/*{bgHighlightXPos}*/ 50%/*{bgHighlightYPos}*/ repeat-x/*{bgHighlightRepeat}*/; color: #363636/*{fcHighlight}*/; }
|
.ui-state-highlight, .ui-widget-content .ui-state-highlight, .ui-widget-header .ui-state-highlight {border: 1px solid #fcefa1/*{borderColorHighlight}*/; background: #fbf9ee/*{bgColorHighlight}*/ url(<%= asset_data_uri('images/ui-bg_glass_55_fbf9ee_1x400.png') %>)/*{bgImgUrlHighlight}*/ 50%/*{bgHighlightXPos}*/ 50%/*{bgHighlightYPos}*/ repeat-x/*{bgHighlightRepeat}*/; color: #363636/*{fcHighlight}*/; }
|
||||||
.ui-state-highlight a, .ui-widget-content .ui-state-highlight a,.ui-widget-header .ui-state-highlight a { color: #363636/*{fcHighlight}*/; }
|
.ui-state-highlight a, .ui-widget-content .ui-state-highlight a,.ui-widget-header .ui-state-highlight a { color: #363636/*{fcHighlight}*/; }
|
||||||
.ui-state-error, .ui-widget-content .ui-state-error, .ui-widget-header .ui-state-error {border: 1px solid #cd0a0a/*{borderColorError}*/; background: #fef1ec/*{bgColorError}*/ url(<%= asset_data_uri('images/ui-bg_glass_95_fef1ec_1x400.png') %>)/*{bgImgUrlError}*/ 50%/*{bgErrorXPos}*/ 50%/*{bgErrorYPos}*/ repeat-x/*{bgErrorRepeat}*/; color: #cd0a0a/*{fcError}*/; }
|
.ui-state-error, .ui-widget-content .ui-state-error, .ui-widget-header .ui-state-error {border: 1px solid #cd0a0a/*{borderColorError}*/; background: #fef1ec/*{bgColorError}*/ url(<%= asset_data_uri('images/ui-bg_glass_95_fef1ec_1x400.png') %>)/*{bgImgUrlError}*/ 50%/*{bgErrorXPos}*/ 50%/*{bgErrorYPos}*/ repeat-x/*{bgErrorRepeat}*/; color: #cd0a0a/*{fcError}*/; }
|
||||||
.ui-state-error a, .ui-widget-content .ui-state-error a, .ui-widget-header .ui-state-error a { color: #cd0a0a/*{fcError}*/; }
|
.ui-state-error a, .ui-widget-content .ui-state-error a, .ui-widget-header .ui-state-error a { color: #cd0a0a/*{fcError}*/; }
|
||||||
.ui-state-error-text, .ui-widget-content .ui-state-error-text, .ui-widget-header .ui-state-error-text { color: #cd0a0a/*{fcError}*/; }
|
.ui-state-error-text, .ui-widget-content .ui-state-error-text, .ui-widget-header .ui-state-error-text { color: #cd0a0a/*{fcError}*/; }
|
||||||
.ui-priority-primary, .ui-widget-content .ui-priority-primary, .ui-widget-header .ui-priority-primary { font-weight: bold; }
|
.ui-priority-primary, .ui-widget-content .ui-priority-primary, .ui-widget-header .ui-priority-primary { font-weight: bold; }
|
||||||
.ui-priority-secondary, .ui-widget-content .ui-priority-secondary, .ui-widget-header .ui-priority-secondary { opacity: .7; filter:Alpha(Opacity=70); font-weight: normal; }
|
.ui-priority-secondary, .ui-widget-content .ui-priority-secondary, .ui-widget-header .ui-priority-secondary { opacity: .7; filter:Alpha(Opacity=70); font-weight: normal; }
|
||||||
.ui-state-disabled, .ui-widget-content .ui-state-disabled, .ui-widget-header .ui-state-disabled { opacity: .35; filter:Alpha(Opacity=35); background-image: none; }
|
.ui-state-disabled, .ui-widget-content .ui-state-disabled, .ui-widget-header .ui-state-disabled { opacity: .35; filter:Alpha(Opacity=35); background-image: none; }
|
||||||
.ui-state-disabled .ui-icon { filter:Alpha(Opacity=35); } /* For IE8 - See #6059 */
|
.ui-state-disabled .ui-icon { filter:Alpha(Opacity=35); } /* For IE8 - See #6059 */
|
||||||
|
|
||||||
/* Icons
|
/* Icons
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
|
|
||||||
/* states and images */
|
/* states and images */
|
||||||
.ui-icon { width: 16px; height: 16px; background-image: url(<%= asset_data_uri('images/ui-icons_222222_256x240.png') %>)/*{iconsContent}*/; }
|
.ui-icon { width: 16px; height: 16px; background-image: url(<%= asset_data_uri('images/ui-icons_222222_256x240.png') %>)/*{iconsContent}*/; }
|
||||||
.ui-widget-content .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_222222_256x240.png') %>)/*{iconsContent}*/; }
|
.ui-widget-content .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_222222_256x240.png') %>)/*{iconsContent}*/; }
|
||||||
.ui-widget-header .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_222222_256x240.png') %>)/*{iconsHeader}*/; }
|
.ui-widget-header .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_222222_256x240.png') %>)/*{iconsHeader}*/; }
|
||||||
.ui-state-default .ui-icon { background-image: url(<%= asset_data_uri('images/ui-icons_888888_256x240.png') %>)/*{iconsDefault}*/; }
|
.ui-state-default .ui-icon { background-image: url(<%= asset_data_uri('images/ui-icons_888888_256x240.png') %>)/*{iconsDefault}*/; }
|
||||||
.ui-state-hover .ui-icon, .ui-state-focus .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_454545_256x240.png') %>)/*{iconsHover}*/; }
|
.ui-state-hover .ui-icon, .ui-state-focus .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_454545_256x240.png') %>)/*{iconsHover}*/; }
|
||||||
.ui-state-active .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_454545_256x240.png') %>)/*{iconsActive}*/; }
|
.ui-state-active .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_454545_256x240.png') %>)/*{iconsActive}*/; }
|
||||||
.ui-state-highlight .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_2e83ff_256x240.png') %>)/*{iconsHighlight}*/; }
|
.ui-state-highlight .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_2e83ff_256x240.png') %>)/*{iconsHighlight}*/; }
|
||||||
.ui-state-error .ui-icon, .ui-state-error-text .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_cd0a0a_256x240.png') %>)/*{iconsError}*/; }
|
.ui-state-error .ui-icon, .ui-state-error-text .ui-icon {background-image: url(<%= asset_data_uri('images/ui-icons_cd0a0a_256x240.png') %>)/*{iconsError}*/; }
|
||||||
|
|
||||||
/* positioning */
|
/* positioning */
|
||||||
.ui-icon-carat-1-n { background-position: 0 0; }
|
.ui-icon-carat-1-n { background-position: 0 0; }
|
||||||
.ui-icon-carat-1-ne { background-position: -16px 0; }
|
.ui-icon-carat-1-ne { background-position: -16px 0; }
|
||||||
.ui-icon-carat-1-e { background-position: -32px 0; }
|
.ui-icon-carat-1-e { background-position: -32px 0; }
|
||||||
.ui-icon-carat-1-se { background-position: -48px 0; }
|
.ui-icon-carat-1-se { background-position: -48px 0; }
|
||||||
.ui-icon-carat-1-s { background-position: -64px 0; }
|
.ui-icon-carat-1-s { background-position: -64px 0; }
|
||||||
.ui-icon-carat-1-sw { background-position: -80px 0; }
|
.ui-icon-carat-1-sw { background-position: -80px 0; }
|
||||||
.ui-icon-carat-1-w { background-position: -96px 0; }
|
.ui-icon-carat-1-w { background-position: -96px 0; }
|
||||||
.ui-icon-carat-1-nw { background-position: -112px 0; }
|
.ui-icon-carat-1-nw { background-position: -112px 0; }
|
||||||
.ui-icon-carat-2-n-s { background-position: -128px 0; }
|
.ui-icon-carat-2-n-s { background-position: -128px 0; }
|
||||||
.ui-icon-carat-2-e-w { background-position: -144px 0; }
|
.ui-icon-carat-2-e-w { background-position: -144px 0; }
|
||||||
.ui-icon-triangle-1-n { background-position: 0 -16px; }
|
.ui-icon-triangle-1-n { background-position: 0 -16px; }
|
||||||
.ui-icon-triangle-1-ne { background-position: -16px -16px; }
|
.ui-icon-triangle-1-ne { background-position: -16px -16px; }
|
||||||
.ui-icon-triangle-1-e { background-position: -32px -16px; }
|
.ui-icon-triangle-1-e { background-position: -32px -16px; }
|
||||||
.ui-icon-triangle-1-se { background-position: -48px -16px; }
|
.ui-icon-triangle-1-se { background-position: -48px -16px; }
|
||||||
.ui-icon-triangle-1-s { background-position: -64px -16px; }
|
.ui-icon-triangle-1-s { background-position: -64px -16px; }
|
||||||
.ui-icon-triangle-1-sw { background-position: -80px -16px; }
|
.ui-icon-triangle-1-sw { background-position: -80px -16px; }
|
||||||
.ui-icon-triangle-1-w { background-position: -96px -16px; }
|
.ui-icon-triangle-1-w { background-position: -96px -16px; }
|
||||||
.ui-icon-triangle-1-nw { background-position: -112px -16px; }
|
.ui-icon-triangle-1-nw { background-position: -112px -16px; }
|
||||||
.ui-icon-triangle-2-n-s { background-position: -128px -16px; }
|
.ui-icon-triangle-2-n-s { background-position: -128px -16px; }
|
||||||
.ui-icon-triangle-2-e-w { background-position: -144px -16px; }
|
.ui-icon-triangle-2-e-w { background-position: -144px -16px; }
|
||||||
.ui-icon-arrow-1-n { background-position: 0 -32px; }
|
.ui-icon-arrow-1-n { background-position: 0 -32px; }
|
||||||
.ui-icon-arrow-1-ne { background-position: -16px -32px; }
|
.ui-icon-arrow-1-ne { background-position: -16px -32px; }
|
||||||
.ui-icon-arrow-1-e { background-position: -32px -32px; }
|
.ui-icon-arrow-1-e { background-position: -32px -32px; }
|
||||||
.ui-icon-arrow-1-se { background-position: -48px -32px; }
|
.ui-icon-arrow-1-se { background-position: -48px -32px; }
|
||||||
.ui-icon-arrow-1-s { background-position: -64px -32px; }
|
.ui-icon-arrow-1-s { background-position: -64px -32px; }
|
||||||
.ui-icon-arrow-1-sw { background-position: -80px -32px; }
|
.ui-icon-arrow-1-sw { background-position: -80px -32px; }
|
||||||
.ui-icon-arrow-1-w { background-position: -96px -32px; }
|
.ui-icon-arrow-1-w { background-position: -96px -32px; }
|
||||||
.ui-icon-arrow-1-nw { background-position: -112px -32px; }
|
.ui-icon-arrow-1-nw { background-position: -112px -32px; }
|
||||||
.ui-icon-arrow-2-n-s { background-position: -128px -32px; }
|
.ui-icon-arrow-2-n-s { background-position: -128px -32px; }
|
||||||
.ui-icon-arrow-2-ne-sw { background-position: -144px -32px; }
|
.ui-icon-arrow-2-ne-sw { background-position: -144px -32px; }
|
||||||
.ui-icon-arrow-2-e-w { background-position: -160px -32px; }
|
.ui-icon-arrow-2-e-w { background-position: -160px -32px; }
|
||||||
.ui-icon-arrow-2-se-nw { background-position: -176px -32px; }
|
.ui-icon-arrow-2-se-nw { background-position: -176px -32px; }
|
||||||
.ui-icon-arrowstop-1-n { background-position: -192px -32px; }
|
.ui-icon-arrowstop-1-n { background-position: -192px -32px; }
|
||||||
.ui-icon-arrowstop-1-e { background-position: -208px -32px; }
|
.ui-icon-arrowstop-1-e { background-position: -208px -32px; }
|
||||||
.ui-icon-arrowstop-1-s { background-position: -224px -32px; }
|
.ui-icon-arrowstop-1-s { background-position: -224px -32px; }
|
||||||
.ui-icon-arrowstop-1-w { background-position: -240px -32px; }
|
.ui-icon-arrowstop-1-w { background-position: -240px -32px; }
|
||||||
.ui-icon-arrowthick-1-n { background-position: 0 -48px; }
|
.ui-icon-arrowthick-1-n { background-position: 0 -48px; }
|
||||||
.ui-icon-arrowthick-1-ne { background-position: -16px -48px; }
|
.ui-icon-arrowthick-1-ne { background-position: -16px -48px; }
|
||||||
.ui-icon-arrowthick-1-e { background-position: -32px -48px; }
|
.ui-icon-arrowthick-1-e { background-position: -32px -48px; }
|
||||||
.ui-icon-arrowthick-1-se { background-position: -48px -48px; }
|
.ui-icon-arrowthick-1-se { background-position: -48px -48px; }
|
||||||
.ui-icon-arrowthick-1-s { background-position: -64px -48px; }
|
.ui-icon-arrowthick-1-s { background-position: -64px -48px; }
|
||||||
.ui-icon-arrowthick-1-sw { background-position: -80px -48px; }
|
.ui-icon-arrowthick-1-sw { background-position: -80px -48px; }
|
||||||
.ui-icon-arrowthick-1-w { background-position: -96px -48px; }
|
.ui-icon-arrowthick-1-w { background-position: -96px -48px; }
|
||||||
.ui-icon-arrowthick-1-nw { background-position: -112px -48px; }
|
.ui-icon-arrowthick-1-nw { background-position: -112px -48px; }
|
||||||
.ui-icon-arrowthick-2-n-s { background-position: -128px -48px; }
|
.ui-icon-arrowthick-2-n-s { background-position: -128px -48px; }
|
||||||
.ui-icon-arrowthick-2-ne-sw { background-position: -144px -48px; }
|
.ui-icon-arrowthick-2-ne-sw { background-position: -144px -48px; }
|
||||||
.ui-icon-arrowthick-2-e-w { background-position: -160px -48px; }
|
.ui-icon-arrowthick-2-e-w { background-position: -160px -48px; }
|
||||||
.ui-icon-arrowthick-2-se-nw { background-position: -176px -48px; }
|
.ui-icon-arrowthick-2-se-nw { background-position: -176px -48px; }
|
||||||
.ui-icon-arrowthickstop-1-n { background-position: -192px -48px; }
|
.ui-icon-arrowthickstop-1-n { background-position: -192px -48px; }
|
||||||
.ui-icon-arrowthickstop-1-e { background-position: -208px -48px; }
|
.ui-icon-arrowthickstop-1-e { background-position: -208px -48px; }
|
||||||
.ui-icon-arrowthickstop-1-s { background-position: -224px -48px; }
|
.ui-icon-arrowthickstop-1-s { background-position: -224px -48px; }
|
||||||
.ui-icon-arrowthickstop-1-w { background-position: -240px -48px; }
|
.ui-icon-arrowthickstop-1-w { background-position: -240px -48px; }
|
||||||
.ui-icon-arrowreturnthick-1-w { background-position: 0 -64px; }
|
.ui-icon-arrowreturnthick-1-w { background-position: 0 -64px; }
|
||||||
.ui-icon-arrowreturnthick-1-n { background-position: -16px -64px; }
|
.ui-icon-arrowreturnthick-1-n { background-position: -16px -64px; }
|
||||||
.ui-icon-arrowreturnthick-1-e { background-position: -32px -64px; }
|
.ui-icon-arrowreturnthick-1-e { background-position: -32px -64px; }
|
||||||
.ui-icon-arrowreturnthick-1-s { background-position: -48px -64px; }
|
.ui-icon-arrowreturnthick-1-s { background-position: -48px -64px; }
|
||||||
.ui-icon-arrowreturn-1-w { background-position: -64px -64px; }
|
.ui-icon-arrowreturn-1-w { background-position: -64px -64px; }
|
||||||
.ui-icon-arrowreturn-1-n { background-position: -80px -64px; }
|
.ui-icon-arrowreturn-1-n { background-position: -80px -64px; }
|
||||||
.ui-icon-arrowreturn-1-e { background-position: -96px -64px; }
|
.ui-icon-arrowreturn-1-e { background-position: -96px -64px; }
|
||||||
.ui-icon-arrowreturn-1-s { background-position: -112px -64px; }
|
.ui-icon-arrowreturn-1-s { background-position: -112px -64px; }
|
||||||
.ui-icon-arrowrefresh-1-w { background-position: -128px -64px; }
|
.ui-icon-arrowrefresh-1-w { background-position: -128px -64px; }
|
||||||
.ui-icon-arrowrefresh-1-n { background-position: -144px -64px; }
|
.ui-icon-arrowrefresh-1-n { background-position: -144px -64px; }
|
||||||
.ui-icon-arrowrefresh-1-e { background-position: -160px -64px; }
|
.ui-icon-arrowrefresh-1-e { background-position: -160px -64px; }
|
||||||
.ui-icon-arrowrefresh-1-s { background-position: -176px -64px; }
|
.ui-icon-arrowrefresh-1-s { background-position: -176px -64px; }
|
||||||
.ui-icon-arrow-4 { background-position: 0 -80px; }
|
.ui-icon-arrow-4 { background-position: 0 -80px; }
|
||||||
.ui-icon-arrow-4-diag { background-position: -16px -80px; }
|
.ui-icon-arrow-4-diag { background-position: -16px -80px; }
|
||||||
.ui-icon-extlink { background-position: -32px -80px; }
|
.ui-icon-extlink { background-position: -32px -80px; }
|
||||||
.ui-icon-newwin { background-position: -48px -80px; }
|
.ui-icon-newwin { background-position: -48px -80px; }
|
||||||
.ui-icon-refresh { background-position: -64px -80px; }
|
.ui-icon-refresh { background-position: -64px -80px; }
|
||||||
.ui-icon-shuffle { background-position: -80px -80px; }
|
.ui-icon-shuffle { background-position: -80px -80px; }
|
||||||
.ui-icon-transfer-e-w { background-position: -96px -80px; }
|
.ui-icon-transfer-e-w { background-position: -96px -80px; }
|
||||||
.ui-icon-transferthick-e-w { background-position: -112px -80px; }
|
.ui-icon-transferthick-e-w { background-position: -112px -80px; }
|
||||||
.ui-icon-folder-collapsed { background-position: 0 -96px; }
|
.ui-icon-folder-collapsed { background-position: 0 -96px; }
|
||||||
.ui-icon-folder-open { background-position: -16px -96px; }
|
.ui-icon-folder-open { background-position: -16px -96px; }
|
||||||
.ui-icon-document { background-position: -32px -96px; }
|
.ui-icon-document { background-position: -32px -96px; }
|
||||||
.ui-icon-document-b { background-position: -48px -96px; }
|
.ui-icon-document-b { background-position: -48px -96px; }
|
||||||
.ui-icon-note { background-position: -64px -96px; }
|
.ui-icon-note { background-position: -64px -96px; }
|
||||||
.ui-icon-mail-closed { background-position: -80px -96px; }
|
.ui-icon-mail-closed { background-position: -80px -96px; }
|
||||||
.ui-icon-mail-open { background-position: -96px -96px; }
|
.ui-icon-mail-open { background-position: -96px -96px; }
|
||||||
.ui-icon-suitcase { background-position: -112px -96px; }
|
.ui-icon-suitcase { background-position: -112px -96px; }
|
||||||
.ui-icon-comment { background-position: -128px -96px; }
|
.ui-icon-comment { background-position: -128px -96px; }
|
||||||
.ui-icon-person { background-position: -144px -96px; }
|
.ui-icon-person { background-position: -144px -96px; }
|
||||||
.ui-icon-print { background-position: -160px -96px; }
|
.ui-icon-print { background-position: -160px -96px; }
|
||||||
.ui-icon-trash { background-position: -176px -96px; }
|
.ui-icon-trash { background-position: -176px -96px; }
|
||||||
.ui-icon-locked { background-position: -192px -96px; }
|
.ui-icon-locked { background-position: -192px -96px; }
|
||||||
.ui-icon-unlocked { background-position: -208px -96px; }
|
.ui-icon-unlocked { background-position: -208px -96px; }
|
||||||
.ui-icon-bookmark { background-position: -224px -96px; }
|
.ui-icon-bookmark { background-position: -224px -96px; }
|
||||||
.ui-icon-tag { background-position: -240px -96px; }
|
.ui-icon-tag { background-position: -240px -96px; }
|
||||||
.ui-icon-home { background-position: 0 -112px; }
|
.ui-icon-home { background-position: 0 -112px; }
|
||||||
.ui-icon-flag { background-position: -16px -112px; }
|
.ui-icon-flag { background-position: -16px -112px; }
|
||||||
.ui-icon-calendar { background-position: -32px -112px; }
|
.ui-icon-calendar { background-position: -32px -112px; }
|
||||||
.ui-icon-cart { background-position: -48px -112px; }
|
.ui-icon-cart { background-position: -48px -112px; }
|
||||||
.ui-icon-pencil { background-position: -64px -112px; }
|
.ui-icon-pencil { background-position: -64px -112px; }
|
||||||
.ui-icon-clock { background-position: -80px -112px; }
|
.ui-icon-clock { background-position: -80px -112px; }
|
||||||
.ui-icon-disk { background-position: -96px -112px; }
|
.ui-icon-disk { background-position: -96px -112px; }
|
||||||
.ui-icon-calculator { background-position: -112px -112px; }
|
.ui-icon-calculator { background-position: -112px -112px; }
|
||||||
.ui-icon-zoomin { background-position: -128px -112px; }
|
.ui-icon-zoomin { background-position: -128px -112px; }
|
||||||
.ui-icon-zoomout { background-position: -144px -112px; }
|
.ui-icon-zoomout { background-position: -144px -112px; }
|
||||||
.ui-icon-search { background-position: -160px -112px; }
|
.ui-icon-search { background-position: -160px -112px; }
|
||||||
.ui-icon-wrench { background-position: -176px -112px; }
|
.ui-icon-wrench { background-position: -176px -112px; }
|
||||||
.ui-icon-gear { background-position: -192px -112px; }
|
.ui-icon-gear { background-position: -192px -112px; }
|
||||||
.ui-icon-heart { background-position: -208px -112px; }
|
.ui-icon-heart { background-position: -208px -112px; }
|
||||||
.ui-icon-star { background-position: -224px -112px; }
|
.ui-icon-star { background-position: -224px -112px; }
|
||||||
.ui-icon-link { background-position: -240px -112px; }
|
.ui-icon-link { background-position: -240px -112px; }
|
||||||
.ui-icon-cancel { background-position: 0 -128px; }
|
.ui-icon-cancel { background-position: 0 -128px; }
|
||||||
.ui-icon-plus { background-position: -16px -128px; }
|
.ui-icon-plus { background-position: -16px -128px; }
|
||||||
.ui-icon-plusthick { background-position: -32px -128px; }
|
.ui-icon-plusthick { background-position: -32px -128px; }
|
||||||
.ui-icon-minus { background-position: -48px -128px; }
|
.ui-icon-minus { background-position: -48px -128px; }
|
||||||
.ui-icon-minusthick { background-position: -64px -128px; }
|
.ui-icon-minusthick { background-position: -64px -128px; }
|
||||||
.ui-icon-close { background-position: -80px -128px; }
|
.ui-icon-close { background-position: -80px -128px; }
|
||||||
.ui-icon-closethick { background-position: -96px -128px; }
|
.ui-icon-closethick { background-position: -96px -128px; }
|
||||||
.ui-icon-key { background-position: -112px -128px; }
|
.ui-icon-key { background-position: -112px -128px; }
|
||||||
.ui-icon-lightbulb { background-position: -128px -128px; }
|
.ui-icon-lightbulb { background-position: -128px -128px; }
|
||||||
.ui-icon-scissors { background-position: -144px -128px; }
|
.ui-icon-scissors { background-position: -144px -128px; }
|
||||||
.ui-icon-clipboard { background-position: -160px -128px; }
|
.ui-icon-clipboard { background-position: -160px -128px; }
|
||||||
.ui-icon-copy { background-position: -176px -128px; }
|
.ui-icon-copy { background-position: -176px -128px; }
|
||||||
.ui-icon-contact { background-position: -192px -128px; }
|
.ui-icon-contact { background-position: -192px -128px; }
|
||||||
.ui-icon-image { background-position: -208px -128px; }
|
.ui-icon-image { background-position: -208px -128px; }
|
||||||
.ui-icon-video { background-position: -224px -128px; }
|
.ui-icon-video { background-position: -224px -128px; }
|
||||||
.ui-icon-script { background-position: -240px -128px; }
|
.ui-icon-script { background-position: -240px -128px; }
|
||||||
.ui-icon-alert { background-position: 0 -144px; }
|
.ui-icon-alert { background-position: 0 -144px; }
|
||||||
.ui-icon-info { background-position: -16px -144px; }
|
.ui-icon-info { background-position: -16px -144px; }
|
||||||
.ui-icon-notice { background-position: -32px -144px; }
|
.ui-icon-notice { background-position: -32px -144px; }
|
||||||
.ui-icon-help { background-position: -48px -144px; }
|
.ui-icon-help { background-position: -48px -144px; }
|
||||||
.ui-icon-check { background-position: -64px -144px; }
|
.ui-icon-check { background-position: -64px -144px; }
|
||||||
.ui-icon-bullet { background-position: -80px -144px; }
|
.ui-icon-bullet { background-position: -80px -144px; }
|
||||||
.ui-icon-radio-on { background-position: -96px -144px; }
|
.ui-icon-radio-on { background-position: -96px -144px; }
|
||||||
.ui-icon-radio-off { background-position: -112px -144px; }
|
.ui-icon-radio-off { background-position: -112px -144px; }
|
||||||
.ui-icon-pin-w { background-position: -128px -144px; }
|
.ui-icon-pin-w { background-position: -128px -144px; }
|
||||||
.ui-icon-pin-s { background-position: -144px -144px; }
|
.ui-icon-pin-s { background-position: -144px -144px; }
|
||||||
.ui-icon-play { background-position: 0 -160px; }
|
.ui-icon-play { background-position: 0 -160px; }
|
||||||
.ui-icon-pause { background-position: -16px -160px; }
|
.ui-icon-pause { background-position: -16px -160px; }
|
||||||
.ui-icon-seek-next { background-position: -32px -160px; }
|
.ui-icon-seek-next { background-position: -32px -160px; }
|
||||||
.ui-icon-seek-prev { background-position: -48px -160px; }
|
.ui-icon-seek-prev { background-position: -48px -160px; }
|
||||||
.ui-icon-seek-end { background-position: -64px -160px; }
|
.ui-icon-seek-end { background-position: -64px -160px; }
|
||||||
.ui-icon-seek-start { background-position: -80px -160px; }
|
.ui-icon-seek-start { background-position: -80px -160px; }
|
||||||
/* ui-icon-seek-first is deprecated, use ui-icon-seek-start instead */
|
/* ui-icon-seek-first is deprecated, use ui-icon-seek-start instead */
|
||||||
.ui-icon-seek-first { background-position: -80px -160px; }
|
.ui-icon-seek-first { background-position: -80px -160px; }
|
||||||
.ui-icon-stop { background-position: -96px -160px; }
|
.ui-icon-stop { background-position: -96px -160px; }
|
||||||
.ui-icon-eject { background-position: -112px -160px; }
|
.ui-icon-eject { background-position: -112px -160px; }
|
||||||
.ui-icon-volume-off { background-position: -128px -160px; }
|
.ui-icon-volume-off { background-position: -128px -160px; }
|
||||||
.ui-icon-volume-on { background-position: -144px -160px; }
|
.ui-icon-volume-on { background-position: -144px -160px; }
|
||||||
.ui-icon-power { background-position: 0 -176px; }
|
.ui-icon-power { background-position: 0 -176px; }
|
||||||
.ui-icon-signal-diag { background-position: -16px -176px; }
|
.ui-icon-signal-diag { background-position: -16px -176px; }
|
||||||
.ui-icon-signal { background-position: -32px -176px; }
|
.ui-icon-signal { background-position: -32px -176px; }
|
||||||
.ui-icon-battery-0 { background-position: -48px -176px; }
|
.ui-icon-battery-0 { background-position: -48px -176px; }
|
||||||
.ui-icon-battery-1 { background-position: -64px -176px; }
|
.ui-icon-battery-1 { background-position: -64px -176px; }
|
||||||
.ui-icon-battery-2 { background-position: -80px -176px; }
|
.ui-icon-battery-2 { background-position: -80px -176px; }
|
||||||
.ui-icon-battery-3 { background-position: -96px -176px; }
|
.ui-icon-battery-3 { background-position: -96px -176px; }
|
||||||
.ui-icon-circle-plus { background-position: 0 -192px; }
|
.ui-icon-circle-plus { background-position: 0 -192px; }
|
||||||
.ui-icon-circle-minus { background-position: -16px -192px; }
|
.ui-icon-circle-minus { background-position: -16px -192px; }
|
||||||
.ui-icon-circle-close { background-position: -32px -192px; }
|
.ui-icon-circle-close { background-position: -32px -192px; }
|
||||||
.ui-icon-circle-triangle-e { background-position: -48px -192px; }
|
.ui-icon-circle-triangle-e { background-position: -48px -192px; }
|
||||||
.ui-icon-circle-triangle-s { background-position: -64px -192px; }
|
.ui-icon-circle-triangle-s { background-position: -64px -192px; }
|
||||||
.ui-icon-circle-triangle-w { background-position: -80px -192px; }
|
.ui-icon-circle-triangle-w { background-position: -80px -192px; }
|
||||||
.ui-icon-circle-triangle-n { background-position: -96px -192px; }
|
.ui-icon-circle-triangle-n { background-position: -96px -192px; }
|
||||||
.ui-icon-circle-arrow-e { background-position: -112px -192px; }
|
.ui-icon-circle-arrow-e { background-position: -112px -192px; }
|
||||||
.ui-icon-circle-arrow-s { background-position: -128px -192px; }
|
.ui-icon-circle-arrow-s { background-position: -128px -192px; }
|
||||||
.ui-icon-circle-arrow-w { background-position: -144px -192px; }
|
.ui-icon-circle-arrow-w { background-position: -144px -192px; }
|
||||||
.ui-icon-circle-arrow-n { background-position: -160px -192px; }
|
.ui-icon-circle-arrow-n { background-position: -160px -192px; }
|
||||||
.ui-icon-circle-zoomin { background-position: -176px -192px; }
|
.ui-icon-circle-zoomin { background-position: -176px -192px; }
|
||||||
.ui-icon-circle-zoomout { background-position: -192px -192px; }
|
.ui-icon-circle-zoomout { background-position: -192px -192px; }
|
||||||
.ui-icon-circle-check { background-position: -208px -192px; }
|
.ui-icon-circle-check { background-position: -208px -192px; }
|
||||||
.ui-icon-circlesmall-plus { background-position: 0 -208px; }
|
.ui-icon-circlesmall-plus { background-position: 0 -208px; }
|
||||||
.ui-icon-circlesmall-minus { background-position: -16px -208px; }
|
.ui-icon-circlesmall-minus { background-position: -16px -208px; }
|
||||||
.ui-icon-circlesmall-close { background-position: -32px -208px; }
|
.ui-icon-circlesmall-close { background-position: -32px -208px; }
|
||||||
.ui-icon-squaresmall-plus { background-position: -48px -208px; }
|
.ui-icon-squaresmall-plus { background-position: -48px -208px; }
|
||||||
.ui-icon-squaresmall-minus { background-position: -64px -208px; }
|
.ui-icon-squaresmall-minus { background-position: -64px -208px; }
|
||||||
.ui-icon-squaresmall-close { background-position: -80px -208px; }
|
.ui-icon-squaresmall-close { background-position: -80px -208px; }
|
||||||
.ui-icon-grip-dotted-vertical { background-position: 0 -224px; }
|
.ui-icon-grip-dotted-vertical { background-position: 0 -224px; }
|
||||||
.ui-icon-grip-dotted-horizontal { background-position: -16px -224px; }
|
.ui-icon-grip-dotted-horizontal { background-position: -16px -224px; }
|
||||||
.ui-icon-grip-solid-vertical { background-position: -32px -224px; }
|
.ui-icon-grip-solid-vertical { background-position: -32px -224px; }
|
||||||
.ui-icon-grip-solid-horizontal { background-position: -48px -224px; }
|
.ui-icon-grip-solid-horizontal { background-position: -48px -224px; }
|
||||||
.ui-icon-gripsmall-diagonal-se { background-position: -64px -224px; }
|
.ui-icon-gripsmall-diagonal-se { background-position: -64px -224px; }
|
||||||
.ui-icon-grip-diagonal-se { background-position: -80px -224px; }
|
.ui-icon-grip-diagonal-se { background-position: -80px -224px; }
|
||||||
|
|
||||||
|
|
||||||
/* Misc visuals
|
/* Misc visuals
|
||||||
----------------------------------*/
|
----------------------------------*/
|
||||||
|
|
||||||
/* Corner radius */
|
/* Corner radius */
|
||||||
.ui-corner-all, .ui-corner-top, .ui-corner-left, .ui-corner-tl { -moz-border-radius-topleft: 4px/*{cornerRadius}*/; -webkit-border-top-left-radius: 4px/*{cornerRadius}*/; -khtml-border-top-left-radius: 4px/*{cornerRadius}*/; border-top-left-radius: 4px/*{cornerRadius}*/; }
|
.ui-corner-all, .ui-corner-top, .ui-corner-left, .ui-corner-tl { -moz-border-radius-topleft: 4px/*{cornerRadius}*/; -webkit-border-top-left-radius: 4px/*{cornerRadius}*/; -khtml-border-top-left-radius: 4px/*{cornerRadius}*/; border-top-left-radius: 4px/*{cornerRadius}*/; }
|
||||||
.ui-corner-all, .ui-corner-top, .ui-corner-right, .ui-corner-tr { -moz-border-radius-topright: 4px/*{cornerRadius}*/; -webkit-border-top-right-radius: 4px/*{cornerRadius}*/; -khtml-border-top-right-radius: 4px/*{cornerRadius}*/; border-top-right-radius: 4px/*{cornerRadius}*/; }
|
.ui-corner-all, .ui-corner-top, .ui-corner-right, .ui-corner-tr { -moz-border-radius-topright: 4px/*{cornerRadius}*/; -webkit-border-top-right-radius: 4px/*{cornerRadius}*/; -khtml-border-top-right-radius: 4px/*{cornerRadius}*/; border-top-right-radius: 4px/*{cornerRadius}*/; }
|
||||||
.ui-corner-all, .ui-corner-bottom, .ui-corner-left, .ui-corner-bl { -moz-border-radius-bottomleft: 4px/*{cornerRadius}*/; -webkit-border-bottom-left-radius: 4px/*{cornerRadius}*/; -khtml-border-bottom-left-radius: 4px/*{cornerRadius}*/; border-bottom-left-radius: 4px/*{cornerRadius}*/; }
|
.ui-corner-all, .ui-corner-bottom, .ui-corner-left, .ui-corner-bl { -moz-border-radius-bottomleft: 4px/*{cornerRadius}*/; -webkit-border-bottom-left-radius: 4px/*{cornerRadius}*/; -khtml-border-bottom-left-radius: 4px/*{cornerRadius}*/; border-bottom-left-radius: 4px/*{cornerRadius}*/; }
|
||||||
.ui-corner-all, .ui-corner-bottom, .ui-corner-right, .ui-corner-br { -moz-border-radius-bottomright: 4px/*{cornerRadius}*/; -webkit-border-bottom-right-radius: 4px/*{cornerRadius}*/; -khtml-border-bottom-right-radius: 4px/*{cornerRadius}*/; border-bottom-right-radius: 4px/*{cornerRadius}*/; }
|
.ui-corner-all, .ui-corner-bottom, .ui-corner-right, .ui-corner-br { -moz-border-radius-bottomright: 4px/*{cornerRadius}*/; -webkit-border-bottom-right-radius: 4px/*{cornerRadius}*/; -khtml-border-bottom-right-radius: 4px/*{cornerRadius}*/; border-bottom-right-radius: 4px/*{cornerRadius}*/; }
|
||||||
|
|
||||||
/* Overlays */
|
/* Overlays */
|
||||||
.ui-widget-overlay { background: #aaaaaa/*{bgColorOverlay}*/ url(<%= asset_data_uri('images/ui-bg_flat_0_aaaaaa_40x100.png') %>)/*{bgImgUrlOverlay}*/ 50%/*{bgOverlayXPos}*/ 50%/*{bgOverlayYPos}*/ repeat-x/*{bgOverlayRepeat}*/; opacity: .3;filter:Alpha(Opacity=30)/*{opacityOverlay}*/; }
|
.ui-widget-overlay { background: #aaaaaa/*{bgColorOverlay}*/ url(<%= asset_data_uri('images/ui-bg_flat_0_aaaaaa_40x100.png') %>)/*{bgImgUrlOverlay}*/ 50%/*{bgOverlayXPos}*/ 50%/*{bgOverlayYPos}*/ repeat-x/*{bgOverlayRepeat}*/; opacity: .3;filter:Alpha(Opacity=30)/*{opacityOverlay}*/; }
|
||||||
.ui-widget-shadow { margin: -8px/*{offsetTopShadow}*/ 0 0 -8px/*{offsetLeftShadow}*/; padding: 8px/*{thicknessShadow}*/; background: #aaaaaa/*{bgColorShadow}*/ url(images/<%= asset_data_uri('ui-bg_flat_0_aaaaaa_40x100.png') %>)/*{bgImgUrlShadow}*/ 50%/*{bgShadowXPos}*/ 50%/*{bgShadowYPos}*/ repeat-x/*{bgShadowRepeat}*/; opacity: .3;filter:Alpha(Opacity=30)/*{opacityShadow}*/; -moz-border-radius: 8px/*{cornerRadiusShadow}*/; -khtml-border-radius: 8px/*{cornerRadiusShadow}*/; -webkit-border-radius: 8px/*{cornerRadiusShadow}*/; border-radius: 8px/*{cornerRadiusShadow}*/; }
|
.ui-widget-shadow { margin: -8px/*{offsetTopShadow}*/ 0 0 -8px/*{offsetLeftShadow}*/; padding: 8px/*{thicknessShadow}*/; background: #aaaaaa/*{bgColorShadow}*/ url(images/<%= asset_data_uri('ui-bg_flat_0_aaaaaa_40x100.png') %>)/*{bgImgUrlShadow}*/ 50%/*{bgShadowXPos}*/ 50%/*{bgShadowYPos}*/ repeat-x/*{bgShadowRepeat}*/; opacity: .3;filter:Alpha(Opacity=30)/*{opacityShadow}*/; -moz-border-radius: 8px/*{cornerRadiusShadow}*/; -khtml-border-radius: 8px/*{cornerRadiusShadow}*/; -webkit-border-radius: 8px/*{cornerRadiusShadow}*/; border-radius: 8px/*{cornerRadiusShadow}*/; }
|
||||||
|
|
|
@ -1,473 +1,473 @@
|
||||||
/* basic scrollbar styling */
|
/* basic scrollbar styling */
|
||||||
/* vertical scrollbar */
|
/* vertical scrollbar */
|
||||||
.mCSB_container{
|
.mCSB_container{
|
||||||
width:auto;
|
width:auto;
|
||||||
margin-right:30px;
|
margin-right:30px;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
}
|
}
|
||||||
.mCSB_container.mCS_no_scrollbar{
|
.mCSB_container.mCS_no_scrollbar{
|
||||||
margin-right:0;
|
margin-right:0;
|
||||||
}
|
}
|
||||||
.mCS_disabled>.mCustomScrollBox>.mCSB_container.mCS_no_scrollbar,
|
.mCS_disabled>.mCustomScrollBox>.mCSB_container.mCS_no_scrollbar,
|
||||||
.mCS_destroyed>.mCustomScrollBox>.mCSB_container.mCS_no_scrollbar{
|
.mCS_destroyed>.mCustomScrollBox>.mCSB_container.mCS_no_scrollbar{
|
||||||
margin-right:30px;
|
margin-right:30px;
|
||||||
}
|
}
|
||||||
.mCustomScrollBox>.mCSB_scrollTools{
|
.mCustomScrollBox>.mCSB_scrollTools{
|
||||||
width:16px;
|
width:16px;
|
||||||
height:100%;
|
height:100%;
|
||||||
top:0;
|
top:0;
|
||||||
right:0;
|
right:0;
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_draggerContainer{
|
.mCSB_scrollTools .mCSB_draggerContainer{
|
||||||
position:absolute;
|
position:absolute;
|
||||||
top:0;
|
top:0;
|
||||||
left:0;
|
left:0;
|
||||||
bottom:0;
|
bottom:0;
|
||||||
right:0;
|
right:0;
|
||||||
height:auto;
|
height:auto;
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools a+.mCSB_draggerContainer{
|
.mCSB_scrollTools a+.mCSB_draggerContainer{
|
||||||
margin:20px 0;
|
margin:20px 0;
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_draggerRail{
|
.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:2px;
|
width:2px;
|
||||||
height:100%;
|
height:100%;
|
||||||
margin:0 auto;
|
margin:0 auto;
|
||||||
-webkit-border-radius:10px;
|
-webkit-border-radius:10px;
|
||||||
-moz-border-radius:10px;
|
-moz-border-radius:10px;
|
||||||
border-radius:10px;
|
border-radius:10px;
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_dragger{
|
.mCSB_scrollTools .mCSB_dragger{
|
||||||
cursor:pointer;
|
cursor:pointer;
|
||||||
width:100%;
|
width:100%;
|
||||||
height:30px;
|
height:30px;
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:4px;
|
width:4px;
|
||||||
height:100%;
|
height:100%;
|
||||||
margin:0 auto;
|
margin:0 auto;
|
||||||
-webkit-border-radius:10px;
|
-webkit-border-radius:10px;
|
||||||
-moz-border-radius:10px;
|
-moz-border-radius:10px;
|
||||||
border-radius:10px;
|
border-radius:10px;
|
||||||
text-align:center;
|
text-align:center;
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonUp,
|
.mCSB_scrollTools .mCSB_buttonUp,
|
||||||
.mCSB_scrollTools .mCSB_buttonDown{
|
.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
display:block;
|
display:block;
|
||||||
position:relative;
|
position:relative;
|
||||||
height:20px;
|
height:20px;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
margin:0 auto;
|
margin:0 auto;
|
||||||
cursor:pointer;
|
cursor:pointer;
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonDown{
|
.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
top:100%;
|
top:100%;
|
||||||
margin-top:-40px;
|
margin-top:-40px;
|
||||||
}
|
}
|
||||||
/* horizontal scrollbar */
|
/* horizontal scrollbar */
|
||||||
.mCSB_horizontal>.mCSB_container{
|
.mCSB_horizontal>.mCSB_container{
|
||||||
height:auto;
|
height:auto;
|
||||||
margin-right:0;
|
margin-right:0;
|
||||||
margin-bottom:30px;
|
margin-bottom:30px;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal>.mCSB_container.mCS_no_scrollbar{
|
.mCSB_horizontal>.mCSB_container.mCS_no_scrollbar{
|
||||||
margin-bottom:0;
|
margin-bottom:0;
|
||||||
}
|
}
|
||||||
.mCS_disabled>.mCSB_horizontal>.mCSB_container.mCS_no_scrollbar,
|
.mCS_disabled>.mCSB_horizontal>.mCSB_container.mCS_no_scrollbar,
|
||||||
.mCS_destroyed>.mCSB_horizontal>.mCSB_container.mCS_no_scrollbar{
|
.mCS_destroyed>.mCSB_horizontal>.mCSB_container.mCS_no_scrollbar{
|
||||||
margin-right:0;
|
margin-right:0;
|
||||||
margin-bottom:30px;
|
margin-bottom:30px;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal.mCustomScrollBox>.mCSB_scrollTools{
|
.mCSB_horizontal.mCustomScrollBox>.mCSB_scrollTools{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:16px;
|
height:16px;
|
||||||
top:auto;
|
top:auto;
|
||||||
right:auto;
|
right:auto;
|
||||||
bottom:0;
|
bottom:0;
|
||||||
left:0;
|
left:0;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal>.mCSB_scrollTools a+.mCSB_draggerContainer{
|
.mCSB_horizontal>.mCSB_scrollTools a+.mCSB_draggerContainer{
|
||||||
margin:0 20px;
|
margin:0 20px;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:2px;
|
height:2px;
|
||||||
margin:7px 0;
|
margin:7px 0;
|
||||||
-webkit-border-radius:10px;
|
-webkit-border-radius:10px;
|
||||||
-moz-border-radius:10px;
|
-moz-border-radius:10px;
|
||||||
border-radius:10px;
|
border-radius:10px;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger{
|
.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger{
|
||||||
width:30px;
|
width:30px;
|
||||||
height:100%;
|
height:100%;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:4px;
|
height:4px;
|
||||||
margin:6px auto;
|
margin:6px auto;
|
||||||
-webkit-border-radius:10px;
|
-webkit-border-radius:10px;
|
||||||
-moz-border-radius:10px;
|
-moz-border-radius:10px;
|
||||||
border-radius:10px;
|
border-radius:10px;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal>.mCSB_scrollTools .mCSB_buttonLeft,
|
.mCSB_horizontal>.mCSB_scrollTools .mCSB_buttonLeft,
|
||||||
.mCSB_horizontal>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCSB_horizontal>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
display:block;
|
display:block;
|
||||||
position:relative;
|
position:relative;
|
||||||
width:20px;
|
width:20px;
|
||||||
height:100%;
|
height:100%;
|
||||||
overflow:hidden;
|
overflow:hidden;
|
||||||
margin:0 auto;
|
margin:0 auto;
|
||||||
cursor:pointer;
|
cursor:pointer;
|
||||||
float:left;
|
float:left;
|
||||||
}
|
}
|
||||||
.mCSB_horizontal>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCSB_horizontal>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
margin-left:-40px;
|
margin-left:-40px;
|
||||||
float:right;
|
float:right;
|
||||||
}
|
}
|
||||||
.mCustomScrollBox{
|
.mCustomScrollBox{
|
||||||
-ms-touch-action:none; /*MSPointer events - direct all pointer events to js*/
|
-ms-touch-action:none; /*MSPointer events - direct all pointer events to js*/
|
||||||
}
|
}
|
||||||
|
|
||||||
/* default scrollbar colors and backgrounds (default theme) */
|
/* default scrollbar colors and backgrounds (default theme) */
|
||||||
.mCustomScrollBox>.mCSB_scrollTools{
|
.mCustomScrollBox>.mCSB_scrollTools{
|
||||||
opacity:0.75;
|
opacity:0.75;
|
||||||
filter:"alpha(opacity=75)"; -ms-filter:"alpha(opacity=75)"; /* old ie */
|
filter:"alpha(opacity=75)"; -ms-filter:"alpha(opacity=75)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCustomScrollBox:hover>.mCSB_scrollTools{
|
.mCustomScrollBox:hover>.mCSB_scrollTools{
|
||||||
opacity:1;
|
opacity:1;
|
||||||
filter:"alpha(opacity=100)"; -ms-filter:"alpha(opacity=100)"; /* old ie */
|
filter:"alpha(opacity=100)"; -ms-filter:"alpha(opacity=100)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_draggerRail{
|
.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.4);
|
background:rgba(0,0,0,0.4);
|
||||||
filter:"alpha(opacity=40)"; -ms-filter:"alpha(opacity=40)"; /* old ie */
|
filter:"alpha(opacity=40)"; -ms-filter:"alpha(opacity=40)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
background:#fff; /* rgba fallback */
|
background:#fff; /* rgba fallback */
|
||||||
background:rgba(255,255,255,0.75);
|
background:rgba(255,255,255,0.75);
|
||||||
filter:"alpha(opacity=75)"; -ms-filter:"alpha(opacity=75)"; /* old ie */
|
filter:"alpha(opacity=75)"; -ms-filter:"alpha(opacity=75)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
||||||
background:rgba(255,255,255,0.85);
|
background:rgba(255,255,255,0.85);
|
||||||
filter:"alpha(opacity=85)"; -ms-filter:"alpha(opacity=85)"; /* old ie */
|
filter:"alpha(opacity=85)"; -ms-filter:"alpha(opacity=85)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
||||||
.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
||||||
background:rgba(255,255,255,0.9);
|
background:rgba(255,255,255,0.9);
|
||||||
filter:"alpha(opacity=90)"; -ms-filter:"alpha(opacity=90)"; /* old ie */
|
filter:"alpha(opacity=90)"; -ms-filter:"alpha(opacity=90)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonUp,
|
.mCSB_scrollTools .mCSB_buttonUp,
|
||||||
.mCSB_scrollTools .mCSB_buttonDown,
|
.mCSB_scrollTools .mCSB_buttonDown,
|
||||||
.mCSB_scrollTools .mCSB_buttonLeft,
|
.mCSB_scrollTools .mCSB_buttonLeft,
|
||||||
.mCSB_scrollTools .mCSB_buttonRight{
|
.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-repeat:no-repeat;
|
background-repeat:no-repeat;
|
||||||
opacity:0.4;
|
opacity:0.4;
|
||||||
filter:"alpha(opacity=40)"; -ms-filter:"alpha(opacity=40)"; /* old ie */
|
filter:"alpha(opacity=40)"; -ms-filter:"alpha(opacity=40)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonUp{
|
.mCSB_scrollTools .mCSB_buttonUp{
|
||||||
background-position:0 0;
|
background-position:0 0;
|
||||||
/*
|
/*
|
||||||
sprites locations are 0 0/-16px 0/-32px 0/-48px 0 (light) and -80px 0/-96px 0/-112px 0/-128px 0 (dark)
|
sprites locations are 0 0/-16px 0/-32px 0/-48px 0 (light) and -80px 0/-96px 0/-112px 0/-128px 0 (dark)
|
||||||
*/
|
*/
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonDown{
|
.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
background-position:0 -20px;
|
background-position:0 -20px;
|
||||||
/*
|
/*
|
||||||
sprites locations are 0 -20px/-16px -20px/-32px -20px/-48px -20px (light) and -80px -20px/-96px -20px/-112px -20px/-128px -20px (dark)
|
sprites locations are 0 -20px/-16px -20px/-32px -20px/-48px -20px (light) and -80px -20px/-96px -20px/-112px -20px/-128px -20px (dark)
|
||||||
*/
|
*/
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonLeft{
|
.mCSB_scrollTools .mCSB_buttonLeft{
|
||||||
background-position:0 -40px;
|
background-position:0 -40px;
|
||||||
/*
|
/*
|
||||||
sprites locations are 0 -40px/-20px -40px/-40px -40px/-60px -40px (light) and -80px -40px/-100px -40px/-120px -40px/-140px -40px (dark)
|
sprites locations are 0 -40px/-20px -40px/-40px -40px/-60px -40px (light) and -80px -40px/-100px -40px/-120px -40px/-140px -40px (dark)
|
||||||
*/
|
*/
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonRight{
|
.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-position:0 -56px;
|
background-position:0 -56px;
|
||||||
/*
|
/*
|
||||||
sprites locations are 0 -56px/-20px -56px/-40px -56px/-60px -56px (light) and -80px -56px/-100px -56px/-120px -56px/-140px -56px (dark)
|
sprites locations are 0 -56px/-20px -56px/-40px -56px/-60px -56px (light) and -80px -56px/-100px -56px/-120px -56px/-140px -56px (dark)
|
||||||
*/
|
*/
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonUp:hover,
|
.mCSB_scrollTools .mCSB_buttonUp:hover,
|
||||||
.mCSB_scrollTools .mCSB_buttonDown:hover,
|
.mCSB_scrollTools .mCSB_buttonDown:hover,
|
||||||
.mCSB_scrollTools .mCSB_buttonLeft:hover,
|
.mCSB_scrollTools .mCSB_buttonLeft:hover,
|
||||||
.mCSB_scrollTools .mCSB_buttonRight:hover{
|
.mCSB_scrollTools .mCSB_buttonRight:hover{
|
||||||
opacity:0.75;
|
opacity:0.75;
|
||||||
filter:"alpha(opacity=75)"; -ms-filter:"alpha(opacity=75)"; /* old ie */
|
filter:"alpha(opacity=75)"; -ms-filter:"alpha(opacity=75)"; /* old ie */
|
||||||
}
|
}
|
||||||
.mCSB_scrollTools .mCSB_buttonUp:active,
|
.mCSB_scrollTools .mCSB_buttonUp:active,
|
||||||
.mCSB_scrollTools .mCSB_buttonDown:active,
|
.mCSB_scrollTools .mCSB_buttonDown:active,
|
||||||
.mCSB_scrollTools .mCSB_buttonLeft:active,
|
.mCSB_scrollTools .mCSB_buttonLeft:active,
|
||||||
.mCSB_scrollTools .mCSB_buttonRight:active{
|
.mCSB_scrollTools .mCSB_buttonRight:active{
|
||||||
opacity:0.9;
|
opacity:0.9;
|
||||||
filter:"alpha(opacity=90)"; -ms-filter:"alpha(opacity=90)"; /* old ie */
|
filter:"alpha(opacity=90)"; -ms-filter:"alpha(opacity=90)"; /* old ie */
|
||||||
}
|
}
|
||||||
|
|
||||||
/*scrollbar themes*/
|
/*scrollbar themes*/
|
||||||
/*dark (dark colored scrollbar)*/
|
/*dark (dark colored scrollbar)*/
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-dark>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.15);
|
background:rgba(0,0,0,0.15);
|
||||||
}
|
}
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-dark>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.75);
|
background:rgba(0,0,0,0.75);
|
||||||
}
|
}
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
.mCS-dark>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.85);
|
background:rgba(0,0,0,0.85);
|
||||||
}
|
}
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
.mCS-dark>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
.mCS-dark>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.9);
|
background:rgba(0,0,0,0.9);
|
||||||
}
|
}
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_buttonUp{
|
.mCS-dark>.mCSB_scrollTools .mCSB_buttonUp{
|
||||||
background-position:-80px 0;
|
background-position:-80px 0;
|
||||||
}
|
}
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_buttonDown{
|
.mCS-dark>.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
background-position:-80px -20px;
|
background-position:-80px -20px;
|
||||||
}
|
}
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_buttonLeft{
|
.mCS-dark>.mCSB_scrollTools .mCSB_buttonLeft{
|
||||||
background-position:-80px -40px;
|
background-position:-80px -40px;
|
||||||
}
|
}
|
||||||
.mCS-dark>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCS-dark>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-position:-80px -56px;
|
background-position:-80px -56px;
|
||||||
}
|
}
|
||||||
/*light-2*/
|
/*light-2*/
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:4px;
|
width:4px;
|
||||||
background:#fff; /* rgba fallback */
|
background:#fff; /* rgba fallback */
|
||||||
background:rgba(255,255,255,0.1);
|
background:rgba(255,255,255,0.1);
|
||||||
-webkit-border-radius:1px;
|
-webkit-border-radius:1px;
|
||||||
-moz-border-radius:1px;
|
-moz-border-radius:1px;
|
||||||
border-radius:1px;
|
border-radius:1px;
|
||||||
}
|
}
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:4px;
|
width:4px;
|
||||||
background:#fff; /* rgba fallback */
|
background:#fff; /* rgba fallback */
|
||||||
background:rgba(255,255,255,0.75);
|
background:rgba(255,255,255,0.75);
|
||||||
-webkit-border-radius:1px;
|
-webkit-border-radius:1px;
|
||||||
-moz-border-radius:1px;
|
-moz-border-radius:1px;
|
||||||
border-radius:1px;
|
border-radius:1px;
|
||||||
}
|
}
|
||||||
.mCS-light-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-light-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:4px;
|
height:4px;
|
||||||
margin:6px 0;
|
margin:6px 0;
|
||||||
}
|
}
|
||||||
.mCS-light-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-light-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:4px;
|
height:4px;
|
||||||
margin:6px auto;
|
margin:6px auto;
|
||||||
}
|
}
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
||||||
background:rgba(255,255,255,0.85);
|
background:rgba(255,255,255,0.85);
|
||||||
}
|
}
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
||||||
background:rgba(255,255,255,0.9);
|
background:rgba(255,255,255,0.9);
|
||||||
}
|
}
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonUp{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonUp{
|
||||||
background-position:-32px 0;
|
background-position:-32px 0;
|
||||||
}
|
}
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonDown{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
background-position:-32px -20px;
|
background-position:-32px -20px;
|
||||||
}
|
}
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonLeft{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonLeft{
|
||||||
background-position:-40px -40px;
|
background-position:-40px -40px;
|
||||||
}
|
}
|
||||||
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCS-light-2>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-position:-40px -56px;
|
background-position:-40px -56px;
|
||||||
}
|
}
|
||||||
/*dark-2*/
|
/*dark-2*/
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:4px;
|
width:4px;
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.1);
|
background:rgba(0,0,0,0.1);
|
||||||
-webkit-border-radius:1px;
|
-webkit-border-radius:1px;
|
||||||
-moz-border-radius:1px;
|
-moz-border-radius:1px;
|
||||||
border-radius:1px;
|
border-radius:1px;
|
||||||
}
|
}
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:4px;
|
width:4px;
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.75);
|
background:rgba(0,0,0,0.75);
|
||||||
-webkit-border-radius:1px;
|
-webkit-border-radius:1px;
|
||||||
-moz-border-radius:1px;
|
-moz-border-radius:1px;
|
||||||
border-radius:1px;
|
border-radius:1px;
|
||||||
}
|
}
|
||||||
.mCS-dark-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-dark-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:4px;
|
height:4px;
|
||||||
margin:6px 0;
|
margin:6px 0;
|
||||||
}
|
}
|
||||||
.mCS-dark-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-dark-2.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:4px;
|
height:4px;
|
||||||
margin:6px auto;
|
margin:6px auto;
|
||||||
}
|
}
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.85);
|
background:rgba(0,0,0,0.85);
|
||||||
}
|
}
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.9);
|
background:rgba(0,0,0,0.9);
|
||||||
}
|
}
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonUp{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonUp{
|
||||||
background-position:-112px 0;
|
background-position:-112px 0;
|
||||||
}
|
}
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonDown{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
background-position:-112px -20px;
|
background-position:-112px -20px;
|
||||||
}
|
}
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonLeft{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonLeft{
|
||||||
background-position:-120px -40px;
|
background-position:-120px -40px;
|
||||||
}
|
}
|
||||||
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCS-dark-2>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-position:-120px -56px;
|
background-position:-120px -56px;
|
||||||
}
|
}
|
||||||
/*light-thick*/
|
/*light-thick*/
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:4px;
|
width:4px;
|
||||||
background:#fff; /* rgba fallback */
|
background:#fff; /* rgba fallback */
|
||||||
background:rgba(255,255,255,0.1);
|
background:rgba(255,255,255,0.1);
|
||||||
-webkit-border-radius:2px;
|
-webkit-border-radius:2px;
|
||||||
-moz-border-radius:2px;
|
-moz-border-radius:2px;
|
||||||
border-radius:2px;
|
border-radius:2px;
|
||||||
}
|
}
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:6px;
|
width:6px;
|
||||||
background:#fff; /* rgba fallback */
|
background:#fff; /* rgba fallback */
|
||||||
background:rgba(255,255,255,0.75);
|
background:rgba(255,255,255,0.75);
|
||||||
-webkit-border-radius:2px;
|
-webkit-border-radius:2px;
|
||||||
-moz-border-radius:2px;
|
-moz-border-radius:2px;
|
||||||
border-radius:2px;
|
border-radius:2px;
|
||||||
}
|
}
|
||||||
.mCS-light-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-light-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:4px;
|
height:4px;
|
||||||
margin:6px 0;
|
margin:6px 0;
|
||||||
}
|
}
|
||||||
.mCS-light-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-light-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:6px;
|
height:6px;
|
||||||
margin:5px auto;
|
margin:5px auto;
|
||||||
}
|
}
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
||||||
background:rgba(255,255,255,0.85);
|
background:rgba(255,255,255,0.85);
|
||||||
}
|
}
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
||||||
background:rgba(255,255,255,0.9);
|
background:rgba(255,255,255,0.9);
|
||||||
}
|
}
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonUp{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonUp{
|
||||||
background-position:-16px 0;
|
background-position:-16px 0;
|
||||||
}
|
}
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonDown{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
background-position:-16px -20px;
|
background-position:-16px -20px;
|
||||||
}
|
}
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonLeft{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonLeft{
|
||||||
background-position:-20px -40px;
|
background-position:-20px -40px;
|
||||||
}
|
}
|
||||||
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCS-light-thick>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-position:-20px -56px;
|
background-position:-20px -56px;
|
||||||
}
|
}
|
||||||
/*dark-thick*/
|
/*dark-thick*/
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:4px;
|
width:4px;
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.1);
|
background:rgba(0,0,0,0.1);
|
||||||
-webkit-border-radius:2px;
|
-webkit-border-radius:2px;
|
||||||
-moz-border-radius:2px;
|
-moz-border-radius:2px;
|
||||||
border-radius:2px;
|
border-radius:2px;
|
||||||
}
|
}
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:6px;
|
width:6px;
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.75);
|
background:rgba(0,0,0,0.75);
|
||||||
-webkit-border-radius:2px;
|
-webkit-border-radius:2px;
|
||||||
-moz-border-radius:2px;
|
-moz-border-radius:2px;
|
||||||
border-radius:2px;
|
border-radius:2px;
|
||||||
}
|
}
|
||||||
.mCS-dark-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-dark-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:4px;
|
height:4px;
|
||||||
margin:6px 0;
|
margin:6px 0;
|
||||||
}
|
}
|
||||||
.mCS-dark-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-dark-thick.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:6px;
|
height:6px;
|
||||||
margin:5px auto;
|
margin:5px auto;
|
||||||
}
|
}
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.85);
|
background:rgba(0,0,0,0.85);
|
||||||
}
|
}
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.9);
|
background:rgba(0,0,0,0.9);
|
||||||
}
|
}
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonUp{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonUp{
|
||||||
background-position:-96px 0;
|
background-position:-96px 0;
|
||||||
}
|
}
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonDown{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
background-position:-96px -20px;
|
background-position:-96px -20px;
|
||||||
}
|
}
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonLeft{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonLeft{
|
||||||
background-position:-100px -40px;
|
background-position:-100px -40px;
|
||||||
}
|
}
|
||||||
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCS-dark-thick>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-position:-100px -56px;
|
background-position:-100px -56px;
|
||||||
}
|
}
|
||||||
/*light-thin*/
|
/*light-thin*/
|
||||||
.mCS-light-thin>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-light-thin>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
background:#fff; /* rgba fallback */
|
background:#fff; /* rgba fallback */
|
||||||
background:rgba(255,255,255,0.1);
|
background:rgba(255,255,255,0.1);
|
||||||
}
|
}
|
||||||
.mCS-light-thin>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-light-thin>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:2px;
|
width:2px;
|
||||||
}
|
}
|
||||||
.mCS-light-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-light-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:100%;
|
width:100%;
|
||||||
}
|
}
|
||||||
.mCS-light-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-light-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:2px;
|
height:2px;
|
||||||
margin:7px auto;
|
margin:7px auto;
|
||||||
}
|
}
|
||||||
/*dark-thin*/
|
/*dark-thin*/
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.15);
|
background:rgba(0,0,0,0.15);
|
||||||
}
|
}
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:2px;
|
width:2px;
|
||||||
background:#000; /* rgba fallback */
|
background:#000; /* rgba fallback */
|
||||||
background:rgba(0,0,0,0.75);
|
background:rgba(0,0,0,0.75);
|
||||||
}
|
}
|
||||||
.mCS-dark-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
.mCS-dark-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_draggerRail{
|
||||||
width:100%;
|
width:100%;
|
||||||
}
|
}
|
||||||
.mCS-dark-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
.mCS-dark-thin.mCSB_horizontal>.mCSB_scrollTools .mCSB_dragger .mCSB_dragger_bar{
|
||||||
width:100%;
|
width:100%;
|
||||||
height:2px;
|
height:2px;
|
||||||
margin:7px auto;
|
margin:7px auto;
|
||||||
}
|
}
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger:hover .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.85);
|
background:rgba(0,0,0,0.85);
|
||||||
}
|
}
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger:active .mCSB_dragger_bar,
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_dragger.mCSB_dragger_onDrag .mCSB_dragger_bar{
|
||||||
background:rgba(0,0,0,0.9);
|
background:rgba(0,0,0,0.9);
|
||||||
}
|
}
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonUp{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonUp{
|
||||||
background-position:-80px 0;
|
background-position:-80px 0;
|
||||||
}
|
}
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonDown{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonDown{
|
||||||
background-position:-80px -20px;
|
background-position:-80px -20px;
|
||||||
}
|
}
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonLeft{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonLeft{
|
||||||
background-position:-80px -40px;
|
background-position:-80px -40px;
|
||||||
}
|
}
|
||||||
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonRight{
|
.mCS-dark-thin>.mCSB_scrollTools .mCSB_buttonRight{
|
||||||
background-position:-80px -56px;
|
background-position:-80px -56px;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,215 +1,215 @@
|
||||||
class TopicsController < ApplicationController
|
class TopicsController < ApplicationController
|
||||||
include TopicsHelper
|
include TopicsHelper
|
||||||
|
|
||||||
before_filter :require_user, only: [:create, :update, :destroy]
|
before_filter :require_user, only: [:create, :update, :destroy]
|
||||||
|
|
||||||
respond_to :html, :js, :json
|
respond_to :html, :js, :json
|
||||||
|
|
||||||
# GET /topics/autocomplete_topic
|
# GET /topics/autocomplete_topic
|
||||||
def autocomplete_topic
|
def autocomplete_topic
|
||||||
@current = current_user
|
@current = current_user
|
||||||
term = params[:term]
|
term = params[:term]
|
||||||
if term && !term.empty?
|
if term && !term.empty?
|
||||||
@topics = Topic.where('LOWER("name") like ?', term.downcase + '%').order('"name"')
|
@topics = Topic.where('LOWER("name") like ?', term.downcase + '%').order('"name"')
|
||||||
|
|
||||||
#read this next line as 'delete a topic if its private and you're either
|
#read this next line as 'delete a topic if its private and you're either
|
||||||
#1. logged out or 2. logged in but not the topic creator
|
#1. logged out or 2. logged in but not the topic creator
|
||||||
@topics.to_a.delete_if {|t| t.permission == "private" &&
|
@topics.to_a.delete_if {|t| t.permission == "private" &&
|
||||||
(!authenticated? || (authenticated? && @current.id != t.user_id)) }
|
(!authenticated? || (authenticated? && @current.id != t.user_id)) }
|
||||||
else
|
else
|
||||||
@topics = []
|
@topics = []
|
||||||
end
|
end
|
||||||
render json: autocomplete_array_json(@topics)
|
render json: autocomplete_array_json(@topics)
|
||||||
end
|
end
|
||||||
|
|
||||||
# GET topics/:id
|
# GET topics/:id
|
||||||
def show
|
def show
|
||||||
@current = current_user
|
@current = current_user
|
||||||
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
||||||
|
|
||||||
if not @topic
|
if not @topic
|
||||||
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
||||||
end
|
end
|
||||||
|
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.html {
|
format.html {
|
||||||
@alltopics = ([@topic] + @topic.relatives).delete_if {|t| t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)) } # should limit to topics visible to user
|
@alltopics = ([@topic] + @topic.relatives).delete_if {|t| t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)) } # should limit to topics visible to user
|
||||||
@allsynapses = @topic.synapses.to_a.delete_if {|s| s.permission == "private" && (!authenticated? || (authenticated? && @current.id != s.user_id)) }
|
@allsynapses = @topic.synapses.to_a.delete_if {|s| s.permission == "private" && (!authenticated? || (authenticated? && @current.id != s.user_id)) }
|
||||||
|
|
||||||
@allcreators = []
|
@allcreators = []
|
||||||
@alltopics.each do |t|
|
@alltopics.each do |t|
|
||||||
if @allcreators.index(t.user) == nil
|
if @allcreators.index(t.user) == nil
|
||||||
@allcreators.push(t.user)
|
@allcreators.push(t.user)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@allsynapses.each do |s|
|
@allsynapses.each do |s|
|
||||||
if @allcreators.index(s.user) == nil
|
if @allcreators.index(s.user) == nil
|
||||||
@allcreators.push(s.user)
|
@allcreators.push(s.user)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
respond_with(@allsynapses, @alltopics, @allcreators, @topic)
|
respond_with(@allsynapses, @alltopics, @allcreators, @topic)
|
||||||
}
|
}
|
||||||
format.json { render json: @topic }
|
format.json { render json: @topic }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# GET topics/:id/network
|
# GET topics/:id/network
|
||||||
def network
|
def network
|
||||||
@current = current_user
|
@current = current_user
|
||||||
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
||||||
|
|
||||||
if not @topic
|
if not @topic
|
||||||
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
||||||
end
|
end
|
||||||
|
|
||||||
@alltopics = @topic.relatives.to_a.delete_if {|t| t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)) }
|
@alltopics = @topic.relatives.to_a.delete_if {|t| t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)) }
|
||||||
@allsynapses = @topic.synapses.to_a.delete_if {|s| s.permission == "private" && (!authenticated? || (authenticated? && @current.id != s.user_id)) }
|
@allsynapses = @topic.synapses.to_a.delete_if {|s| s.permission == "private" && (!authenticated? || (authenticated? && @current.id != s.user_id)) }
|
||||||
@allcreators = []
|
@allcreators = []
|
||||||
@allcreators.push(@topic.user)
|
@allcreators.push(@topic.user)
|
||||||
@alltopics.each do |t|
|
@alltopics.each do |t|
|
||||||
if @allcreators.index(t.user) == nil
|
if @allcreators.index(t.user) == nil
|
||||||
@allcreators.push(t.user)
|
@allcreators.push(t.user)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@allsynapses.each do |s|
|
@allsynapses.each do |s|
|
||||||
if @allcreators.index(s.user) == nil
|
if @allcreators.index(s.user) == nil
|
||||||
@allcreators.push(s.user)
|
@allcreators.push(s.user)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@json = Hash.new()
|
@json = Hash.new()
|
||||||
@json['topic'] = @topic
|
@json['topic'] = @topic
|
||||||
@json['creators'] = @allcreators
|
@json['creators'] = @allcreators
|
||||||
@json['relatives'] = @alltopics
|
@json['relatives'] = @alltopics
|
||||||
@json['synapses'] = @allsynapses
|
@json['synapses'] = @allsynapses
|
||||||
|
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.json { render json: @json }
|
format.json { render json: @json }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# GET topics/:id/relative_numbers
|
# GET topics/:id/relative_numbers
|
||||||
def relative_numbers
|
def relative_numbers
|
||||||
@current = current_user
|
@current = current_user
|
||||||
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
||||||
|
|
||||||
if not @topic
|
if not @topic
|
||||||
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
||||||
end
|
end
|
||||||
|
|
||||||
@topicsAlreadyHas = params[:network] ? params[:network].split(',') : []
|
@topicsAlreadyHas = params[:network] ? params[:network].split(',') : []
|
||||||
|
|
||||||
@alltopics = @topic.relatives.to_a.delete_if {|t|
|
@alltopics = @topic.relatives.to_a.delete_if {|t|
|
||||||
@topicsAlreadyHas.index(t.id.to_s) != nil ||
|
@topicsAlreadyHas.index(t.id.to_s) != nil ||
|
||||||
(t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)))
|
(t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)))
|
||||||
}
|
}
|
||||||
|
|
||||||
@alltopics.uniq!
|
@alltopics.uniq!
|
||||||
|
|
||||||
@json = Hash.new()
|
@json = Hash.new()
|
||||||
@alltopics.each do |t|
|
@alltopics.each do |t|
|
||||||
if @json[t.metacode.id]
|
if @json[t.metacode.id]
|
||||||
@json[t.metacode.id] += 1
|
@json[t.metacode.id] += 1
|
||||||
else
|
else
|
||||||
@json[t.metacode.id] = 1
|
@json[t.metacode.id] = 1
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.json { render json: @json }
|
format.json { render json: @json }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# GET topics/:id/relatives
|
# GET topics/:id/relatives
|
||||||
def relatives
|
def relatives
|
||||||
@current = current_user
|
@current = current_user
|
||||||
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
@topic = Topic.find(params[:id]).authorize_to_show(@current)
|
||||||
|
|
||||||
if not @topic
|
if not @topic
|
||||||
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
redirect_to root_url, notice: "Access denied. That topic is private." and return
|
||||||
end
|
end
|
||||||
|
|
||||||
@topicsAlreadyHas = params[:network] ? params[:network].split(',') : []
|
@topicsAlreadyHas = params[:network] ? params[:network].split(',') : []
|
||||||
|
|
||||||
@alltopics = @topic.relatives.to_a.delete_if {|t|
|
@alltopics = @topic.relatives.to_a.delete_if {|t|
|
||||||
@topicsAlreadyHas.index(t.id.to_s) != nil ||
|
@topicsAlreadyHas.index(t.id.to_s) != nil ||
|
||||||
(params[:metacode] && t.metacode_id.to_s != params[:metacode]) ||
|
(params[:metacode] && t.metacode_id.to_s != params[:metacode]) ||
|
||||||
(t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)))
|
(t.permission == "private" && (!authenticated? || (authenticated? && @current.id != t.user_id)))
|
||||||
}
|
}
|
||||||
|
|
||||||
@alltopics.uniq!
|
@alltopics.uniq!
|
||||||
|
|
||||||
@allsynapses = @topic.synapses.to_a.delete_if {|s|
|
@allsynapses = @topic.synapses.to_a.delete_if {|s|
|
||||||
(s.topic1 == @topic && @alltopics.index(s.topic2) == nil) ||
|
(s.topic1 == @topic && @alltopics.index(s.topic2) == nil) ||
|
||||||
(s.topic2 == @topic && @alltopics.index(s.topic1) == nil)
|
(s.topic2 == @topic && @alltopics.index(s.topic1) == nil)
|
||||||
}
|
}
|
||||||
|
|
||||||
@creatorsAlreadyHas = params[:creators] ? params[:creators].split(',') : []
|
@creatorsAlreadyHas = params[:creators] ? params[:creators].split(',') : []
|
||||||
@allcreators = []
|
@allcreators = []
|
||||||
@alltopics.each do |t|
|
@alltopics.each do |t|
|
||||||
if @allcreators.index(t.user) == nil && @creatorsAlreadyHas.index(t.user_id.to_s) == nil
|
if @allcreators.index(t.user) == nil && @creatorsAlreadyHas.index(t.user_id.to_s) == nil
|
||||||
@allcreators.push(t.user)
|
@allcreators.push(t.user)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@allsynapses.each do |s|
|
@allsynapses.each do |s|
|
||||||
if @allcreators.index(s.user) == nil && @creatorsAlreadyHas.index(s.user_id.to_s) == nil
|
if @allcreators.index(s.user) == nil && @creatorsAlreadyHas.index(s.user_id.to_s) == nil
|
||||||
@allcreators.push(s.user)
|
@allcreators.push(s.user)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@json = Hash.new()
|
@json = Hash.new()
|
||||||
@json['topics'] = @alltopics
|
@json['topics'] = @alltopics
|
||||||
@json['synapses'] = @allsynapses
|
@json['synapses'] = @allsynapses
|
||||||
@json['creators'] = @allcreators
|
@json['creators'] = @allcreators
|
||||||
|
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.json { render json: @json }
|
format.json { render json: @json }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# POST /topics
|
# POST /topics
|
||||||
# POST /topics.json
|
# POST /topics.json
|
||||||
def create
|
def create
|
||||||
@topic = Topic.new(topic_params)
|
@topic = Topic.new(topic_params)
|
||||||
|
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
if @topic.save
|
if @topic.save
|
||||||
format.json { render json: @topic, status: :created }
|
format.json { render json: @topic, status: :created }
|
||||||
else
|
else
|
||||||
format.json { render json: @topic.errors, status: :unprocessable_entity }
|
format.json { render json: @topic.errors, status: :unprocessable_entity }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# PUT /topics/1
|
# PUT /topics/1
|
||||||
# PUT /topics/1.json
|
# PUT /topics/1.json
|
||||||
def update
|
def update
|
||||||
@topic = Topic.find(params[:id])
|
@topic = Topic.find(params[:id])
|
||||||
|
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
if @topic.update_attributes(topic_params)
|
if @topic.update_attributes(topic_params)
|
||||||
format.json { head :no_content }
|
format.json { head :no_content }
|
||||||
else
|
else
|
||||||
format.json { render json: @topic.errors, status: :unprocessable_entity }
|
format.json { render json: @topic.errors, status: :unprocessable_entity }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
# DELETE topics/:id
|
# DELETE topics/:id
|
||||||
def destroy
|
def destroy
|
||||||
@current = current_user
|
@current = current_user
|
||||||
@topic = Topic.find(params[:id]).authorize_to_delete(@current)
|
@topic = Topic.find(params[:id]).authorize_to_delete(@current)
|
||||||
@topic.delete if @topic
|
@topic.delete if @topic
|
||||||
|
|
||||||
respond_to do |format|
|
respond_to do |format|
|
||||||
format.json { head :no_content }
|
format.json { head :no_content }
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
private
|
private
|
||||||
|
|
||||||
def topic_params
|
def topic_params
|
||||||
params.require(:topic).permit(:id, :name, :desc, :link, :permission, :user_id, :metacode_id)
|
params.require(:topic).permit(:id, :name, :desc, :link, :permission, :user_id, :metacode_id)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,117 +1,117 @@
|
||||||
class Topic < ActiveRecord::Base
|
class Topic < ActiveRecord::Base
|
||||||
include TopicsHelper
|
include TopicsHelper
|
||||||
|
|
||||||
belongs_to :user
|
belongs_to :user
|
||||||
|
|
||||||
has_many :synapses1, :class_name => 'Synapse', :foreign_key => 'node1_id', dependent: :destroy
|
has_many :synapses1, :class_name => 'Synapse', :foreign_key => 'node1_id', dependent: :destroy
|
||||||
has_many :synapses2, :class_name => 'Synapse', :foreign_key => 'node2_id', dependent: :destroy
|
has_many :synapses2, :class_name => 'Synapse', :foreign_key => 'node2_id', dependent: :destroy
|
||||||
has_many :topics1, :through => :synapses2, :source => :topic1
|
has_many :topics1, :through => :synapses2, :source => :topic1
|
||||||
has_many :topics2, :through => :synapses1, :source => :topic2
|
has_many :topics2, :through => :synapses1, :source => :topic2
|
||||||
|
|
||||||
has_many :mappings, as: :mappable, dependent: :destroy
|
has_many :mappings, as: :mappable, dependent: :destroy
|
||||||
has_many :maps, :through => :mappings
|
has_many :maps, :through => :mappings
|
||||||
|
|
||||||
validates :permission, presence: true
|
validates :permission, presence: true
|
||||||
validates :permission, inclusion: { in: Perm::ISSIONS.map(&:to_s) }
|
validates :permission, inclusion: { in: Perm::ISSIONS.map(&:to_s) }
|
||||||
|
|
||||||
# This method associates the attribute ":image" with a file attachment
|
# This method associates the attribute ":image" with a file attachment
|
||||||
has_attached_file :image
|
has_attached_file :image
|
||||||
|
|
||||||
#, styles: {
|
#, styles: {
|
||||||
# thumb: '100x100>',
|
# thumb: '100x100>',
|
||||||
# square: '200x200#',
|
# square: '200x200#',
|
||||||
# medium: '300x300>'
|
# medium: '300x300>'
|
||||||
#}
|
#}
|
||||||
|
|
||||||
# Validate the attached image is image/jpg, image/png, etc
|
# Validate the attached image is image/jpg, image/png, etc
|
||||||
validates_attachment_content_type :image, :content_type => /\Aimage\/.*\Z/
|
validates_attachment_content_type :image, :content_type => /\Aimage\/.*\Z/
|
||||||
|
|
||||||
# This method associates the attribute ":image" with a file attachment
|
# This method associates the attribute ":image" with a file attachment
|
||||||
has_attached_file :audio
|
has_attached_file :audio
|
||||||
# Validate the attached audio is audio/wav, audio/mp3, etc
|
# Validate the attached audio is audio/wav, audio/mp3, etc
|
||||||
validates_attachment_content_type :audio, :content_type => /\Aaudio\/.*\Z/
|
validates_attachment_content_type :audio, :content_type => /\Aaudio\/.*\Z/
|
||||||
|
|
||||||
def synapses
|
def synapses
|
||||||
synapses1 + synapses2
|
synapses1 + synapses2
|
||||||
end
|
end
|
||||||
|
|
||||||
def relatives
|
def relatives
|
||||||
topics1 + topics2
|
topics1 + topics2
|
||||||
end
|
end
|
||||||
|
|
||||||
belongs_to :metacode
|
belongs_to :metacode
|
||||||
|
|
||||||
def user_name
|
def user_name
|
||||||
user.name
|
user.name
|
||||||
end
|
end
|
||||||
|
|
||||||
def user_image
|
def user_image
|
||||||
user.image.url
|
user.image.url
|
||||||
end
|
end
|
||||||
|
|
||||||
def map_count
|
def map_count
|
||||||
maps.count
|
maps.count
|
||||||
end
|
end
|
||||||
|
|
||||||
def synapse_count
|
def synapse_count
|
||||||
synapses.count
|
synapses.count
|
||||||
end
|
end
|
||||||
|
|
||||||
def inmaps
|
def inmaps
|
||||||
maps.map(&:name)
|
maps.map(&:name)
|
||||||
end
|
end
|
||||||
|
|
||||||
def inmapsLinks
|
def inmapsLinks
|
||||||
maps.map(&:id)
|
maps.map(&:id)
|
||||||
end
|
end
|
||||||
|
|
||||||
def as_json(options={})
|
def as_json(options={})
|
||||||
super(:methods =>[:user_name, :user_image, :map_count, :synapse_count, :inmaps, :inmapsLinks])
|
super(:methods =>[:user_name, :user_image, :map_count, :synapse_count, :inmaps, :inmapsLinks])
|
||||||
end
|
end
|
||||||
|
|
||||||
def topic_autocomplete_method
|
def topic_autocomplete_method
|
||||||
"Get: #{self.name}"
|
"Get: #{self.name}"
|
||||||
end
|
end
|
||||||
|
|
||||||
def mk_permission
|
def mk_permission
|
||||||
Perm.short(permission)
|
Perm.short(permission)
|
||||||
end
|
end
|
||||||
|
|
||||||
# has no viewable synapses helper function
|
# has no viewable synapses helper function
|
||||||
def has_viewable_synapses(current)
|
def has_viewable_synapses(current)
|
||||||
result = false
|
result = false
|
||||||
synapses.each do |synapse|
|
synapses.each do |synapse|
|
||||||
if synapse.authorize_to_show(current)
|
if synapse.authorize_to_show(current)
|
||||||
result = true
|
result = true
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
result
|
result
|
||||||
end
|
end
|
||||||
|
|
||||||
##### PERMISSIONS ######
|
##### PERMISSIONS ######
|
||||||
|
|
||||||
# returns false if user not allowed to 'show' Topic, Synapse, or Map
|
# returns false if user not allowed to 'show' Topic, Synapse, or Map
|
||||||
def authorize_to_show(user)
|
def authorize_to_show(user)
|
||||||
if (self.permission == "private" && self.user != user)
|
if (self.permission == "private" && self.user != user)
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
|
|
||||||
# returns false if user not allowed to 'edit' Topic, Synapse, or Map
|
# returns false if user not allowed to 'edit' Topic, Synapse, or Map
|
||||||
def authorize_to_edit(user)
|
def authorize_to_edit(user)
|
||||||
if (self.permission == "private" && self.user != user)
|
if (self.permission == "private" && self.user != user)
|
||||||
return false
|
return false
|
||||||
elsif (self.permission == "public" && self.user != user)
|
elsif (self.permission == "public" && self.user != user)
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
|
|
||||||
def authorize_to_delete(user)
|
def authorize_to_delete(user)
|
||||||
if (self.user == user || user.admin)
|
if (self.user == user || user.admin)
|
||||||
return self
|
return self
|
||||||
end
|
end
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
class UserPreference
|
class UserPreference
|
||||||
attr_accessor :metacodes
|
attr_accessor :metacodes
|
||||||
|
|
||||||
def initialize
|
def initialize
|
||||||
array = []
|
array = []
|
||||||
Metacode.all.each do |m|
|
Metacode.all.each do |m|
|
||||||
array.push(m.id.to_s)
|
array.push(m.id.to_s)
|
||||||
end
|
end
|
||||||
@metacodes = array
|
@metacodes = array
|
||||||
end
|
end
|
||||||
end
|
end
|
|
@ -1,6 +1,6 @@
|
||||||
<%= link_to 'Metacode Sets', metacode_sets_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
<%= link_to 'Metacode Sets', metacode_sets_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
||||||
<%= link_to 'New Set', new_metacode_set_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
<%= link_to 'New Set', new_metacode_set_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
||||||
<%= link_to 'Metacodes', metacodes_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
<%= link_to 'Metacodes', metacodes_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
||||||
<%= link_to 'New Metacode', new_metacode_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
<%= link_to 'New Metacode', new_metacode_path, { :class => 'button', 'data-bypass' => 'true' }%>
|
||||||
<div class='clearfloat'></div>
|
<div class='clearfloat'></div>
|
||||||
<br />
|
<br />
|
||||||
|
|
|
@ -1,152 +1,152 @@
|
||||||
<%#
|
<%#
|
||||||
# @file
|
# @file
|
||||||
# Main application file. Holds scaffolding present on every page.
|
# Main application file. Holds scaffolding present on every page.
|
||||||
# Then a certain non-partial view (no _ preceding filename) will be
|
# Then a certain non-partial view (no _ preceding filename) will be
|
||||||
# displayed within, based on URL
|
# displayed within, based on URL
|
||||||
#%>
|
#%>
|
||||||
|
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<title><%=h yield(:title) %></title>
|
<title><%=h yield(:title) %></title>
|
||||||
<%= csrf_meta_tags %>
|
<%= csrf_meta_tags %>
|
||||||
<meta name="viewport" content="width=device-width, user-scalable=no">
|
<meta name="viewport" content="width=device-width, user-scalable=no">
|
||||||
|
|
||||||
<%= stylesheet_link_tag "application", :media => "all" %>
|
<%= stylesheet_link_tag "application", :media => "all" %>
|
||||||
<%= javascript_include_tag "application" %>
|
<%= javascript_include_tag "application" %>
|
||||||
|
|
||||||
<!-- typekit for vinyl font -->
|
<!-- typekit for vinyl font -->
|
||||||
<script type="text/javascript" src="https://use.typekit.net/tki2nyo.js"></script>
|
<script type="text/javascript" src="https://use.typekit.net/tki2nyo.js"></script>
|
||||||
<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
|
<script type="text/javascript">try{Typekit.load();}catch(e){}</script>
|
||||||
|
|
||||||
<!-- app code -->
|
<!-- app code -->
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
require.config({baseUrl: '<%= "#{ asset_path '/famous/main.js' }".chomp('main.js') %>'});
|
require.config({baseUrl: '<%= "#{ asset_path '/famous/main.js' }".chomp('main.js') %>'});
|
||||||
require(['main']);
|
require(['main']);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<!--[if (IE)]>
|
<!--[if (IE)]>
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
#lightbox_overlay {
|
#lightbox_overlay {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
#lightbox_main {
|
#lightbox_main {
|
||||||
top: 50%;
|
top: 50%;
|
||||||
margin-top: -281px;
|
margin-top: -281px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#lightbox_screen {
|
#lightbox_screen {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
opacity: 0.42;
|
opacity: 0.42;
|
||||||
}
|
}
|
||||||
|
|
||||||
.lightboxContent {
|
.lightboxContent {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
#noIE {
|
#noIE {
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
#lightbox_close {
|
#lightbox_close {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
$("#lightbox_screen").unbind().click(function(event){
|
$("#lightbox_screen").unbind().click(function(event){
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
<![endif]-->
|
<![endif]-->
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body class="<%= authenticated? ? "authenticated" : "unauthenticated" %>">
|
<body class="<%= authenticated? ? "authenticated" : "unauthenticated" %>">
|
||||||
|
|
||||||
<% if devise_error_messages? %>
|
<% if devise_error_messages? %>
|
||||||
<p id="toast"><%= devise_error_messages! %></p>
|
<p id="toast"><%= devise_error_messages! %></p>
|
||||||
<% elsif notice %>
|
<% elsif notice %>
|
||||||
<p id="toast"><%= notice %></p>
|
<p id="toast"><%= notice %></p>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= content_tag :div, class: "main" do %>
|
<%= content_tag :div, class: "main" do %>
|
||||||
|
|
||||||
<% classes = action_name == "home" ? "homePage" : ""
|
<% classes = action_name == "home" ? "homePage" : ""
|
||||||
classes += action_name == "home" && authenticated? ? " explorePage" : ""
|
classes += action_name == "home" && authenticated? ? " explorePage" : ""
|
||||||
classes += controller_name == "maps" && action_name == "index" ? " explorePage" : ""
|
classes += controller_name == "maps" && action_name == "index" ? " explorePage" : ""
|
||||||
if controller_name == "maps" && action_name == "show"
|
if controller_name == "maps" && action_name == "show"
|
||||||
classes += " mapPage"
|
classes += " mapPage"
|
||||||
if @map.authorize_to_edit(current_user)
|
if @map.authorize_to_edit(current_user)
|
||||||
classes += " canEditMap"
|
classes += " canEditMap"
|
||||||
end
|
end
|
||||||
if @map.permission == "commons"
|
if @map.permission == "commons"
|
||||||
classes += " commonsMap"
|
classes += " commonsMap"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
classes += controller_name == "topics" && action_name == "show" ? " topicPage" : ""
|
classes += controller_name == "topics" && action_name == "show" ? " topicPage" : ""
|
||||||
%>
|
%>
|
||||||
|
|
||||||
<div class="wrapper <%= classes %>" id="wrapper">
|
<div class="wrapper <%= classes %>" id="wrapper">
|
||||||
|
|
||||||
<%= render :partial => 'layouts/upperelements' %>
|
<%= render :partial => 'layouts/upperelements' %>
|
||||||
|
|
||||||
<%= yield %>
|
<%= yield %>
|
||||||
|
|
||||||
<div class="showcard mapElement mapElementHidden" id="showcard"></div> <!-- the topic card -->
|
<div class="showcard mapElement mapElementHidden" id="showcard"></div> <!-- the topic card -->
|
||||||
<% if authenticated? %>
|
<% if authenticated? %>
|
||||||
<% # for creating and pulling in topics and synapses %>
|
<% # for creating and pulling in topics and synapses %>
|
||||||
<%= render :partial => 'maps/newtopic' %>
|
<%= render :partial => 'maps/newtopic' %>
|
||||||
<%= render :partial => 'maps/newsynapse' %>
|
<%= render :partial => 'maps/newsynapse' %>
|
||||||
<% # for populating the change metacode list on the topic card %>
|
<% # for populating the change metacode list on the topic card %>
|
||||||
<%= render :partial => 'shared/metacodeoptions' %>
|
<%= render :partial => 'shared/metacodeoptions' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= render :partial => 'layouts/lowermapelements' %>
|
<%= render :partial => 'layouts/lowermapelements' %>
|
||||||
|
|
||||||
<div id="famousOverlay"></div>
|
<div id="famousOverlay"></div>
|
||||||
<div id="loading"></div>
|
<div id="loading"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render :partial => 'layouts/lightboxes' %>
|
<%= render :partial => 'layouts/lightboxes' %>
|
||||||
<%= render :partial => 'layouts/templates' %>
|
<%= render :partial => 'layouts/templates' %>
|
||||||
<%= render :partial => 'shared/metacodeBgColors' %>
|
<%= render :partial => 'shared/metacodeBgColors' %>
|
||||||
<script type="text/javascript" charset="utf-8">
|
<script type="text/javascript" charset="utf-8">
|
||||||
<% if authenticated? %>
|
<% if authenticated? %>
|
||||||
Metamaps.Active.Mapper = <%= user.to_json.html_safe %>
|
Metamaps.Active.Mapper = <%= user.to_json.html_safe %>
|
||||||
<% else %>
|
<% else %>
|
||||||
Metamaps.Active.Mapper = null;
|
Metamaps.Active.Mapper = null;
|
||||||
<% end %>
|
<% end %>
|
||||||
Metamaps.Metacodes = <%= Metacode.all.to_json.html_safe %>;
|
Metamaps.Metacodes = <%= Metacode.all.to_json.html_safe %>;
|
||||||
|
|
||||||
Metamaps.Loading = {
|
Metamaps.Loading = {
|
||||||
loader: new CanvasLoader('loading'),
|
loader: new CanvasLoader('loading'),
|
||||||
hide: function () {
|
hide: function () {
|
||||||
$('#loading').hide();
|
$('#loading').hide();
|
||||||
},
|
},
|
||||||
show: function () {
|
show: function () {
|
||||||
$('#loading').show();
|
$('#loading').show();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
Metamaps.Loading.loader.setColor('#4fb5c0'); // default is '#000000'
|
Metamaps.Loading.loader.setColor('#4fb5c0'); // default is '#000000'
|
||||||
Metamaps.Loading.loader.setDiameter(28); // default is 40
|
Metamaps.Loading.loader.setDiameter(28); // default is 40
|
||||||
Metamaps.Loading.loader.setDensity(41); // default is 40
|
Metamaps.Loading.loader.setDensity(41); // default is 40
|
||||||
Metamaps.Loading.loader.setRange(0.9); // default is 1.3
|
Metamaps.Loading.loader.setRange(0.9); // default is 1.3
|
||||||
Metamaps.Loading.loader.show(); // Hidden by default
|
Metamaps.Loading.loader.show(); // Hidden by default
|
||||||
|
|
||||||
// set up uservoice with signed in user
|
// set up uservoice with signed in user
|
||||||
<% if authenticated? && ENV['SSO_KEY'] %>
|
<% if authenticated? && ENV['SSO_KEY'] %>
|
||||||
USERVOICE.load(Metamaps.Active.Mapper.name, Metamaps.Active.Mapper.id, "<%= user.email %>", "<%= current_sso_token %>");
|
USERVOICE.load(Metamaps.Active.Mapper.name, Metamaps.Active.Mapper.id, "<%= user.email %>", "<%= current_sso_token %>");
|
||||||
<% else %>
|
<% else %>
|
||||||
USERVOICE.load();
|
USERVOICE.load();
|
||||||
<% end %>
|
<% end %>
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<%= render :partial => 'layouts/googleanalytics' if Rails.env.production? %>
|
<%= render :partial => 'layouts/googleanalytics' if Rails.env.production? %>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
<%= form_for Synapse.new, url: synapses_url, remote: true do |form| %>
|
<%= form_for Synapse.new, url: synapses_url, remote: true do |form| %>
|
||||||
<%= form.text_field :desc, :placeholder => "describe the connection..." %>
|
<%= form.text_field :desc, :placeholder => "describe the connection..." %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
<%#
|
<%#
|
||||||
# @file
|
# @file
|
||||||
# Partial for rendered a new synapse form
|
# Partial for rendered a new synapse form
|
||||||
# TODO: Is this used? Where?
|
# TODO: Is this used? Where?
|
||||||
#%>
|
#%>
|
||||||
<div class="anypage">
|
<div class="anypage">
|
||||||
<%= form_for Synapse.new, url: synapses_url, remote: true do |form| %>
|
<%= form_for Synapse.new, url: synapses_url, remote: true do |form| %>
|
||||||
<%= form.text_field :desc, :placeholder => "describe the connection..." %>
|
<%= form.text_field :desc, :placeholder => "describe the connection..." %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,21 +1,21 @@
|
||||||
default: &default
|
default: &default
|
||||||
min_messages: WARNING
|
min_messages: WARNING
|
||||||
encoding: unicode
|
encoding: unicode
|
||||||
pool: 5
|
pool: 5
|
||||||
adapter: postgresql
|
adapter: postgresql
|
||||||
host: <%= ENV['DB_HOST'] %>
|
host: <%= ENV['DB_HOST'] %>
|
||||||
port: <%= ENV['DB_PORT'] %>
|
port: <%= ENV['DB_PORT'] %>
|
||||||
username: <%= ENV['DB_USERNAME'] %>
|
username: <%= ENV['DB_USERNAME'] %>
|
||||||
password: <%= ENV['DB_PASSWORD'] %>
|
password: <%= ENV['DB_PASSWORD'] %>
|
||||||
|
|
||||||
development:
|
development:
|
||||||
<<: *default
|
<<: *default
|
||||||
database: <%= ENV['DB_NAME'] %>_development
|
database: <%= ENV['DB_NAME'] %>_development
|
||||||
|
|
||||||
test:
|
test:
|
||||||
<<: *default
|
<<: *default
|
||||||
database: <%= ENV['DB_NAME'] %>_test
|
database: <%= ENV['DB_NAME'] %>_test
|
||||||
|
|
||||||
production:
|
production:
|
||||||
<<: *default
|
<<: *default
|
||||||
database: <%= ENV['DB_NAME'] %>_production
|
database: <%= ENV['DB_NAME'] %>_production
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
Paperclip::Attachment.default_options[:url] = ':s3_domain_url'
|
Paperclip::Attachment.default_options[:url] = ':s3_domain_url'
|
||||||
Paperclip::Attachment.default_options[:path] = '/:class/:attachment/:id_partition/:style/:filename'
|
Paperclip::Attachment.default_options[:path] = '/:class/:attachment/:id_partition/:style/:filename'
|
|
@ -1,7 +1,7 @@
|
||||||
require 'uservoice-ruby'
|
require 'uservoice-ruby'
|
||||||
|
|
||||||
def current_sso_token
|
def current_sso_token
|
||||||
@current_sso_token ||= UserVoice.generate_sso_token('metamapscc', ENV['SSO_KEY'], {
|
@current_sso_token ||= UserVoice.generate_sso_token('metamapscc', ENV['SSO_KEY'], {
|
||||||
:email => current_user.email
|
:email => current_user.email
|
||||||
}, 300) # Default expiry time is 5 minutes = 300 seconds
|
}, 300) # Default expiry time is 5 minutes = 300 seconds
|
||||||
end
|
end
|
|
@ -1,18 +1,18 @@
|
||||||
## Node.js realtime server
|
## Node.js realtime server
|
||||||
|
|
||||||
To run the server, you need to install the dependencies and run the server.
|
To run the server, you need to install the dependencies and run the server.
|
||||||
Please ensure you have followed the OS-specific instructions in doc/ to
|
Please ensure you have followed the OS-specific instructions in doc/ to
|
||||||
install NodeJS. Once you have node, then you can proceed to install the
|
install NodeJS. Once you have node, then you can proceed to install the
|
||||||
node packages for the realtime server:
|
node packages for the realtime server:
|
||||||
|
|
||||||
cd realtime
|
cd realtime
|
||||||
npm install #creates node_modules directory
|
npm install #creates node_modules directory
|
||||||
node realtime-server.js
|
node realtime-server.js
|
||||||
|
|
||||||
That's it!
|
That's it!
|
||||||
|
|
||||||
To run the server as a daemon that will be re-run if it crashes, you can
|
To run the server as a daemon that will be re-run if it crashes, you can
|
||||||
use the forever node package.
|
use the forever node package.
|
||||||
|
|
||||||
sudo npm install -g forever
|
sudo npm install -g forever
|
||||||
forever start realtime-server.js
|
forever start realtime-server.js
|
||||||
|
|
Loading…
Reference in a new issue