Skip to content

Commit

Permalink
JSHinted for mixed tabs and spaces
Browse files Browse the repository at this point in the history
  • Loading branch information
nschonni committed Sep 10, 2012
1 parent a0fa36d commit 5732306
Show file tree
Hide file tree
Showing 9 changed files with 116 additions and 117 deletions.
10 changes: 5 additions & 5 deletions src/js/dependencies/calendar.js
Expand Up @@ -488,9 +488,9 @@
compare : function (a, b) {
// Compare two dates (could be of any type supported by the convert
// function above) and returns:
// -1 : if a < b
// 0 : if a = b
// 1 : if a > b
// -1 : if a < b
// 0 : if a = b
// 1 : if a > b
// NaN : if a or b is an illegal date
// NOTE: The code inside isFinite does an assignment (=).
return (
Expand All @@ -500,9 +500,9 @@
inRange : function (d, start, end) {
// Checks if date in d is between dates in start and end.
// Returns a boolean or NaN:
// true : if d is between start and end (inclusive)
// true : if d is between start and end (inclusive)
// false : if d is before start or after end
// NaN : if one or more of the dates is illegal.
// NaN : if one or more of the dates is illegal.
// NOTE: The code inside isFinite does an assignment (=).
return (
isFinite(d = _pe.fn.calendar.dates.convert(d).valueOf()) && isFinite(start = _pe.fn.calendar.dates.convert(start).valueOf()) && isFinite(end = _pe.fn.calendar.dates.convert(end).valueOf()) ? start <= d && d <= end : NaN
Expand Down
2 changes: 1 addition & 1 deletion src/js/dependencies/equalheights.js
@@ -1,6 +1,6 @@
/*--------------------------------------------------------------------
* JQuery Plugin: "EqualHeights"
* by: Scott Jehl, Todd Parker, Maggie Costello Wachs (http://www.filamentgroup.com)
* by: Scott Jehl, Todd Parker, Maggie Costello Wachs (http://www.filamentgroup.com)
*
* Copyright (c) 2008 Filament Group
* Licensed under GPL (http://www.opensource.org/licenses/gpl-license.php)
Expand Down
4 changes: 2 additions & 2 deletions src/js/dependencies/raphael.js
Expand Up @@ -3746,7 +3746,7 @@
// +---------------------------------------------------------------------+ \\
// ¦ Raphaël - JavaScript Vector Library ¦ \\
// +---------------------------------------------------------------------¦ \\
// ¦ SVG Module ¦ \\
// ¦ SVG Module ¦ \\
// +---------------------------------------------------------------------¦ \\
// ¦ Copyright (c) 2008-2011 Dmitry Baranovskiy (http://raphaeljs.com) ¦ \\
// ¦ Copyright (c) 2008-2011 Sencha Labs (http://sencha.com) ¦ \\
Expand Down Expand Up @@ -4843,7 +4843,7 @@ window.Raphael.svg && function (R) {
// +---------------------------------------------------------------------+ \\
// ¦ Raphaël - JavaScript Vector Library ¦ \\
// +---------------------------------------------------------------------¦ \\
// ¦ VML Module ¦ \\
// ¦ VML Module ¦ \\
// +---------------------------------------------------------------------¦ \\
// ¦ Copyright (c) 2008-2011 Dmitry Baranovskiy (http://raphaeljs.com) ¦ \\
// ¦ Copyright (c) 2008-2011 Sencha Labs (http://sencha.com) ¦ \\
Expand Down
34 changes: 17 additions & 17 deletions src/js/i18n/formvalid/messages_fa.js
Expand Up @@ -3,21 +3,21 @@
* Locale: FA
*/
jQuery.extend(jQuery.validator.messages, {
required: "تکمیل این فیلد اجباری است.",
remote: "لطفا این فیلد را تصحیح کنید.",
email: ".لطفا یک ایمیل صحیح وارد کنید",
url: "لطفا آدرس صحیح وارد کنید.",
date: "لطفا یک تاریخ صحیح وارد کنید",
dateISO: "لطفا تاریخ صحیح وارد کنید (ISO).",
number: "لطفا عدد صحیح وارد کنید.",
digits: "لطفا تنها رقم وارد کنید",
creditcard: "لطفا کریدیت کارت صحیح وارد کنید.",
equalTo: "لطفا مقدار برابری وارد کنید",
accept: "لطفا مقداری وارد کنید که ",
maxlength: jQuery.validator.format("لطفا بیشتر از {0} حرف وارد نکنید."),
minlength: jQuery.validator.format("لطفا کمتر از {0} حرف وارد نکنید."),
rangelength: jQuery.validator.format("لطفا مقداری بین {0} تا {1} حرف وارد کنید."),
range: jQuery.validator.format("لطفا مقداری بین {0} تا {1} حرف وارد کنید."),
max: jQuery.validator.format("لطفا مقداری کمتر از {0} حرف وارد کنید."),
min: jQuery.validator.format("لطفا مقداری بیشتر از {0} حرف وارد کنید.")
required: "تکمیل این فیلد اجباری است.",
remote: "لطفا این فیلد را تصحیح کنید.",
email: ".لطفا یک ایمیل صحیح وارد کنید",
url: "لطفا آدرس صحیح وارد کنید.",
date: "لطفا یک تاریخ صحیح وارد کنید",
dateISO: "لطفا تاریخ صحیح وارد کنید (ISO).",
number: "لطفا عدد صحیح وارد کنید.",
digits: "لطفا تنها رقم وارد کنید",
creditcard: "لطفا کریدیت کارت صحیح وارد کنید.",
equalTo: "لطفا مقدار برابری وارد کنید",
accept: "لطفا مقداری وارد کنید که ",
maxlength: jQuery.validator.format("لطفا بیشتر از {0} حرف وارد نکنید."),
minlength: jQuery.validator.format("لطفا کمتر از {0} حرف وارد نکنید."),
rangelength: jQuery.validator.format("لطفا مقداری بین {0} تا {1} حرف وارد کنید."),
range: jQuery.validator.format("لطفا مقداری بین {0} تا {1} حرف وارد کنید."),
max: jQuery.validator.format("لطفا مقداری کمتر از {0} حرف وارد کنید."),
min: jQuery.validator.format("لطفا مقداری بیشتر از {0} حرف وارد کنید.")
});
34 changes: 17 additions & 17 deletions src/js/i18n/formvalid/messages_it.js
Expand Up @@ -3,21 +3,21 @@
* Locale: IT
*/
jQuery.extend(jQuery.validator.messages, {
required: "Campo obbligatorio.",
remote: "Controlla questo campo.",
email: "Inserisci un indirizzo email valido.",
url: "Inserisci un indirizzo web valido.",
date: "Inserisci una data valida.",
dateISO: "Inserisci una data valida (ISO).",
number: "Inserisci un numero valido.",
digits: "Inserisci solo numeri.",
creditcard: "Inserisci un numero di carta di credito valido.",
equalTo: "Il valore non corrisponde.",
accept: "Inserisci un valore con un&apos;estensione valida.",
maxlength: jQuery.validator.format("Non inserire pi&ugrave; di {0} caratteri."),
minlength: jQuery.validator.format("Inserisci almeno {0} caratteri."),
rangelength: jQuery.validator.format("Inserisci un valore compreso tra {0} e {1} caratteri."),
range: jQuery.validator.format("Inserisci un valore compreso tra {0} e {1}."),
max: jQuery.validator.format("Inserisci un valore minore o uguale a {0}."),
min: jQuery.validator.format("Inserisci un valore maggiore o uguale a {0}.")
required: "Campo obbligatorio.",
remote: "Controlla questo campo.",
email: "Inserisci un indirizzo email valido.",
url: "Inserisci un indirizzo web valido.",
date: "Inserisci una data valida.",
dateISO: "Inserisci una data valida (ISO).",
number: "Inserisci un numero valido.",
digits: "Inserisci solo numeri.",
creditcard: "Inserisci un numero di carta di credito valido.",
equalTo: "Il valore non corrisponde.",
accept: "Inserisci un valore con un&apos;estensione valida.",
maxlength: jQuery.validator.format("Non inserire pi&ugrave; di {0} caratteri."),
minlength: jQuery.validator.format("Inserisci almeno {0} caratteri."),
rangelength: jQuery.validator.format("Inserisci un valore compreso tra {0} e {1} caratteri."),
range: jQuery.validator.format("Inserisci un valore compreso tra {0} e {1}."),
max: jQuery.validator.format("Inserisci un valore minore o uguale a {0}."),
min: jQuery.validator.format("Inserisci un valore maggiore o uguale a {0}.")
});
34 changes: 17 additions & 17 deletions src/js/i18n/formvalid/messages_lt.js
Expand Up @@ -3,21 +3,21 @@
* Locale: LT
*/
jQuery.extend(jQuery.validator.messages, {
required: "Šis laukas yra privalomas.",
remote: "Prašau pataisyti šį lauką.",
email: "Prašau įvesti teisingą elektroninio pašto adresą.",
url: "Prašau įvesti teisingą URL.",
date: "Prašau įvesti teisingą datą.",
dateISO: "Prašau įvesti teisingą datą (ISO).",
number: "Prašau įvesti teisingą skaičių.",
digits: "Prašau naudoti tik skaitmenis.",
creditcard: "Prašau įvesti teisingą kreditinės kortelės numerį.",
equalTo: "Prašau įvestį tą pačią reikšmę dar kartą.",
accept: "Prašau įvesti reikšmę su teisingu plėtiniu.",
maxlength: jQuery.format("Prašau įvesti ne daugiau kaip {0} simbolių."),
minlength: jQuery.format("Prašau įvesti bent {0} simbolius."),
rangelength: jQuery.format("Prašau įvesti reikšmes, kurių ilgis nuo {0} iki {1} simbolių."),
range: jQuery.format("Prašau įvesti reikšmę intervale nuo {0} iki {1}."),
max: jQuery.format("Prašau įvesti reikšmę mažesnę arba lygią {0}."),
min: jQuery.format("Prašau įvesti reikšmę didesnę arba lygią {0}.")
required: "Šis laukas yra privalomas.",
remote: "Prašau pataisyti šį lauką.",
email: "Prašau įvesti teisingą elektroninio pašto adresą.",
url: "Prašau įvesti teisingą URL.",
date: "Prašau įvesti teisingą datą.",
dateISO: "Prašau įvesti teisingą datą (ISO).",
number: "Prašau įvesti teisingą skaičių.",
digits: "Prašau naudoti tik skaitmenis.",
creditcard: "Prašau įvesti teisingą kreditinės kortelės numerį.",
equalTo: "Prašau įvestį tą pačią reikšmę dar kartą.",
accept: "Prašau įvesti reikšmę su teisingu plėtiniu.",
maxlength: jQuery.format("Prašau įvesti ne daugiau kaip {0} simbolių."),
minlength: jQuery.format("Prašau įvesti bent {0} simbolius."),
rangelength: jQuery.format("Prašau įvesti reikšmes, kurių ilgis nuo {0} iki {1} simbolių."),
range: jQuery.format("Prašau įvesti reikšmę intervale nuo {0} iki {1}."),
max: jQuery.format("Prašau įvesti reikšmę mažesnę arba lygią {0}."),
min: jQuery.format("Prašau įvesti reikšmę didesnę arba lygią {0}.")
});
34 changes: 17 additions & 17 deletions src/js/i18n/formvalid/messages_no.js
Expand Up @@ -3,21 +3,21 @@
* Locale: NO (Norwegian)
*/
jQuery.extend(jQuery.validator.messages, {
required: "Dette feltet er obligatorisk.",
maxlength: jQuery.validator.format("Maksimalt {0} tegn."),
minlength: jQuery.validator.format("Minimum {0} tegn."),
rangelength: jQuery.validator.format("Angi minimum {0} og maksimum {1} tegn."),
email: "Oppgi en gyldig epostadresse.",
url: "Angi en gyldig URL.",
date: "Angi en gyldig dato.",
dateISO: "Angi en gyldig dato (&ARING;&ARING;&ARING;&ARING;-MM-DD).",
dateSE: "Angi en gyldig dato.",
number: "Angi et gyldig nummer.",
numberSE: "Angi et gyldig nummer.",
digits: "Skriv kun tall.",
equalTo: "Skriv samme verdi igjen.",
range: jQuery.validator.format("Angi en verdi mellom {0} og {1}."),
max: jQuery.validator.format("Angi en verdi som er mindre eller lik {0}."),
min: jQuery.validator.format("Angi en verdi som er st&oslash;rre eller lik {0}."),
creditcard: "Angi et gyldig kredittkortnummer."
required: "Dette feltet er obligatorisk.",
maxlength: jQuery.validator.format("Maksimalt {0} tegn."),
minlength: jQuery.validator.format("Minimum {0} tegn."),
rangelength: jQuery.validator.format("Angi minimum {0} og maksimum {1} tegn."),
email: "Oppgi en gyldig epostadresse.",
url: "Angi en gyldig URL.",
date: "Angi en gyldig dato.",
dateISO: "Angi en gyldig dato (&ARING;&ARING;&ARING;&ARING;-MM-DD).",
dateSE: "Angi en gyldig dato.",
number: "Angi et gyldig nummer.",
numberSE: "Angi et gyldig nummer.",
digits: "Skriv kun tall.",
equalTo: "Skriv samme verdi igjen.",
range: jQuery.validator.format("Angi en verdi mellom {0} og {1}."),
max: jQuery.validator.format("Angi en verdi som er mindre eller lik {0}."),
min: jQuery.validator.format("Angi en verdi som er st&oslash;rre eller lik {0}."),
creditcard: "Angi et gyldig kredittkortnummer."
});
44 changes: 22 additions & 22 deletions src/js/pe-ap.js
Expand Up @@ -285,7 +285,7 @@
* @type {string}
* @example
* pe.url('http://www.canada.ca/index.html').host
* returns 'www.canada.ca'
* returns 'www.canada.ca'
*/
host: a.hostname,
/**
Expand All @@ -301,7 +301,7 @@
* @see #params
* @example
* pe.url('http://www.canada.ca?a=1&b=2').query
* returns '?a=1&b=2'
* returns '?a=1&b=2'
*/
query: a.search,
/**
Expand All @@ -310,12 +310,12 @@
* @type {object (key/value map of strings)}
* @see #query
* @example
* pe.url('http://www.canada.ca?a=1&b=2').params
* returns
* {
* a: '1',
* b: '2'
* }
* pe.url('http://www.canada.ca?a=1&b=2').params
* returns
* {
* a: '1',
* b: '2'
* }
*/
params: (function () {
var key, ret, s, seg, _i, _len;
Expand All @@ -336,7 +336,7 @@
* @memberof pe.url
* @type {string}
* @example
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').file
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').file
* returns 'menu-eng.html'
*/
file: a.pathname.match(/\/([^\/?#]+)$/i) ? a.pathname.match(/\/([^\/?#]+)$/i)[1] : '',
Expand All @@ -345,7 +345,7 @@
* @memberof pe.url
* @type {string}
* @example
* pe.url('http://www.canada.ca#wb-main-in').hash
* pe.url('http://www.canada.ca#wb-main-in').hash
* returns 'wb-main-in'
*/
hash: a.hash.replace('#', ''),
Expand All @@ -354,7 +354,7 @@
* @memberof pe.url
* @type {string}
* @example
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').path
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').path
* returns '/aboutcanada-ausujetcanada/hist/menu-eng.html'
*/
path: a.pathname.replace(/^([^\/])/, '/$1'),
Expand All @@ -363,7 +363,7 @@
* @memberof pe.url
* @type {string}
* @example
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').relative
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').relative
* returns '/aboutcanada-ausujetcanada/hist/menu-eng.html'
*/
relative: a.href.match(/tps?:\/\/[^\/]+(.+)/) ? a.href.match(/tps?:\/\/[^\/]+(.+)/)[1] : '',
Expand All @@ -372,7 +372,7 @@
* @memberof pe.url
* @type {string[]}
* @example
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').segments
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html').segments
* returns ['aboutcanada-ausujetcanada', 'hist', 'menu-eng.html']
*/
segments: a.pathname.replace(/^\//, '').split('/'),
Expand All @@ -382,9 +382,9 @@
* @type {string}
* @function
* @example
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html#wb-main-in').removehash()
* pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html#wb-main-in').removehash()
* returns 'http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html'
* pe.url( pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html#wb-main-in').removehash() ).relative
* pe.url( pe.url('http://www.canada.gc.ca/aboutcanada-ausujetcanada/hist/menu-eng.html#wb-main-in').removehash() ).relative
* returns '/aboutcanada-ausujetcanada/hist/menu-eng.html'
*/
removehash: function () {
Expand Down Expand Up @@ -461,9 +461,9 @@
* @param {string} tweet The tweet to format.
* @return {string}
* @example
* pe.string.ify.clean('@ded the cdn url is http://cdn.enderjs.com')
* returns '@&lt;a href="http://twitter.com/ded"&gt;ded&lt;/a&gt; the cdn url is &lt;a href="http://cdn.enderjs.com"&gt;http://cdn.enderjs.com&lt;/a&gt;'
* ie. '@<a href="http://twitter.com/ded">ded</a> the cdn url is <a href="http://cdn.enderjs.com">http://cdn.enderjs.com</a>'
* pe.string.ify.clean('@ded the cdn url is http://cdn.enderjs.com')
* returns '@&lt;a href="http://twitter.com/ded"&gt;ded&lt;/a&gt; the cdn url is &lt;a href="http://cdn.enderjs.com"&gt;http://cdn.enderjs.com&lt;/a&gt;'
* ie. '@<a href="http://twitter.com/ded">ded</a> the cdn url is <a href="http://cdn.enderjs.com">http://cdn.enderjs.com</a>'
*/
'clean': function (tweet) {
return this.hash(this.at(this.link(tweet)));
Expand Down Expand Up @@ -639,10 +639,10 @@
* @param {boolean} timepresent Optional. Whether to include the time in the result, or just the date. False if blank.
* @return {string}
* @example
* pe.date.to_iso_format(new Date())
* returns '2012-04-27'
* pe.date.to_iso_format(new Date(), true)
* returns '2012-04-27 13:46'
* pe.date.to_iso_format(new Date())
* returns '2012-04-27'
* pe.date.to_iso_format(new Date(), true)
* returns '2012-04-27 13:46'
*/
to_iso_format: function (d, timepresent) {
var date;
Expand Down
37 changes: 18 additions & 19 deletions src/js/workers/parser.table.js
Expand Up @@ -65,27 +65,26 @@
return;
}
/*
+-----------------------------------------------------+
| FYI - Here the value and signification of each type |
+------+---------------+------------------------------+
| Type | Signification | Technicality
+------+---------------+-------------------------------
| 1 | Header | TH element only
+------+---------------+-------------------------------
| 2 | Data | TD element only
+------+---------------+-------------------------------
| 3 | Summary | TD element and TD of type 2 exist
+------+---------------+-------------------------------
| 4 | Key | TD element applicable to right TH, Only available on row
+------+---------------+-------------------------------
| 5 | Description | TD element applicable to left or top TH
+------+---------------+-------------------------------
| 6 | Layout | Can be only: Top Left cell or/and Summmary group intersection
+------+---------------+-------------------------------
| 7 | Header Group | TH element only, visual heading grouping, this type are an extension of the type 1
+------+---------------+-------------------------------
*/
+-------+---------------+-----------------------------+
| Type | Signification | Technicality
+-------+---------------+------------------------------
| 1 | Header | TH element only
+-------+---------------+------------------------------
| 2 | Data | TD element only
+-------+---------------+------------------------------
| 3 | Summary | TD element and TD of type 2 exist
+-------+---------------+------------------------------
| 4 | Key | TD element applicable to right TH, Only available on row
+-------+---------------+------------------------------
| 5 | Description | TD element applicable to left or top TH
+-------+---------------+------------------------------
| 6 | Layout | Can be only: Top Left cell or/and Summmary group intersection
+-------+---------------+------------------------------
| 7 | Header Group | TH element only, visual heading grouping, this type are an extension of the type 1
+-------+---------------+------------------------------
*/
$(obj).data().tblparser = groupZero;
groupZero.colgroup = colgroupFrame;
if (!groupZero.rowgroup) {
Expand Down

0 comments on commit 5732306

Please sign in to comment.