diff --git a/docs/symbols/src/kis-js_src_modules_indexedDB.js.html b/docs/symbols/src/kis-js_src_modules_indexedDB.js.html index 27a7bd5..5c7a317 100755 --- a/docs/symbols/src/kis-js_src_modules_indexedDB.js.html +++ b/docs/symbols/src/kis-js_src_modules_indexedDB.js.html @@ -8,7 +8,7 @@
  1 /**
   2  * Module for simplifying Indexed DB access
   3  */
-  4 (function() {
+  4 (function (){
   5 	"use strict";
   6 	
   7 	var db = window.indexedDB || window.webkitIndexedDB || window.mozIndexedDB || window.msIndexedDB,
diff --git a/docs/symbols/src/kis-js_src_modules_util.js.html b/docs/symbols/src/kis-js_src_modules_util.js.html
index 7badfcd..7658d09 100755
--- a/docs/symbols/src/kis-js_src_modules_util.js.html
+++ b/docs/symbols/src/kis-js_src_modules_util.js.html
@@ -11,7 +11,7 @@
   4  * Various object and string manipulation functions
   5  * Note: these are based on similar phpjs functions: http://phpjs.org
   6  */
-  7 (function(){
+  7 (function (){
   8 
   9 	"use strict";
  10 
diff --git a/kis-all.js b/kis-all.js
index 41d8700..6bb79c4 100755
--- a/kis-all.js
+++ b/kis-all.js
@@ -223,66 +223,69 @@
  * A module of various browser polyfills
  * @file polyfill.js
  */
-(function(){
 
-	"use strict";
+// Console.log polyfill for IE 8 stupidity
+if(typeof window.console === "undefined")
+{
+	window.console = {
+		log:function(){}
+	};
+}
 
-	// Console.log polyfill for IE 8 stupidity
-	if(typeof window.console === "undefined")
-	{
-		window.console = {
-			log:function(){}
-		};
-	}
-
-	// --------------------------------------------------------------------------
+// --------------------------------------------------------------------------
 
+/**
+ * String trim function polyfill
+ */
+if(typeof String.prototype.trim === "undefined")
+{
 	/**
-	 * String trim function polyfill
-	 */
-	if(typeof String.prototype.trim === "undefined")
-	{
-		/**
-		 * @private
-		 */
-		String.prototype.trim = function()
-		{
-			return this.replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g, "");
-		};
-	}
-
-	// --------------------------------------------------------------------------
-
-	/**
-	 * event.preventDefault/e.stopPropagation polyfill
 	 * @private
 	 */
-	if(typeof Event.preventDefault === "undefined" && typeof window.event !== "undefined")
+	String.prototype.trim = function()
 	{
-		Event.prototype.preventDefault = function()
-		{
-			window.event.returnValue = false;
-		},
-		Event.prototype.stopPropagation = function()
-		{
-			window.event.cancelBubble = true;
-		}
-	}
-	
-	// --------------------------------------------------------------------------
-	
-	/**
-	 * Array.isArray polyfill
-	 */
-	if (typeof [].isArray === "undefined")
-	{
-		Array.isArray = function(v)
-		{
-			return Object.prototype.toString.apply(v) === '[object Array]';
-		}
-	}
+		return this.replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g, "");
+	};
+}
 
-}());
+// --------------------------------------------------------------------------
+
+/**
+ * event.preventDefault/e.stopPropagation polyfill
+ * @private
+ */
+if(typeof Event.preventDefault === "undefined" && typeof window.event !== "undefined")
+{
+	Event.prototype.preventDefault = function()
+	{
+		window.event.returnValue = false;
+	},
+	Event.prototype.stopPropagation = function()
+	{
+		window.event.cancelBubble = true;
+	}
+}
+
+// --------------------------------------------------------------------------
+
+/**
+ * Array.isArray polyfill
+ */
+if (typeof Array.isArray === "undefined")
+{
+	Array.isArray = function(v)
+	{
+		return Object.prototype.toString.apply(v) === '[object Array]';
+	}
+}
+
+
+// --------------------------------------------------------------------------
+
+
+(function ($_){
+
+"use strict"
 
 // --------------------------------------------------------------------------
 
@@ -458,10 +461,8 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
  *
  * Dom manipulation module
  */
-(function (){
-
-	"use strict";
 
+	
 	var d;
 
 	//Private function for getting/setting attributes/properties
@@ -825,7 +826,7 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
 
 	$_.ext('dom', d);
 
-}());
+
 
 // --------------------------------------------------------------------------
 
@@ -834,10 +835,8 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
  *
  * Module for making ajax requests
  */
-(function (){
-
-	"use strict";
 
+	
 	// Don't bother even defining the object if the XMLHttpRequest isn't available
 	if(typeof window.XMLHttpRequest === "undefined")
 	{
@@ -976,7 +975,7 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
 		}
 	});
 	
-}());
+
 
 // --------------------------------------------------------------------------
 
@@ -986,10 +985,8 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
  * Event api wrapper
  * @todo Add method for triggering events
  */
-(function (){
-
-	"use strict";
 
+	
 	// Property name for expandos on DOM objects
 	var kis_expando = "KIS_0_6_0";
 
@@ -1234,16 +1231,14 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
 
 	$_.ext('event', e);
 
-}());
+
 
 // --------------------------------------------------------------------------
 
 /**
  * Module for simplifying Indexed DB access
  */
-(function() {
-	"use strict";
-	
+		
 	var db = window.indexedDB || window.webkitIndexedDB || window.mozIndexedDB || window.msIndexedDB,
 		indexedDB = {};
 		
@@ -1352,7 +1347,7 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
 	
 	$_.ext('indexedDB', indexedDB);
 	
-}());
+
 
 // --------------------------------------------------------------------------
 
@@ -1361,10 +1356,8 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
  *
  * Wrapper for local / sessionstorage
  */
-(function (){
-
-	"use strict";
 
+	
 	//No support for localstorage? Bail out early
 	if(typeof localStorage === "undefined" || typeof JSON === "undefined")
 	{
@@ -1480,7 +1473,7 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
 	};
 
 	$_.ext('store', store);
-}());
+
 
 // --------------------------------------------------------------------------
 
@@ -1490,10 +1483,8 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
  * Various object and string manipulation functions
  * Note: these are based on similar phpjs functions: http://phpjs.org
  */
-(function(){
-
-	"use strict";
 
+	
 	var reverse_key_sort =  function(o)
 	{
 		//Define some variables
@@ -1843,5 +1834,6 @@ if (typeof document !== "undefined" && !("classList" in document.createElement("
 
 	//Add it to the $_ object
 	$_.ext('util', u);
-}());
 
+
+}($_));
\ No newline at end of file
diff --git a/kis-lite-dom-min.js b/kis-lite-dom-min.js
index 9d4ccfd..e5244ae 100755
--- a/kis-lite-dom-min.js
+++ b/kis-lite-dom-min.js
@@ -1,18 +1,17 @@
 (function(){if("undefined"!==typeof document.querySelector){var c,g,e,b;c=function(a){b="undefined"===typeof a?"undefined"!==typeof c.el?c.el:document.documentElement:"object"!==typeof a?g(a):a;c.prototype.el=b;var a=e(c),d;for(d in a)"object"===typeof a[d]&&(a[d].el=b);a.el=b;return a};g=function(a,d){var b;if("string"!=typeof a||"undefined"===typeof a)return a;b=null!=d&&1===d.nodeType?d:document;if(a.match(/^#([\w\-]+$)/))return document.getElementById(a.split("#")[1]);b=b.querySelectorAll(a);
 return 1===b.length?b[0]:b};e=function(a){var d;if("undefined"!==typeof a){if("undefined"!==typeof Object.create)return Object.create(a);d=typeof a;if(!("object"!==d&&"function"!==d))return d=function(){},d.prototype=a,new d}};c.ext=function(a,d){d.el=b;c[a]=d};c.ext("each",function(a){if("undefined"!==typeof b.length&&b!==window)if("undefined"!==typeof Array.prototype.forEach)[].forEach.call(b,a);else{var d=b.length;if(0!==d)for(var h,f=0;f1&&typeof a==="undefined"){console.log(d);console.log("Must be a singular element")}else if(d.length>
+1&&typeof a!=="undefined")$_.each(function(d){return c(d,b,a)});else return c(d,b,a)},text:function(b){var a,c,e;e=this.el;c=typeof e.textContent!=="undefined"?"textContent":typeof e.innerText!=="undefined"?"innerText":"innerHTML";a=e[c];if(typeof b!=="undefined")return e[c]=b;return a},css:function(b,a){if(typeof a==="undefined")return e(this.el,b);$_.each(function(c){e(c,b,a)})},append:function(b){typeof document.insertAdjacentHTML!=="undefined"?this.el.insertAdjacentHTML("beforeend",b):this.el.innerHTML=
+this.el.innerHTML+b},prepend:function(b){typeof document.insertAdjacentHTML!=="undefined"?this.el.insertAdjacentHTML("afterbegin",b):this.el.innerHTML=b+this.el.innerHTML},html:function(b){if(typeof b!=="undefined")this.el.innerHTML=b;return this.el.innerHTML}})})();
diff --git a/kis-lite-dom.js b/kis-lite-dom.js
index c31bd3d..45271ca 100755
--- a/kis-lite-dom.js
+++ b/kis-lite-dom.js
@@ -223,66 +223,61 @@
  * A module of various browser polyfills
  * @file polyfill.js
  */
-(function(){
 
-	"use strict";
+// Console.log polyfill for IE 8 stupidity
+if(typeof window.console === "undefined")
+{
+	window.console = {
+		log:function(){}
+	};
+}
 
-	// Console.log polyfill for IE 8 stupidity
-	if(typeof window.console === "undefined")
-	{
-		window.console = {
-			log:function(){}
-		};
-	}
-
-	// --------------------------------------------------------------------------
+// --------------------------------------------------------------------------
 
+/**
+ * String trim function polyfill
+ */
+if(typeof String.prototype.trim === "undefined")
+{
 	/**
-	 * String trim function polyfill
-	 */
-	if(typeof String.prototype.trim === "undefined")
-	{
-		/**
-		 * @private
-		 */
-		String.prototype.trim = function()
-		{
-			return this.replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g, "");
-		};
-	}
-
-	// --------------------------------------------------------------------------
-
-	/**
-	 * event.preventDefault/e.stopPropagation polyfill
 	 * @private
 	 */
-	if(typeof Event.preventDefault === "undefined" && typeof window.event !== "undefined")
+	String.prototype.trim = function()
 	{
-		Event.prototype.preventDefault = function()
-		{
-			window.event.returnValue = false;
-		},
-		Event.prototype.stopPropagation = function()
-		{
-			window.event.cancelBubble = true;
-		}
-	}
-	
-	// --------------------------------------------------------------------------
-	
-	/**
-	 * Array.isArray polyfill
-	 */
-	if (typeof [].isArray === "undefined")
-	{
-		Array.isArray = function(v)
-		{
-			return Object.prototype.toString.apply(v) === '[object Array]';
-		}
-	}
+		return this.replace(/^[\s\uFEFF]+|[\s\uFEFF]+$/g, "");
+	};
+}
 
-}());
+// --------------------------------------------------------------------------
+
+/**
+ * event.preventDefault/e.stopPropagation polyfill
+ * @private
+ */
+if(typeof Event.preventDefault === "undefined" && typeof window.event !== "undefined")
+{
+	Event.prototype.preventDefault = function()
+	{
+		window.event.returnValue = false;
+	},
+	Event.prototype.stopPropagation = function()
+	{
+		window.event.cancelBubble = true;
+	}
+}
+
+// --------------------------------------------------------------------------
+
+/**
+ * Array.isArray polyfill
+ */
+if (typeof Array.isArray === "undefined")
+{
+	Array.isArray = function(v)
+	{
+		return Object.prototype.toString.apply(v) === '[object Array]';
+	}
+}
 
 // --------------------------------------------------------------------------
 
diff --git a/kis-lite-min.js b/kis-lite-min.js
index 9f4e90b..b13a922 100755
--- a/kis-lite-min.js
+++ b/kis-lite-min.js
@@ -1,10 +1,9 @@
 (function(){if("undefined"!==typeof document.querySelector){var f,d,e,c;f=function(a){c="undefined"===typeof a?"undefined"!==typeof f.el?f.el:document.documentElement:"object"!==typeof a?d(a):a;f.prototype.el=c;var a=e(f),b;for(b in a)"object"===typeof a[b]&&(a[b].el=c);a.el=c;return a};d=function(a,b){var g;if("string"!=typeof a||"undefined"===typeof a)return a;g=null!=b&&1===b.nodeType?b:document;if(a.match(/^#([\w\-]+$)/))return document.getElementById(a.split("#")[1]);g=g.querySelectorAll(a);
 return 1===g.length?g[0]:g};e=function(a){var b;if("undefined"!==typeof a){if("undefined"!==typeof Object.create)return Object.create(a);b=typeof a;if(!("object"!==b&&"function"!==b))return b=function(){},b.prototype=a,new b}};f.ext=function(a,b){b.el=c;f[a]=b};f.ext("each",function(a){if("undefined"!==typeof c.length&&c!==window)if("undefined"!==typeof Array.prototype.forEach)[].forEach.call(c,a);else{var b=c.length;if(0!==b)for(var g,d=0;dd?1:ca?1:b1&&typeof b==="undefined"){console.log(c);console.log("Must be a singular element")}else if(c.length>
+1&&typeof b!=="undefined")e.each(function(c){return n(c,a,b)});else return n(c,a,b)},text:function(a){var b,c,d;d=this.el;c=typeof d.textContent!=="undefined"?"textContent":typeof d.innerText!=="undefined"?"innerText":"innerHTML";b=d[c];if(typeof a!=="undefined")return d[c]=a;return b},css:function(a,b){if(typeof b==="undefined")return f(this.el,a);e.each(function(c){f(c,a,b)})},append:function(a){typeof document.insertAdjacentHTML!=="undefined"?this.el.insertAdjacentHTML("beforeend",a):this.el.innerHTML=
+this.el.innerHTML+a},prepend:function(a){typeof document.insertAdjacentHTML!=="undefined"?this.el.insertAdjacentHTML("afterbegin",a):this.el.innerHTML=a+this.el.innerHTML},html:function(a){if(typeof a!=="undefined")this.el.innerHTML=a;return this.el.innerHTML}});if(typeof window.XMLHttpRequest!=="undefined"){var g={_do:function(a,b,c,d){var h=new XMLHttpRequest;typeof c==="undefined"&&(c=function(){});d=d?"POST":"GET";a=a+(d==="GET"?"?"+this._serialize(b):"");h.open(d,a);h.onreadystatechange=function(){h.readyState===
+4&&c(h.responseText)};if(d==="POST"){h.setRequestHeader("Content-Type","application/x-www-form-urlencoded");h.send(this._serialize(b))}else h.send(null)},_serialize:function(a){var b,c,d=[];for(b in a)if(a.hasOwnProperty(b)&&typeof a[b]!=="function"){c=a[b].toString();b=encodeURIComponent(b);c=encodeURIComponent(c);d.push(b+"="+c)}return d.join("&")}};e.ext("get",function(a,b,c){g._do(a,b,c,false)});e.ext("post",function(a,b,c){g._do(a,b,c,true)});e.ext("sse",function(a,b,c){if(typeof EventSource!==
+"undefined"){a=new EventSource(a);a.onmessage=function(a){b(a.data)}}else setInterval(e.get,c||3E4,a,{},function(a){a.trim().replace(/data:/gim,"");a.replace(/^event|id|retry?:(.*)$/gim,"");b(a)})});var i,k,j,r;if(typeof document.addEventListener!=="undefined"){i=function(a,b,c){typeof a.addEventListener!=="undefined"&&a.addEventListener(b,c,false)};k=function(a,b,c){typeof a.removeEventListener!=="undefined"&&a.removeEventListener(b,c,false)}}else if(typeof document.attachEvent!=="undefined"){i=
+function(a,b,c){function d(a){c.apply(a)}if(typeof a.attachEvent!=="undefined"){k(b,c);a.attachEvent("on"+b,d);a=a.KIS_0_6_0=a.KIS_0_6_0||{};a.listeners=a.listeners||{};a.listeners[b]=a.listeners[b]||[];a.listeners[b].push({callback:c,_listener:d})}else console.log("Failed to _attach event:"+b+" on "+a)};k=function(a,b,c){if(typeof a.detachEvent!=="undefined"){var d=a.KIS_0_6_0;if(d&&d.listeners&&d.listeners[b])for(var h=d.listeners[b],e=h.length,f=0;fd?1:ca?1:b