I have an id of "popup" on my page container and only look like a dialog because the link to me had a data-rel="dialog" attribute which gives me this inset look and a data-transition="pop" attribute to change the transition to pop. Without this, I'd be styled as a normal page.
I have an id of "two" on my page container. I'm the second page container in this multi-page template.
10 |
Notice that the theme is different for this page because we've added a few data-theme swatch assigments here to show off how flexible it is. You can add any content or widget to these pages, but we're keeping these simple.
I have an id of "one" on my page container. I'm first in the source order so I'm shown when the page loads.
11 |
12 |
This is a multi-page boilerplate template that you can copy to build you first jQuery Mobile page. This template contains multiple "page" containers inside, unlike a single page template that has just one page within it.
13 |
Just view the source and copy the code to get started. All the CSS and JS is linked to the jQuery CDN versions so this is super easy to set up. Remember to include a meta viewport tag in the head to set the zoom level.
14 |
You link to internal pages by referring to the ID of the page you want to show. For example, to link to the page with an ID of "two", my link would have a href="two" in the code.
24 |
25 |
--------------------------------------------------------------------------------
/client/js/libs/amd/plugins/text.js:
--------------------------------------------------------------------------------
1 | /*
2 | RequireJS text 1.0.2 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
3 | Available via the MIT or new BSD license.
4 | see: http://github.com/jrburke/requirejs for details
5 | */
6 | (function(){var k=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],n=/^\s*<\?xml(\s)+version=[\'\"](\d)*.(\d)*[\'\"](\s)*\?>/im,o=/]*>\s*([\s\S]+)\s*<\/body>/im,i=typeof location!=="undefined"&&location.href,p=i&&location.protocol&&location.protocol.replace(/\:/,""),q=i&&location.hostname,r=i&&(location.port||void 0),j=[];define(function(){var g,h,l;typeof window!=="undefined"&&window.navigator&&window.document?h=function(a,c){var b=g.createXhr();b.open("GET",a,!0);b.onreadystatechange=
7 | function(){b.readyState===4&&c(b.responseText)};b.send(null)}:typeof process!=="undefined"&&process.versions&&process.versions.node?(l=require.nodeRequire("fs"),h=function(a,c){c(l.readFileSync(a,"utf8"))}):typeof Packages!=="undefined"&&(h=function(a,c){var b=new java.io.File(a),e=java.lang.System.getProperty("line.separator"),b=new java.io.BufferedReader(new java.io.InputStreamReader(new java.io.FileInputStream(b),"utf-8")),d,f,g="";try{d=new java.lang.StringBuffer;(f=b.readLine())&&f.length()&&
8 | f.charAt(0)===65279&&(f=f.substring(1));for(d.append(f);(f=b.readLine())!==null;)d.append(e),d.append(f);g=String(d.toString())}finally{b.close()}c(g)});return g={version:"1.0.2",strip:function(a){if(a){var a=a.replace(n,""),c=a.match(o);c&&(a=c[1])}else a="";return a},jsEscape:function(a){return a.replace(/(['\\])/g,"\\$1").replace(/[\f]/g,"\\f").replace(/[\b]/g,"\\b").replace(/[\n]/g,"\\n").replace(/[\t]/g,"\\t").replace(/[\r]/g,"\\r")},createXhr:function(){var a,c,b;if(typeof XMLHttpRequest!==
9 | "undefined")return new XMLHttpRequest;else for(c=0;c<3;c++){b=k[c];try{a=new ActiveXObject(b)}catch(e){}if(a){k=[b];break}}if(!a)throw Error("createXhr(): XMLHttpRequest not available");return a},get:h,parseName:function(a){var c=!1,b=a.indexOf("."),e=a.substring(0,b),a=a.substring(b+1,a.length),b=a.indexOf("!");b!==-1&&(c=a.substring(b+1,a.length),c=c==="strip",a=a.substring(0,b));return{moduleName:e,ext:a,strip:c}},xdRegExp:/^((\w+)\:)?\/\/([^\/\\]+)/,useXhr:function(a,c,b,e){var d=g.xdRegExp.exec(a),
10 | f;if(!d)return!0;a=d[2];d=d[3];d=d.split(":");f=d[1];d=d[0];return(!a||a===c)&&(!d||d===b)&&(!f&&!d||f===e)},finishLoad:function(a,c,b,e,d){b=c?g.strip(b):b;d.isBuild&&(j[a]=b);e(b)},load:function(a,c,b,e){if(e.isBuild&&!e.inlineText)b();else{var d=g.parseName(a),f=d.moduleName+"."+d.ext,m=c.toUrl(f),h=e&&e.text&&e.text.useXhr||g.useXhr;!i||h(m,p,q,r)?g.get(m,function(c){g.finishLoad(a,d.strip,c,b,e)}):c([f],function(a){g.finishLoad(d.moduleName+"."+d.ext,d.strip,a,b,e)})}},write:function(a,c,b){if(c in
11 | j){var e=g.jsEscape(j[c]);b.asModule(a+"!"+c,"define(function () { return '"+e+"';});\n")}},writeFile:function(a,c,b,e,d){var c=g.parseName(c),f=c.moduleName+"."+c.ext,h=b.toUrl(c.moduleName+"."+c.ext)+".js";g.load(f,b,function(){var b=function(a){return e(h,a)};b.asModule=function(a,b){return e.asModule(a,h,b)};g.write(a,f,b,d)},d)}}})})();
12 |
--------------------------------------------------------------------------------
/client/js/libs/amd/curl.js:
--------------------------------------------------------------------------------
1 | var m=!0;
2 | (function(x,E,h){var I,J;function n(a,b){return 0==T.call(a).indexOf("[object "+b)}function U(a){function b(b){if(b in a)return b="."!=a[b].charAt(0)?(!a.path||y(a.path)?a.path:a.path+"/")+a[b]:q(a[b],a.path),r(b)}n(a,"String")&&(a=r(a),a={name:a,path:a,main:I,lib:J});a.path=a.path||"";a.h=b("lib");a.i=b("main");return a}function K(a){var b,d,c,e=[];s=a.baseUrl||"";if(a.debug)z=m,k.cache=i,k.cfg=a,k.undefine=function(a){delete i[a]};var f=a.paths;for(b in f)d=r(b.replace("!","!/")),c=t[d]={path:r(f[b])},
3 | c.f=(c.path.match(L)||[]).length,e.push(d);f=a.packages;for(b in f)d=r(f[b].name||b),c=t[d]=U(f[b]),c.f=(c.path.match(L)||[]).length,e.push(d);M=RegExp("^("+e.sort(function(a,b){return t[a].fg.indexOf("/")&&(g=u((!o||y(o)?o:o+"/")+g));var l=i[e];if(!l)l=i[e]=new p(e),l.url=B(g,s,m),l.baseName=g,R(l);b=A(b.baseName);b.e.toUrl=function(a){a=u(a,e);return B(a,s)};F=X(e?h.plugins&&h.plugins[e]:h)||{};var k=function(a){return q(a,b.baseName)};j=new p(a);l.c(function(g){var h;f=a.substr(c+1);f="normalize"in g?g.normalize(f,k,F):k(f);d=e+"!"+f;h=i[d];if(!h){h=new p(d);f&&!g.dynamic&&(i[d]=h);var l=h.b;l.resolve=l;l.reject=h.a;g.load(f,b.e,
9 | l,F)}h.c(j.b,j.a)},j.a)}else if(f=d=q(a,b.baseName),j=i[f],!j)j=i[f]=new p(f),j.url=B(u(f),s,m),R(j);return j}function Q(a,b,d,c){for(var e=[],f=a.length,j=f,h=!1,g=0;g
31 |
32 | Or you can use the [jQuery Mobile Router plugin](https://github.com/azicchetti/jquerymobile-router)
33 |
34 | The jQM Router plugin enhanced the default jQM Router but allows parameters in the URL.
35 |
36 | When you define your pages in HTML, you will need to set the `data-url`
37 | property on each `data-role="page"` to the url defined in the jQM Router.
38 |
39 | In so doing, jQM knows what URL to trigger when you (or jQM) call
40 | `$.mobile.changePage('pageID')`
41 |
42 | For more details take a look at . You will learn that the index page is the first `data-role="page"` present in the DOM.
43 |
44 |
45 | DOM injection
46 | -------------
47 |
48 | jQM needs every `data-role="page"` present in the DOM when jQM init.
49 | That's why my template index.html contains every pages. Pages could be
50 | empty. The important thing is that the container is here, with `id`,
51 | `data-role="page"` and `data-url` present.
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 | After init, the first page `id="one"` is loaded. The `data-url`:
60 | `http://youwebsite.com/#one` is called. And your Router will be
61 | triggered to handle it.
62 |
63 | new $.mobile.Router({
64 | "#one": { handler: 'one', events: "bc" },
65 | "#two": { handler: 'two', events: "bc" },
66 | "#popup": { handler: 'popup', events: "bc" }
67 | }, {
68 | one: function(){
69 | console.log('Yeahh it works')
70 | },
71 | ...
72 | });
73 |
74 | If the page change, the same thing happens, the url triggered is given by
75 | the data-url.
76 |
77 | Now, if we want to inject HTML before rendering the view, we will need
78 | to do it before the page is created : beforeCreate (bc).
79 |
80 | If we did it after page creation, for example before show (bs), elements
81 | like `data-role="header"`, `data-role="footer"`, ... will not be
82 | enhanced by jQM after injection.
83 |
84 |
85 | Templates and code structure
86 | -----------------------------
87 |
88 | Personnally I hate debugging HTML in JS files. To avoid this I use
89 | [RequireJS](http://www.requirejs.org/) with the [text plugin](http://www.requirejs.org/docs/api.html#text)
90 |
91 | Look the syntax is quite simple :
92 |
93 | define([
94 | 'data',
95 | 'text!templates/one.html'
96 | ], function(data, tmpl){
97 | // populate the template
98 | var html = _.template(tmpl, data),
99 | });
100 |
101 | RequireJS is also a good help with Backbone application. The famous Todo
102 | example is great, but everything is in one single file. Arrgggh.
103 |
104 | With RequireJS you can split your code in smaller units.
105 |
106 | Take a look at the Todo example `Backbone + RequireJS` :
107 |
108 | PushState
109 | ---------
110 |
111 | [jQM](http://jquerymobile.com/demos/1.0/docs/pages/page-navmodel.html) and [jQM Router plugin](https://github.com/azicchetti/jquerymobile-router/issues/2) are said to be PushState able.
112 | Unfortunately, I didn't find a way to make it work in a Single Page
113 | Web App. The URL is nice, the navigation works well, but if you reload
114 | the page you always come back to the first page (because your url does
115 | not contain a hash) :(
116 |
117 | If you figure how to make this work. Please tell me :)
118 |
119 |
120 | And now ?
121 | ----------
122 | I explain you what I did in this repo. You are now able to do this on
123 | your own, or you can clone it :)
124 |
--------------------------------------------------------------------------------
/client/js/libs/jquery.mobile.router.js:
--------------------------------------------------------------------------------
1 | define(['jquery'], function(jQuery){
2 | /*
3 | * jQueryMobile-router v0.6
4 | * http://github.com/azicchetti/jquerymobile-router
5 | *
6 | * Copyright 2011 (c) Andrea Zicchetti
7 | * Dual licensed under the MIT or GPL Version 2 licenses.
8 | * http://github.com/azicchetti/jquerymobile-router/blob/master/MIT-LICENSE.txt
9 | * http://github.com/azicchetti/jquerymobile-router/blob/master/GPL-LICENSE.txt
10 | */
11 | (function($){
12 |
13 | $(document).bind("mobileinit",function(){
14 |
15 | /* supports the following configurations:
16 | $.mobile.jqmRouter.fixFirstPageDataUrl=true
17 | $.mobile.jqmRouter.firstPageDataUrl="index.html"
18 | jQM doesn't handle correctly the dataurl of the first page you display
19 | in a single-page template mode. In fact, the page is fetched again
20 | from the server the first time you try to access it through a link.
21 | If this option is set to true, jquery mobile router extensions will
22 | try to fix this problem. In order to set the data url, you have to
23 | provide the name of the file containing the first page into the
24 | "firstPageDataUrl" property (for example: index.html)
25 |
26 | */
27 |
28 | var config=$.extend({
29 | fixFirstPageDataUrl: false, firstPageDataUrl: "index.html", ajaxApp: false
30 | },$.mobile.jqmRouter || {});
31 |
32 |
33 | var DEBUG=true;
34 | function debug(err){
35 | if (DEBUG) console.log(err);
36 | }
37 |
38 | var previousUrl=null, nextUrl=null;
39 |
40 | $(document).bind("pagebeforechange", function( e, data ) {
41 | // We only want to handle changePage() calls where the caller is
42 | // asking us to load a page by URL.
43 | if ( typeof data.toPage === "string" ) {
44 | // We are being asked to load a page by URL, but we only
45 | // want to handle URLs that request the data for a specific
46 | // category.
47 | var u = $.mobile.path.parseUrl( data.toPage );
48 | previousUrl=nextUrl;
49 | nextUrl=u;
50 |
51 | if ( u.hash.indexOf("?") !== -1 ) {
52 | var page=u.hash.replace( /\?.*$/, "" );
53 | // We don't want the data-url of the page we just modified
54 | // to be the url that shows up in the browser's location field,
55 | // so set the dataUrl option to the URL with hash parameters
56 | data.options.dataUrl = u.href;
57 | // Now call changePage() and tell it to switch to
58 | // the page we just modified, but only in case it's different
59 | // from the current page
60 | if ( $.mobile.activePage &&
61 | page.replace(/^#/,"")==$.mobile.activePage.jqmData("url")
62 | ){
63 | data.options.allowSamePageTransition=true;
64 | $.mobile.changePage( $(page), data.options );
65 | } else {
66 | $.mobile.changePage( $(page), data.options );
67 | }
68 | // Make sure to tell changePage() we've handled this call so it doesn't
69 | // have to do anything.
70 | e.preventDefault();
71 | }
72 | }
73 | });
74 |
75 |
76 | if (config.fixFirstPageDataUrl){
77 | $(document).ready(function(){
78 | var page=$(":jqmData(role='page')").first();
79 | var dataUrl=page.jqmData("url"),
80 | guessedDataUrl=window.location.pathname
81 | +config.firstPageDataUrl
82 | +window.location.search
83 | +window.location.hash
84 | ;
85 | if (!window.location.pathname.match("/$")){
86 | return;
87 | }
88 | if (dataUrl!=guessedDataUrl){
89 | page.attr("data-url",guessedDataUrl)
90 | .jqmData("url",guessedDataUrl);
91 | }
92 | });
93 | }
94 |
95 | $.mobile.Router=function(userRoutes,userHandlers,conf){
96 | /* userRoutes format:
97 | {
98 | "regexp": "function name", // defaults to jqm pagebeforeshow event
99 | "regexp": function(){ ... }, // defaults to jqm pagebeforeshow event
100 | "regexp": { handler: "function name", events: "bc,c,bs,s,bh,h" },
101 | "regexp": { handler: function(){ ... }, events: "bc,c,bs,s,bh,h" }
102 | }
103 | */
104 | this.routes={
105 | pagebeforecreate: null, pagecreate: null,
106 | pagebeforeshow: null, pageshow: null,
107 | pagebeforehide: null, pagehide: null,
108 | pageinit: null, pageremove: null
109 | };
110 | this.evtLookup = {
111 | bc: "pagebeforecreate", c: "pagecreate",
112 | bs: "pagebeforeshow", s: "pageshow",
113 | bh: "pagebeforehide", h: "pagehide",
114 | i: "pageinit", rm: "pageremove"
115 | };
116 | this.routesRex={};
117 | this.conf=$.extend({}, config, conf || {});
118 | this.defaultHandlerEvents = {};
119 | if (this.conf.defaultHandlerEvents) {
120 | var evts = this.conf.defaultHandlerEvents.split(",");
121 | for (var i = 0; i < evts.length; i++) {
122 | this.defaultHandlerEvents[this.evtLookup[evts[i]]] = evts[i];
123 | }
124 | }
125 | this.add(userRoutes,userHandlers);
126 | }
127 | $.extend($.mobile.Router.prototype,{
128 | add: function(userRoutes,userHandlers){
129 | if (!userRoutes) return;
130 |
131 | var _self=this, evtList=[];
132 | if (userRoutes instanceof Array){
133 | $.each(userRoutes,$.proxy(function(k,v){
134 | this.add(v,userHandlers);
135 | },this));
136 | } else {
137 | $.each(userRoutes,function(r,el){
138 | if(typeof(el)=="string" || typeof(el)=="function"){
139 | if (_self.routes.pagebeforeshow===null){
140 | _self.routes.pagebeforeshow={};
141 | }
142 | _self.routes.pagebeforeshow[r]=el;
143 | if (! _self.routesRex.hasOwnProperty(r)){
144 | _self.routesRex[r]=new RegExp(r);
145 | }
146 | } else {
147 | var i,trig=el.events.split(","),evt;
148 | for(i in trig){
149 | evt=_self.evtLookup[trig[i]];
150 | if (_self.routes.hasOwnProperty(evt)){
151 | if (_self.routes[evt]===null){
152 | _self.routes[evt]={};
153 | }
154 | _self.routes[evt][r]=el.handler;
155 | if (! _self.routesRex.hasOwnProperty(r)){
156 | _self.routesRex[r]=new RegExp(r);
157 | }
158 | } else {
159 | debug("can't set unsupported route "+trig[i]);
160 | }
161 | }
162 | }
163 | });
164 | $.each(_self.routes,function(evt,el){
165 | if (el!==null){
166 | evtList.push(evt);
167 | }
168 | });
169 | if (!this.userHandlers) this.userHandlers={};
170 | $.extend(this.userHandlers,userHandlers||{});
171 | this._detachEvents();
172 | if (evtList.length>0){
173 | this._liveData={
174 | events: evtList.join(" "),
175 | handler: function(e,ui){ _self._processRoutes(e,ui,this); }
176 | };
177 | $("div:jqmData(role='page'),div:jqmData(role='dialog')").live(
178 | this._liveData.events, this._liveData.handler
179 | );
180 | }
181 | }
182 | },
183 |
184 | _processRoutes: function(e,ui,page){
185 | var _self=this, refUrl, url, $page, retry=0;
186 | if (e.type in {
187 | "pagebeforehide":true, "pagehide":true, "pageremove": true
188 | }){
189 | refUrl=previousUrl;
190 | } else {
191 | refUrl=nextUrl;
192 | }
193 | do {
194 | if (!refUrl){
195 | if (page){
196 | $page=$(page);
197 | refUrl=$page.jqmData("url");
198 | if (refUrl){
199 | if ($page.attr("id")==refUrl) refUrl="#"+refUrl;
200 | refUrl=$.mobile.path.parseUrl(refUrl);
201 | }
202 | }
203 | } else if (page && !$(page).jqmData("url")){
204 | return;
205 | }
206 | if (!refUrl) return;
207 | url=( !this.conf.ajaxApp ?
208 | refUrl.hash
209 | :refUrl.pathname + refUrl.search + refUrl.hash
210 | );
211 | if (url.length==0){
212 | // if ajaxApp is false, url may be "" when the user clicks the back button
213 | // and returns to the first page of the application (which is usually
214 | // loaded without the hash part of the url). Let's handle this...
215 | refUrl="";
216 | }
217 | retry++;
218 | } while(url.length==0 && retry<=1);
219 |
220 | var bHandled = false;
221 | $.each(this.routes[e.type],function(route,handler){
222 | var res, handleFn;
223 | if ( (res=url.match(_self.routesRex[route])) ){
224 | if (typeof(handler)=="function"){
225 | handleFn=handler;
226 | } else if (typeof(_self.userHandlers[handler])=="function"){
227 | handleFn=_self.userHandlers[handler];
228 | }
229 | if (handleFn){
230 | try { handleFn(e.type,res,ui,page,e); bHandled = true;
231 | }catch(err){ debug(err); }
232 | }
233 | }
234 | });
235 | //Pass to default if specified and can handle this event type
236 | if (!bHandled && this.conf.defaultHandler && this.defaultHandlerEvents[e.type]) {
237 | if (typeof(this.conf.defaultHandler) == "function") {
238 | try {
239 | this.conf.defaultHandler(e.type, ui, page, e);
240 | } catch(err) { debug(err); }
241 | }
242 | }
243 | },
244 |
245 | _detachEvents: function(){
246 | if (this._liveData){
247 | $("div:jqmData(role='page'),div:jqmData(role='dialog')").die(
248 | this._liveData.events, this._liveData.handler
249 | );
250 | }
251 | } ,
252 |
253 | destroy: function(){
254 | this._detachEvents();
255 | this.routes=this.routesRex=null;
256 | } ,
257 |
258 | getParams: function(hashparams){
259 | if (!hashparams) return null;
260 | var params={}, tmp;
261 | var tokens=hashparams.slice( hashparams.indexOf('?')+1 ).split("&");
262 | $.each(tokens,function(k,v){
263 | tmp=v.split("=");
264 | if (params[tmp[0]]){
265 | if (!(params[tmp[0]] instanceof Array)){
266 | params[tmp[0]]=[ params[tmp[0]] ];
267 | }
268 | params[tmp[0]].push(tmp[1]);
269 | } else {
270 | params[tmp[0]]=tmp[1];
271 | }
272 | });
273 | if ($.isEmptyObject(params)) return null;
274 | return params;
275 | }
276 | });
277 |
278 | });
279 |
280 | })(jQuery);
281 |
282 | });
283 |
--------------------------------------------------------------------------------
/client/js/libs/amd/require.js:
--------------------------------------------------------------------------------
1 | /*
2 | RequireJS 1.0.2 Copyright (c) 2010-2011, The Dojo Foundation All Rights Reserved.
3 | Available via the MIT or new BSD license.
4 | see: http://github.com/jrburke/requirejs for details
5 | */
6 | var requirejs,require,define;
7 | (function(){function J(a){return M.call(a)==="[object Function]"}function E(a){return M.call(a)==="[object Array]"}function Z(a,c,h){for(var k in c)if(!(k in K)&&(!(k in a)||h))a[k]=c[k];return d}function N(a,c,d){a=Error(c+"\nhttp://requirejs.org/docs/errors.html#"+a);if(d)a.originalError=d;return a}function $(a,c,d){var k,j,q;for(k=0;q=c[k];k++){q=typeof q==="string"?{name:q}:q;j=q.location;if(d&&(!j||j.indexOf("/")!==0&&j.indexOf(":")===-1))j=d+"/"+(j||q.name);a[q.name]={name:q.name,location:j||
8 | q.name,main:(q.main||"main").replace(ea,"").replace(aa,"")}}}function V(a,c){a.holdReady?a.holdReady(c):c?a.readyWait+=1:a.ready(!0)}function fa(a){function c(b,l){var f,a;if(b&&b.charAt(0)===".")if(l){p.pkgs[l]?l=[l]:(l=l.split("/"),l=l.slice(0,l.length-1));f=b=l.concat(b.split("/"));var c;for(a=0;c=f[a];a++)if(c===".")f.splice(a,1),a-=1;else if(c==="..")if(a===1&&(f[2]===".."||f[0]===".."))break;else a>0&&(f.splice(a-1,2),a-=2);a=p.pkgs[f=b[0]];b=b.join("/");a&&b===f+"/"+a.main&&(b=f)}else b.indexOf("./")===
9 | 0&&(b=b.substring(2));return b}function h(b,l){var f=b?b.indexOf("!"):-1,a=null,d=l?l.name:null,i=b,e,h;f!==-1&&(a=b.substring(0,f),b=b.substring(f+1,b.length));a&&(a=c(a,d));b&&(a?e=(f=m[a])&&f.normalize?f.normalize(b,function(b){return c(b,d)}):c(b,d):(e=c(b,d),h=E[e],h||(h=g.nameToUrl(e,null,l),E[e]=h)));return{prefix:a,name:e,parentMap:l,url:h,originalName:i,fullName:a?a+"!"+(e||""):e}}function k(){var b=!0,l=p.priorityWait,f,a;if(l){for(a=0;f=l[a];a++)if(!s[f]){b=!1;break}b&&delete p.priorityWait}return b}
10 | function j(b,l,f){return function(){var a=ga.call(arguments,0),c;if(f&&J(c=a[a.length-1]))c.__requireJsBuild=!0;a.push(l);return b.apply(null,a)}}function q(b,l){var a=j(g.require,b,l);Z(a,{nameToUrl:j(g.nameToUrl,b),toUrl:j(g.toUrl,b),defined:j(g.requireDefined,b),specified:j(g.requireSpecified,b),isBrowser:d.isBrowser});return a}function o(b){var l,a,c,C=b.callback,i=b.map,e=i.fullName,ba=b.deps;c=b.listeners;if(C&&J(C)){if(p.catchError.define)try{a=d.execCb(e,b.callback,ba,m[e])}catch(k){l=k}else a=
11 | d.execCb(e,b.callback,ba,m[e]);if(e)(C=b.cjsModule)&&C.exports!==void 0&&C.exports!==m[e]?a=m[e]=b.cjsModule.exports:a===void 0&&b.usingExports?a=m[e]:(m[e]=a,F[e]&&(Q[e]=!0))}else e&&(a=m[e]=C,F[e]&&(Q[e]=!0));if(D[b.id])delete D[b.id],b.isDone=!0,g.waitCount-=1,g.waitCount===0&&(I=[]);delete R[e];if(d.onResourceLoad&&!b.placeholder)d.onResourceLoad(g,i,b.depArray);if(l)return a=(e?h(e).url:"")||l.fileName||l.sourceURL,c=l.moduleTree,l=N("defineerror",'Error evaluating module "'+e+'" at location "'+
12 | a+'":\n'+l+"\nfileName:"+a+"\nlineNumber: "+(l.lineNumber||l.line),l),l.moduleName=e,l.moduleTree=c,d.onError(l);for(l=0;C=c[l];l++)C(a)}function r(b,a){return function(f){b.depDone[a]||(b.depDone[a]=!0,b.deps[a]=f,b.depCount-=1,b.depCount||o(b))}}function u(b,a){var f=a.map,c=f.fullName,h=f.name,i=L[b]||(L[b]=m[b]),e;if(!a.loading)a.loading=!0,e=function(b){a.callback=function(){return b};o(a);s[a.id]=!0;w()},e.fromText=function(b,a){var l=O;s[b]=!1;g.scriptCount+=1;g.fake[b]=!0;l&&(O=!1);d.exec(a);
13 | l&&(O=!0);g.completeLoad(b)},c in m?e(m[c]):i.load(h,q(f.parentMap,!0),e,p)}function v(b){D[b.id]||(D[b.id]=b,I.push(b),g.waitCount+=1)}function B(b){this.listeners.push(b)}function t(b,a){var f=b.fullName,c=b.prefix,d=c?L[c]||(L[c]=m[c]):null,i,e;f&&(i=R[f]);if(!i&&(e=!0,i={id:(c&&!d?M++ +"__p@:":"")+(f||"__r@"+M++),map:b,depCount:0,depDone:[],depCallbacks:[],deps:[],listeners:[],add:B},y[i.id]=!0,f&&(!c||L[c])))R[f]=i;c&&!d?(f=t(h(c),!0),f.add(function(){var a=h(b.originalName,b.parentMap),a=t(a,
14 | !0);i.placeholder=!0;a.add(function(b){i.callback=function(){return b};o(i)})})):e&&a&&(s[i.id]=!1,g.paused.push(i),v(i));return i}function x(b,a,f,c){var b=h(b,c),d=b.name,i=b.fullName,e=t(b),k=e.id,j=e.deps,n;if(i){if(i in m||s[k]===!0||i==="jquery"&&p.jQuery&&p.jQuery!==f().fn.jquery)return;y[k]=!0;s[k]=!0;i==="jquery"&&f&&S(f())}e.depArray=a;e.callback=f;for(f=0;f0)){if(p.priorityWait)if(k())w();else return;for(j in s)if(!(j in K)&&(c=!0,!s[j]))if(a)b+=j+" ";else{h=!0;break}if(c||g.waitCount){if(a&&b)return j=N("timeout","Load timeout for modules: "+b),j.requireType="timeout",j.requireModules=b,d.onError(j);if(h||g.scriptCount){if((G||ca)&&!W)W=setTimeout(function(){W=0;A()},50)}else{if(g.waitCount){for(H=
17 | 0;b=I[H];H++)z(b,{});g.paused.length&&w();X<5&&(X+=1,A())}X=0;d.checkReadyState()}}}}var g,w,p={waitSeconds:7,baseUrl:"./",paths:{},pkgs:{},catchError:{}},P=[],y={require:!0,exports:!0,module:!0},E={},m={},s={},D={},I=[],T={},M=0,R={},L={},F={},Q={},Y=0;S=function(b){if(!g.jQuery&&(b=b||(typeof jQuery!=="undefined"?jQuery:null))&&!(p.jQuery&&b.fn.jquery!==p.jQuery)&&("holdReady"in b||"readyWait"in b))if(g.jQuery=b,n(["jquery",[],function(){return jQuery}]),g.scriptCount)V(b,!0),g.jQueryIncremented=
18 | !0};w=function(){var b,a,c,h,j,i;Y+=1;if(g.scriptCount<=0)g.scriptCount=0;for(;P.length;)if(b=P.shift(),b[0]===null)return d.onError(N("mismatch","Mismatched anonymous define() module: "+b[b.length-1]));else n(b);if(!p.priorityWait||k())for(;g.paused.length;){j=g.paused;g.pausedCount+=j.length;g.paused=[];for(h=0;b=j[h];h++)a=b.map,c=a.url,i=a.fullName,a.prefix?u(a.prefix,b):!T[c]&&!s[i]&&(d.load(g,i,c),c.indexOf("empty:")!==0&&(T[c]=!0));g.startTime=(new Date).getTime();g.pausedCount-=j.length}Y===
19 | 1&&A();Y-=1};g={contextName:a,config:p,defQueue:P,waiting:D,waitCount:0,specified:y,loaded:s,urlMap:E,urlFetched:T,scriptCount:0,defined:m,paused:[],pausedCount:0,plugins:L,needFullExec:F,fake:{},fullExec:Q,managerCallbacks:R,makeModuleMap:h,normalize:c,configure:function(b){var a,c,d;b.baseUrl&&b.baseUrl.charAt(b.baseUrl.length-1)!=="/"&&(b.baseUrl+="/");a=p.paths;d=p.pkgs;Z(p,b,!0);if(b.paths){for(c in b.paths)c in K||(a[c]=b.paths[c]);p.paths=a}if((a=b.packagePaths)||b.packages){if(a)for(c in a)c in
20 | K||$(d,a[c],c);b.packages&&$(d,b.packages);p.pkgs=d}if(b.priority)c=g.requireWait,g.requireWait=!1,g.takeGlobalQueue(),w(),g.require(b.priority),w(),g.requireWait=c,p.priorityWait=b.priority;if(b.deps||b.callback)g.require(b.deps||[],b.callback)},requireDefined:function(b,a){return h(b,a).fullName in m},requireSpecified:function(b,a){return h(b,a).fullName in y},require:function(b,c,f){if(typeof b==="string"){if(J(c))return d.onError(N("requireargs","Invalid require call"));if(d.get)return d.get(g,
21 | b,c);c=h(b,c);b=c.fullName;return!(b in m)?d.onError(N("notloaded","Module name '"+c.fullName+"' has not been loaded yet for context: "+a)):m[b]}(b&&b.length||c)&&x(null,b,c,f);if(!g.requireWait)for(;!g.scriptCount&&g.paused.length;)g.takeGlobalQueue(),w();return g.require},takeGlobalQueue:function(){U.length&&(ha.apply(g.defQueue,[g.defQueue.length-1,0].concat(U)),U=[])},completeLoad:function(b){var a;for(g.takeGlobalQueue();P.length;)if(a=P.shift(),a[0]===null){a[0]=b;break}else if(a[0]===b)break;
22 | else n(a),a=null;a?n(a):n([b,[],b==="jquery"&&typeof jQuery!=="undefined"?function(){return jQuery}:null]);S();d.isAsync&&(g.scriptCount-=1);w();d.isAsync||(g.scriptCount-=1)},toUrl:function(a,c){var d=a.lastIndexOf("."),h=null;d!==-1&&(h=a.substring(d,a.length),a=a.substring(0,d));return g.nameToUrl(a,h,c)},nameToUrl:function(a,h,f){var j,k,i,e,m=g.config,a=c(a,f&&f.fullName);if(d.jsExtRegExp.test(a))h=a+(h?h:"");else{j=m.paths;k=m.pkgs;f=a.split("/");for(e=f.length;e>0;e--)if(i=f.slice(0,e).join("/"),
23 | j[i]){f.splice(0,e,j[i]);break}else if(i=k[i]){a=a===i.name?i.location+"/"+i.main:i.location;f.splice(0,e,a);break}h=f.join("/")+(h||".js");h=(h.charAt(0)==="/"||h.match(/^\w+:/)?"":m.baseUrl)+h}return m.urlArgs?h+((h.indexOf("?")===-1?"?":"&")+m.urlArgs):h}};g.jQueryCheck=S;g.resume=w;return g}function ia(){var a,c,d;if(n&&n.readyState==="interactive")return n;a=document.getElementsByTagName("script");for(c=a.length-1;c>-1&&(d=a[c]);c--)if(d.readyState==="interactive")return n=d;return null}var ja=
24 | /(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/mg,ka=/require\(\s*["']([^'"\s]+)["']\s*\)/g,ea=/^\.\//,aa=/\.js$/,M=Object.prototype.toString,r=Array.prototype,ga=r.slice,ha=r.splice,G=!!(typeof window!=="undefined"&&navigator&&document),ca=!G&&typeof importScripts!=="undefined",la=G&&navigator.platform==="PLAYSTATION 3"?/^complete$/:/^(complete|loaded)$/,da=typeof opera!=="undefined"&&opera.toString()==="[object Opera]",K={},t={},U=[],n=null,X=0,O=!1,d,r={},I,v,x,y,u,z,A,H,B,S,W;if(typeof define==="undefined"){if(typeof requirejs!==
25 | "undefined")if(J(requirejs))return;else r=requirejs,requirejs=void 0;typeof require!=="undefined"&&!J(require)&&(r=require,require=void 0);d=requirejs=function(a,c,d){var k="_",j;!E(a)&&typeof a!=="string"&&(j=a,E(c)?(a=c,c=d):a=[]);if(j&&j.context)k=j.context;d=t[k]||(t[k]=fa(k));j&&d.configure(j);return d.require(a,c)};d.config=function(a){return d(a)};require||(require=d);d.toUrl=function(a){return t._.toUrl(a)};d.version="1.0.2";d.jsExtRegExp=/^\/|:|\?|\.js$/;v=d.s={contexts:t,skipAsync:{}};if(d.isAsync=
26 | d.isBrowser=G)if(x=v.head=document.getElementsByTagName("head")[0],y=document.getElementsByTagName("base")[0])x=v.head=y.parentNode;d.onError=function(a){throw a;};d.load=function(a,c,h){d.resourcesReady(!1);a.scriptCount+=1;d.attach(h,a,c);if(a.jQuery&&!a.jQueryIncremented)V(a.jQuery,!0),a.jQueryIncremented=!0};define=function(a,c,d){var k,j;typeof a!=="string"&&(d=c,c=a,a=null);E(c)||(d=c,c=[]);!c.length&&J(d)&&d.length&&(d.toString().replace(ja,"").replace(ka,function(a,d){c.push(d)}),c=(d.length===
27 | 1?["require"]:["require","exports","module"]).concat(c));if(O&&(k=I||ia()))a||(a=k.getAttribute("data-requiremodule")),j=t[k.getAttribute("data-requirecontext")];(j?j.defQueue:U).push([a,c,d])};define.amd={multiversion:!0,plugins:!0,jQuery:!0};d.exec=function(a){return eval(a)};d.execCb=function(a,c,d,k){return c.apply(k,d)};d.addScriptToDom=function(a){I=a;y?x.insertBefore(a,y):x.appendChild(a);I=null};d.onScriptLoad=function(a){var c=a.currentTarget||a.srcElement,h;if(a.type==="load"||c&&la.test(c.readyState))n=
28 | null,a=c.getAttribute("data-requirecontext"),h=c.getAttribute("data-requiremodule"),t[a].completeLoad(h),c.detachEvent&&!da?c.detachEvent("onreadystatechange",d.onScriptLoad):c.removeEventListener("load",d.onScriptLoad,!1)};d.attach=function(a,c,h,k,j,n){var o;if(G)return k=k||d.onScriptLoad,o=c&&c.config&&c.config.xhtml?document.createElementNS("http://www.w3.org/1999/xhtml","html:script"):document.createElement("script"),o.type=j||"text/javascript",o.charset="utf-8",o.async=!v.skipAsync[a],c&&o.setAttribute("data-requirecontext",
29 | c.contextName),o.setAttribute("data-requiremodule",h),o.attachEvent&&!da?(O=!0,n?o.onreadystatechange=function(){if(o.readyState==="loaded")o.onreadystatechange=null,o.attachEvent("onreadystatechange",k),n(o)}:o.attachEvent("onreadystatechange",k)):o.addEventListener("load",k,!1),o.src=a,n||d.addScriptToDom(o),o;else ca&&(importScripts(a),c.completeLoad(h));return null};if(G){u=document.getElementsByTagName("script");for(H=u.length-1;H>-1&&(z=u[H]);H--){if(!x)x=z.parentNode;if(A=z.getAttribute("data-main")){if(!r.baseUrl)u=
30 | A.split("/"),z=u.pop(),u=u.length?u.join("/")+"/":"./",r.baseUrl=u,A=z.replace(aa,"");r.deps=r.deps?r.deps.concat(A):[A];break}}}d.checkReadyState=function(){var a=v.contexts,c;for(c in a)if(!(c in K)&&a[c].waitCount)return;d.resourcesReady(!0)};d.resourcesReady=function(a){var c,h;d.resourcesDone=a;if(d.resourcesDone)for(h in a=v.contexts,a)if(!(h in K)&&(c=a[h],c.jQueryIncremented))V(c.jQuery,!1),c.jQueryIncremented=!1};d.pageLoaded=function(){if(document.readyState!=="complete")document.readyState=
31 | "complete"};if(G&&document.addEventListener&&!document.readyState)document.readyState="loading",window.addEventListener("load",d.pageLoaded,!1);d(r);if(d.isAsync&&typeof setTimeout!=="undefined")B=v.contexts[r.context||"_"],B.requireWait=!0,setTimeout(function(){B.requireWait=!1;B.takeGlobalQueue();B.jQueryCheck();B.scriptCount||B.resume();d.checkReadyState()},0)}})();
32 |
--------------------------------------------------------------------------------
/client/js/libs/underscore.js:
--------------------------------------------------------------------------------
1 | // Underscore.js 1.2.3
2 | // (c) 2009-2011 Jeremy Ashkenas, DocumentCloud Inc.
3 | // Underscore is freely distributable under the MIT license.
4 | // Portions of Underscore are inspired or borrowed from Prototype,
5 | // Oliver Steele's Functional, and John Resig's Micro-Templating.
6 | // For all details and documentation:
7 | // http://documentcloud.github.com/underscore
8 |
9 | (function() {
10 |
11 | // Baseline setup
12 | // --------------
13 |
14 | // Establish the root object, `window` in the browser, or `global` on the server.
15 | var root = this;
16 |
17 | // Save the previous value of the `_` variable.
18 | var previousUnderscore = root._;
19 |
20 | // Establish the object that gets returned to break out of a loop iteration.
21 | var breaker = {};
22 |
23 | // Save bytes in the minified (but not gzipped) version:
24 | var ArrayProto = Array.prototype, ObjProto = Object.prototype, FuncProto = Function.prototype;
25 |
26 | // Create quick reference variables for speed access to core prototypes.
27 | var slice = ArrayProto.slice,
28 | concat = ArrayProto.concat,
29 | unshift = ArrayProto.unshift,
30 | toString = ObjProto.toString,
31 | hasOwnProperty = ObjProto.hasOwnProperty;
32 |
33 | // All **ECMAScript 5** native function implementations that we hope to use
34 | // are declared here.
35 | var
36 | nativeForEach = ArrayProto.forEach,
37 | nativeMap = ArrayProto.map,
38 | nativeReduce = ArrayProto.reduce,
39 | nativeReduceRight = ArrayProto.reduceRight,
40 | nativeFilter = ArrayProto.filter,
41 | nativeEvery = ArrayProto.every,
42 | nativeSome = ArrayProto.some,
43 | nativeIndexOf = ArrayProto.indexOf,
44 | nativeLastIndexOf = ArrayProto.lastIndexOf,
45 | nativeIsArray = Array.isArray,
46 | nativeKeys = Object.keys,
47 | nativeBind = FuncProto.bind;
48 |
49 | // Create a safe reference to the Underscore object for use below.
50 | var _ = function(obj) { return new wrapper(obj); };
51 |
52 | // Export the Underscore object for **Node.js** and **"CommonJS"**, with
53 | // backwards-compatibility for the old `require()` API. If we're not in
54 | // CommonJS, add `_` to the global object.
55 | if (typeof exports !== 'undefined') {
56 | if (typeof module !== 'undefined' && module.exports) {
57 | exports = module.exports = _;
58 | }
59 | exports._ = _;
60 | } else if (typeof define === 'function' && define.amd) {
61 | // Register as a named module with AMD.
62 | define('underscore', function() {
63 | return _;
64 | });
65 | } else {
66 | // Exported as a string, for Closure Compiler "advanced" mode.
67 | root['_'] = _;
68 | }
69 |
70 | // Current version.
71 | _.VERSION = '1.2.3';
72 |
73 | // Collection Functions
74 | // --------------------
75 |
76 | // The cornerstone, an `each` implementation, aka `forEach`.
77 | // Handles objects with the built-in `forEach`, arrays, and raw objects.
78 | // Delegates to **ECMAScript 5**'s native `forEach` if available.
79 | var each = _.each = _.forEach = function(obj, iterator, context) {
80 | if (obj == null) return;
81 | if (nativeForEach && obj.forEach === nativeForEach) {
82 | obj.forEach(iterator, context);
83 | } else if (obj.length === +obj.length) {
84 | for (var i = 0, l = obj.length; i < l; i++) {
85 | if (i in obj && iterator.call(context, obj[i], i, obj) === breaker) return;
86 | }
87 | } else {
88 | for (var key in obj) {
89 | if (hasOwnProperty.call(obj, key)) {
90 | if (iterator.call(context, obj[key], key, obj) === breaker) return;
91 | }
92 | }
93 | }
94 | };
95 |
96 | // Return the results of applying the iterator to each element.
97 | // Delegates to **ECMAScript 5**'s native `map` if available.
98 | _.map = function(obj, iterator, context) {
99 | var results = [];
100 | if (obj == null) return results;
101 | if (nativeMap && obj.map === nativeMap) return obj.map(iterator, context);
102 | each(obj, function(value, index, list) {
103 | results[results.length] = iterator.call(context, value, index, list);
104 | });
105 | return results;
106 | };
107 |
108 | // **Reduce** builds up a single result from a list of values, aka `inject`,
109 | // or `foldl`. Delegates to **ECMAScript 5**'s native `reduce` if available.
110 | _.reduce = _.foldl = _.inject = function(obj, iterator, memo, context) {
111 | var initial = arguments.length > 2;
112 | if (obj == null) obj = [];
113 | if (nativeReduce && obj.reduce === nativeReduce) {
114 | if (context) iterator = _.bind(iterator, context);
115 | return initial ? obj.reduce(iterator, memo) : obj.reduce(iterator);
116 | }
117 | each(obj, function(value, index, list) {
118 | if (!initial) {
119 | memo = value;
120 | initial = true;
121 | } else {
122 | memo = iterator.call(context, memo, value, index, list);
123 | }
124 | });
125 | if (!initial) throw new TypeError('Reduce of empty array with no initial value');
126 | return memo;
127 | };
128 |
129 | // The right-associative version of reduce, also known as `foldr`.
130 | // Delegates to **ECMAScript 5**'s native `reduceRight` if available.
131 | _.reduceRight = _.foldr = function(obj, iterator, memo, context) {
132 | var initial = arguments.length > 2;
133 | if (obj == null) obj = [];
134 | if (nativeReduceRight && obj.reduceRight === nativeReduceRight) {
135 | if (context) iterator = _.bind(iterator, context);
136 | return initial ? obj.reduceRight(iterator, memo) : obj.reduceRight(iterator);
137 | }
138 | var reversed = _.toArray(obj).reverse();
139 | if (context && !initial) iterator = _.bind(iterator, context);
140 | return initial ? _.reduce(reversed, iterator, memo, context) : _.reduce(reversed, iterator);
141 | };
142 |
143 | // Return the first value which passes a truth test. Aliased as `detect`.
144 | _.find = _.detect = function(obj, iterator, context) {
145 | var result;
146 | any(obj, function(value, index, list) {
147 | if (iterator.call(context, value, index, list)) {
148 | result = value;
149 | return true;
150 | }
151 | });
152 | return result;
153 | };
154 |
155 | // Return all the elements that pass a truth test.
156 | // Delegates to **ECMAScript 5**'s native `filter` if available.
157 | // Aliased as `select`.
158 | _.filter = _.select = function(obj, iterator, context) {
159 | var results = [];
160 | if (obj == null) return results;
161 | if (nativeFilter && obj.filter === nativeFilter) return obj.filter(iterator, context);
162 | each(obj, function(value, index, list) {
163 | if (iterator.call(context, value, index, list)) results[results.length] = value;
164 | });
165 | return results;
166 | };
167 |
168 | // Return all the elements for which a truth test fails.
169 | _.reject = function(obj, iterator, context) {
170 | var results = [];
171 | if (obj == null) return results;
172 | each(obj, function(value, index, list) {
173 | if (!iterator.call(context, value, index, list)) results[results.length] = value;
174 | });
175 | return results;
176 | };
177 |
178 | // Determine whether all of the elements match a truth test.
179 | // Delegates to **ECMAScript 5**'s native `every` if available.
180 | // Aliased as `all`.
181 | _.every = _.all = function(obj, iterator, context) {
182 | var result = true;
183 | if (obj == null) return result;
184 | if (nativeEvery && obj.every === nativeEvery) return obj.every(iterator, context);
185 | each(obj, function(value, index, list) {
186 | if (!(result = result && iterator.call(context, value, index, list))) return breaker;
187 | });
188 | return result;
189 | };
190 |
191 | // Determine if at least one element in the object matches a truth test.
192 | // Delegates to **ECMAScript 5**'s native `some` if available.
193 | // Aliased as `any`.
194 | var any = _.some = _.any = function(obj, iterator, context) {
195 | iterator || (iterator = _.identity);
196 | var result = false;
197 | if (obj == null) return result;
198 | if (nativeSome && obj.some === nativeSome) return obj.some(iterator, context);
199 | each(obj, function(value, index, list) {
200 | if (result || (result = iterator.call(context, value, index, list))) return breaker;
201 | });
202 | return !!result;
203 | };
204 |
205 | // Determine if a given value is included in the array or object using `===`.
206 | // Aliased as `contains`.
207 | _.include = _.contains = function(obj, target) {
208 | var found = false;
209 | if (obj == null) return found;
210 | if (nativeIndexOf && obj.indexOf === nativeIndexOf) return obj.indexOf(target) != -1;
211 | found = any(obj, function(value) {
212 | return value === target;
213 | });
214 | return found;
215 | };
216 |
217 | // Invoke a method (with arguments) on every item in a collection.
218 | _.invoke = function(obj, method) {
219 | var args = slice.call(arguments, 2);
220 | return _.map(obj, function(value) {
221 | return (method.call ? method || value : value[method]).apply(value, args);
222 | });
223 | };
224 |
225 | // Convenience version of a common use case of `map`: fetching a property.
226 | _.pluck = function(obj, key) {
227 | return _.map(obj, function(value){ return value[key]; });
228 | };
229 |
230 | // Return the maximum element or (element-based computation).
231 | _.max = function(obj, iterator, context) {
232 | if (!iterator && _.isArray(obj)) return Math.max.apply(Math, obj);
233 | if (!iterator && _.isEmpty(obj)) return -Infinity;
234 | var result = {computed : -Infinity};
235 | each(obj, function(value, index, list) {
236 | var computed = iterator ? iterator.call(context, value, index, list) : value;
237 | computed >= result.computed && (result = {value : value, computed : computed});
238 | });
239 | return result.value;
240 | };
241 |
242 | // Return the minimum element (or element-based computation).
243 | _.min = function(obj, iterator, context) {
244 | if (!iterator && _.isArray(obj)) return Math.min.apply(Math, obj);
245 | if (!iterator && _.isEmpty(obj)) return Infinity;
246 | var result = {computed : Infinity};
247 | each(obj, function(value, index, list) {
248 | var computed = iterator ? iterator.call(context, value, index, list) : value;
249 | computed < result.computed && (result = {value : value, computed : computed});
250 | });
251 | return result.value;
252 | };
253 |
254 | // Shuffle an array.
255 | _.shuffle = function(obj) {
256 | var shuffled = [], rand;
257 | each(obj, function(value, index, list) {
258 | if (index == 0) {
259 | shuffled[0] = value;
260 | } else {
261 | rand = Math.floor(Math.random() * (index + 1));
262 | shuffled[index] = shuffled[rand];
263 | shuffled[rand] = value;
264 | }
265 | });
266 | return shuffled;
267 | };
268 |
269 | // Sort the object's values by a criterion produced by an iterator.
270 | _.sortBy = function(obj, iterator, context) {
271 | return _.pluck(_.map(obj, function(value, index, list) {
272 | return {
273 | value : value,
274 | criteria : iterator.call(context, value, index, list)
275 | };
276 | }).sort(function(left, right) {
277 | var a = left.criteria, b = right.criteria;
278 | return a < b ? -1 : a > b ? 1 : 0;
279 | }), 'value');
280 | };
281 |
282 | // Groups the object's values by a criterion. Pass either a string attribute
283 | // to group by, or a function that returns the criterion.
284 | _.groupBy = function(obj, val) {
285 | var result = {};
286 | var iterator = _.isFunction(val) ? val : function(obj) { return obj[val]; };
287 | each(obj, function(value, index) {
288 | var key = iterator(value, index);
289 | (result[key] || (result[key] = [])).push(value);
290 | });
291 | return result;
292 | };
293 |
294 | // Use a comparator function to figure out at what index an object should
295 | // be inserted so as to maintain order. Uses binary search.
296 | _.sortedIndex = function(array, obj, iterator) {
297 | iterator || (iterator = _.identity);
298 | var low = 0, high = array.length;
299 | while (low < high) {
300 | var mid = (low + high) >> 1;
301 | iterator(array[mid]) < iterator(obj) ? low = mid + 1 : high = mid;
302 | }
303 | return low;
304 | };
305 |
306 | // Safely convert anything iterable into a real, live array.
307 | _.toArray = function(iterable) {
308 | if (!iterable) return [];
309 | if (iterable.toArray) return iterable.toArray();
310 | if (_.isArray(iterable)) return slice.call(iterable);
311 | if (_.isArguments(iterable)) return slice.call(iterable);
312 | return _.values(iterable);
313 | };
314 |
315 | // Return the number of elements in an object.
316 | _.size = function(obj) {
317 | return _.toArray(obj).length;
318 | };
319 |
320 | // Array Functions
321 | // ---------------
322 |
323 | // Get the first element of an array. Passing **n** will return the first N
324 | // values in the array. Aliased as `head`. The **guard** check allows it to work
325 | // with `_.map`.
326 | _.first = _.head = function(array, n, guard) {
327 | return (n != null) && !guard ? slice.call(array, 0, n) : array[0];
328 | };
329 |
330 | // Returns everything but the last entry of the array. Especcialy useful on
331 | // the arguments object. Passing **n** will return all the values in
332 | // the array, excluding the last N. The **guard** check allows it to work with
333 | // `_.map`.
334 | _.initial = function(array, n, guard) {
335 | return slice.call(array, 0, array.length - ((n == null) || guard ? 1 : n));
336 | };
337 |
338 | // Get the last element of an array. Passing **n** will return the last N
339 | // values in the array. The **guard** check allows it to work with `_.map`.
340 | _.last = function(array, n, guard) {
341 | if ((n != null) && !guard) {
342 | return slice.call(array, Math.max(array.length - n, 0));
343 | } else {
344 | return array[array.length - 1];
345 | }
346 | };
347 |
348 | // Returns everything but the first entry of the array. Aliased as `tail`.
349 | // Especially useful on the arguments object. Passing an **index** will return
350 | // the rest of the values in the array from that index onward. The **guard**
351 | // check allows it to work with `_.map`.
352 | _.rest = _.tail = function(array, index, guard) {
353 | return slice.call(array, (index == null) || guard ? 1 : index);
354 | };
355 |
356 | // Trim out all falsy values from an array.
357 | _.compact = function(array) {
358 | return _.filter(array, function(value){ return !!value; });
359 | };
360 |
361 | // Return a completely flattened version of an array.
362 | _.flatten = function(array, shallow) {
363 | return _.reduce(array, function(memo, value) {
364 | if (_.isArray(value)) return memo.concat(shallow ? value : _.flatten(value));
365 | memo[memo.length] = value;
366 | return memo;
367 | }, []);
368 | };
369 |
370 | // Return a version of the array that does not contain the specified value(s).
371 | _.without = function(array) {
372 | return _.difference(array, slice.call(arguments, 1));
373 | };
374 |
375 | // Produce a duplicate-free version of the array. If the array has already
376 | // been sorted, you have the option of using a faster algorithm.
377 | // Aliased as `unique`.
378 | _.uniq = _.unique = function(array, isSorted, iterator) {
379 | var initial = iterator ? _.map(array, iterator) : array;
380 | var result = [];
381 | _.reduce(initial, function(memo, el, i) {
382 | if (0 == i || (isSorted === true ? _.last(memo) != el : !_.include(memo, el))) {
383 | memo[memo.length] = el;
384 | result[result.length] = array[i];
385 | }
386 | return memo;
387 | }, []);
388 | return result;
389 | };
390 |
391 | // Produce an array that contains the union: each distinct element from all of
392 | // the passed-in arrays.
393 | _.union = function() {
394 | return _.uniq(_.flatten(arguments, true));
395 | };
396 |
397 | // Produce an array that contains every item shared between all the
398 | // passed-in arrays. (Aliased as "intersect" for back-compat.)
399 | _.intersection = _.intersect = function(array) {
400 | var rest = slice.call(arguments, 1);
401 | return _.filter(_.uniq(array), function(item) {
402 | return _.every(rest, function(other) {
403 | return _.indexOf(other, item) >= 0;
404 | });
405 | });
406 | };
407 |
408 | // Take the difference between one array and a number of other arrays.
409 | // Only the elements present in just the first array will remain.
410 | _.difference = function(array) {
411 | var rest = _.flatten(slice.call(arguments, 1));
412 | return _.filter(array, function(value){ return !_.include(rest, value); });
413 | };
414 |
415 | // Zip together multiple lists into a single array -- elements that share
416 | // an index go together.
417 | _.zip = function() {
418 | var args = slice.call(arguments);
419 | var length = _.max(_.pluck(args, 'length'));
420 | var results = new Array(length);
421 | for (var i = 0; i < length; i++) results[i] = _.pluck(args, "" + i);
422 | return results;
423 | };
424 |
425 | // If the browser doesn't supply us with indexOf (I'm looking at you, **MSIE**),
426 | // we need this function. Return the position of the first occurrence of an
427 | // item in an array, or -1 if the item is not included in the array.
428 | // Delegates to **ECMAScript 5**'s native `indexOf` if available.
429 | // If the array is large and already in sort order, pass `true`
430 | // for **isSorted** to use binary search.
431 | _.indexOf = function(array, item, isSorted) {
432 | if (array == null) return -1;
433 | var i, l;
434 | if (isSorted) {
435 | i = _.sortedIndex(array, item);
436 | return array[i] === item ? i : -1;
437 | }
438 | if (nativeIndexOf && array.indexOf === nativeIndexOf) return array.indexOf(item);
439 | for (i = 0, l = array.length; i < l; i++) if (i in array && array[i] === item) return i;
440 | return -1;
441 | };
442 |
443 | // Delegates to **ECMAScript 5**'s native `lastIndexOf` if available.
444 | _.lastIndexOf = function(array, item) {
445 | if (array == null) return -1;
446 | if (nativeLastIndexOf && array.lastIndexOf === nativeLastIndexOf) return array.lastIndexOf(item);
447 | var i = array.length;
448 | while (i--) if (i in array && array[i] === item) return i;
449 | return -1;
450 | };
451 |
452 | // Generate an integer Array containing an arithmetic progression. A port of
453 | // the native Python `range()` function. See
454 | // [the Python documentation](http://docs.python.org/library/functions.html#range).
455 | _.range = function(start, stop, step) {
456 | if (arguments.length <= 1) {
457 | stop = start || 0;
458 | start = 0;
459 | }
460 | step = arguments[2] || 1;
461 |
462 | var len = Math.max(Math.ceil((stop - start) / step), 0);
463 | var idx = 0;
464 | var range = new Array(len);
465 |
466 | while(idx < len) {
467 | range[idx++] = start;
468 | start += step;
469 | }
470 |
471 | return range;
472 | };
473 |
474 | // Function (ahem) Functions
475 | // ------------------
476 |
477 | // Reusable constructor function for prototype setting.
478 | var ctor = function(){};
479 |
480 | // Create a function bound to a given object (assigning `this`, and arguments,
481 | // optionally). Binding with arguments is also known as `curry`.
482 | // Delegates to **ECMAScript 5**'s native `Function.bind` if available.
483 | // We check for `func.bind` first, to fail fast when `func` is undefined.
484 | _.bind = function bind(func, context) {
485 | var bound, args;
486 | if (func.bind === nativeBind && nativeBind) return nativeBind.apply(func, slice.call(arguments, 1));
487 | if (!_.isFunction(func)) throw new TypeError;
488 | args = slice.call(arguments, 2);
489 | return bound = function() {
490 | if (!(this instanceof bound)) return func.apply(context, args.concat(slice.call(arguments)));
491 | ctor.prototype = func.prototype;
492 | var self = new ctor;
493 | var result = func.apply(self, args.concat(slice.call(arguments)));
494 | if (Object(result) === result) return result;
495 | return self;
496 | };
497 | };
498 |
499 | // Bind all of an object's methods to that object. Useful for ensuring that
500 | // all callbacks defined on an object belong to it.
501 | _.bindAll = function(obj) {
502 | var funcs = slice.call(arguments, 1);
503 | if (funcs.length == 0) funcs = _.functions(obj);
504 | each(funcs, function(f) { obj[f] = _.bind(obj[f], obj); });
505 | return obj;
506 | };
507 |
508 | // Memoize an expensive function by storing its results.
509 | _.memoize = function(func, hasher) {
510 | var memo = {};
511 | hasher || (hasher = _.identity);
512 | return function() {
513 | var key = hasher.apply(this, arguments);
514 | return hasOwnProperty.call(memo, key) ? memo[key] : (memo[key] = func.apply(this, arguments));
515 | };
516 | };
517 |
518 | // Delays a function for the given number of milliseconds, and then calls
519 | // it with the arguments supplied.
520 | _.delay = function(func, wait) {
521 | var args = slice.call(arguments, 2);
522 | return setTimeout(function(){ return func.apply(func, args); }, wait);
523 | };
524 |
525 | // Defers a function, scheduling it to run after the current call stack has
526 | // cleared.
527 | _.defer = function(func) {
528 | return _.delay.apply(_, [func, 1].concat(slice.call(arguments, 1)));
529 | };
530 |
531 | // Returns a function, that, when invoked, will only be triggered at most once
532 | // during a given window of time.
533 | _.throttle = function(func, wait) {
534 | var context, args, timeout, throttling, more;
535 | var whenDone = _.debounce(function(){ more = throttling = false; }, wait);
536 | return function() {
537 | context = this; args = arguments;
538 | var later = function() {
539 | timeout = null;
540 | if (more) func.apply(context, args);
541 | whenDone();
542 | };
543 | if (!timeout) timeout = setTimeout(later, wait);
544 | if (throttling) {
545 | more = true;
546 | } else {
547 | func.apply(context, args);
548 | }
549 | whenDone();
550 | throttling = true;
551 | };
552 | };
553 |
554 | // Returns a function, that, as long as it continues to be invoked, will not
555 | // be triggered. The function will be called after it stops being called for
556 | // N milliseconds.
557 | _.debounce = function(func, wait) {
558 | var timeout;
559 | return function() {
560 | var context = this, args = arguments;
561 | var later = function() {
562 | timeout = null;
563 | func.apply(context, args);
564 | };
565 | clearTimeout(timeout);
566 | timeout = setTimeout(later, wait);
567 | };
568 | };
569 |
570 | // Returns a function that will be executed at most one time, no matter how
571 | // often you call it. Useful for lazy initialization.
572 | _.once = function(func) {
573 | var ran = false, memo;
574 | return function() {
575 | if (ran) return memo;
576 | ran = true;
577 | return memo = func.apply(this, arguments);
578 | };
579 | };
580 |
581 | // Returns the first function passed as an argument to the second,
582 | // allowing you to adjust arguments, run code before and after, and
583 | // conditionally execute the original function.
584 | _.wrap = function(func, wrapper) {
585 | return function() {
586 | var args = concat.apply([func], arguments);
587 | return wrapper.apply(this, args);
588 | };
589 | };
590 |
591 | // Returns a function that is the composition of a list of functions, each
592 | // consuming the return value of the function that follows.
593 | _.compose = function() {
594 | var funcs = arguments;
595 | return function() {
596 | var args = arguments;
597 | for (var i = funcs.length - 1; i >= 0; i--) {
598 | args = [funcs[i].apply(this, args)];
599 | }
600 | return args[0];
601 | };
602 | };
603 |
604 | // Returns a function that will only be executed after being called N times.
605 | _.after = function(times, func) {
606 | if (times <= 0) return func();
607 | return function() {
608 | if (--times < 1) { return func.apply(this, arguments); }
609 | };
610 | };
611 |
612 | // Object Functions
613 | // ----------------
614 |
615 | // Retrieve the names of an object's properties.
616 | // Delegates to **ECMAScript 5**'s native `Object.keys`
617 | _.keys = nativeKeys || function(obj) {
618 | if (obj !== Object(obj)) throw new TypeError('Invalid object');
619 | var keys = [];
620 | for (var key in obj) if (hasOwnProperty.call(obj, key)) keys[keys.length] = key;
621 | return keys;
622 | };
623 |
624 | // Retrieve the values of an object's properties.
625 | _.values = function(obj) {
626 | return _.map(obj, _.identity);
627 | };
628 |
629 | // Return a sorted list of the function names available on the object.
630 | // Aliased as `methods`
631 | _.functions = _.methods = function(obj) {
632 | var names = [];
633 | for (var key in obj) {
634 | if (_.isFunction(obj[key])) names.push(key);
635 | }
636 | return names.sort();
637 | };
638 |
639 | // Extend a given object with all the properties in passed-in object(s).
640 | _.extend = function(obj) {
641 | each(slice.call(arguments, 1), function(source) {
642 | for (var prop in source) {
643 | if (source[prop] !== void 0) obj[prop] = source[prop];
644 | }
645 | });
646 | return obj;
647 | };
648 |
649 | // Fill in a given object with default properties.
650 | _.defaults = function(obj) {
651 | each(slice.call(arguments, 1), function(source) {
652 | for (var prop in source) {
653 | if (obj[prop] == null) obj[prop] = source[prop];
654 | }
655 | });
656 | return obj;
657 | };
658 |
659 | // Create a (shallow-cloned) duplicate of an object.
660 | _.clone = function(obj) {
661 | if (!_.isObject(obj)) return obj;
662 | return _.isArray(obj) ? obj.slice() : _.extend({}, obj);
663 | };
664 |
665 | // Invokes interceptor with the obj, and then returns obj.
666 | // The primary purpose of this method is to "tap into" a method chain, in
667 | // order to perform operations on intermediate results within the chain.
668 | _.tap = function(obj, interceptor) {
669 | interceptor(obj);
670 | return obj;
671 | };
672 |
673 | // Internal recursive comparison function.
674 | function eq(a, b, stack) {
675 | // Identical objects are equal. `0 === -0`, but they aren't identical.
676 | // See the Harmony `egal` proposal: http://wiki.ecmascript.org/doku.php?id=harmony:egal.
677 | if (a === b) return a !== 0 || 1 / a == 1 / b;
678 | // A strict comparison is necessary because `null == undefined`.
679 | if (a == null || b == null) return a === b;
680 | // Unwrap any wrapped objects.
681 | if (a._chain) a = a._wrapped;
682 | if (b._chain) b = b._wrapped;
683 | // Invoke a custom `isEqual` method if one is provided.
684 | if (a.isEqual && _.isFunction(a.isEqual)) return a.isEqual(b);
685 | if (b.isEqual && _.isFunction(b.isEqual)) return b.isEqual(a);
686 | // Compare `[[Class]]` names.
687 | var className = toString.call(a);
688 | if (className != toString.call(b)) return false;
689 | switch (className) {
690 | // Strings, numbers, dates, and booleans are compared by value.
691 | case '[object String]':
692 | // Primitives and their corresponding object wrappers are equivalent; thus, `"5"` is
693 | // equivalent to `new String("5")`.
694 | return a == String(b);
695 | case '[object Number]':
696 | // `NaN`s are equivalent, but non-reflexive. An `egal` comparison is performed for
697 | // other numeric values.
698 | return a != +a ? b != +b : (a == 0 ? 1 / a == 1 / b : a == +b);
699 | case '[object Date]':
700 | case '[object Boolean]':
701 | // Coerce dates and booleans to numeric primitive values. Dates are compared by their
702 | // millisecond representations. Note that invalid dates with millisecond representations
703 | // of `NaN` are not equivalent.
704 | return +a == +b;
705 | // RegExps are compared by their source patterns and flags.
706 | case '[object RegExp]':
707 | return a.source == b.source &&
708 | a.global == b.global &&
709 | a.multiline == b.multiline &&
710 | a.ignoreCase == b.ignoreCase;
711 | }
712 | if (typeof a != 'object' || typeof b != 'object') return false;
713 | // Assume equality for cyclic structures. The algorithm for detecting cyclic
714 | // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`.
715 | var length = stack.length;
716 | while (length--) {
717 | // Linear search. Performance is inversely proportional to the number of
718 | // unique nested structures.
719 | if (stack[length] == a) return true;
720 | }
721 | // Add the first object to the stack of traversed objects.
722 | stack.push(a);
723 | var size = 0, result = true;
724 | // Recursively compare objects and arrays.
725 | if (className == '[object Array]') {
726 | // Compare array lengths to determine if a deep comparison is necessary.
727 | size = a.length;
728 | result = size == b.length;
729 | if (result) {
730 | // Deep compare the contents, ignoring non-numeric properties.
731 | while (size--) {
732 | // Ensure commutative equality for sparse arrays.
733 | if (!(result = size in a == size in b && eq(a[size], b[size], stack))) break;
734 | }
735 | }
736 | } else {
737 | // Objects with different constructors are not equivalent.
738 | if ('constructor' in a != 'constructor' in b || a.constructor != b.constructor) return false;
739 | // Deep compare objects.
740 | for (var key in a) {
741 | if (hasOwnProperty.call(a, key)) {
742 | // Count the expected number of properties.
743 | size++;
744 | // Deep compare each member.
745 | if (!(result = hasOwnProperty.call(b, key) && eq(a[key], b[key], stack))) break;
746 | }
747 | }
748 | // Ensure that both objects contain the same number of properties.
749 | if (result) {
750 | for (key in b) {
751 | if (hasOwnProperty.call(b, key) && !(size--)) break;
752 | }
753 | result = !size;
754 | }
755 | }
756 | // Remove the first object from the stack of traversed objects.
757 | stack.pop();
758 | return result;
759 | }
760 |
761 | // Perform a deep comparison to check if two objects are equal.
762 | _.isEqual = function(a, b) {
763 | return eq(a, b, []);
764 | };
765 |
766 | // Is a given array, string, or object empty?
767 | // An "empty" object has no enumerable own-properties.
768 | _.isEmpty = function(obj) {
769 | if (_.isArray(obj) || _.isString(obj)) return obj.length === 0;
770 | for (var key in obj) if (hasOwnProperty.call(obj, key)) return false;
771 | return true;
772 | };
773 |
774 | // Is a given value a DOM element?
775 | _.isElement = function(obj) {
776 | return !!(obj && obj.nodeType == 1);
777 | };
778 |
779 | // Is a given value an array?
780 | // Delegates to ECMA5's native Array.isArray
781 | _.isArray = nativeIsArray || function(obj) {
782 | return toString.call(obj) == '[object Array]';
783 | };
784 |
785 | // Is a given variable an object?
786 | _.isObject = function(obj) {
787 | return obj === Object(obj);
788 | };
789 |
790 | // Is a given variable an arguments object?
791 | _.isArguments = function(obj) {
792 | return toString.call(obj) == '[object Arguments]';
793 | };
794 | if (!_.isArguments(arguments)) {
795 | _.isArguments = function(obj) {
796 | return !!(obj && hasOwnProperty.call(obj, 'callee'));
797 | };
798 | }
799 |
800 | // Is a given value a function?
801 | _.isFunction = function(obj) {
802 | return toString.call(obj) == '[object Function]';
803 | };
804 |
805 | // Is a given value a string?
806 | _.isString = function(obj) {
807 | return toString.call(obj) == '[object String]';
808 | };
809 |
810 | // Is a given value a number?
811 | _.isNumber = function(obj) {
812 | return toString.call(obj) == '[object Number]';
813 | };
814 |
815 | // Is the given value `NaN`?
816 | _.isNaN = function(obj) {
817 | // `NaN` is the only value for which `===` is not reflexive.
818 | return obj !== obj;
819 | };
820 |
821 | // Is a given value a boolean?
822 | _.isBoolean = function(obj) {
823 | return obj === true || obj === false || toString.call(obj) == '[object Boolean]';
824 | };
825 |
826 | // Is a given value a date?
827 | _.isDate = function(obj) {
828 | return toString.call(obj) == '[object Date]';
829 | };
830 |
831 | // Is the given value a regular expression?
832 | _.isRegExp = function(obj) {
833 | return toString.call(obj) == '[object RegExp]';
834 | };
835 |
836 | // Is a given value equal to null?
837 | _.isNull = function(obj) {
838 | return obj === null;
839 | };
840 |
841 | // Is a given variable undefined?
842 | _.isUndefined = function(obj) {
843 | return obj === void 0;
844 | };
845 |
846 | // Utility Functions
847 | // -----------------
848 |
849 | // Run Underscore.js in *noConflict* mode, returning the `_` variable to its
850 | // previous owner. Returns a reference to the Underscore object.
851 | _.noConflict = function() {
852 | root._ = previousUnderscore;
853 | return this;
854 | };
855 |
856 | // Keep the identity function around for default iterators.
857 | _.identity = function(value) {
858 | return value;
859 | };
860 |
861 | // Run a function **n** times.
862 | _.times = function (n, iterator, context) {
863 | for (var i = 0; i < n; i++) iterator.call(context, i);
864 | };
865 |
866 | // Escape a string for HTML interpolation.
867 | _.escape = function(string) {
868 | return (''+string).replace(/&/g, '&').replace(//g, '>').replace(/"/g, '"').replace(/'/g, ''').replace(/\//g,'/');
869 | };
870 |
871 | // Add your own custom functions to the Underscore object, ensuring that
872 | // they're correctly added to the OOP wrapper as well.
873 | _.mixin = function(obj) {
874 | each(_.functions(obj), function(name){
875 | addToWrapper(name, _[name] = obj[name]);
876 | });
877 | };
878 |
879 | // Generate a unique integer id (unique within the entire client session).
880 | // Useful for temporary DOM ids.
881 | var idCounter = 0;
882 | _.uniqueId = function(prefix) {
883 | var id = idCounter++;
884 | return prefix ? prefix + id : id;
885 | };
886 |
887 | // By default, Underscore uses ERB-style template delimiters, change the
888 | // following template settings to use alternative delimiters.
889 | _.templateSettings = {
890 | evaluate : /<%([\s\S]+?)%>/g,
891 | interpolate : /<%=([\s\S]+?)%>/g,
892 | escape : /<%-([\s\S]+?)%>/g
893 | };
894 |
895 | // JavaScript micro-templating, similar to John Resig's implementation.
896 | // Underscore templating handles arbitrary delimiters, preserves whitespace,
897 | // and correctly escapes quotes within interpolated code.
898 | _.template = function(str, data) {
899 | var c = _.templateSettings;
900 | var tmpl = 'var __p=[],print=function(){__p.push.apply(__p,arguments);};' +
901 | 'with(obj||{}){__p.push(\'' +
902 | str.replace(/\\/g, '\\\\')
903 | .replace(/'/g, "\\'")
904 | .replace(c.escape, function(match, code) {
905 | return "',_.escape(" + code.replace(/\\'/g, "'") + "),'";
906 | })
907 | .replace(c.interpolate, function(match, code) {
908 | return "'," + code.replace(/\\'/g, "'") + ",'";
909 | })
910 | .replace(c.evaluate || null, function(match, code) {
911 | return "');" + code.replace(/\\'/g, "'")
912 | .replace(/[\r\n\t]/g, ' ') + ";__p.push('";
913 | })
914 | .replace(/\r/g, '\\r')
915 | .replace(/\n/g, '\\n')
916 | .replace(/\t/g, '\\t')
917 | + "');}return __p.join('');";
918 | var func = new Function('obj', '_', tmpl);
919 | if (data) return func(data, _);
920 | return function(data) {
921 | return func.call(this, data, _);
922 | };
923 | };
924 |
925 | // The OOP Wrapper
926 | // ---------------
927 |
928 | // If Underscore is called as a function, it returns a wrapped object that
929 | // can be used OO-style. This wrapper holds altered versions of all the
930 | // underscore functions. Wrapped objects may be chained.
931 | var wrapper = function(obj) { this._wrapped = obj; };
932 |
933 | // Expose `wrapper.prototype` as `_.prototype`
934 | _.prototype = wrapper.prototype;
935 |
936 | // Helper function to continue chaining intermediate results.
937 | var result = function(obj, chain) {
938 | return chain ? _(obj).chain() : obj;
939 | };
940 |
941 | // A method to easily add functions to the OOP wrapper.
942 | var addToWrapper = function(name, func) {
943 | wrapper.prototype[name] = function() {
944 | var args = slice.call(arguments);
945 | unshift.call(args, this._wrapped);
946 | return result(func.apply(_, args), this._chain);
947 | };
948 | };
949 |
950 | // Add all of the Underscore functions to the wrapper object.
951 | _.mixin(_);
952 |
953 | // Add all mutator Array functions to the wrapper.
954 | each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) {
955 | var method = ArrayProto[name];
956 | wrapper.prototype[name] = function() {
957 | method.apply(this._wrapped, arguments);
958 | return result(this._wrapped, this._chain);
959 | };
960 | });
961 |
962 | // Add all accessor Array functions to the wrapper.
963 | each(['concat', 'join', 'slice'], function(name) {
964 | var method = ArrayProto[name];
965 | wrapper.prototype[name] = function() {
966 | return result(method.apply(this._wrapped, arguments), this._chain);
967 | };
968 | });
969 |
970 | // Start chaining a wrapped Underscore object.
971 | wrapper.prototype.chain = function() {
972 | this._chain = true;
973 | return this;
974 | };
975 |
976 | // Extracts the result from a wrapped and chained object.
977 | wrapper.prototype.value = function() {
978 | return this._wrapped;
979 | };
980 |
981 | }).call(this);
982 |
--------------------------------------------------------------------------------
/client/js/libs/backbone.js:
--------------------------------------------------------------------------------
1 | // Backbone.js 0.5.3
2 | // (c) 2010 Jeremy Ashkenas, DocumentCloud Inc.
3 | // Backbone may be freely distributed under the MIT license.
4 | // For all details and documentation:
5 | // http://documentcloud.github.com/backbone
6 |
7 | // Use a factory function to attach Backbone properties to an exports value.
8 | // Code at the end of this file creates the right define, require and exports
9 | // values to allow Backbone to run in a CommonJS or AMD container or in the
10 | // default browser environment.
11 | (function(root, define){ define('backbone', function(require, exports) {
12 |
13 | // Initial Setup
14 | // -------------
15 |
16 | // Save the previous value of the `Backbone` variable.
17 | var previousBackbone = root.Backbone;
18 |
19 | // The top-level namespace. All public Backbone classes and modules will
20 | // be attached to this.
21 | var Backbone = exports;
22 |
23 | // Current version of the library. Keep in sync with `package.json`.
24 | Backbone.VERSION = '0.5.3';
25 |
26 | // Require Underscore.
27 | var _ = require('underscore');
28 |
29 | // The DOM/Ajax library used internally by Backbone. It can be set to any
30 | // library that supports the portions of the jQuery API used by Backbone.
31 | // In the browser, by default Backbone looks for a global jQuery, Zepto or Ender.
32 | var $ = require('jquery');
33 |
34 | // Runs Backbone.js in *noConflict* mode, returning the `Backbone` variable
35 | // to its previous owner. Returns a reference to this Backbone object.
36 | Backbone.noConflict = function() {
37 | root.Backbone = previousBackbone;
38 | return exports;
39 | };
40 |
41 | // Turn on `emulateHTTP` to support legacy HTTP servers. Setting this option will
42 | // fake `"PUT"` and `"DELETE"` requests via the `_method` parameter and set a
43 | // `X-Http-Method-Override` header.
44 | Backbone.emulateHTTP = false;
45 |
46 | // Turn on `emulateJSON` to support legacy servers that can't deal with direct
47 | // `application/json` requests ... will encode the body as
48 | // `application/x-www-form-urlencoded` instead and will send the model in a
49 | // form param named `model`.
50 | Backbone.emulateJSON = false;
51 |
52 | // Backbone.Events
53 | // -----------------
54 |
55 | // A module that can be mixed in to *any object* in order to provide it with
56 | // custom events. You may `bind` or `unbind` a callback function to an event;
57 | // `trigger`-ing an event fires all callbacks in succession.
58 | //
59 | // var object = {};
60 | // _.extend(object, Backbone.Events);
61 | // object.bind('expand', function(){ alert('expanded'); });
62 | // object.trigger('expand');
63 | //
64 | Backbone.Events = {
65 |
66 | // Bind an event, specified by a string name, `ev`, to a `callback` function.
67 | // Passing `"all"` will bind the callback to all events fired.
68 | bind : function(ev, callback, context) {
69 | var calls = this._callbacks || (this._callbacks = {});
70 | var list = calls[ev] || (calls[ev] = []);
71 | list.push([callback, context]);
72 | return this;
73 | },
74 |
75 | // Remove one or many callbacks. If `callback` is null, removes all
76 | // callbacks for the event. If `ev` is null, removes all bound callbacks
77 | // for all events.
78 | unbind : function(ev, callback) {
79 | var calls;
80 | if (!ev) {
81 | this._callbacks = {};
82 | } else if (calls = this._callbacks) {
83 | if (!callback) {
84 | calls[ev] = [];
85 | } else {
86 | var list = calls[ev];
87 | if (!list) return this;
88 | for (var i = 0, l = list.length; i < l; i++) {
89 | if (list[i] && callback === list[i][0]) {
90 | list[i] = null;
91 | break;
92 | }
93 | }
94 | }
95 | }
96 | return this;
97 | },
98 |
99 | // Trigger an event, firing all bound callbacks. Callbacks are passed the
100 | // same arguments as `trigger` is, apart from the event name.
101 | // Listening for `"all"` passes the true event name as the first argument.
102 | trigger : function(eventName) {
103 | var list, calls, ev, callback, args;
104 | var both = 2;
105 | if (!(calls = this._callbacks)) return this;
106 | while (both--) {
107 | ev = both ? eventName : 'all';
108 | if (list = calls[ev]) {
109 | for (var i = 0, l = list.length; i < l; i++) {
110 | if (!(callback = list[i])) {
111 | list.splice(i, 1); i--; l--;
112 | } else {
113 | args = both ? Array.prototype.slice.call(arguments, 1) : arguments;
114 | callback[0].apply(callback[1] || this, args);
115 | }
116 | }
117 | }
118 | }
119 | return this;
120 | }
121 |
122 | };
123 |
124 | // Backbone.Model
125 | // --------------
126 |
127 | // Create a new model, with defined attributes. A client id (`cid`)
128 | // is automatically generated and assigned for you.
129 | Backbone.Model = function(attributes, options) {
130 | var defaults;
131 | attributes || (attributes = {});
132 | if (defaults = this.defaults) {
133 | if (_.isFunction(defaults)) defaults = defaults.call(this);
134 | attributes = _.extend({}, defaults, attributes);
135 | }
136 | this.attributes = {};
137 | this._escapedAttributes = {};
138 | this.cid = _.uniqueId('c');
139 | this.set(attributes, {silent : true});
140 | this._changed = false;
141 | this._previousAttributes = _.clone(this.attributes);
142 | if (options && options.collection) this.collection = options.collection;
143 | this.initialize(attributes, options);
144 | };
145 |
146 | // Attach all inheritable methods to the Model prototype.
147 | _.extend(Backbone.Model.prototype, Backbone.Events, {
148 |
149 | // Has the item been changed since the last `"change"` event?
150 | _changed : false,
151 |
152 | // The default name for the JSON `id` attribute is `"id"`. MongoDB and
153 | // CouchDB users may want to set this to `"_id"`.
154 | idAttribute : 'id',
155 |
156 | // Initialize is an empty function by default. Override it with your own
157 | // initialization logic.
158 | initialize : function(){},
159 |
160 | // Return a copy of the model's `attributes` object.
161 | toJSON : function() {
162 | return _.clone(this.attributes);
163 | },
164 |
165 | // Get the value of an attribute.
166 | get : function(attr) {
167 | return this.attributes[attr];
168 | },
169 |
170 | // Get the HTML-escaped value of an attribute.
171 | escape : function(attr) {
172 | var html;
173 | if (html = this._escapedAttributes[attr]) return html;
174 | var val = this.attributes[attr];
175 | return this._escapedAttributes[attr] = escapeHTML(val == null ? '' : '' + val);
176 | },
177 |
178 | // Returns `true` if the attribute contains a value that is not null
179 | // or undefined.
180 | has : function(attr) {
181 | return this.attributes[attr] != null;
182 | },
183 |
184 | // Set a hash of model attributes on the object, firing `"change"` unless you
185 | // choose to silence it.
186 | set : function(attrs, options) {
187 |
188 | // Extract attributes and options.
189 | options || (options = {});
190 | if (!attrs) return this;
191 | if (attrs.attributes) attrs = attrs.attributes;
192 | var now = this.attributes, escaped = this._escapedAttributes;
193 |
194 | // Run validation.
195 | if (!options.silent && this.validate && !this._performValidation(attrs, options)) return false;
196 |
197 | // Check for changes of `id`.
198 | if (this.idAttribute in attrs) this.id = attrs[this.idAttribute];
199 |
200 | // We're about to start triggering change events.
201 | var alreadyChanging = this._changing;
202 | this._changing = true;
203 |
204 | // Update attributes.
205 | for (var attr in attrs) {
206 | var val = attrs[attr];
207 | if (!_.isEqual(now[attr], val)) {
208 | now[attr] = val;
209 | delete escaped[attr];
210 | this._changed = true;
211 | if (!options.silent) this.trigger('change:' + attr, this, val, options);
212 | }
213 | }
214 |
215 | // Fire the `"change"` event, if the model has been changed.
216 | if (!alreadyChanging && !options.silent && this._changed) this.change(options);
217 | this._changing = false;
218 | return this;
219 | },
220 |
221 | // Remove an attribute from the model, firing `"change"` unless you choose
222 | // to silence it. `unset` is a noop if the attribute doesn't exist.
223 | unset : function(attr, options) {
224 | if (!(attr in this.attributes)) return this;
225 | options || (options = {});
226 | var value = this.attributes[attr];
227 |
228 | // Run validation.
229 | var validObj = {};
230 | validObj[attr] = void 0;
231 | if (!options.silent && this.validate && !this._performValidation(validObj, options)) return false;
232 |
233 | // changedAttributes needs to know if an attribute has been unset.
234 | (this._unsetAttributes || (this._unsetAttributes = [])).push(attr);
235 |
236 | // Remove the attribute.
237 | delete this.attributes[attr];
238 | delete this._escapedAttributes[attr];
239 | if (attr == this.idAttribute) delete this.id;
240 | this._changed = true;
241 | if (!options.silent) {
242 | this.trigger('change:' + attr, this, void 0, options);
243 | this.change(options);
244 | }
245 | return this;
246 | },
247 |
248 | // Clear all attributes on the model, firing `"change"` unless you choose
249 | // to silence it.
250 | clear : function(options) {
251 | options || (options = {});
252 | var attr;
253 | var old = this.attributes;
254 |
255 | // Run validation.
256 | var validObj = {};
257 | for (attr in old) validObj[attr] = void 0;
258 | if (!options.silent && this.validate && !this._performValidation(validObj, options)) return false;
259 |
260 | this.attributes = {};
261 | this._escapedAttributes = {};
262 | this._changed = true;
263 | if (!options.silent) {
264 | for (attr in old) {
265 | this.trigger('change:' + attr, this, void 0, options);
266 | }
267 | this.change(options);
268 | }
269 | return this;
270 | },
271 |
272 | // Fetch the model from the server. If the server's representation of the
273 | // model differs from its current attributes, they will be overriden,
274 | // triggering a `"change"` event.
275 | fetch : function(options) {
276 | options || (options = {});
277 | var model = this;
278 | var success = options.success;
279 | options.success = function(resp, status, xhr) {
280 | if (!model.set(model.parse(resp, xhr), options)) return false;
281 | if (success) success(model, resp);
282 | };
283 | options.error = wrapError(options.error, model, options);
284 | return (this.sync || Backbone.sync).call(this, 'read', this, options);
285 | },
286 |
287 | // Set a hash of model attributes, and sync the model to the server.
288 | // If the server returns an attributes hash that differs, the model's
289 | // state will be `set` again.
290 | save : function(attrs, options) {
291 | options || (options = {});
292 | if (attrs && !this.set(attrs, options)) return false;
293 | var model = this;
294 | var success = options.success;
295 | options.success = function(resp, status, xhr) {
296 | if (!model.set(model.parse(resp, xhr), options)) return false;
297 | if (success) success(model, resp, xhr);
298 | };
299 | options.error = wrapError(options.error, model, options);
300 | var method = this.isNew() ? 'create' : 'update';
301 | return (this.sync || Backbone.sync).call(this, method, this, options);
302 | },
303 |
304 | // Destroy this model on the server if it was already persisted. Upon success, the model is removed
305 | // from its collection, if it has one.
306 | destroy : function(options) {
307 | options || (options = {});
308 | if (this.isNew()) return this.trigger('destroy', this, this.collection, options);
309 | var model = this;
310 | var success = options.success;
311 | options.success = function(resp) {
312 | model.trigger('destroy', model, model.collection, options);
313 | if (success) success(model, resp);
314 | };
315 | options.error = wrapError(options.error, model, options);
316 | return (this.sync || Backbone.sync).call(this, 'delete', this, options);
317 | },
318 |
319 | // Default URL for the model's representation on the server -- if you're
320 | // using Backbone's restful methods, override this to change the endpoint
321 | // that will be called.
322 | url : function() {
323 | var base = getUrl(this.collection) || this.urlRoot || urlError();
324 | if (this.isNew()) return base;
325 | return base + (base.charAt(base.length - 1) == '/' ? '' : '/') + encodeURIComponent(this.id);
326 | },
327 |
328 | // **parse** converts a response into the hash of attributes to be `set` on
329 | // the model. The default implementation is just to pass the response along.
330 | parse : function(resp, xhr) {
331 | return resp;
332 | },
333 |
334 | // Create a new model with identical attributes to this one.
335 | clone : function() {
336 | return new this.constructor(this);
337 | },
338 |
339 | // A model is new if it has never been saved to the server, and lacks an id.
340 | isNew : function() {
341 | return this.id == null;
342 | },
343 |
344 | // Call this method to manually fire a `change` event for this model.
345 | // Calling this will cause all objects observing the model to update.
346 | change : function(options) {
347 | this.trigger('change', this, options);
348 | this._previousAttributes = _.clone(this.attributes);
349 | this._unsetAttributes = null;
350 | this._changed = false;
351 | },
352 |
353 | // Determine if the model has changed since the last `"change"` event.
354 | // If you specify an attribute name, determine if that attribute has changed.
355 | hasChanged : function(attr) {
356 | if (attr) return this._previousAttributes[attr] != this.attributes[attr];
357 | return this._changed;
358 | },
359 |
360 | // Return an object containing all the attributes that have changed, or false
361 | // if there are no changed attributes. Useful for determining what parts of a
362 | // view need to be updated and/or what attributes need to be persisted to
363 | // the server. Unset attributes will be set to undefined.
364 | changedAttributes : function(now) {
365 | now || (now = this.attributes);
366 | var old = this._previousAttributes, unset = this._unsetAttributes;
367 |
368 | var changed = false;
369 | for (var attr in now) {
370 | if (!_.isEqual(old[attr], now[attr])) {
371 | changed || (changed = {});
372 | changed[attr] = now[attr];
373 | }
374 | }
375 |
376 | if (unset) {
377 | changed || (changed = {});
378 | var len = unset.length;
379 | while (len--) changed[unset[len]] = void 0;
380 | }
381 |
382 | return changed;
383 | },
384 |
385 | // Get the previous value of an attribute, recorded at the time the last
386 | // `"change"` event was fired.
387 | previous : function(attr) {
388 | if (!attr || !this._previousAttributes) return null;
389 | return this._previousAttributes[attr];
390 | },
391 |
392 | // Get all of the attributes of the model at the time of the previous
393 | // `"change"` event.
394 | previousAttributes : function() {
395 | return _.clone(this._previousAttributes);
396 | },
397 |
398 | // Run validation against a set of incoming attributes, returning `true`
399 | // if all is well. If a specific `error` callback has been passed,
400 | // call that instead of firing the general `"error"` event.
401 | _performValidation : function(attrs, options) {
402 | var error = this.validate(attrs);
403 | if (error) {
404 | if (options.error) {
405 | options.error(this, error, options);
406 | } else {
407 | this.trigger('error', this, error, options);
408 | }
409 | return false;
410 | }
411 | return true;
412 | }
413 |
414 | });
415 |
416 | // Backbone.Collection
417 | // -------------------
418 |
419 | // Provides a standard collection class for our sets of models, ordered
420 | // or unordered. If a `comparator` is specified, the Collection will maintain
421 | // its models in sort order, as they're added and removed.
422 | Backbone.Collection = function(models, options) {
423 | options || (options = {});
424 | if (options.comparator) this.comparator = options.comparator;
425 | _.bindAll(this, '_onModelEvent', '_removeReference');
426 | this._reset();
427 | if (models) this.reset(models, {silent: true});
428 | this.initialize.apply(this, arguments);
429 | };
430 |
431 | // Define the Collection's inheritable methods.
432 | _.extend(Backbone.Collection.prototype, Backbone.Events, {
433 |
434 | // The default model for a collection is just a **Backbone.Model**.
435 | // This should be overridden in most cases.
436 | model : Backbone.Model,
437 |
438 | // Initialize is an empty function by default. Override it with your own
439 | // initialization logic.
440 | initialize : function(){},
441 |
442 | // The JSON representation of a Collection is an array of the
443 | // models' attributes.
444 | toJSON : function() {
445 | return this.map(function(model){ return model.toJSON(); });
446 | },
447 |
448 | // Add a model, or list of models to the set. Pass **silent** to avoid
449 | // firing the `added` event for every new model.
450 | add : function(models, options) {
451 | if (_.isArray(models)) {
452 | for (var i = 0, l = models.length; i < l; i++) {
453 | this._add(models[i], options);
454 | }
455 | } else {
456 | this._add(models, options);
457 | }
458 | return this;
459 | },
460 |
461 | // Remove a model, or a list of models from the set. Pass silent to avoid
462 | // firing the `removed` event for every model removed.
463 | remove : function(models, options) {
464 | if (_.isArray(models)) {
465 | for (var i = 0, l = models.length; i < l; i++) {
466 | this._remove(models[i], options);
467 | }
468 | } else {
469 | this._remove(models, options);
470 | }
471 | return this;
472 | },
473 |
474 | // Get a model from the set by id.
475 | get : function(id) {
476 | if (id == null) return null;
477 | return this._byId[id.id != null ? id.id : id];
478 | },
479 |
480 | // Get a model from the set by client id.
481 | getByCid : function(cid) {
482 | return cid && this._byCid[cid.cid || cid];
483 | },
484 |
485 | // Get the model at the given index.
486 | at: function(index) {
487 | return this.models[index];
488 | },
489 |
490 | // Force the collection to re-sort itself. You don't need to call this under normal
491 | // circumstances, as the set will maintain sort order as each item is added.
492 | sort : function(options) {
493 | options || (options = {});
494 | if (!this.comparator) throw new Error('Cannot sort a set without a comparator');
495 | this.models = this.sortBy(this.comparator);
496 | if (!options.silent) this.trigger('reset', this, options);
497 | return this;
498 | },
499 |
500 | // Pluck an attribute from each model in the collection.
501 | pluck : function(attr) {
502 | return _.map(this.models, function(model){ return model.get(attr); });
503 | },
504 |
505 | // When you have more items than you want to add or remove individually,
506 | // you can reset the entire set with a new list of models, without firing
507 | // any `added` or `removed` events. Fires `reset` when finished.
508 | reset : function(models, options) {
509 | models || (models = []);
510 | options || (options = {});
511 | this.each(this._removeReference);
512 | this._reset();
513 | this.add(models, {silent: true});
514 | if (!options.silent) this.trigger('reset', this, options);
515 | return this;
516 | },
517 |
518 | // Fetch the default set of models for this collection, resetting the
519 | // collection when they arrive. If `add: true` is passed, appends the
520 | // models to the collection instead of resetting.
521 | fetch : function(options) {
522 | options || (options = {});
523 | var collection = this;
524 | var success = options.success;
525 | options.success = function(resp, status, xhr) {
526 | collection[options.add ? 'add' : 'reset'](collection.parse(resp, xhr), options);
527 | if (success) success(collection, resp);
528 | };
529 | options.error = wrapError(options.error, collection, options);
530 | return (this.sync || Backbone.sync).call(this, 'read', this, options);
531 | },
532 |
533 | // Create a new instance of a model in this collection. After the model
534 | // has been created on the server, it will be added to the collection.
535 | // Returns the model, or 'false' if validation on a new model fails.
536 | create : function(model, options) {
537 | var coll = this;
538 | options || (options = {});
539 | model = this._prepareModel(model, options);
540 | if (!model) return false;
541 | var success = options.success;
542 | options.success = function(nextModel, resp, xhr) {
543 | coll.add(nextModel, options);
544 | if (success) success(nextModel, resp, xhr);
545 | };
546 | model.save(null, options);
547 | return model;
548 | },
549 |
550 | // **parse** converts a response into a list of models to be added to the
551 | // collection. The default implementation is just to pass it through.
552 | parse : function(resp, xhr) {
553 | return resp;
554 | },
555 |
556 | // Proxy to _'s chain. Can't be proxied the same way the rest of the
557 | // underscore methods are proxied because it relies on the underscore
558 | // constructor.
559 | chain: function () {
560 | return _(this.models).chain();
561 | },
562 |
563 | // Reset all internal state. Called when the collection is reset.
564 | _reset : function(options) {
565 | this.length = 0;
566 | this.models = [];
567 | this._byId = {};
568 | this._byCid = {};
569 | },
570 |
571 | // Prepare a model to be added to this collection
572 | _prepareModel: function(model, options) {
573 | if (!(model instanceof Backbone.Model)) {
574 | var attrs = model;
575 | model = new this.model(attrs, {collection: this});
576 | if (model.validate && !model._performValidation(model.attributes, options)) model = false;
577 | } else if (!model.collection) {
578 | model.collection = this;
579 | }
580 | return model;
581 | },
582 |
583 | // Internal implementation of adding a single model to the set, updating
584 | // hash indexes for `id` and `cid` lookups.
585 | // Returns the model, or 'false' if validation on a new model fails.
586 | _add : function(model, options) {
587 | options || (options = {});
588 | model = this._prepareModel(model, options);
589 | if (!model) return false;
590 | var already = this.getByCid(model);
591 | if (already) throw new Error(["Can't add the same model to a set twice", already.id]);
592 | this._byId[model.id] = model;
593 | this._byCid[model.cid] = model;
594 | var index = options.at != null ? options.at :
595 | this.comparator ? this.sortedIndex(model, this.comparator) :
596 | this.length;
597 | this.models.splice(index, 0, model);
598 | model.bind('all', this._onModelEvent);
599 | this.length++;
600 | options.index = index;
601 | if (!options.silent) model.trigger('add', model, this, options);
602 | return model;
603 | },
604 |
605 | // Internal implementation of removing a single model from the set, updating
606 | // hash indexes for `id` and `cid` lookups.
607 | _remove : function(model, options) {
608 | options || (options = {});
609 | model = this.getByCid(model) || this.get(model);
610 | if (!model) return null;
611 | delete this._byId[model.id];
612 | delete this._byCid[model.cid];
613 | var index = this.indexOf(model);
614 | this.models.splice(index, 1);
615 | this.length--;
616 | options.index = index;
617 | if (!options.silent) model.trigger('remove', model, this, options);
618 | this._removeReference(model);
619 | return model;
620 | },
621 |
622 | // Internal method to remove a model's ties to a collection.
623 | _removeReference : function(model) {
624 | if (this == model.collection) {
625 | delete model.collection;
626 | }
627 | model.unbind('all', this._onModelEvent);
628 | },
629 |
630 | // Internal method called every time a model in the set fires an event.
631 | // Sets need to update their indexes when models change ids. All other
632 | // events simply proxy through. "add" and "remove" events that originate
633 | // in other collections are ignored.
634 | _onModelEvent : function(ev, model, collection, options) {
635 | if ((ev == 'add' || ev == 'remove') && collection != this) return;
636 | if (ev == 'destroy') {
637 | this._remove(model, options);
638 | }
639 | if (model && ev === 'change:' + model.idAttribute) {
640 | delete this._byId[model.previous(model.idAttribute)];
641 | this._byId[model.id] = model;
642 | }
643 | this.trigger.apply(this, arguments);
644 | }
645 |
646 | });
647 |
648 | // Underscore methods that we want to implement on the Collection.
649 | var methods = ['forEach', 'each', 'map', 'reduce', 'reduceRight', 'find', 'detect',
650 | 'filter', 'select', 'reject', 'every', 'all', 'some', 'any', 'include',
651 | 'contains', 'invoke', 'max', 'min', 'sortBy', 'sortedIndex', 'toArray', 'size',
652 | 'first', 'rest', 'last', 'without', 'indexOf', 'lastIndexOf', 'isEmpty', 'groupBy'];
653 |
654 | // Mix in each Underscore method as a proxy to `Collection#models`.
655 | _.each(methods, function(method) {
656 | Backbone.Collection.prototype[method] = function() {
657 | return _[method].apply(_, [this.models].concat(_.toArray(arguments)));
658 | };
659 | });
660 |
661 | // Backbone.View
662 | // -------------
663 |
664 | // Creating a Backbone.View creates its initial element outside of the DOM,
665 | // if an existing element is not provided...
666 | Backbone.View = function(options) {
667 | this.cid = _.uniqueId('view');
668 | this._configure(options || {});
669 | this._ensureElement();
670 | this.delegateEvents();
671 | this.initialize.apply(this, arguments);
672 | };
673 |
674 | // Element lookup, scoped to DOM elements within the current view.
675 | // This should be prefered to global lookups, if you're dealing with
676 | // a specific view.
677 | var selectorDelegate = function(selector) {
678 | return $(selector, this.el);
679 | };
680 |
681 | // Cached regex to split keys for `delegate`.
682 | var eventSplitter = /^(\S+)\s*(.*)$/;
683 |
684 | // List of view options to be merged as properties.
685 | var viewOptions = ['model', 'collection', 'el', 'id', 'attributes', 'className', 'tagName'];
686 |
687 | // Set up all inheritable **Backbone.View** properties and methods.
688 | _.extend(Backbone.View.prototype, Backbone.Events, {
689 |
690 | // The default `tagName` of a View's element is `"div"`.
691 | tagName : 'div',
692 |
693 | // Attach the `selectorDelegate` function as the `$` property.
694 | $ : selectorDelegate,
695 |
696 | // Initialize is an empty function by default. Override it with your own
697 | // initialization logic.
698 | initialize : function(){},
699 |
700 | // **render** is the core function that your view should override, in order
701 | // to populate its element (`this.el`), with the appropriate HTML. The
702 | // convention is for **render** to always return `this`.
703 | render : function() {
704 | return this;
705 | },
706 |
707 | // Remove this view from the DOM. Note that the view isn't present in the
708 | // DOM by default, so calling this method may be a no-op.
709 | remove : function() {
710 | $(this.el).remove();
711 | return this;
712 | },
713 |
714 | // For small amounts of DOM Elements, where a full-blown template isn't
715 | // needed, use **make** to manufacture elements, one at a time.
716 | //
717 | // var el = this.make('li', {'class': 'row'}, this.model.escape('title'));
718 | //
719 | make : function(tagName, attributes, content) {
720 | var el = document.createElement(tagName);
721 | if (attributes) $(el).attr(attributes);
722 | if (content) $(el).html(content);
723 | return el;
724 | },
725 |
726 | // Set callbacks, where `this.events` is a hash of
727 | //
728 | // *{"event selector": "callback"}*
729 | //
730 | // {
731 | // 'mousedown .title': 'edit',
732 | // 'click .button': 'save'
733 | // }
734 | //
735 | // pairs. Callbacks will be bound to the view, with `this` set properly.
736 | // Uses event delegation for efficiency.
737 | // Omitting the selector binds the event to `this.el`.
738 | // This only works for delegate-able events: not `focus`, `blur`, and
739 | // not `change`, `submit`, and `reset` in Internet Explorer.
740 | delegateEvents : function(events) {
741 | if (!(events || (events = this.events))) return;
742 | if (_.isFunction(events)) events = events.call(this);
743 | this.undelegateEvents();
744 | for (var key in events) {
745 | var method = this[events[key]];
746 | if (!method) throw new Error('Event "' + events[key] + '" does not exist');
747 | var match = key.match(eventSplitter);
748 | var eventName = match[1], selector = match[2];
749 | method = _.bind(method, this);
750 | eventName += '.delegateEvents' + this.cid;
751 | if (selector === '') {
752 | $(this.el).bind(eventName, method);
753 | } else {
754 | $(this.el).delegate(selector, eventName, method);
755 | }
756 | }
757 | },
758 |
759 | // Clears all callbacks previously bound to the view with `delegateEvents`.
760 | undelegateEvents: function() {
761 | $(this.el).unbind('.delegateEvents' + this.cid);
762 | },
763 |
764 | // Performs the initial configuration of a View with a set of options.
765 | // Keys with special meaning *(model, collection, id, className)*, are
766 | // attached directly to the view.
767 | _configure : function(options) {
768 | if (this.options) options = _.extend({}, this.options, options);
769 | for (var i = 0, l = viewOptions.length; i < l; i++) {
770 | var attr = viewOptions[i];
771 | if (options[attr]) this[attr] = options[attr];
772 | }
773 | this.options = options;
774 | },
775 |
776 | // Ensure that the View has a DOM element to render into.
777 | // If `this.el` is a string, pass it through `$()`, take the first
778 | // matching element, and re-assign it to `el`. Otherwise, create
779 | // an element from the `id`, `className` and `tagName` properties.
780 | _ensureElement : function() {
781 | if (!this.el) {
782 | var attrs = this.attributes || {};
783 | if (this.id) attrs.id = this.id;
784 | if (this.className) attrs['class'] = this.className;
785 | this.el = this.make(this.tagName, attrs);
786 | } else if (_.isString(this.el)) {
787 | this.el = $(this.el).get(0);
788 | }
789 | }
790 |
791 | });
792 |
793 | // The self-propagating extend function that Backbone classes use.
794 | var extend = function (protoProps, classProps) {
795 | var child = inherits(this, protoProps, classProps);
796 | child.extend = this.extend;
797 | return child;
798 | };
799 |
800 | // Set up inheritance for the model, collection, and view.
801 | Backbone.Model.extend = Backbone.Collection.extend =
802 | Backbone.View.extend = extend;
803 |
804 | // Map from CRUD to HTTP for our default `Backbone.sync` implementation.
805 | var methodMap = {
806 | 'create': 'POST',
807 | 'update': 'PUT',
808 | 'delete': 'DELETE',
809 | 'read' : 'GET'
810 | };
811 |
812 | // Backbone.sync
813 | // -------------
814 |
815 | // Override this function to change the manner in which Backbone persists
816 | // models to the server. You will be passed the type of request, and the
817 | // model in question. By default, makes a RESTful Ajax request
818 | // to the model's `url()`. Some possible customizations could be:
819 | //
820 | // * Use `setTimeout` to batch rapid-fire updates into a single request.
821 | // * Send up the models as XML instead of JSON.
822 | // * Persist models via WebSockets instead of Ajax.
823 | //
824 | // Turn on `Backbone.emulateHTTP` in order to send `PUT` and `DELETE` requests
825 | // as `POST`, with a `_method` parameter containing the true HTTP method,
826 | // as well as all requests with the body as `application/x-www-form-urlencoded` instead of
827 | // `application/json` with the model in a param named `model`.
828 | // Useful when interfacing with server-side languages like **PHP** that make
829 | // it difficult to read the body of `PUT` requests.
830 | Backbone.sync = function(method, model, options) {
831 | var type = methodMap[method];
832 |
833 | // Default JSON-request options.
834 | var params = {type : type, dataType : 'json'};
835 |
836 | // Ensure that we have a URL.
837 | if (!options.url) {
838 | params.url = getUrl(model) || urlError();
839 | }
840 |
841 | // Ensure that we have the appropriate request data.
842 | if (!options.data && model && (method == 'create' || method == 'update')) {
843 | params.contentType = 'application/json';
844 | params.data = JSON.stringify(model.toJSON());
845 | }
846 |
847 | // For older servers, emulate JSON by encoding the request into an HTML-form.
848 | if (Backbone.emulateJSON) {
849 | params.contentType = 'application/x-www-form-urlencoded';
850 | params.data = params.data ? {model : params.data} : {};
851 | }
852 |
853 | // For older servers, emulate HTTP by mimicking the HTTP method with `_method`
854 | // And an `X-HTTP-Method-Override` header.
855 | if (Backbone.emulateHTTP) {
856 | if (type === 'PUT' || type === 'DELETE') {
857 | if (Backbone.emulateJSON) params.data._method = type;
858 | params.type = 'POST';
859 | params.beforeSend = function(xhr) {
860 | xhr.setRequestHeader('X-HTTP-Method-Override', type);
861 | };
862 | }
863 | }
864 |
865 | // Don't process data on a non-GET request.
866 | if (params.type !== 'GET' && !Backbone.emulateJSON) {
867 | params.processData = false;
868 | }
869 |
870 | // Make the request, allowing the user to override any Ajax options.
871 | return $.ajax(_.extend(params, options));
872 | };
873 |
874 | // Helpers
875 | // -------
876 |
877 | // Shared empty constructor function to aid in prototype-chain creation.
878 | var ctor = function(){};
879 |
880 | // Helper function to correctly set up the prototype chain, for subclasses.
881 | // Similar to `goog.inherits`, but uses a hash of prototype properties and
882 | // class properties to be extended.
883 | var inherits = function(parent, protoProps, staticProps) {
884 | var child;
885 |
886 | // The constructor function for the new subclass is either defined by you
887 | // (the "constructor" property in your `extend` definition), or defaulted
888 | // by us to simply call `super()`.
889 | if (protoProps && protoProps.hasOwnProperty('constructor')) {
890 | child = protoProps.constructor;
891 | } else {
892 | child = function(){ return parent.apply(this, arguments); };
893 | }
894 |
895 | // Inherit class (static) properties from parent.
896 | _.extend(child, parent);
897 |
898 | // Set the prototype chain to inherit from `parent`, without calling
899 | // `parent`'s constructor function.
900 | ctor.prototype = parent.prototype;
901 | child.prototype = new ctor();
902 |
903 | // Add prototype properties (instance properties) to the subclass,
904 | // if supplied.
905 | if (protoProps) _.extend(child.prototype, protoProps);
906 |
907 | // Add static properties to the constructor function, if supplied.
908 | if (staticProps) _.extend(child, staticProps);
909 |
910 | // Correctly set child's `prototype.constructor`.
911 | child.prototype.constructor = child;
912 |
913 | // Set a convenience property in case the parent's prototype is needed later.
914 | child.__super__ = parent.prototype;
915 |
916 | return child;
917 | };
918 |
919 | // Helper function to get a URL from a Model or Collection as a property
920 | // or as a function.
921 | var getUrl = function(object) {
922 | if (!(object && object.url)) return null;
923 | return _.isFunction(object.url) ? object.url() : object.url;
924 | };
925 |
926 | // Throw an error when a URL is needed, and none is supplied.
927 | var urlError = function() {
928 | throw new Error('A "url" property or function must be specified');
929 | };
930 |
931 | // Wrap an optional error callback with a fallback error event.
932 | var wrapError = function(onError, model, options) {
933 | return function(model, resp) {
934 | var resp = model === model ? resp : model;
935 | if (onError) {
936 | onError(model, resp, options);
937 | } else {
938 | model.trigger('error', model, resp, options);
939 | }
940 | };
941 | };
942 |
943 | // Helper function to escape a string for HTML rendering.
944 | var escapeHTML = function(string) {
945 | return string.replace(/&(?!\w+;|#\d+;|#x[\da-f]+;)/gi, '&').replace(//g, '>').replace(/"/g, '"').replace(/'/g, ''').replace(/\//g,'/');
946 | };
947 |
948 | })}).call(this, this, typeof define === 'function' && define.amd ? define : function (id, factory) {
949 |
950 | if (typeof exports !== 'undefined') {
951 | // CommonJS has require and exports, use them and execute
952 | // the factory function immediately. Provide a wrapper
953 | // for require to deal with jQuery.
954 | factory(function(id) {
955 | // jQuery most likely cannot be loaded
956 | // in a CommonJS environment, unless the developer
957 | // also uses a browser shim like jsdom. Allow
958 | // for that possibility, but do not blow
959 | // up if it does not work. Use of a
960 | // try/catch has precedent in Node modules
961 | // for this kind of situation.
962 | try {
963 | return require(id);
964 | } catch (e) {
965 | // Do not bother returning a value, just absorb
966 | // the error, the caller will receive undefined
967 | // for the value.
968 | }
969 | }, exports);
970 | } else {
971 | // Plain browser. Grab the global.
972 | var root = this;
973 |
974 | // Create an object to hold the exported properties for Backbone.
975 | // Do not use "exports" for the variable name, since var hoisting
976 | // means it will shadow CommonJS exports in that environmetn.
977 | var exportValue = {};
978 |
979 | // Create a global for Backbone.
980 | // Call the factory function to attach the Backbone
981 | // properties to the exports value.
982 | factory(function(id) {
983 | if (id === 'jquery') {
984 | // Support libraries that support the portions of
985 | // the jQuery API used by Backbone.
986 | return root.jQuery || root.Zepto || root.ender;
987 | } else {
988 | // Only other dependency is underscore.
989 | return root._;
990 | }
991 | }, exportValue);
992 |
993 | // Create the global only after running the factory,
994 | // so that the previousBackbone for noConflict is found correctly.
995 | root.Backbone = exportValue;
996 | }
997 | });
998 |
--------------------------------------------------------------------------------
/client/css/jquery.mobile-1.0.css:
--------------------------------------------------------------------------------
1 | /*
2 | * jQuery Mobile Framework 1.0
3 | * http://jquerymobile.com
4 | *
5 | * Copyright 2011 (c) jQuery Project
6 | * Dual licensed under the MIT or GPL Version 2 licenses.
7 | * http://jquery.org/license
8 | *
9 | */
10 | /* Swatches */
11 |
12 | /* A
13 | -----------------------------------------------------------------------------------------------------------*/
14 |
15 | .ui-bar-a {
16 | border: 1px solid #2A2A2A /*{a-bar-border}*/;
17 | background: #111111 /*{a-bar-background-color}*/;
18 | color: #ffffff /*{a-bar-color}*/;
19 | font-weight: bold;
20 | text-shadow: 0 /*{a-bar-shadow-x}*/ -1px /*{a-bar-shadow-y}*/ 1px /*{a-bar-shadow-radius}*/ #000000 /*{a-bar-shadow-color}*/;
21 | background-image: -webkit-gradient(linear, left top, left bottom, from( #3c3c3c /*{a-bar-background-start}*/), to( #111 /*{a-bar-background-end}*/)); /* Saf4+, Chrome */
22 | background-image: -webkit-linear-gradient(#3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
23 | background-image: -moz-linear-gradient(#3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* FF3.6 */
24 | background-image: -ms-linear-gradient(#3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* IE10 */
25 | background-image: -o-linear-gradient(#3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/); /* Opera 11.10+ */
26 | background-image: linear-gradient(#3c3c3c /*{a-bar-background-start}*/, #111 /*{a-bar-background-end}*/);
27 | }
28 | .ui-bar-a,
29 | .ui-bar-a input,
30 | .ui-bar-a select,
31 | .ui-bar-a textarea,
32 | .ui-bar-a button {
33 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
34 | }
35 | .ui-bar-a .ui-link-inherit {
36 | color: #fff /*{a-bar-color}*/;
37 | }
38 |
39 | .ui-bar-a .ui-link {
40 | color: #7cc4e7 /*{a-bar-link-color}*/;
41 | font-weight: bold;
42 | }
43 |
44 | .ui-bar-a .ui-link:hover {
45 | color: #2489CE /*{a-bar-link-hover}*/;
46 | }
47 |
48 | .ui-bar-a .ui-link:active {
49 | color: #2489CE /*{a-bar-link-active}*/;
50 | }
51 |
52 | .ui-bar-a .ui-link:visited {
53 | color: #2489CE /*{a-bar-link-visited}*/;
54 | }
55 | .ui-body-a,
56 | .ui-dialog.ui-overlay-a {
57 | border: 1px solid #2A2A2A /*{a-body-border}*/;
58 | background: #222222 /*{a-body-background-color}*/;
59 | color: #fff /*{a-body-color}*/;
60 | text-shadow: 0 /*{a-body-shadow-x}*/ 1px /*{a-body-shadow-y}*/ 0 /*{a-body-shadow-radius}*/ #000 /*{a-body-shadow-color}*/;
61 | font-weight: normal;
62 | background-image: -webkit-gradient(linear, left top, left bottom, from( #666 /*{a-body-background-start}*/), to( #222 /*{a-body-background-end}*/)); /* Saf4+, Chrome */
63 | background-image: -webkit-linear-gradient(#666 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
64 | background-image: -moz-linear-gradient(#666 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* FF3.6 */
65 | background-image: -ms-linear-gradient(#666 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* IE10 */
66 | background-image: -o-linear-gradient(#666 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/); /* Opera 11.10+ */
67 | background-image: linear-gradient(#666 /*{a-body-background-start}*/, #222 /*{a-body-background-end}*/);
68 | }
69 | .ui-body-a,
70 | .ui-body-a input,
71 | .ui-body-a select,
72 | .ui-body-a textarea,
73 | .ui-body-a button {
74 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
75 | }
76 | .ui-body-a .ui-link-inherit {
77 | color: #fff /*{a-body-color}*/;
78 | }
79 |
80 | .ui-body-a .ui-link {
81 | color: #2489CE /*{a-body-link-color}*/;
82 | font-weight: bold;
83 | }
84 |
85 | .ui-body-a .ui-link:hover {
86 | color: #2489CE /*{a-body-link-hover}*/;
87 | }
88 |
89 | .ui-body-a .ui-link:active {
90 | color: #2489CE /*{a-body-link-active}*/;
91 | }
92 |
93 | .ui-body-a .ui-link:visited {
94 | color: #2489CE /*{a-body-link-visited}*/;
95 | }
96 |
97 | .ui-btn-up-a {
98 | border: 1px solid #222 /*{a-bup-border}*/;
99 | background: #333333 /*{a-bup-background-color}*/;
100 | font-weight: bold;
101 | color: #fff /*{a-bup-color}*/;
102 | text-shadow: 0 /*{a-bup-shadow-x}*/ -1px /*{a-bup-shadow-y}*/ 1px /*{a-bup-shadow-radius}*/ #000 /*{a-bup-shadow-color}*/;
103 | background-image: -webkit-gradient(linear, left top, left bottom, from( #555 /*{a-bup-background-start}*/), to( #333 /*{a-bup-background-end}*/)); /* Saf4+, Chrome */
104 | background-image: -webkit-linear-gradient(#555 /*{a-bup-background-start}*/, #333 /*{a-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
105 | background-image: -moz-linear-gradient(#555 /*{a-bup-background-start}*/, #333 /*{a-bup-background-end}*/); /* FF3.6 */
106 | background-image: -ms-linear-gradient(#555 /*{a-bup-background-start}*/, #333 /*{a-bup-background-end}*/); /* IE10 */
107 | background-image: -o-linear-gradient(#555 /*{a-bup-background-start}*/, #333 /*{a-bup-background-end}*/); /* Opera 11.10+ */
108 | background-image: linear-gradient(#555 /*{a-bup-background-start}*/, #333 /*{a-bup-background-end}*/);
109 | }
110 | .ui-btn-up-a a.ui-link-inherit {
111 | color: #fff /*{a-bup-color}*/;
112 | }
113 | .ui-btn-hover-a {
114 | border: 1px solid #000 /*{a-bhover-border}*/;
115 | background: #444444 /*{a-bhover-background-color}*/;
116 | font-weight: bold;
117 | color: #fff /*{a-bhover-color}*/;
118 | text-shadow: 0 /*{a-bhover-shadow-x}*/ -1px /*{a-bhover-shadow-y}*/ 1px /*{a-bhover-shadow-radius}*/ #000 /*{a-bhover-shadow-color}*/;
119 | background-image: -webkit-gradient(linear, left top, left bottom, from( #666 /*{a-bhover-background-start}*/), to( #444 /*{a-bhover-background-end}*/)); /* Saf4+, Chrome */
120 | background-image: -webkit-linear-gradient(#666 /*{a-bhover-background-start}*/, #444 /*{a-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
121 | background-image: -moz-linear-gradient(#666 /*{a-bhover-background-start}*/, #444 /*{a-bhover-background-end}*/); /* FF3.6 */
122 | background-image: -ms-linear-gradient(#666 /*{a-bhover-background-start}*/, #444 /*{a-bhover-background-end}*/); /* IE10 */
123 | background-image: -o-linear-gradient(#666 /*{a-bhover-background-start}*/, #444 /*{a-bhover-background-end}*/); /* Opera 11.10+ */
124 | background-image: linear-gradient(#666 /*{a-bhover-background-start}*/, #444 /*{a-bhover-background-end}*/);
125 | }
126 | .ui-btn-hover-a a.ui-link-inherit {
127 | color: #fff /*{a-bhover-color}*/;
128 | }
129 | .ui-btn-down-a {
130 | border: 1px solid #000 /*{a-bdown-border}*/;
131 | background: #3d3d3d /*{a-bdown-background-color}*/;
132 | font-weight: bold;
133 | color: #fff /*{a-bdown-color}*/;
134 | text-shadow: 0 /*{a-bdown-shadow-x}*/ -1px /*{a-bdown-shadow-y}*/ 1px /*{a-bdown-shadow-radius}*/ #000 /*{a-bdown-shadow-color}*/;
135 | background-image: -webkit-gradient(linear, left top, left bottom, from( #333 /*{a-bdown-background-start}*/), to( #5a5a5a /*{a-bdown-background-end}*/)); /* Saf4+, Chrome */
136 | background-image: -webkit-linear-gradient(#333 /*{a-bdown-background-start}*/, #5a5a5a /*{a-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
137 | background-image: -moz-linear-gradient(#333 /*{a-bdown-background-start}*/, #5a5a5a /*{a-bdown-background-end}*/); /* FF3.6 */
138 | background-image: -ms-linear-gradient(#333 /*{a-bdown-background-start}*/, #5a5a5a /*{a-bdown-background-end}*/); /* IE10 */
139 | background-image: -o-linear-gradient(#333 /*{a-bdown-background-start}*/, #5a5a5a /*{a-bdown-background-end}*/); /* Opera 11.10+ */
140 | background-image: linear-gradient(#333 /*{a-bdown-background-start}*/, #5a5a5a /*{a-bdown-background-end}*/);
141 | }
142 | .ui-btn-down-a a.ui-link-inherit {
143 | color: #fff /*{a-bdown-color}*/;
144 | }
145 | .ui-btn-up-a,
146 | .ui-btn-hover-a,
147 | .ui-btn-down-a {
148 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
149 | text-decoration: none;
150 | }
151 |
152 |
153 | /* B
154 | -----------------------------------------------------------------------------------------------------------*/
155 |
156 | .ui-bar-b {
157 | border: 1px solid #456f9a /*{b-bar-border}*/;
158 | background: #5e87b0 /*{b-bar-background-color}*/;
159 | color: #fff /*{b-bar-color}*/;
160 | font-weight: bold;
161 | text-shadow: 0 /*{b-bar-shadow-x}*/ -1px /*{b-bar-shadow-y}*/ 1px /*{b-bar-shadow-radius}*/ #254f7a /*{b-bar-shadow-color}*/;
162 | background-image: -webkit-gradient(linear, left top, left bottom, from( #81a8ce /*{b-bar-background-start}*/), to( #5e87b0 /*{b-bar-background-end}*/)); /* Saf4+, Chrome */
163 | background-image: -webkit-linear-gradient(#81a8ce /*{b-bar-background-start}*/, #5e87b0 /*{b-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
164 | background-image: -moz-linear-gradient(#81a8ce /*{b-bar-background-start}*/, #5e87b0 /*{b-bar-background-end}*/); /* FF3.6 */
165 | background-image: -ms-linear-gradient(#81a8ce /*{b-bar-background-start}*/, #5e87b0 /*{b-bar-background-end}*/); /* IE10 */
166 | background-image: -o-linear-gradient(#81a8ce /*{b-bar-background-start}*/, #5e87b0 /*{b-bar-background-end}*/); /* Opera 11.10+ */
167 | background-image: linear-gradient(#81a8ce /*{b-bar-background-start}*/, #5e87b0 /*{b-bar-background-end}*/);
168 | }
169 | .ui-bar-b,
170 | .ui-bar-b input,
171 | .ui-bar-b select,
172 | .ui-bar-b textarea,
173 | .ui-bar-b button {
174 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
175 | }
176 | .ui-bar-b .ui-link-inherit {
177 | color: #fff /*{b-bar-color}*/;
178 | }
179 | .ui-bar-b .ui-link {
180 | color: #ddf0f8 /*{b-bar-link-color}*/;
181 | font-weight: bold;
182 | }
183 |
184 | .ui-bar-b .ui-link:hover {
185 | color: #ddf0f8 /*{b-bar-link-hover}*/;
186 | }
187 |
188 | .ui-bar-b .ui-link:active {
189 | color: #ddf0f8 /*{b-bar-link-active}*/;
190 | }
191 |
192 | .ui-bar-b .ui-link:visited {
193 | color: #ddf0f8 /*{b-bar-link-visited}*/;
194 | }
195 | .ui-body-b,
196 | .ui-dialog.ui-overlay-b {
197 | border: 1px solid #C6C6C6 /*{b-body-border}*/;
198 | background: #cccccc /*{b-body-background-color}*/;
199 | color: #333333 /*{b-body-color}*/;
200 | text-shadow: 0 /*{b-body-shadow-x}*/ 1px /*{b-body-shadow-y}*/ 0 /*{b-body-shadow-radius}*/ #fff /*{b-body-shadow-color}*/;
201 | font-weight: normal;
202 | background-image: -webkit-gradient(linear, left top, left bottom, from( #e6e6e6 /*{b-body-background-start}*/), to( #ccc /*{b-body-background-end}*/)); /* Saf4+, Chrome */
203 | background-image: -webkit-linear-gradient(#e6e6e6 /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
204 | background-image: -moz-linear-gradient(#e6e6e6 /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* FF3.6 */
205 | background-image: -ms-linear-gradient(#e6e6e6 /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* IE10 */
206 | background-image: -o-linear-gradient(#e6e6e6 /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/); /* Opera 11.10+ */
207 | background-image: linear-gradient(#e6e6e6 /*{b-body-background-start}*/, #ccc /*{b-body-background-end}*/);
208 | }
209 | .ui-body-b,
210 | .ui-body-b input,
211 | .ui-body-b select,
212 | .ui-body-b textarea,
213 | .ui-body-b button {
214 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
215 | }
216 | .ui-body-b .ui-link-inherit {
217 | color: #333333 /*{b-body-color}*/;
218 | }
219 |
220 | .ui-body-b .ui-link {
221 | color: #2489CE /*{b-body-link-color}*/;
222 | font-weight: bold;
223 | }
224 |
225 | .ui-body-b .ui-link:hover {
226 | color: #2489CE /*{b-body-link-hover}*/;
227 | }
228 |
229 | .ui-body-b .ui-link:active {
230 | color: #2489CE /*{b-body-link-active}*/;
231 | }
232 |
233 | .ui-body-b .ui-link:visited {
234 | color: #2489CE /*{b-body-link-visited}*/;
235 | }
236 |
237 | .ui-btn-up-b {
238 | border: 1px solid #145072 /*{b-bup-border}*/;
239 | background: #2567ab /*{b-bup-background-color}*/;
240 | font-weight: bold;
241 | color: #fff /*{b-bup-color}*/;
242 | text-shadow: 0 /*{b-bup-shadow-x}*/ -1px /*{b-bup-shadow-y}*/ 1px /*{b-bup-shadow-radius}*/ #145072 /*{b-bup-shadow-color}*/;
243 | background-image: -webkit-gradient(linear, left top, left bottom, from( #5f9cc5 /*{b-bup-background-start}*/), to( #396b9e /*{b-bup-background-end}*/)); /* Saf4+, Chrome */
244 | background-image: -webkit-linear-gradient(#5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
245 | background-image: -moz-linear-gradient(#5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* FF3.6 */
246 | background-image: -ms-linear-gradient(#5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* IE10 */
247 | background-image: -o-linear-gradient(#5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/); /* Opera 11.10+ */
248 | background-image: linear-gradient(#5f9cc5 /*{b-bup-background-start}*/, #396b9e /*{b-bup-background-end}*/);
249 | }
250 | .ui-btn-up-b a.ui-link-inherit {
251 | color: #fff /*{b-bup-color}*/;
252 | }
253 | .ui-btn-hover-b {
254 | border: 1px solid #00516e /*{b-bhover-border}*/;
255 | background: #4b88b6 /*{b-bhover-background-color}*/;
256 | font-weight: bold;
257 | color: #fff /*{b-bhover-color}*/;
258 | text-shadow: 0 /*{b-bhover-shadow-x}*/ -1px /*{b-bhover-shadow-y}*/ 1px /*{b-bhover-shadow-radius}*/ #014D68 /*{b-bhover-shadow-color}*/;
259 | background-image: -webkit-gradient(linear, left top, left bottom, from( #72b0d4 /*{b-bhover-background-start}*/), to( #4b88b6 /*{b-bhover-background-end}*/)); /* Saf4+, Chrome */
260 | background-image: -webkit-linear-gradient(#72b0d4 /*{b-bhover-background-start}*/, #4b88b6 /*{b-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
261 | background-image: -moz-linear-gradient(#72b0d4 /*{b-bhover-background-start}*/, #4b88b6 /*{b-bhover-background-end}*/); /* FF3.6 */
262 | background-image: -ms-linear-gradient(#72b0d4 /*{b-bhover-background-start}*/, #4b88b6 /*{b-bhover-background-end}*/); /* IE10 */
263 | background-image: -o-linear-gradient(#72b0d4 /*{b-bhover-background-start}*/, #4b88b6 /*{b-bhover-background-end}*/); /* Opera 11.10+ */
264 | background-image: linear-gradient(#72b0d4 /*{b-bhover-background-start}*/, #4b88b6 /*{b-bhover-background-end}*/);
265 | }
266 | .ui-btn-hover-b a.ui-link-inherit {
267 | color: #fff /*{b-bhover-color}*/;
268 | }
269 | .ui-btn-down-b {
270 | border: 1px solid #225377 /*{b-bdown-border}*/;
271 | background: #4e89c5 /*{b-bdown-background-color}*/;
272 | font-weight: bold;
273 | color: #fff /*{b-bdown-color}*/;
274 | text-shadow: 0 /*{b-bdown-shadow-x}*/ -1px /*{b-bdown-shadow-y}*/ 1px /*{b-bdown-shadow-radius}*/ #225377 /*{b-bdown-shadow-color}*/;
275 | background-image: -webkit-gradient(linear, left top, left bottom, from( #396b9e /*{b-bdown-background-start}*/), to( #4e89c5 /*{b-bdown-background-end}*/)); /* Saf4+, Chrome */
276 | background-image: -webkit-linear-gradient(#396b9e /*{b-bdown-background-start}*/, #4e89c5 /*{b-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
277 | background-image: -moz-linear-gradient(#396b9e /*{b-bdown-background-start}*/, #4e89c5 /*{b-bdown-background-end}*/); /* FF3.6 */
278 | background-image: -ms-linear-gradient(#396b9e /*{b-bdown-background-start}*/, #4e89c5 /*{b-bdown-background-end}*/); /* IE10 */
279 | background-image: -o-linear-gradient(#396b9e /*{b-bdown-background-start}*/, #4e89c5 /*{b-bdown-background-end}*/); /* Opera 11.10+ */
280 | background-image: linear-gradient(#396b9e /*{b-bdown-background-start}*/, #4e89c5 /*{b-bdown-background-end}*/);
281 | }
282 | .ui-btn-down-b a.ui-link-inherit {
283 | color: #fff /*{b-bdown-color}*/;
284 | }
285 | .ui-btn-up-b,
286 | .ui-btn-hover-b,
287 | .ui-btn-down-b {
288 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
289 | text-decoration: none;
290 | }
291 |
292 |
293 | /* C
294 | -----------------------------------------------------------------------------------------------------------*/
295 |
296 | .ui-bar-c {
297 | border: 1px solid #B3B3B3 /*{c-bar-border}*/;
298 | background: #e9eaeb /*{c-bar-background-color}*/;
299 | color: #3E3E3E /*{c-bar-color}*/;
300 | font-weight: bold;
301 | text-shadow: 0 /*{c-bar-shadow-x}*/ 1px /*{c-bar-shadow-y}*/ 1px /*{c-bar-shadow-radius}*/ #fff /*{c-bar-shadow-color}*/;
302 | background-image: -webkit-gradient(linear, left top, left bottom, from( #f0f0f0 /*{c-bar-background-start}*/), to( #e9eaeb /*{c-bar-background-end}*/)); /* Saf4+, Chrome */
303 | background-image: -webkit-linear-gradient(#f0f0f0 /*{c-bar-background-start}*/, #e9eaeb /*{c-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
304 | background-image: -moz-linear-gradient(#f0f0f0 /*{c-bar-background-start}*/, #e9eaeb /*{c-bar-background-end}*/); /* FF3.6 */
305 | background-image: -ms-linear-gradient(#f0f0f0 /*{c-bar-background-start}*/, #e9eaeb /*{c-bar-background-end}*/); /* IE10 */
306 | background-image: -o-linear-gradient(#f0f0f0 /*{c-bar-background-start}*/, #e9eaeb /*{c-bar-background-end}*/); /* Opera 11.10+ */
307 | background-image: linear-gradient(#f0f0f0 /*{c-bar-background-start}*/, #e9eaeb /*{c-bar-background-end}*/);
308 | }
309 |
310 | .ui-bar-c .ui-link-inherit {
311 | color: #3E3E3E /*{c-bar-color}*/;
312 | }
313 | .ui-bar-c .ui-link {
314 | color: #7cc4e7 /*{c-bar-link-color}*/;
315 | font-weight: bold;
316 | }
317 |
318 | .ui-bar-c .ui-link:hover {
319 | color: #2489CE /*{c-bar-link-hover}*/;
320 | }
321 |
322 | .ui-bar-c .ui-link:active {
323 | color: #2489CE /*{c-bar-link-active}*/;
324 | }
325 |
326 | .ui-bar-c .ui-link:visited {
327 | color: #2489CE /*{c-bar-link-visited}*/;
328 | }
329 |
330 | .ui-bar-c,
331 | .ui-bar-c input,
332 | .ui-bar-c select,
333 | .ui-bar-c textarea,
334 | .ui-bar-c button {
335 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
336 | }
337 | .ui-body-c,
338 | .ui-dialog.ui-overlay-c {
339 | border: 1px solid #B3B3B3 /*{c-body-border}*/;
340 | color: #333333 /*{c-body-color}*/;
341 | text-shadow: 0 /*{c-body-shadow-x}*/ 1px /*{c-body-shadow-y}*/ 0 /*{c-body-shadow-radius}*/ #fff /*{c-body-shadow-color}*/;
342 | background: #f0f0f0 /*{c-body-background-color}*/;
343 | background-image: -webkit-gradient(linear, left top, left bottom, from( #eee /*{c-body-background-start}*/), to( #ddd /*{c-body-background-end}*/)); /* Saf4+, Chrome */
344 | background-image: -webkit-linear-gradient(#eee /*{c-body-background-start}*/, #ddd /*{c-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
345 | background-image: -moz-linear-gradient(#eee /*{c-body-background-start}*/, #ddd /*{c-body-background-end}*/); /* FF3.6 */
346 | background-image: -ms-linear-gradient(#eee /*{c-body-background-start}*/, #ddd /*{c-body-background-end}*/); /* IE10 */
347 | background-image: -o-linear-gradient(#eee /*{c-body-background-start}*/, #ddd /*{c-body-background-end}*/); /* Opera 11.10+ */
348 | background-image: linear-gradient(#eee /*{c-body-background-start}*/, #ddd /*{c-body-background-end}*/);
349 | }
350 | .ui-body-c,
351 | .ui-body-c input,
352 | .ui-body-c select,
353 | .ui-body-c textarea,
354 | .ui-body-c button {
355 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
356 | }
357 |
358 | .ui-body-c .ui-link-inherit {
359 | color: #333333 /*{c-body-color}*/;
360 | }
361 |
362 | .ui-body-c .ui-link {
363 | color: #2489CE /*{c-body-link-color}*/;
364 | font-weight: bold;
365 | }
366 |
367 | .ui-body-c .ui-link:hover {
368 | color: #2489CE /*{c-body-link-hover}*/;
369 | }
370 |
371 | .ui-body-c .ui-link:active {
372 | color: #2489CE /*{c-body-link-active}*/;
373 | }
374 |
375 | .ui-body-c .ui-link:visited {
376 | color: #2489CE /*{c-body-link-visited}*/;
377 | }
378 |
379 | .ui-btn-up-c {
380 | border: 1px solid #ccc /*{c-bup-border}*/;
381 | background: #eee /*{c-bup-background-color}*/;
382 | font-weight: bold;
383 | color: #444 /*{c-bup-color}*/;
384 | text-shadow: 0 /*{c-bup-shadow-x}*/ 1px /*{c-bup-shadow-y}*/ 1px /*{c-bup-shadow-radius}*/ #f6f6f6 /*{c-bup-shadow-color}*/;
385 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fdfdfd /*{c-bup-background-start}*/), to( #eee /*{c-bup-background-end}*/)); /* Saf4+, Chrome */
386 | background-image: -webkit-linear-gradient(#fdfdfd /*{c-bup-background-start}*/, #eee /*{c-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
387 | background-image: -moz-linear-gradient(#fdfdfd /*{c-bup-background-start}*/, #eee /*{c-bup-background-end}*/); /* FF3.6 */
388 | background-image: -ms-linear-gradient(#fdfdfd /*{c-bup-background-start}*/, #eee /*{c-bup-background-end}*/); /* IE10 */
389 | background-image: -o-linear-gradient(#fdfdfd /*{c-bup-background-start}*/, #eee /*{c-bup-background-end}*/); /* Opera 11.10+ */
390 | background-image: linear-gradient(#fdfdfd /*{c-bup-background-start}*/, #eee /*{c-bup-background-end}*/);
391 | }
392 | .ui-btn-up-c a.ui-link-inherit {
393 | color: #2F3E46 /*{c-bup-color}*/;
394 | }
395 |
396 | .ui-btn-hover-c {
397 | border: 1px solid #bbbbbb /*{c-bhover-border}*/;
398 | background: #dadada /*{c-bhover-background-color}*/;
399 | font-weight: bold;
400 | color: #101010 /*{c-bhover-color}*/;
401 | text-shadow: 0 /*{c-bhover-shadow-x}*/ 1px /*{c-bhover-shadow-y}*/ 1px /*{c-bhover-shadow-radius}*/ #fff /*{c-bhover-shadow-color}*/;
402 | background-image: -webkit-gradient(linear, left top, left bottom, from( #ededed /*{c-bhover-background-start}*/), to( #dadada /*{c-bhover-background-end}*/)); /* Saf4+, Chrome */
403 | background-image: -webkit-linear-gradient(#ededed /*{c-bhover-background-start}*/, #dadada /*{c-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
404 | background-image: -moz-linear-gradient(#ededed /*{c-bhover-background-start}*/, #dadada /*{c-bhover-background-end}*/); /* FF3.6 */
405 | background-image: -ms-linear-gradient(#ededed /*{c-bhover-background-start}*/, #dadada /*{c-bhover-background-end}*/); /* IE10 */
406 | background-image: -o-linear-gradient(#ededed /*{c-bhover-background-start}*/, #dadada /*{c-bhover-background-end}*/); /* Opera 11.10+ */
407 | background-image: linear-gradient(#ededed /*{c-bhover-background-start}*/, #dadada /*{c-bhover-background-end}*/);
408 | }
409 | .ui-btn-hover-c a.ui-link-inherit {
410 | color: #2F3E46 /*{c-bhover-color}*/;
411 | }
412 | .ui-btn-down-c {
413 | border: 1px solid #808080 /*{c-bdown-border}*/;
414 | background: #fdfdfd /*{c-bdown-background-color}*/;
415 | font-weight: bold;
416 | color: #111111 /*{c-bdown-color}*/;
417 | text-shadow: 0 /*{c-bdown-shadow-x}*/ 1px /*{c-bdown-shadow-y}*/ 1px /*{c-bdown-shadow-radius}*/ #ffffff /*{c-bdown-shadow-color}*/;
418 | background-image: -webkit-gradient(linear, left top, left bottom, from( #eee /*{c-bdown-background-start}*/), to( #fdfdfd /*{c-bdown-background-end}*/)); /* Saf4+, Chrome */
419 | background-image: -webkit-linear-gradient(#eee /*{c-bdown-background-start}*/, #fdfdfd /*{c-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
420 | background-image: -moz-linear-gradient(#eee /*{c-bdown-background-start}*/, #fdfdfd /*{c-bdown-background-end}*/); /* FF3.6 */
421 | background-image: -ms-linear-gradient(#eee /*{c-bdown-background-start}*/, #fdfdfd /*{c-bdown-background-end}*/); /* IE10 */
422 | background-image: -o-linear-gradient(#eee /*{c-bdown-background-start}*/, #fdfdfd /*{c-bdown-background-end}*/); /* Opera 11.10+ */
423 | background-image: linear-gradient(#eee /*{c-bdown-background-start}*/, #fdfdfd /*{c-bdown-background-end}*/);
424 | }
425 | .ui-btn-down-c a.ui-link-inherit {
426 | color: #2F3E46 /*{c-bdown-color}*/;
427 | }
428 | .ui-btn-up-c,
429 | .ui-btn-hover-c,
430 | .ui-btn-down-c {
431 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
432 | text-decoration: none;
433 | }
434 |
435 |
436 | /* D
437 | -----------------------------------------------------------------------------------------------------------*/
438 |
439 | .ui-bar-d {
440 | border: 1px solid #ccc /*{d-bar-border}*/;
441 | background: #bbb /*{d-bar-background-color}*/;
442 | color: #333 /*{d-bar-color}*/;
443 | text-shadow: 0 /*{d-bar-shadow-x}*/ 1px /*{d-bar-shadow-y}*/ 0 /*{d-bar-shadow-radius}*/ #eee /*{d-bar-shadow-color}*/;
444 | background-image: -webkit-gradient(linear, left top, left bottom, from( #ddd /*{d-bar-background-start}*/), to( #bbb /*{d-bar-background-end}*/)); /* Saf4+, Chrome */
445 | background-image: -webkit-linear-gradient(#ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
446 | background-image: -moz-linear-gradient(#ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* FF3.6 */
447 | background-image: -ms-linear-gradient(#ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* IE10 */
448 | background-image: -o-linear-gradient(#ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/); /* Opera 11.10+ */
449 | background-image: linear-gradient(#ddd /*{d-bar-background-start}*/, #bbb /*{d-bar-background-end}*/);
450 | }
451 | .ui-bar-d,
452 | .ui-bar-d input,
453 | .ui-bar-d select,
454 | .ui-bar-d textarea,
455 | .ui-bar-d button {
456 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
457 | }
458 |
459 | .ui-bar-d .ui-link-inherit {
460 | color: #333333 /*{d-bar-color}*/;
461 | }
462 | .ui-bar-d .ui-link {
463 | color: #2489CE /*{d-bar-link-color}*/;
464 | font-weight: bold;
465 | }
466 |
467 | .ui-bar-d .ui-link:hover {
468 | color: #2489CE /*{d-bar-link-hover}*/;
469 | }
470 |
471 | .ui-bar-d .ui-link:active {
472 | color: #2489CE /*{d-bar-link-active}*/;
473 | }
474 |
475 | .ui-bar-d .ui-link:visited {
476 | color: #2489CE /*{d-bar-link-visited}*/;
477 | }
478 |
479 | .ui-body-d,
480 | .ui-dialog.ui-overlay-d {
481 | border: 1px solid #ccc /*{d-body-border}*/;
482 | color: #333333 /*{d-body-color}*/;
483 | text-shadow: 0 /*{d-body-shadow-x}*/ 1px /*{d-body-shadow-y}*/ 0 /*{d-body-shadow-radius}*/ #fff /*{d-body-shadow-color}*/;
484 | background: #ffffff /*{d-body-background-color}*/;
485 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fff), to( #fff /*{d-body-background-end}*/)); /* Saf4+, Chrome */
486 | background-image: -webkit-linear-gradient(#fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
487 | background-image: -moz-linear-gradient(#fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* FF3.6 */
488 | background-image: -ms-linear-gradient(#fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* IE10 */
489 | background-image: -o-linear-gradient(#fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/); /* Opera 11.10+ */
490 | background-image: linear-gradient(#fff /*{d-body-background-start}*/, #fff /*{d-body-background-end}*/);
491 | }
492 | .ui-body-d,
493 | .ui-body-d input,
494 | .ui-body-d select,
495 | .ui-body-d textarea,
496 | .ui-body-d button {
497 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
498 | }
499 |
500 | .ui-body-d .ui-link-inherit {
501 | color: #333333 /*{d-body-color}*/;
502 | }
503 |
504 | .ui-body-d .ui-link {
505 | color: #2489CE /*{d-body-link-color}*/;
506 | font-weight: bold;
507 | }
508 |
509 | .ui-body-d .ui-link:hover {
510 | color: #2489CE /*{d-body-link-hover}*/;
511 | }
512 |
513 | .ui-body-d .ui-link:active {
514 | color: #2489CE /*{d-body-link-active}*/;
515 | }
516 |
517 | .ui-body-d .ui-link:visited {
518 | color: #2489CE /*{d-body-link-visited}*/;
519 | }
520 |
521 | .ui-btn-up-d {
522 | border: 1px solid #ccc /*{d-bup-border}*/;
523 | background: #fff /*{d-bup-background-color}*/;
524 | font-weight: bold;
525 | color: #444 /*{d-bup-color}*/;
526 | text-shadow: 0 /*{d-bup-shadow-x}*/ 1px /*{d-bup-shadow-y}*/ 1px /*{d-bup-shadow-radius}*/ #fff /*{d-bup-shadow-color}*/;
527 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fff), to( #fff /*{d-bup-background-end}*/)); /* Saf4+, Chrome */
528 | background-image: -webkit-linear-gradient(#fff /*{d-bup-background-start}*/, #fff /*{d-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
529 | background-image: -moz-linear-gradient(#fff /*{d-bup-background-start}*/, #fff /*{d-bup-background-end}*/); /* FF3.6 */
530 | background-image: -ms-linear-gradient(#fff /*{d-bup-background-start}*/, #fff /*{d-bup-background-end}*/); /* IE10 */
531 | background-image: -o-linear-gradient(#fff /*{d-bup-background-start}*/, #fff /*{d-bup-background-end}*/); /* Opera 11.10+ */
532 | background-image: linear-gradient(#fff /*{d-bup-background-start}*/, #fff /*{d-bup-background-end}*/);
533 | }
534 | .ui-btn-up-d a.ui-link-inherit {
535 | color: #333 /*{d-bup-color}*/;
536 | }
537 | .ui-btn-hover-d {
538 | border: 1px solid #aaa /*{d-bhover-border}*/;
539 | background: #eeeeee /*{d-bhover-background-color}*/;
540 | font-weight: bold;
541 | color: #222 /*{d-bhover-color}*/;
542 | cursor: pointer;
543 | text-shadow: 0 /*{d-bhover-shadow-x}*/ 1px /*{d-bhover-shadow-y}*/ 1px /*{d-bhover-shadow-radius}*/ #fff /*{d-bhover-shadow-color}*/;
544 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fdfdfd), to( #eee /*{d-bhover-background-end}*/)); /* Saf4+, Chrome */
545 | background-image: -webkit-linear-gradient(#fdfdfd /*{d-bhover-background-start}*/, #eee /*{d-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
546 | background-image: -moz-linear-gradient(#fdfdfd /*{d-bhover-background-start}*/, #eee /*{d-bhover-background-end}*/); /* FF3.6 */
547 | background-image: -ms-linear-gradient(#fdfdfd /*{d-bhover-background-start}*/, #eee /*{d-bhover-background-end}*/); /* IE10 */
548 | background-image: -o-linear-gradient(#fdfdfd /*{d-bhover-background-start}*/, #eee /*{d-bhover-background-end}*/); /* Opera 11.10+ */
549 | background-image: linear-gradient(#fdfdfd /*{d-bhover-background-start}*/, #eee /*{d-bhover-background-end}*/);
550 | }
551 | .ui-btn-hover-d a.ui-link-inherit {
552 | color: #222 /*{d-bhover-color}*/;
553 | }
554 | .ui-btn-down-d {
555 | border: 1px solid #aaaaaa /*{d-bdown-border}*/;
556 | background: #ffffff /*{d-bdown-background-color}*/;
557 | font-weight: bold;
558 | color: #111 /*{d-bdown-color}*/;
559 | text-shadow: 0 /*{d-bdown-shadow-x}*/ 1px /*{d-bdown-shadow-y}*/ 1px /*{d-bdown-shadow-radius}*/ #ffffff /*{d-bdown-shadow-color}*/;
560 | background-image: -webkit-gradient(linear, left top, left bottom, from( #eee /*{d-bdown-background-start}*/), to( #fff /*{d-bdown-background-end}*/)); /* Saf4+, Chrome */
561 | background-image: -webkit-linear-gradient(#eee /*{d-bdown-background-start}*/, #fff /*{d-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
562 | background-image: -moz-linear-gradient(#eee /*{d-bdown-background-start}*/, #fff /*{d-bdown-background-end}*/); /* FF3.6 */
563 | background-image: -ms-linear-gradient(#eee /*{d-bdown-background-start}*/, #fff /*{d-bdown-background-end}*/); /* IE10 */
564 | background-image: -o-linear-gradient(#eee /*{d-bdown-background-start}*/, #fff /*{d-bdown-background-end}*/); /* Opera 11.10+ */
565 | background-image: linear-gradient(#eee /*{d-bdown-background-start}*/, #fff /*{d-bdown-background-end}*/);
566 | }
567 | .ui-btn-down-d a.ui-link-inherit {
568 | color: #111 /*{d-bdown-color}*/;
569 | }
570 | .ui-btn-up-d,
571 | .ui-btn-hover-d,
572 | .ui-btn-down-d {
573 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
574 | text-decoration: none;
575 | }
576 |
577 |
578 | /* E
579 | -----------------------------------------------------------------------------------------------------------*/
580 |
581 | .ui-bar-e {
582 | border: 1px solid #F7C942 /*{e-bar-border}*/;
583 | background: #fadb4e /*{e-bar-background-color}*/;
584 | color: #333 /*{e-bar-color}*/;
585 | text-shadow: 0 /*{e-bar-shadow-x}*/ 1px /*{e-bar-shadow-y}*/ 0 /*{e-bar-shadow-radius}*/ #fff /*{e-bar-shadow-color}*/;
586 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fceda7 /*{e-bar-background-start}*/), to( #fadb4e /*{e-bar-background-end}*/)); /* Saf4+, Chrome */
587 | background-image: -webkit-linear-gradient(#fceda7 /*{e-bar-background-start}*/, #fadb4e /*{e-bar-background-end}*/); /* Chrome 10+, Saf5.1+ */
588 | background-image: -moz-linear-gradient(#fceda7 /*{e-bar-background-start}*/, #fadb4e /*{e-bar-background-end}*/); /* FF3.6 */
589 | background-image: -ms-linear-gradient(#fceda7 /*{e-bar-background-start}*/, #fadb4e /*{e-bar-background-end}*/); /* IE10 */
590 | background-image: -o-linear-gradient(#fceda7 /*{e-bar-background-start}*/, #fadb4e /*{e-bar-background-end}*/); /* Opera 11.10+ */
591 | background-image: linear-gradient(#fceda7 /*{e-bar-background-start}*/, #fadb4e /*{e-bar-background-end}*/);
592 | }
593 | .ui-bar-e,
594 | .ui-bar-e input,
595 | .ui-bar-e select,
596 | .ui-bar-e textarea,
597 | .ui-bar-e button {
598 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
599 | }
600 | .ui-bar-e .ui-link-inherit {
601 | color: #333333 /*{e-bar-color}*/;
602 | }
603 | .ui-bar-e .ui-link {
604 | color: #2489CE /*{e-bar-link-color}*/;
605 | font-weight: bold;
606 | }
607 |
608 | .ui-bar-e .ui-link:hover {
609 | color: #2489CE /*{e-bar-link-hover}*/;
610 | }
611 |
612 | .ui-bar-e .ui-link:active {
613 | color: #2489CE /*{e-bar-link-active}*/;
614 | }
615 |
616 | .ui-bar-e .ui-link:visited {
617 | color: #2489CE /*{e-bar-link-visited}*/;
618 | }
619 |
620 | .ui-body-e,
621 | .ui-dialog.ui-overlay-e {
622 | border: 1px solid #F7C942 /*{e-body-border}*/;
623 | color: #333333 /*{e-body-color}*/;
624 | text-shadow: 0 /*{e-body-shadow-x}*/ 1px /*{e-body-shadow-y}*/ 0 /*{e-body-shadow-radius}*/ #fff /*{e-body-shadow-color}*/;
625 | background: #faeb9e /*{e-body-background-color}*/;
626 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fff /*{e-body-background-start}*/), to( #faeb9e /*{e-body-background-end}*/)); /* Saf4+, Chrome */
627 | background-image: -webkit-linear-gradient(#fff /*{e-body-background-start}*/, #faeb9e /*{e-body-background-end}*/); /* Chrome 10+, Saf5.1+ */
628 | background-image: -moz-linear-gradient(#fff /*{e-body-background-start}*/, #faeb9e /*{e-body-background-end}*/); /* FF3.6 */
629 | background-image: -ms-linear-gradient(#fff /*{e-body-background-start}*/, #faeb9e /*{e-body-background-end}*/); /* IE10 */
630 | background-image: -o-linear-gradient(#fff /*{e-body-background-start}*/, #faeb9e /*{e-body-background-end}*/); /* Opera 11.10+ */
631 | background-image: linear-gradient(#fff /*{e-body-background-start}*/, #faeb9e /*{e-body-background-end}*/);
632 | }
633 | .ui-body-e,
634 | .ui-body-e input,
635 | .ui-body-e select,
636 | .ui-body-e textarea,
637 | .ui-body-e button {
638 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
639 | }
640 | .ui-body-e .ui-link-inherit {
641 | color: #333333 /*{e-body-color}*/;
642 | }
643 |
644 | .ui-body-e .ui-link {
645 | color: #2489CE /*{e-body-link-color}*/;
646 | font-weight: bold;
647 | }
648 |
649 | .ui-body-e .ui-link:hover {
650 | color: #2489CE /*{e-body-link-hover}*/;
651 | }
652 |
653 | .ui-body-e .ui-link:active {
654 | color: #2489CE /*{e-body-link-active}*/;
655 | }
656 |
657 | .ui-body-e .ui-link:visited {
658 | color: #2489CE /*{e-body-link-visited}*/;
659 | }
660 |
661 | .ui-btn-up-e {
662 | border: 1px solid #F7C942 /*{e-bup-border}*/;
663 | background: #fadb4e /*{e-bup-background-color}*/;
664 | font-weight: bold;
665 | color: #333 /*{e-bup-color}*/;
666 | text-shadow: 0 /*{e-bup-shadow-x}*/ 1px /*{e-bup-shadow-y}*/ 0 /*{e-bup-shadow-radius}*/ #fff /*{e-bup-shadow-color}*/;
667 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fceda7 /*{e-bup-background-start}*/), to( #fadb4e /*{e-bup-background-end}*/)); /* Saf4+, Chrome */
668 | background-image: -webkit-linear-gradient(#fceda7 /*{e-bup-background-start}*/, #fadb4e /*{e-bup-background-end}*/); /* Chrome 10+, Saf5.1+ */
669 | background-image: -moz-linear-gradient(#fceda7 /*{e-bup-background-start}*/, #fadb4e /*{e-bup-background-end}*/); /* FF3.6 */
670 | background-image: -ms-linear-gradient(#fceda7 /*{e-bup-background-start}*/, #fadb4e /*{e-bup-background-end}*/); /* IE10 */
671 | background-image: -o-linear-gradient(#fceda7 /*{e-bup-background-start}*/, #fadb4e /*{e-bup-background-end}*/); /* Opera 11.10+ */
672 | background-image: linear-gradient(#fceda7 /*{e-bup-background-start}*/, #fadb4e /*{e-bup-background-end}*/);
673 | }
674 | .ui-btn-up-e a.ui-link-inherit {
675 | color: #333 /*{e-bup-color}*/;
676 | }
677 | .ui-btn-hover-e {
678 | border: 1px solid #e79952 /*{e-bhover-border}*/;
679 | background: #fbe26f /*{e-bhover-background-color}*/;
680 | font-weight: bold;
681 | color: #111 /*{e-bhover-color}*/;
682 | text-shadow: 0 /*{e-bhover-shadow-x}*/ 1px /*{e-bhover-shadow-y}*/ 1px /*{e-bhover-shadow-radius}*/ #fff /*{e-bhover-shadow-color}*/;
683 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fcf0b5 /*{e-bhover-background-start}*/), to( #fbe26f /*{e-bhover-background-end}*/)); /* Saf4+, Chrome */
684 | background-image: -webkit-linear-gradient(#fcf0b5 /*{e-bhover-background-start}*/, #fbe26f /*{e-bhover-background-end}*/); /* Chrome 10+, Saf5.1+ */
685 | background-image: -moz-linear-gradient(#fcf0b5 /*{e-bhover-background-start}*/, #fbe26f /*{e-bhover-background-end}*/); /* FF3.6 */
686 | background-image: -ms-linear-gradient(#fcf0b5 /*{e-bhover-background-start}*/, #fbe26f /*{e-bhover-background-end}*/); /* IE10 */
687 | background-image: -o-linear-gradient(#fcf0b5 /*{e-bhover-background-start}*/, #fbe26f /*{e-bhover-background-end}*/); /* Opera 11.10+ */
688 | background-image: linear-gradient(#fcf0b5 /*{e-bhover-background-start}*/, #fbe26f /*{e-bhover-background-end}*/);
689 | }
690 |
691 | .ui-btn-hover-e a.ui-link-inherit {
692 | color: #333 /*{e-bhover-color}*/;
693 | }
694 | .ui-btn-down-e {
695 | border: 1px solid #F7C942 /*{e-bdown-border}*/;
696 | background: #fceda7 /*{e-bdown-background-color}*/;
697 | font-weight: bold;
698 | color: #111 /*{e-bdown-color}*/;
699 | text-shadow: 0 /*{e-bdown-shadow-x}*/ 1px /*{e-bdown-shadow-y}*/ 1px /*{e-bdown-shadow-radius}*/ #ffffff /*{e-bdown-shadow-color}*/;
700 | background-image: -webkit-gradient(linear, left top, left bottom, from( #fadb4e /*{e-bdown-background-start}*/), to( #fceda7 /*{e-bdown-background-end}*/)); /* Saf4+, Chrome */
701 | background-image: -webkit-linear-gradient(#fadb4e /*{e-bdown-background-start}*/, #fceda7 /*{e-bdown-background-end}*/); /* Chrome 10+, Saf5.1+ */
702 | background-image: -moz-linear-gradient(#fadb4e /*{e-bdown-background-start}*/, #fceda7 /*{e-bdown-background-end}*/); /* FF3.6 */
703 | background-image: -ms-linear-gradient(#fadb4e /*{e-bdown-background-start}*/, #fceda7 /*{e-bdown-background-end}*/); /* IE10 */
704 | background-image: -o-linear-gradient(#fadb4e /*{e-bdown-background-start}*/, #fceda7 /*{e-bdown-background-end}*/); /* Opera 11.10+ */
705 | background-image: linear-gradient(#fadb4e /*{e-bdown-background-start}*/, #fceda7 /*{e-bdown-background-end}*/);
706 | }
707 | .ui-btn-down-e a.ui-link-inherit {
708 | color: #333 /*{e-bdown-color}*/;
709 | }
710 | .ui-btn-up-e,
711 | .ui-btn-hover-e,
712 | .ui-btn-down-e {
713 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
714 | text-decoration: none;
715 | }
716 |
717 | /* Structure */
718 |
719 | /* links within "buttons"
720 | -----------------------------------------------------------------------------------------------------------*/
721 |
722 | a.ui-link-inherit {
723 | text-decoration: none !important;
724 | }
725 |
726 |
727 | /* Active class used as the "on" state across all themes
728 | -----------------------------------------------------------------------------------------------------------*/
729 |
730 | .ui-btn-active {
731 | border: 1px solid #155678 /*{global-active-border}*/;
732 | background: #4596ce /*{global-active-background-color}*/;
733 | font-weight: bold;
734 | color: #fff /*{global-active-color}*/;
735 | cursor: pointer;
736 | text-shadow: 0 /*{global-active-shadow-x}*/ -1px /*{global-active-shadow-y}*/ 1px /*{global-active-shadow-radius}*/ #145072 /*{global-active-shadow-color}*/;
737 | text-decoration: none;
738 | background-image: -webkit-gradient(linear, left top, left bottom, from( #85bae4 /*{global-active-background-start}*/), to( #5393c5 /*{global-active-background-end}*/)); /* Saf4+, Chrome */
739 | background-image: -webkit-linear-gradient(#85bae4 /*{global-active-background-start}*/, #5393c5 /*{global-active-background-end}*/); /* Chrome 10+, Saf5.1+ */
740 | background-image: -moz-linear-gradient(#85bae4 /*{global-active-background-start}*/, #5393c5 /*{global-active-background-end}*/); /* FF3.6 */
741 | background-image: -ms-linear-gradient(#85bae4 /*{global-active-background-start}*/, #5393c5 /*{global-active-background-end}*/); /* IE10 */
742 | background-image: -o-linear-gradient(#85bae4 /*{global-active-background-start}*/, #5393c5 /*{global-active-background-end}*/); /* Opera 11.10+ */
743 | background-image: linear-gradient(#85bae4 /*{global-active-background-start}*/, #5393c5 /*{global-active-background-end}*/);
744 | font-family: Helvetica, Arial, sans-serif /*{global-font-family}*/;
745 | }
746 | .ui-btn-active a.ui-link-inherit {
747 | color: #fff /*{global-active-color}*/;
748 | }
749 |
750 |
751 | /* button inner top highlight
752 | -----------------------------------------------------------------------------------------------------------*/
753 |
754 | .ui-btn-inner {
755 | border-top: 1px solid #fff;
756 | border-color: rgba(255,255,255,.3);
757 | }
758 |
759 |
760 | /* corner rounding classes
761 | -----------------------------------------------------------------------------------------------------------*/
762 |
763 | .ui-corner-tl {
764 | -moz-border-radius-topleft: .6em /*{global-radii-blocks}*/;
765 | -webkit-border-top-left-radius: .6em /*{global-radii-blocks}*/;
766 | border-top-left-radius: .6em /*{global-radii-blocks}*/;
767 | }
768 | .ui-corner-tr {
769 | -moz-border-radius-topright: .6em /*{global-radii-blocks}*/;
770 | -webkit-border-top-right-radius: .6em /*{global-radii-blocks}*/;
771 | border-top-right-radius: .6em /*{global-radii-blocks}*/;
772 | }
773 | .ui-corner-bl {
774 | -moz-border-radius-bottomleft: .6em /*{global-radii-blocks}*/;
775 | -webkit-border-bottom-left-radius: .6em /*{global-radii-blocks}*/;
776 | border-bottom-left-radius: .6em /*{global-radii-blocks}*/;
777 | }
778 | .ui-corner-br {
779 | -moz-border-radius-bottomright: .6em /*{global-radii-blocks}*/;
780 | -webkit-border-bottom-right-radius: .6em /*{global-radii-blocks}*/;
781 | border-bottom-right-radius: .6em /*{global-radii-blocks}*/;
782 | }
783 | .ui-corner-top {
784 | -moz-border-radius-topleft: .6em /*{global-radii-blocks}*/;
785 | -webkit-border-top-left-radius: .6em /*{global-radii-blocks}*/;
786 | border-top-left-radius: .6em /*{global-radii-blocks}*/;
787 | -moz-border-radius-topright: .6em /*{global-radii-blocks}*/;
788 | -webkit-border-top-right-radius: .6em /*{global-radii-blocks}*/;
789 | border-top-right-radius: .6em /*{global-radii-blocks}*/;
790 | }
791 | .ui-corner-bottom {
792 | -moz-border-radius-bottomleft: .6em /*{global-radii-blocks}*/;
793 | -webkit-border-bottom-left-radius: .6em /*{global-radii-blocks}*/;
794 | border-bottom-left-radius: .6em /*{global-radii-blocks}*/;
795 | -moz-border-radius-bottomright: .6em /*{global-radii-blocks}*/;
796 | -webkit-border-bottom-right-radius: .6em /*{global-radii-blocks}*/;
797 | border-bottom-right-radius: .6em /*{global-radii-blocks}*/;
798 | }
799 | .ui-corner-right {
800 | -moz-border-radius-topright: .6em /*{global-radii-blocks}*/;
801 | -webkit-border-top-right-radius: .6em /*{global-radii-blocks}*/;
802 | border-top-right-radius: .6em /*{global-radii-blocks}*/;
803 | -moz-border-radius-bottomright: .6em /*{global-radii-blocks}*/;
804 | -webkit-border-bottom-right-radius: .6em /*{global-radii-blocks}*/;
805 | border-bottom-right-radius: .6em /*{global-radii-blocks}*/;
806 | }
807 | .ui-corner-left {
808 | -moz-border-radius-topleft: .6em /*{global-radii-blocks}*/;
809 | -webkit-border-top-left-radius: .6em /*{global-radii-blocks}*/;
810 | border-top-left-radius: .6em /*{global-radii-blocks}*/;
811 | -moz-border-radius-bottomleft: .6em /*{global-radii-blocks}*/;
812 | -webkit-border-bottom-left-radius: .6em /*{global-radii-blocks}*/;
813 | border-bottom-left-radius: .6em /*{global-radii-blocks}*/;
814 | }
815 | .ui-corner-all {
816 | -moz-border-radius: .6em /*{global-radii-blocks}*/;
817 | -webkit-border-radius: .6em /*{global-radii-blocks}*/;
818 | border-radius: .6em /*{global-radii-blocks}*/;
819 | }
820 | .ui-corner-none {
821 | -moz-border-radius: 0;
822 | -webkit-border-radius: 0;
823 | border-radius: 0;
824 | }
825 |
826 | /* Form field separator
827 | -----------------------------------------------------------------------------------------------------------*/
828 | .ui-br {
829 | border-bottom: rgb(130,130,130);
830 | border-bottom: rgba(130,130,130,.3);
831 | border-bottom-width: 1px;
832 | border-bottom-style: solid;
833 | }
834 |
835 | /* Interaction cues
836 | -----------------------------------------------------------------------------------------------------------*/
837 | .ui-disabled {
838 | opacity: .3;
839 | }
840 | .ui-disabled,
841 | .ui-disabled a {
842 | pointer-events: none;
843 | cursor: default;
844 | }
845 |
846 | /* Icons
847 | -----------------------------------------------------------------------------------------------------------*/
848 |
849 | .ui-icon,
850 | .ui-icon-searchfield:after {
851 | background: #666 /*{global-icon-color}*/;
852 | background: rgba(0,0,0,.4) /*{global-icon-disc}*/;
853 | background-image: url(images/icons-18-white.png) /*{global-icon-set}*/;
854 | background-repeat: no-repeat;
855 | -moz-border-radius: 9px;
856 | -webkit-border-radius: 9px;
857 | border-radius: 9px;
858 | }
859 |
860 |
861 | /* Alt icon color
862 | -----------------------------------------------------------------------------------------------------------*/
863 |
864 | .ui-icon-alt {
865 | background: #fff;
866 | background: rgba(255,255,255,.3);
867 | background-image: url(images/icons-18-black.png);
868 | background-repeat: no-repeat;
869 | }
870 |
871 | /* HD/"retina" sprite
872 | -----------------------------------------------------------------------------------------------------------*/
873 |
874 | @media only screen and (-webkit-min-device-pixel-ratio: 1.5),
875 | only screen and (min--moz-device-pixel-ratio: 1.5),
876 | only screen and (min-resolution: 240dpi) {
877 |
878 | .ui-icon-plus, .ui-icon-minus, .ui-icon-delete, .ui-icon-arrow-r,
879 | .ui-icon-arrow-l, .ui-icon-arrow-u, .ui-icon-arrow-d, .ui-icon-check,
880 | .ui-icon-gear, .ui-icon-refresh, .ui-icon-forward, .ui-icon-back,
881 | .ui-icon-grid, .ui-icon-star, .ui-icon-alert, .ui-icon-info, .ui-icon-home, .ui-icon-search, .ui-icon-searchfield:after,
882 | .ui-icon-checkbox-off, .ui-icon-checkbox-on, .ui-icon-radio-off, .ui-icon-radio-on {
883 | background-image: url(images/icons-36-white.png);
884 | -moz-background-size: 776px 18px;
885 | -o-background-size: 776px 18px;
886 | -webkit-background-size: 776px 18px;
887 | background-size: 776px 18px;
888 | }
889 | .ui-icon-alt {
890 | background-image: url(images/icons-36-black.png);
891 | }
892 | }
893 |
894 | /* plus minus */
895 | .ui-icon-plus {
896 | background-position: -0 50%;
897 | }
898 | .ui-icon-minus {
899 | background-position: -36px 50%;
900 | }
901 |
902 | /* delete/close */
903 | .ui-icon-delete {
904 | background-position: -72px 50%;
905 | }
906 |
907 | /* arrows */
908 | .ui-icon-arrow-r {
909 | background-position: -108px 50%;
910 | }
911 | .ui-icon-arrow-l {
912 | background-position: -144px 50%;
913 | }
914 | .ui-icon-arrow-u {
915 | background-position: -180px 50%;
916 | }
917 | .ui-icon-arrow-d {
918 | background-position: -216px 50%;
919 | }
920 |
921 | /* misc */
922 | .ui-icon-check {
923 | background-position: -252px 50%;
924 | }
925 | .ui-icon-gear {
926 | background-position: -288px 50%;
927 | }
928 | .ui-icon-refresh {
929 | background-position: -324px 50%;
930 | }
931 | .ui-icon-forward {
932 | background-position: -360px 50%;
933 | }
934 | .ui-icon-back {
935 | background-position: -396px 50%;
936 | }
937 | .ui-icon-grid {
938 | background-position: -432px 50%;
939 | }
940 | .ui-icon-star {
941 | background-position: -468px 50%;
942 | }
943 | .ui-icon-alert {
944 | background-position: -504px 50%;
945 | }
946 | .ui-icon-info {
947 | background-position: -540px 50%;
948 | }
949 | .ui-icon-home {
950 | background-position: -576px 50%;
951 | }
952 | .ui-icon-search,
953 | .ui-icon-searchfield:after {
954 | background-position: -612px 50%;
955 | }
956 | .ui-icon-checkbox-off {
957 | background-position: -684px 50%;
958 | }
959 | .ui-icon-checkbox-on {
960 | background-position: -648px 50%;
961 | }
962 | .ui-icon-radio-off {
963 | background-position: -756px 50%;
964 | }
965 | .ui-icon-radio-on {
966 | background-position: -720px 50%;
967 | }
968 |
969 |
970 | /* checks,radios */
971 | .ui-checkbox .ui-icon {
972 | -moz-border-radius: 3px;
973 | -webkit-border-radius: 3px;
974 | border-radius: 3px;
975 | }
976 | .ui-icon-checkbox-off,
977 | .ui-icon-radio-off {
978 | background-color: transparent;
979 | }
980 | .ui-checkbox-on .ui-icon,
981 | .ui-radio-on .ui-icon {
982 | background-color: #4596ce /*{global-active-background-color}*/; /* NOTE: this hex should match the active state color. It's repeated here for cascade */
983 | }
984 |
985 | /* loading icon */
986 | .ui-icon-loading {
987 | background-image: url(images/ajax-loader.png);
988 | width: 40px;
989 | height: 40px;
990 | -moz-border-radius: 20px;
991 | -webkit-border-radius: 20px;
992 | border-radius: 20px;
993 | background-size: 35px 35px;
994 | }
995 |
996 |
997 | /* Button corner classes
998 | -----------------------------------------------------------------------------------------------------------*/
999 |
1000 | .ui-btn-corner-tl {
1001 | -moz-border-radius-topleft: 1em /*{global-radii-buttons}*/;
1002 | -webkit-border-top-left-radius: 1em /*{global-radii-buttons}*/;
1003 | border-top-left-radius: 1em /*{global-radii-buttons}*/;
1004 | }
1005 | .ui-btn-corner-tr {
1006 | -moz-border-radius-topright: 1em /*{global-radii-buttons}*/;
1007 | -webkit-border-top-right-radius: 1em /*{global-radii-buttons}*/;
1008 | border-top-right-radius: 1em /*{global-radii-buttons}*/;
1009 | }
1010 | .ui-btn-corner-bl {
1011 | -moz-border-radius-bottomleft: 1em /*{global-radii-buttons}*/;
1012 | -webkit-border-bottom-left-radius: 1em /*{global-radii-buttons}*/;
1013 | border-bottom-left-radius: 1em /*{global-radii-buttons}*/;
1014 | }
1015 | .ui-btn-corner-br {
1016 | -moz-border-radius-bottomright: 1em /*{global-radii-buttons}*/;
1017 | -webkit-border-bottom-right-radius: 1em /*{global-radii-buttons}*/;
1018 | border-bottom-right-radius: 1em /*{global-radii-buttons}*/;
1019 | }
1020 | .ui-btn-corner-top {
1021 | -moz-border-radius-topleft: 1em /*{global-radii-buttons}*/;
1022 | -webkit-border-top-left-radius: 1em /*{global-radii-buttons}*/;
1023 | border-top-left-radius: 1em /*{global-radii-buttons}*/;
1024 | -moz-border-radius-topright: 1em /*{global-radii-buttons}*/;
1025 | -webkit-border-top-right-radius: 1em /*{global-radii-buttons}*/;
1026 | border-top-right-radius: 1em /*{global-radii-buttons}*/;
1027 | }
1028 | .ui-btn-corner-bottom {
1029 | -moz-border-radius-bottomleft: 1em /*{global-radii-buttons}*/;
1030 | -webkit-border-bottom-left-radius: 1em /*{global-radii-buttons}*/;
1031 | border-bottom-left-radius: 1em /*{global-radii-buttons}*/;
1032 | -moz-border-radius-bottomright: 1em /*{global-radii-buttons}*/;
1033 | -webkit-border-bottom-right-radius: 1em /*{global-radii-buttons}*/;
1034 | border-bottom-right-radius: 1em /*{global-radii-buttons}*/;
1035 | }
1036 | .ui-btn-corner-right {
1037 | -moz-border-radius-topright: 1em /*{global-radii-buttons}*/;
1038 | -webkit-border-top-right-radius: 1em /*{global-radii-buttons}*/;
1039 | border-top-right-radius: 1em /*{global-radii-buttons}*/;
1040 | -moz-border-radius-bottomright: 1em /*{global-radii-buttons}*/;
1041 | -webkit-border-bottom-right-radius: 1em /*{global-radii-buttons}*/;
1042 | border-bottom-right-radius: 1em /*{global-radii-buttons}*/;
1043 | }
1044 | .ui-btn-corner-left {
1045 | -moz-border-radius-topleft: 1em /*{global-radii-buttons}*/;
1046 | -webkit-border-top-left-radius: 1em /*{global-radii-buttons}*/;
1047 | border-top-left-radius: 1em /*{global-radii-buttons}*/;
1048 | -moz-border-radius-bottomleft: 1em /*{global-radii-buttons}*/;
1049 | -webkit-border-bottom-left-radius: 1em /*{global-radii-buttons}*/;
1050 | border-bottom-left-radius: 1em /*{global-radii-buttons}*/;
1051 | }
1052 | .ui-btn-corner-all {
1053 | -moz-border-radius: 1em /*{global-radii-buttons}*/;
1054 | -webkit-border-radius: 1em /*{global-radii-buttons}*/;
1055 | border-radius: 1em /*{global-radii-buttons}*/;
1056 | }
1057 |
1058 | /* radius clip workaround for cleaning up corner trapping */
1059 | .ui-corner-tl,
1060 | .ui-corner-tr,
1061 | .ui-corner-bl,
1062 | .ui-corner-br,
1063 | .ui-corner-top,
1064 | .ui-corner-bottom,
1065 | .ui-corner-right,
1066 | .ui-corner-left,
1067 | .ui-corner-all,
1068 | .ui-btn-corner-tl,
1069 | .ui-btn-corner-tr,
1070 | .ui-btn-corner-bl,
1071 | .ui-btn-corner-br,
1072 | .ui-btn-corner-top,
1073 | .ui-btn-corner-bottom,
1074 | .ui-btn-corner-right,
1075 | .ui-btn-corner-left,
1076 | .ui-btn-corner-all {
1077 | -webkit-background-clip: padding-box;
1078 | -moz-background-clip: padding;
1079 | background-clip: padding-box;
1080 | }
1081 |
1082 | /* Overlay / modal
1083 | -----------------------------------------------------------------------------------------------------------*/
1084 |
1085 | .ui-overlay {
1086 | background: #666;
1087 | opacity: .5;
1088 | filter: Alpha(Opacity=50);
1089 | position: absolute;
1090 | width: 100%;
1091 | height: 100%;
1092 | }
1093 | .ui-overlay-shadow {
1094 | -moz-box-shadow: 0px 0px 12px rgba(0,0,0,.6);
1095 | -webkit-box-shadow: 0px 0px 12px rgba(0,0,0,.6);
1096 | box-shadow: 0px 0px 12px rgba(0,0,0,.6);
1097 | }
1098 | .ui-shadow {
1099 | -moz-box-shadow: 0px 1px 4px /*{global-box-shadow-size}*/ rgba(0,0,0,.3) /*{global-box-shadow-color}*/;
1100 | -webkit-box-shadow: 0px 1px 4px /*{global-box-shadow-size}*/ rgba(0,0,0,.3) /*{global-box-shadow-color}*/;
1101 | box-shadow: 0px 1px 4px /*{global-box-shadow-size}*/ rgba(0,0,0,.3) /*{global-box-shadow-color}*/;
1102 | }
1103 | .ui-bar-a .ui-shadow,
1104 | .ui-bar-b .ui-shadow ,
1105 | .ui-bar-c .ui-shadow {
1106 | -moz-box-shadow: 0px 1px 0 rgba(255,255,255,.3);
1107 | -webkit-box-shadow: 0px 1px 0 rgba(255,255,255,.3);
1108 | box-shadow: 0px 1px 0 rgba(255,255,255,.3);
1109 | }
1110 | .ui-shadow-inset {
1111 | -moz-box-shadow: inset 0px 1px 4px rgba(0,0,0,.2);
1112 | -webkit-box-shadow: inset 0px 1px 4px rgba(0,0,0,.2);
1113 | box-shadow: inset 0px 1px 4px rgba(0,0,0,.2);
1114 | }
1115 | .ui-icon-shadow {
1116 | -moz-box-shadow: 0px 1px 0 rgba(255,255,255,.4);
1117 | -webkit-box-shadow: 0px 1px 0 rgba(255,255,255,.4);
1118 | box-shadow: 0px 1px 0 rgba(255,255,255,.4);
1119 | }
1120 |
1121 | /* Focus state - set here for specificity
1122 | -----------------------------------------------------------------------------------------------------------*/
1123 |
1124 | .ui-focus {
1125 | -moz-box-shadow: 0px 0px 12px #387bbe /*{global-active-background-color}*/;
1126 | -webkit-box-shadow: 0px 0px 12px #387bbe /*{global-active-background-color}*/;
1127 | box-shadow: 0px 0px 12px #387bbe /*{global-active-background-color}*/;
1128 | }
1129 |
1130 | /* unset box shadow in browsers that don't do it right
1131 | -----------------------------------------------------------------------------------------------------------*/
1132 |
1133 | .ui-mobile-nosupport-boxshadow * {
1134 | -moz-box-shadow: none !important;
1135 | -webkit-box-shadow: none !important;
1136 | box-shadow: none !important;
1137 | }
1138 |
1139 | /* ...and bring back focus */
1140 | .ui-mobile-nosupport-boxshadow .ui-focus {
1141 | outline-width: 2px;
1142 | }
1143 | /* some unsets - more probably needed */
1144 | .ui-mobile, .ui-mobile body { height: 100%; }
1145 | .ui-mobile fieldset, .ui-page { padding: 0; margin: 0; }
1146 | .ui-mobile a img, .ui-mobile fieldset { border: 0; }
1147 |
1148 | /* responsive page widths */
1149 | .ui-mobile-viewport { margin: 0; overflow-x: visible; -webkit-text-size-adjust: none; -ms-text-size-adjust:none; -webkit-tap-highlight-color: rgba(0, 0, 0, 0); }
1150 | /* Issue #2066 */
1151 | body.ui-mobile-viewport,
1152 | div.ui-mobile-viewport { overflow-x: hidden; }
1153 |
1154 | /* "page" containers - full-screen views, one should always be in view post-pageload */
1155 | .ui-mobile [data-role=page], .ui-mobile [data-role=dialog], .ui-page { top: 0; left: 0; width: 100%; min-height: 100%; position: absolute; display: none; border: 0; }
1156 | .ui-mobile .ui-page-active { display: block; overflow: visible; }
1157 |
1158 | /* on ios4, setting focus on the page element causes flashing during transitions when there is an outline, so we turn off outlines */
1159 | .ui-page { outline: none; }
1160 |
1161 | /*orientations from js are available */
1162 | @media screen and (orientation: portrait){
1163 | .ui-mobile, .ui-mobile .ui-page { min-height: 420px; }
1164 | }
1165 | @media screen and (orientation: landscape){
1166 | .ui-mobile, .ui-mobile .ui-page { min-height: 300px; }
1167 | }
1168 |
1169 | /* native overflow scrolling */
1170 | .ui-page.ui-mobile-touch-overflow,
1171 | .ui-mobile-touch-overflow.ui-native-fixed .ui-content {
1172 | overflow: auto;
1173 | height: 100%;
1174 | -webkit-overflow-scrolling: touch;
1175 | -moz-overflow-scrolling: touch;
1176 | -o-overflow-scrolling: touch;
1177 | -ms-overflow-scrolling: touch;
1178 | overflow-scrolling: touch;
1179 | }
1180 | .ui-page.ui-mobile-touch-overflow,
1181 | .ui-page.ui-mobile-touch-overflow * {
1182 | /* some level of transform keeps elements from blinking out of visibility on iOS */
1183 | -webkit-transform: rotateY(0);
1184 | }
1185 | .ui-page.ui-mobile-pre-transition {
1186 | display: block;
1187 | }
1188 |
1189 | /* loading screen */
1190 | .ui-loading .ui-mobile-viewport { overflow: hidden !important; }
1191 | .ui-loading .ui-loader { display: block; }
1192 | .ui-loading .ui-page { overflow: hidden; }
1193 | .ui-loader { display: none; position: absolute; opacity: .85; z-index: 100; left: 50%; width: 200px; margin-left: -130px; margin-top: -35px; padding: 10px 30px; }
1194 | .ui-loader h1 { font-size: 15px; text-align: center; }
1195 | .ui-loader .ui-icon { position: static; display: block; opacity: .9; margin: 0 auto; width: 35px; height: 35px; background-color: transparent; }
1196 |
1197 | /*fouc*/
1198 | .ui-mobile-rendering > * { visibility: hidden; }
1199 |
1200 | /*headers, content panels*/
1201 | .ui-bar, .ui-body { position: relative; padding: .4em 15px; overflow: hidden; display: block; clear:both; }
1202 | .ui-bar { font-size: 16px; margin: 0; }
1203 | .ui-bar h1, .ui-bar h2, .ui-bar h3, .ui-bar h4, .ui-bar h5, .ui-bar h6 { margin: 0; padding: 0; font-size: 16px; display: inline-block; }
1204 |
1205 | .ui-header, .ui-footer { display: block; }
1206 | .ui-page .ui-header, .ui-page .ui-footer { position: relative; }
1207 | .ui-header .ui-btn-left { position: absolute; left: 10px; top: .4em; }
1208 | .ui-header .ui-btn-right { position: absolute; right: 10px; top: .4em; }
1209 | .ui-header .ui-title, .ui-footer .ui-title { min-height: 1.1em; text-align: center; font-size: 16px; display: block; margin: .6em 90px .8em; padding: 0; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; outline: 0 !important; }
1210 | .ui-footer .ui-title { margin: .6em 15px .8em; }
1211 |
1212 | /*content area*/
1213 | .ui-content { border-width: 0; overflow: visible; overflow-x: hidden; padding: 15px; }
1214 | .ui-page-fullscreen .ui-content { padding:0; }
1215 |
1216 | /* native fixed headers and footers */
1217 | .ui-mobile-touch-overflow.ui-page.ui-native-fixed,
1218 | .ui-mobile-touch-overflow.ui-page.ui-native-fullscreen {
1219 | overflow: visible;
1220 | }
1221 | .ui-mobile-touch-overflow.ui-native-fixed .ui-header,
1222 | .ui-mobile-touch-overflow.ui-native-fixed .ui-footer {
1223 | position: fixed;
1224 | left: 0;
1225 | right: 0;
1226 | top: 0;
1227 | z-index: 200;
1228 | }
1229 | .ui-mobile-touch-overflow.ui-page.ui-native-fixed .ui-footer {
1230 | top: auto;
1231 | bottom: 0;
1232 | }
1233 | .ui-mobile-touch-overflow.ui-native-fixed .ui-content {
1234 | padding-top: 2.5em;
1235 | padding-bottom: 3em;
1236 | top: 0;
1237 | bottom: 0;
1238 | height: auto;
1239 | position: absolute;
1240 | }
1241 | .ui-mobile-touch-overflow.ui-native-fullscreen .ui-content {
1242 | padding-top: 0;
1243 | padding-bottom: 0;
1244 | }
1245 | .ui-mobile-touch-overflow.ui-native-fullscreen .ui-header,
1246 | .ui-mobile-touch-overflow.ui-native-fullscreen .ui-footer {
1247 | opacity: .9;
1248 | }
1249 | .ui-native-bars-hidden {
1250 | display: none;
1251 | }
1252 |
1253 | /* icons sizing */
1254 | .ui-icon { width: 18px; height: 18px; }
1255 |
1256 | /* fullscreen class on ui-content div */
1257 | .ui-fullscreen { }
1258 | .ui-fullscreen img { max-width: 100%; }
1259 |
1260 | /* non-js content hiding */
1261 | .ui-nojs { position: absolute; left: -9999px; }
1262 |
1263 | /* accessible content hiding */
1264 | .ui-hide-label label,
1265 | .ui-hidden-accessible { position: absolute !important; left: -9999px; clip: rect(1px 1px 1px 1px); clip: rect(1px,1px,1px,1px); }
1266 | .spin {
1267 | -webkit-transform: rotate(360deg);
1268 | -webkit-animation-name: spin;
1269 | -webkit-animation-duration: 1s;
1270 | -webkit-animation-iteration-count: infinite;
1271 | -webkit-animation-timing-function: linear;
1272 | }
1273 | @-webkit-keyframes spin {
1274 | from {-webkit-transform: rotate(0deg);}
1275 | to {-webkit-transform: rotate(360deg);}
1276 | }
1277 |
1278 | /* Transitions from jQtouch (with small modifications): http://www.jqtouch.com/
1279 | Built by David Kaneda and maintained by Jonathan Stark.
1280 | */
1281 | .in, .out {
1282 | -webkit-animation-timing-function: ease-in-out;
1283 | -webkit-animation-duration: 350ms;
1284 | }
1285 |
1286 |
1287 | .slide.out {
1288 | -webkit-transform: translateX(-100%);
1289 | -webkit-animation-name: slideouttoleft;
1290 | }
1291 |
1292 | .slide.in {
1293 | -webkit-transform: translateX(0);
1294 | -webkit-animation-name: slideinfromright;
1295 | }
1296 |
1297 | .slide.out.reverse {
1298 | -webkit-transform: translateX(100%);
1299 | -webkit-animation-name: slideouttoright;
1300 | }
1301 |
1302 | .slide.in.reverse {
1303 | -webkit-transform: translateX(0);
1304 | -webkit-animation-name: slideinfromleft;
1305 | }
1306 |
1307 | .slideup.out {
1308 | -webkit-animation-name: dontmove;
1309 | z-index: 0;
1310 | }
1311 |
1312 | .slideup.in {
1313 | -webkit-transform: translateY(0);
1314 | -webkit-animation-name: slideinfrombottom;
1315 | z-index: 10;
1316 | }
1317 |
1318 | .slideup.in.reverse {
1319 | z-index: 0;
1320 | -webkit-animation-name: dontmove;
1321 | }
1322 |
1323 | .slideup.out.reverse {
1324 | -webkit-transform: translateY(100%);
1325 | z-index: 10;
1326 | -webkit-animation-name: slideouttobottom;
1327 | }
1328 |
1329 | .slidedown.out {
1330 | -webkit-animation-name: dontmove;
1331 | z-index: 0;
1332 | }
1333 |
1334 | .slidedown.in {
1335 | -webkit-transform: translateY(0);
1336 | -webkit-animation-name: slideinfromtop;
1337 | z-index: 10;
1338 | }
1339 |
1340 | .slidedown.in.reverse {
1341 | z-index: 0;
1342 | -webkit-animation-name: dontmove;
1343 | }
1344 |
1345 | .slidedown.out.reverse {
1346 | -webkit-transform: translateY(-100%);
1347 | z-index: 10;
1348 | -webkit-animation-name: slideouttotop;
1349 | }
1350 |
1351 | @-webkit-keyframes slideinfromright {
1352 | from { -webkit-transform: translateX(100%); }
1353 | to { -webkit-transform: translateX(0); }
1354 | }
1355 |
1356 | @-webkit-keyframes slideinfromleft {
1357 | from { -webkit-transform: translateX(-100%); }
1358 | to { -webkit-transform: translateX(0); }
1359 | }
1360 |
1361 | @-webkit-keyframes slideouttoleft {
1362 | from { -webkit-transform: translateX(0); }
1363 | to { -webkit-transform: translateX(-100%); }
1364 | }
1365 |
1366 | @-webkit-keyframes slideouttoright {
1367 | from { -webkit-transform: translateX(0); }
1368 | to { -webkit-transform: translateX(100%); }
1369 | }
1370 |
1371 | @-webkit-keyframes slideinfromtop {
1372 | from { -webkit-transform: translateY(-100%); }
1373 | to { -webkit-transform: translateY(0); }
1374 | }
1375 |
1376 | @-webkit-keyframes slideinfrombottom {
1377 | from { -webkit-transform: translateY(100%); }
1378 | to { -webkit-transform: translateY(0); }
1379 | }
1380 |
1381 | @-webkit-keyframes slideouttobottom {
1382 | from { -webkit-transform: translateY(0); }
1383 | to { -webkit-transform: translateY(100%); }
1384 | }
1385 |
1386 | @-webkit-keyframes slideouttotop {
1387 | from { -webkit-transform: translateY(0); }
1388 | to { -webkit-transform: translateY(-100%); }
1389 | }
1390 | @-webkit-keyframes fadein {
1391 | from { opacity: 0; }
1392 | to { opacity: 1; }
1393 | }
1394 |
1395 | @-webkit-keyframes fadeout {
1396 | from { opacity: 1; }
1397 | to { opacity: 0; }
1398 | }
1399 |
1400 | .fade.out {
1401 | z-index: 0;
1402 | -webkit-animation-name: fadeout;
1403 | }
1404 |
1405 | .fade.in {
1406 | opacity: 1;
1407 | z-index: 10;
1408 | -webkit-animation-name: fadein;
1409 | }
1410 |
1411 | /* The properties in this rule are only necessary for the 'flip' transition.
1412 | * We need specify the perspective to create a projection matrix. This will add
1413 | * some depth as the element flips. The depth number represents the distance of
1414 | * the viewer from the z-plane. According to the CSS3 spec, 1000 is a moderate
1415 | * value.
1416 | */
1417 | .viewport-flip {
1418 | -webkit-perspective: 1000;
1419 | position: absolute;
1420 | }
1421 |
1422 | .ui-mobile-viewport-transitioning,
1423 | .ui-mobile-viewport-transitioning .ui-page {
1424 | width: 100%;
1425 | height: 100%;
1426 | overflow: hidden;
1427 | }
1428 |
1429 | .flip {
1430 | -webkit-animation-duration: .65s;
1431 | -webkit-backface-visibility:hidden;
1432 | -webkit-transform:translateX(0); /* Needed to work around an iOS 3.1 bug that causes listview thumbs to disappear when -webkit-visibility:hidden is used. */
1433 | }
1434 |
1435 | .flip.out {
1436 | -webkit-transform: rotateY(-180deg) scale(.8);
1437 | -webkit-animation-name: flipouttoleft;
1438 | }
1439 |
1440 | .flip.in {
1441 | -webkit-transform: rotateY(0) scale(1);
1442 | -webkit-animation-name: flipinfromleft;
1443 | }
1444 |
1445 | /* Shake it all about */
1446 |
1447 | .flip.out.reverse {
1448 | -webkit-transform: rotateY(180deg) scale(.8);
1449 | -webkit-animation-name: flipouttoright;
1450 | }
1451 |
1452 | .flip.in.reverse {
1453 | -webkit-transform: rotateY(0) scale(1);
1454 | -webkit-animation-name: flipinfromright;
1455 | }
1456 |
1457 | @-webkit-keyframes flipinfromright {
1458 | from { -webkit-transform: rotateY(-180deg) scale(.8); }
1459 | to { -webkit-transform: rotateY(0) scale(1); }
1460 | }
1461 |
1462 | @-webkit-keyframes flipinfromleft {
1463 | from { -webkit-transform: rotateY(180deg) scale(.8); }
1464 | to { -webkit-transform: rotateY(0) scale(1); }
1465 | }
1466 |
1467 | @-webkit-keyframes flipouttoleft {
1468 | from { -webkit-transform: rotateY(0) scale(1); }
1469 | to { -webkit-transform: rotateY(-180deg) scale(.8); }
1470 | }
1471 |
1472 | @-webkit-keyframes flipouttoright {
1473 | from { -webkit-transform: rotateY(0) scale(1); }
1474 | to { -webkit-transform: rotateY(180deg) scale(.8); }
1475 | }
1476 |
1477 |
1478 | /* Hackish, but reliable. */
1479 |
1480 | @-webkit-keyframes dontmove {
1481 | from { opacity: 1; }
1482 | to { opacity: 1; }
1483 | }
1484 |
1485 | .pop {
1486 | -webkit-transform-origin: 50% 50%;
1487 | }
1488 |
1489 | .pop.in {
1490 | -webkit-transform: scale(1);
1491 | opacity: 1;
1492 | -webkit-animation-name: popin;
1493 | z-index: 10;
1494 | }
1495 |
1496 | .pop.in.reverse {
1497 | z-index: 0;
1498 | -webkit-animation-name: dontmove;
1499 | }
1500 |
1501 | .pop.out.reverse {
1502 | -webkit-transform: scale(.2);
1503 | opacity: 0;
1504 | -webkit-animation-name: popout;
1505 | z-index: 10;
1506 | }
1507 |
1508 | @-webkit-keyframes popin {
1509 | from {
1510 | -webkit-transform: scale(.2);
1511 | opacity: 0;
1512 | }
1513 | to {
1514 | -webkit-transform: scale(1);
1515 | opacity: 1;
1516 | }
1517 | }
1518 |
1519 | @-webkit-keyframes popout {
1520 | from {
1521 | -webkit-transform: scale(1);
1522 | opacity: 1;
1523 | }
1524 | to {
1525 | -webkit-transform: scale(.2);
1526 | opacity: 0;
1527 | }
1528 | }/* content configurations. */
1529 | .ui-grid-a, .ui-grid-b, .ui-grid-c, .ui-grid-d { overflow: hidden; }
1530 | .ui-block-a, .ui-block-b, .ui-block-c, .ui-block-d, .ui-block-e { margin: 0; padding: 0; border: 0; float: left; min-height:1px;}
1531 |
1532 | /* grid solo: 100 - single item fallback */
1533 | .ui-grid-solo .ui-block-a { width: 100%; float: none; }
1534 |
1535 | /* grid a: 50/50 */
1536 | .ui-grid-a .ui-block-a, .ui-grid-a .ui-block-b { width: 50%; }
1537 | .ui-grid-a .ui-block-a { clear: left; }
1538 |
1539 | /* grid b: 33/33/33 */
1540 | .ui-grid-b .ui-block-a, .ui-grid-b .ui-block-b, .ui-grid-b .ui-block-c { width: 33.333%; }
1541 | .ui-grid-b .ui-block-a { clear: left; }
1542 |
1543 | /* grid c: 25/25/25/25 */
1544 | .ui-grid-c .ui-block-a, .ui-grid-c .ui-block-b, .ui-grid-c .ui-block-c, .ui-grid-c .ui-block-d { width: 25%; }
1545 | .ui-grid-c .ui-block-a { clear: left; }
1546 |
1547 | /* grid d: 20/20/20/20/20 */
1548 | .ui-grid-d .ui-block-a, .ui-grid-d .ui-block-b, .ui-grid-d .ui-block-c, .ui-grid-d .ui-block-d, .ui-grid-d .ui-block-e { width: 20%; }
1549 | .ui-grid-d .ui-block-a { clear: left; }
1550 | /* fixed page header & footer configuration */
1551 | .ui-header, .ui-footer, .ui-page-fullscreen .ui-header, .ui-page-fullscreen .ui-footer { position: absolute; overflow: hidden; width: 100%; border-left-width: 0; border-right-width: 0; }
1552 | .ui-header-fixed, .ui-footer-fixed {
1553 | z-index: 1000;
1554 | -webkit-transform: translateZ(0); /* Force header/footer rendering to go through the same rendering pipeline as native page scrolling. */
1555 | }
1556 | .ui-footer-duplicate, .ui-page-fullscreen .ui-fixed-inline { display: none; }
1557 | .ui-page-fullscreen .ui-header, .ui-page-fullscreen .ui-footer { opacity: .9; }
1558 | .ui-navbar { overflow: hidden; }
1559 | .ui-navbar ul, .ui-navbar-expanded ul { list-style:none; padding: 0; margin: 0; position: relative; display: block; border: 0;}
1560 | .ui-navbar-collapsed ul { float: left; width: 75%; margin-right: -2px; }
1561 | .ui-navbar-collapsed .ui-navbar-toggle { float: left; width: 25%; }
1562 | .ui-navbar li.ui-navbar-truncate { position: absolute; left: -9999px; top: -9999px; }
1563 | .ui-navbar li .ui-btn, .ui-navbar .ui-navbar-toggle .ui-btn { display: block; font-size: 12px; text-align: center; margin: 0; border-right-width: 0; }
1564 | .ui-navbar li .ui-btn { margin-right: -1px; }
1565 | .ui-navbar li .ui-btn:last-child { margin-right: 0; }
1566 | .ui-header .ui-navbar li .ui-btn, .ui-header .ui-navbar .ui-navbar-toggle .ui-btn,
1567 | .ui-footer .ui-navbar li .ui-btn, .ui-footer .ui-navbar .ui-navbar-toggle .ui-btn { border-top-width: 0; border-bottom-width: 0; }
1568 | .ui-navbar .ui-btn-inner { padding-left: 2px; padding-right: 2px; }
1569 | .ui-navbar-noicons li .ui-btn .ui-btn-inner, .ui-navbar-noicons .ui-navbar-toggle .ui-btn-inner { padding-top: .8em; padding-bottom: .9em; }
1570 | /*expanded page styles*/
1571 | .ui-navbar-expanded .ui-btn { margin: 0; font-size: 14px; }
1572 | .ui-navbar-expanded .ui-btn-inner { padding-left: 5px; padding-right: 5px; }
1573 | .ui-navbar-expanded .ui-btn-icon-top .ui-btn-inner { padding: 45px 5px 15px; text-align: center; }
1574 | .ui-navbar-expanded .ui-btn-icon-top .ui-icon { top: 15px; }
1575 | .ui-navbar-expanded .ui-btn-icon-bottom .ui-btn-inner { padding: 15px 5px 45px; text-align: center; }
1576 | .ui-navbar-expanded .ui-btn-icon-bottom .ui-icon { bottom: 15px; }
1577 | .ui-navbar-expanded li .ui-btn .ui-btn-inner { min-height: 2.5em; }
1578 | .ui-navbar-expanded .ui-navbar-noicons .ui-btn .ui-btn-inner { padding-top: 1.8em; padding-bottom: 1.9em; }
1579 | .ui-btn { display: block; text-align: center; cursor:pointer; position: relative; margin: .5em 5px; padding: 0; }
1580 | .ui-header .ui-btn, .ui-footer .ui-btn, .ui-bar .ui-btn { display: inline-block; font-size: 13px; margin: 0; }
1581 | .ui-btn-inline { display: inline-block; }
1582 | .ui-btn-inner { padding: .6em 25px; display: block; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; position: relative; zoom: 1; }
1583 | .ui-btn input, .ui-btn button { z-index: 2; }
1584 | .ui-header .ui-btn-inner, .ui-footer .ui-btn-inner, .ui-bar .ui-btn-inner { padding: .4em 8px .5em; }
1585 | .ui-btn-icon-notext { width: 24px; height: 24px; }
1586 | .ui-btn-icon-notext .ui-btn-inner { padding: 2px 1px 2px 3px; }
1587 | .ui-btn-text { position: relative; z-index: 1; }
1588 | .ui-btn-icon-notext .ui-btn-text { position: absolute; left: -9999px; }
1589 | .ui-btn-icon-left .ui-btn-inner { padding-left: 33px; }
1590 | .ui-header .ui-btn-icon-left .ui-btn-inner,
1591 | .ui-footer .ui-btn-icon-left .ui-btn-inner,
1592 | .ui-bar .ui-btn-icon-left .ui-btn-inner { padding-left: 27px; }
1593 | .ui-btn-icon-right .ui-btn-inner { padding-right: 33px; }
1594 | .ui-header .ui-btn-icon-right .ui-btn-inner,
1595 | .ui-footer .ui-btn-icon-right .ui-btn-inner,
1596 | .ui-bar .ui-btn-icon-right .ui-btn-inner { padding-right: 27px; }
1597 | .ui-btn-icon-top .ui-btn-inner { padding-top: 33px; }
1598 | .ui-header .ui-btn-icon-top .ui-btn-inner,
1599 | .ui-footer .ui-btn-icon-top .ui-btn-inner,
1600 | .ui-bar .ui-btn-icon-top .ui-btn-inner { padding-top: 27px; }
1601 | .ui-btn-icon-bottom .ui-btn-inner { padding-bottom: 33px; }
1602 | .ui-header .ui-btn-icon-bottom .ui-btn-inner,
1603 | .ui-footer .ui-btn-icon-bottom .ui-btn-inner,
1604 | .ui-bar .ui-btn-icon-bottom .ui-btn-inner { padding-bottom: 27px; }
1605 |
1606 | /*btn icon positioning*/
1607 | .ui-btn-icon-notext .ui-icon { display: block; z-index: 0;}
1608 | .ui-btn-icon-left .ui-icon, .ui-btn-icon-right .ui-icon { position: absolute; top: 50%; margin-top: -9px; }
1609 | .ui-btn-icon-top .ui-icon, .ui-btn-icon-bottom .ui-icon { position: absolute; left: 50%; margin-left: -9px; }
1610 | .ui-btn-icon-left .ui-icon { left: 10px; }
1611 | .ui-btn-icon-right .ui-icon { right: 10px; }
1612 | .ui-btn-icon-top .ui-icon { top: 10px; }
1613 | .ui-btn-icon-bottom .ui-icon { bottom: 10px; }
1614 | .ui-header .ui-btn-icon-left .ui-icon,
1615 | .ui-footer .ui-btn-icon-left .ui-icon,
1616 | .ui-bar .ui-btn-icon-left .ui-icon { left: 4px; }
1617 | .ui-header .ui-btn-icon-right .ui-icon,
1618 | .ui-footer .ui-btn-icon-right .ui-icon,
1619 | .ui-bar .ui-btn-icon-right .ui-icon { right: 4px; }
1620 | .ui-header .ui-btn-icon-top .ui-icon,
1621 | .ui-footer .ui-btn-icon-top .ui-icon,
1622 | .ui-bar .ui-btn-icon-top .ui-icon { top: 4px; }
1623 | .ui-header .ui-btn-icon-bottom .ui-icon,
1624 | .ui-footer .ui-btn-icon-bottom .ui-icon,
1625 | .ui-bar .ui-btn-icon-bottom .ui-icon { bottom: 4px; }
1626 |
1627 | /*hiding native button,inputs */
1628 | .ui-btn-hidden { position: absolute; top: 0; left: 0; width: 100%; height: 100%; -webkit-appearance: button; opacity: .1; cursor: pointer; background: #fff; background: rgba(255,255,255,0); filter: Alpha(Opacity=.0001); font-size: 1px; border: none; line-height: 999px; }
1629 | .ui-collapsible { margin: .5em 0; }
1630 | .ui-collapsible-heading { font-size: 16px; display: block; margin: 0 -8px; padding: 0; border-width: 0 0 1px 0; position: relative; }
1631 | .ui-collapsible-heading a { text-align: left; margin: 0; }
1632 | .ui-collapsible-heading a .ui-btn-inner { padding-left: 40px; }
1633 | .ui-collapsible-heading a span.ui-btn { position: absolute; left: 6px; top: 50%; margin: -12px 0 0 0; width: 20px; height: 20px; padding: 1px 0px 1px 2px; text-indent: -9999px; }
1634 | .ui-collapsible-heading a span.ui-btn .ui-btn-inner { padding: 10px 0; }
1635 | .ui-collapsible-heading a span.ui-btn .ui-icon { left: 0; margin-top: -10px; }
1636 | .ui-collapsible-heading-status { position: absolute; top: -9999px; left:0px; }
1637 | .ui-collapsible-content {
1638 | display: block;
1639 | margin: 0 -8px;
1640 | padding: 10px 16px;
1641 | border-top: none; /* Overrides ui-btn-up-* */
1642 | background-image: none; /* Overrides ui-btn-up-* */
1643 | font-weight: normal; /* Overrides ui-btn-up-* */
1644 | }
1645 | .ui-collapsible-content-collapsed { display: none; }
1646 |
1647 | .ui-collapsible-set { margin: .5em 0; }
1648 | .ui-collapsible-set .ui-collapsible { margin: -1px 0 0; }
1649 | .ui-controlgroup, fieldset.ui-controlgroup { padding: 0; margin: .5em 0 1em; }
1650 | .ui-bar .ui-controlgroup { margin: 0 .3em; }
1651 | .ui-controlgroup-label { font-size: 16px; line-height: 1.4; font-weight: normal; margin: 0 0 .3em; }
1652 | .ui-controlgroup-controls { display: block; width: 100%;}
1653 | .ui-controlgroup li { list-style: none; }
1654 | .ui-controlgroup-vertical .ui-btn,
1655 | .ui-controlgroup-vertical .ui-checkbox, .ui-controlgroup-vertical .ui-radio { margin: 0; border-bottom-width: 0; }
1656 | .ui-controlgroup-controls label.ui-select { position: absolute; left: -9999px; }
1657 |
1658 | .ui-controlgroup-vertical .ui-controlgroup-last { border-bottom-width: 1px; }
1659 | .ui-controlgroup-horizontal { padding: 0; }
1660 | .ui-controlgroup-horizontal .ui-btn, .ui-controlgroup-horizontal .ui-select { display: inline-block; margin: 0 -5px 0 0; }
1661 | .ui-controlgroup-horizontal .ui-checkbox, .ui-controlgroup-horizontal .ui-radio { float: left; margin: 0 -1px 0 0; }
1662 | .ui-controlgroup-horizontal .ui-checkbox .ui-btn, .ui-controlgroup-horizontal .ui-radio .ui-btn,
1663 | .ui-controlgroup-horizontal .ui-checkbox:last-child, .ui-controlgroup-horizontal .ui-radio:last-child { margin-right: 0; }
1664 | .ui-controlgroup-horizontal .ui-controlgroup-last { margin-right: 0; }
1665 | .ui-controlgroup .ui-checkbox label, .ui-controlgroup .ui-radio label { font-size: 16px; }
1666 | /* conflicts with listview..
1667 | .ui-controlgroup .ui-btn-icon-notext { width: 30px; height: 30px; text-indent: -9999px; }
1668 | .ui-controlgroup .ui-btn-icon-notext .ui-btn-inner { padding: 5px 6px 5px 5px; }
1669 | */
1670 |
1671 | @media all and (min-width: 450px){
1672 | .ui-field-contain .ui-controlgroup-label { vertical-align: top; display: inline-block; width: 20%; margin: 0 2% 0 0; }
1673 | .ui-field-contain .ui-controlgroup-controls { width: 60%; display: inline-block; }
1674 | .ui-field-contain .ui-controlgroup .ui-select { width: 100%; }
1675 | .ui-field-contain .ui-controlgroup-horizontal .ui-select { width: auto; }
1676 | } .ui-dialog { min-height: 480px; }
1677 | .ui-dialog .ui-header,
1678 | .ui-dialog .ui-content,
1679 | .ui-dialog .ui-footer {
1680 | max-width: 500px;
1681 | margin: 10% auto 15px auto;
1682 | width: 85%;
1683 | position: relative;
1684 | }
1685 | .ui-dialog .ui-header,
1686 | .ui-dialog .ui-footer {
1687 | padding: 0 15px;
1688 | z-index: 10;
1689 | }
1690 | .ui-dialog .ui-content {
1691 | padding: 15px;
1692 | }
1693 | .ui-dialog .ui-content,
1694 | .ui-dialog .ui-footer {
1695 | margin-top: -15px;
1696 | }
1697 | .ui-checkbox, .ui-radio { position:relative; margin: .2em 0 .5em; z-index: 1; }
1698 | .ui-checkbox .ui-btn, .ui-radio .ui-btn { margin: 0; text-align: left; z-index: 2; }
1699 | .ui-checkbox .ui-btn-inner, .ui-radio .ui-btn-inner { white-space: normal; }
1700 | .ui-checkbox .ui-btn-icon-left .ui-btn-inner,.ui-radio .ui-btn-icon-left .ui-btn-inner { padding-left: 45px; }
1701 | .ui-checkbox .ui-btn-icon-right .ui-btn-inner, .ui-radio .ui-btn-icon-right .ui-btn-inner { padding-right: 45px; }
1702 | .ui-checkbox .ui-icon, .ui-radio .ui-icon { top: 1.1em; }
1703 | .ui-checkbox .ui-btn-icon-left .ui-icon, .ui-radio .ui-btn-icon-left .ui-icon {left: 15px; }
1704 | .ui-checkbox .ui-btn-icon-right .ui-icon, .ui-radio .ui-btn-icon-right .ui-icon {right: 15px; }
1705 | /* input, label positioning */
1706 | .ui-checkbox input,.ui-radio input { position:absolute; left:20px; top:50%; width: 10px; height: 10px; margin:-5px 0 0 0; outline: 0 !important; z-index: 1; }.ui-field-contain { padding: 1.5em 0; margin: 0; border-bottom-width: 1px; overflow: visible; }
1707 | .ui-field-contain:first-child { border-top-width: 0; }
1708 | @media all and (min-width: 450px){
1709 | .ui-field-contain { border-width: 0; padding: 0; margin: 1em 0; }
1710 | } .ui-select { display: block; position: relative; }
1711 | .ui-select select { position: absolute; left: -9999px; top: -9999px; }
1712 | .ui-select .ui-btn { overflow: hidden; }
1713 |
1714 |
1715 | .ui-select .ui-btn { opacity: 1; }
1716 |
1717 | /* Fixes #2588 — When Windows Phone 7.5 (Mango) tries to calculate a numeric opacity for a select—including “inherit”—without explicitly specifying an opacity on the parent to give it context, a bug appears where clicking elsewhere on the page after opening the select will open the select again. */
1718 | .ui-select .ui-btn select { cursor: pointer; -webkit-appearance: button; left: 0; top:0; width: 100%; min-height: 1.5em; min-height: 100%; height: 3em; max-height: 100%; opacity: 0; -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)"; filter: alpha(opacity=0); z-index: 2; }
1719 |
1720 | .ui-select .ui-disabled { opacity: .3; }
1721 |
1722 | @-moz-document url-prefix() {.ui-select .ui-btn select { opacity: 0.0001; }}
1723 | .ui-select .ui-btn select.ui-select-nativeonly { opacity: 1; text-indent: 0; }
1724 |
1725 | .ui-select .ui-btn-icon-right .ui-btn-inner { padding-right: 45px; }
1726 | .ui-select .ui-btn-icon-right .ui-icon { right: 15px; }
1727 |
1728 | /* labels */
1729 | label.ui-select { font-size: 16px; line-height: 1.4; font-weight: normal; margin: 0 0 .3em; display: block; }
1730 |
1731 | /*listbox*/
1732 | .ui-select .ui-btn-text, .ui-selectmenu .ui-btn-text { display: block; min-height: 1em; overflow: hidden; }
1733 | .ui-select .ui-btn-text { text-overflow: ellipsis; }
1734 |
1735 | .ui-selectmenu { position: absolute; padding: 0; z-index: 1100 !important; width: 80%; max-width: 350px; padding: 6px; }
1736 | .ui-selectmenu .ui-listview { margin: 0; }
1737 | .ui-selectmenu .ui-btn.ui-li-divider { cursor: default; }
1738 | .ui-selectmenu-hidden { top: -9999px; left: -9999px; }
1739 | .ui-selectmenu-screen { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 99; }
1740 | .ui-screen-hidden, .ui-selectmenu-list .ui-li .ui-icon { display: none; }
1741 | .ui-selectmenu-list .ui-li .ui-icon { display: block; }
1742 | .ui-li.ui-selectmenu-placeholder { display: none; }
1743 | .ui-selectmenu .ui-header .ui-title { margin: 0.6em 46px 0.8em; }
1744 |
1745 | @media all and (min-width: 450px){
1746 | .ui-field-contain label.ui-select { vertical-align: top; display: inline-block; width: 20%; margin: 0 2% 0 0; }
1747 | .ui-field-contain .ui-select { width: 60%; display: inline-block; }
1748 | }
1749 |
1750 | /* when no placeholder is defined in a multiple select, the header height doesn't even extend past the close button. this shim's content in there */
1751 | .ui-selectmenu .ui-header h1:after { content: '.'; visibility: hidden; }label.ui-input-text { font-size: 16px; line-height: 1.4; display: block; font-weight: normal; margin: 0 0 .3em; }
1752 | input.ui-input-text, textarea.ui-input-text { background-image: none; padding: .4em; line-height: 1.4; font-size: 16px; display: block; width: 97%; }
1753 | input.ui-input-text { -webkit-appearance: none; }
1754 | textarea.ui-input-text { height: 50px; -webkit-transition: height 200ms linear; -moz-transition: height 200ms linear; -o-transition: height 200ms linear; transition: height 200ms linear; }
1755 | .ui-input-search { padding: 0 30px; background-image: none; position: relative; }
1756 | .ui-icon-searchfield:after { position: absolute; left: 7px; top: 50%; margin-top: -9px; content: ""; width: 18px; height: 18px; opacity: .5; }
1757 | .ui-input-search input.ui-input-text { border: none; width: 98%; padding: .4em 0; margin: 0; display: block; background: transparent none; outline: 0 !important; }
1758 | .ui-input-search .ui-input-clear { position: absolute; right: 0; top: 50%; margin-top: -13px; }
1759 | .ui-input-search .ui-input-clear-hidden { display: none; }
1760 |
1761 | /* orientation adjustments - incomplete!*/
1762 | @media all and (min-width: 450px){
1763 | .ui-field-contain label.ui-input-text { vertical-align: top; display: inline-block; width: 20%; margin: 0 2% 0 0 }
1764 | .ui-field-contain input.ui-input-text,
1765 | .ui-field-contain textarea.ui-input-text,
1766 | .ui-field-contain .ui-input-search { width: 60%; display: inline-block; }
1767 | .ui-field-contain .ui-input-search { width: 50%; }
1768 | .ui-hide-label input.ui-input-text,
1769 | .ui-hide-label textarea.ui-input-text,
1770 | .ui-hide-label .ui-input-search { padding: .4em; width: 97%; }
1771 | .ui-input-search input.ui-input-text { width: 98%; /*echos rule from above*/ }
1772 | }.ui-listview { margin: 0; counter-reset: listnumbering; }
1773 | .ui-content .ui-listview { margin: -15px; }
1774 | .ui-content .ui-listview-inset { margin: 1em 0; }
1775 | .ui-listview, .ui-li { list-style:none; padding:0; }
1776 | .ui-li, .ui-li.ui-field-contain { display: block; margin:0; position: relative; overflow: visible; text-align: left; border-width: 0; border-top-width: 1px; }
1777 | .ui-li .ui-btn-text a.ui-link-inherit { text-overflow: ellipsis; overflow: hidden; white-space: nowrap; }
1778 | .ui-li-divider, .ui-li-static { padding: .5em 15px; font-size: 14px; font-weight: bold; }
1779 | .ui-li-divider { counter-reset: listnumbering; }
1780 | ol.ui-listview .ui-link-inherit:before, ol.ui-listview .ui-li-static:before, .ui-li-dec { font-size: .8em; display: inline-block; padding-right: .3em; font-weight: normal;counter-increment: listnumbering; content: counter(listnumbering) ". "; }
1781 | ol.ui-listview .ui-li-jsnumbering:before { content: "" !important; } /* to avoid chance of duplication */
1782 | .ui-listview-inset .ui-li { border-right-width: 1px; border-left-width: 1px; }
1783 | .ui-li:last-child, .ui-li.ui-field-contain:last-child { border-bottom-width: 1px; }
1784 | .ui-li>.ui-btn-inner { display: block; position: relative; padding: 0; }
1785 | .ui-li .ui-btn-inner a.ui-link-inherit, .ui-li-static.ui-li { padding: .7em 15px .7em 15px; display: block; }
1786 | .ui-li-has-thumb .ui-btn-inner a.ui-link-inherit, .ui-li-static.ui-li-has-thumb { min-height: 60px; padding-left: 100px; }
1787 | .ui-li-has-icon .ui-btn-inner a.ui-link-inherit, .ui-li-static.ui-li-has-icon { min-height: 20px; padding-left: 40px; }
1788 | .ui-li-has-count .ui-btn-inner a.ui-link-inherit, .ui-li-static.ui-li-has-count { padding-right: 45px; }
1789 | .ui-li-has-arrow .ui-btn-inner a.ui-link-inherit, .ui-li-static.ui-li-has-arrow { padding-right: 30px; }
1790 | .ui-li-has-arrow.ui-li-has-count .ui-btn-inner a.ui-link-inherit, .ui-li-static.ui-li-has-arrow.ui-li-has-count { padding-right: 75px; }
1791 | .ui-li-has-count .ui-btn-text { padding-right: 15px; }
1792 | .ui-li-heading { font-size: 16px; font-weight: bold; display: block; margin: .6em 0; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; }
1793 | .ui-li-desc { font-size: 12px; font-weight: normal; display: block; margin: -.5em 0 .6em; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; }
1794 | .ui-li-thumb, .ui-listview .ui-li-icon { position: absolute; left: 1px; top: 0; max-height: 80px; max-width: 80px; }
1795 | .ui-listview .ui-li-icon { max-height: 40px; max-width: 40px; left: 10px; top: .9em; }
1796 | .ui-li-thumb, .ui-listview .ui-li-icon, .ui-li-content { float: left; margin-right: 10px; }
1797 |
1798 | .ui-li-aside { float: right; width: 50%; text-align: right; margin: .3em 0; }
1799 | @media all and (min-width: 480px){
1800 | .ui-li-aside { width: 45%; }
1801 | }
1802 | .ui-li-divider { cursor: default; }
1803 | .ui-li-has-alt .ui-btn-inner a.ui-link-inherit, .ui-li-static.ui-li-has-alt { padding-right: 95px; }
1804 | .ui-li-has-count .ui-li-count { position: absolute; font-size: 11px; font-weight: bold; padding: .2em .5em; top: 50%; margin-top: -.9em; right: 38px; }
1805 | .ui-li-divider .ui-li-count, .ui-li-static .ui-li-count { right: 10px; }
1806 | .ui-li-has-alt .ui-li-count { right: 55px; }
1807 | .ui-li-link-alt { position: absolute; width: 40px; height: 100%; border-width: 0; border-left-width: 1px; top: 0; right: 0; margin: 0; padding: 0; z-index: 2; }
1808 | .ui-li-link-alt .ui-btn { overflow: hidden; position: absolute; right: 8px; top: 50%; margin: -11px 0 0 0; border-bottom-width: 1px; z-index: -1;}
1809 | .ui-li-link-alt .ui-btn-inner { padding: 0; height: 100%; position: absolute; width: 100%; top: 0; left: 0;}
1810 | .ui-li-link-alt .ui-btn .ui-icon { right: 50%; margin-right: -9px; }
1811 |
1812 | .ui-listview * .ui-btn-inner > .ui-btn > .ui-btn-inner { border-top: 0px; }
1813 |
1814 | .ui-listview-filter { border-width: 0; overflow: hidden; margin: -15px -15px 15px -15px }
1815 | .ui-listview-filter .ui-input-search { margin: 5px; width: auto; display: block; }
1816 |
1817 | .ui-listview-filter-inset { margin: -15px -5px -15px -5px; background: transparent; }
1818 | .ui-li.ui-screen-hidden{display:none;}
1819 | /* Odd iPad positioning issue. */
1820 | @media only screen and (min-device-width: 768px) and (max-device-width: 1024px) {
1821 | .ui-li .ui-btn-text { overflow: visible; }
1822 | }label.ui-slider { font-size: 16px; line-height: 1.4; font-weight: normal; margin: 0 0 .3em; display: block; }
1823 | input.ui-slider-input,
1824 | .ui-field-contain input.ui-slider-input { display: inline-block; width: 50px; }
1825 | select.ui-slider-switch { display: none; }
1826 | div.ui-slider { position: relative; display: inline-block; overflow: visible; height: 15px; padding: 0; margin: 0 2% 0 20px; top: 4px; width: 60%; }
1827 | div.ui-slider-switch { width: 99.8%; }
1828 | a.ui-slider-handle { position: absolute; z-index: 10; top: 50%; width: 28px; height: 28px; margin-top: -15px; margin-left: -15px; }
1829 | a.ui-slider-handle .ui-btn-inner { padding-left: 0; padding-right: 0; }
1830 | @media all and (min-width: 480px){
1831 | .ui-field-contain label.ui-slider { vertical-align: top; display: inline-block; width: 20%; margin: 0 2% 0 0; }
1832 | .ui-field-contain div.ui-slider { width: 43%; }
1833 | }
1834 |
1835 | div.ui-slider-switch { height: 32px; overflow: hidden; margin-left: 0; }
1836 | div.ui-slider-inneroffset { margin-left: 50%; position: absolute; top: 1px; height: 100%; width: 50%; }
1837 | a.ui-slider-handle-snapping { -webkit-transition: left 70ms linear; }
1838 | div.ui-slider-labelbg { position: absolute; top:0; margin: 0; border-width: 0; }
1839 | div.ui-slider-switch div.ui-slider-labelbg-a { width: 60%; height: 100%; left: 0; }
1840 | div.ui-slider-switch div.ui-slider-labelbg-b { width: 60%; height: 100%; right: 0; }
1841 | .ui-slider-switch-a div.ui-slider-labelbg-a, .ui-slider-switch-b div.ui-slider-labelbg-b { z-index: -1; }
1842 | .ui-slider-switch-a div.ui-slider-labelbg-b, .ui-slider-switch-b div.ui-slider-labelbg-a { z-index: 0; }
1843 |
1844 | div.ui-slider-switch a.ui-slider-handle { z-index: 20; width: 101%; height: 32px; margin-top: -18px; margin-left: -101%; }
1845 | span.ui-slider-label { width: 100%; position: absolute;height: 32px; font-size: 16px; text-align: center; line-height: 2; background: none; border-color: transparent; }
1846 | span.ui-slider-label-a { left: -100%; margin-right: -1px }
1847 | span.ui-slider-label-b { right: -100%; margin-left: -1px }
1848 |
--------------------------------------------------------------------------------