From f4068082df9ed42f4a9834d82392f5df5bea7185 Mon Sep 17 00:00:00 2001 From: Rodney Rehm Date: Sat, 19 Sep 2015 17:20:55 +0200 Subject: [PATCH] chore(build): bumping to version 1.16.1 --- README.md | 10 ++++++---- bower.json | 2 +- build.js | 2 +- package.json | 2 +- src/IPv6.js | 2 +- src/SecondLevelDomains.js | 2 +- src/URI.js | 4 ++-- src/URI.min.js | 4 ++-- src/URITemplate.js | 2 +- src/jquery.URI.js | 2 +- src/jquery.URI.min.js | 2 +- 11 files changed, 18 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index 46abce95..bc42618a 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,10 @@ --- +> **NOTE:** The npm package name changed to `urijs` + +--- + I always want to shoot myself in the head when looking at code like the following: ```javascript @@ -17,9 +21,7 @@ var separator = url.indexOf('?') > -1 ? '&' : '?'; url += separator + encodeURIComponent("foo") + "=" + encodeURIComponent("bar"); ``` -I still can't believe javascript - the f**ing backbone-language of the web - doesn't offer an API for mutating URLs. Browsers (Firefox) don't expose the `Location` object (the structure behind window.location). Yes, one could think of [decomposed IDL attributes](http://www.whatwg.org/specs/web-apps/current-work/multipage/urls.html#url-decomposition-idl-attributes) as a native URL management library. But it relies on the DOM element <a>, it's slow and doesn't offer any convenience at all. - -How about a nice, clean and simple API for mutating URIs: +Things are looking up with [URL](https://developer.mozilla.org/en/docs/Web/API/URL) and the [URL spec](http://url.spec.whatwg.org/) but until we can safely rely on that API, have a look at URI.js for a clean and simple API for mutating URIs: ```javascript var url = new URI("http://example.org/foo?bar=baz"); @@ -238,7 +240,7 @@ URI.js is published under the [MIT license](http://www.opensource.org/licenses/m ## Changelog ## -### master (will be 1.16.1) ### +### 1.16.1 (September 19th 2015) ### Package Management Cleanup - no changes to source code! diff --git a/bower.json b/bower.json index a2160640..7a800af1 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "urijs", - "version": "1.16.0", + "version": "1.16.1", "main": "src/URI.js", "ignore": [ ".*", diff --git a/build.js b/build.js index 9f3205ee..020a3cf8 100644 --- a/build.js +++ b/build.js @@ -29,7 +29,7 @@ function build(files) { output_format: "text", output_info: "compiled_code" }, function(data) { - var code = "/*! URI.js v1.16.0 http://medialize.github.io/URI.js/ */\n/* build contains: " + files.join(', ') + " */\n" + data; + var code = "/*! URI.js v1.16.1 http://medialize.github.io/URI.js/ */\n/* build contains: " + files.join(', ') + " */\n" + data; $progress.hide(); $out.val(code).parent().show(); $out.prev().find('a').remove(); diff --git a/package.json b/package.json index f053fdfc..7b8c4101 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "urijs", - "version": "1.16.0", + "version": "1.16.1", "title": "URI.js - Mutating URLs", "author": { "name": "Rodney Rehm", diff --git a/src/IPv6.js b/src/IPv6.js index f4c384af..d6d925f7 100644 --- a/src/IPv6.js +++ b/src/IPv6.js @@ -2,7 +2,7 @@ * URI.js - Mutating URLs * IPv6 Support * - * Version: 1.16.0 + * Version: 1.16.1 * * Author: Rodney Rehm * Web: http://medialize.github.io/URI.js/ diff --git a/src/SecondLevelDomains.js b/src/SecondLevelDomains.js index 06cd3232..75f63832 100644 --- a/src/SecondLevelDomains.js +++ b/src/SecondLevelDomains.js @@ -2,7 +2,7 @@ * URI.js - Mutating URLs * Second Level Domain (SLD) Support * - * Version: 1.16.0 + * Version: 1.16.1 * * Author: Rodney Rehm * Web: http://medialize.github.io/URI.js/ diff --git a/src/URI.js b/src/URI.js index 6fad4f5e..739f788a 100644 --- a/src/URI.js +++ b/src/URI.js @@ -1,7 +1,7 @@ /*! * URI.js - Mutating URLs * - * Version: 1.16.0 + * Version: 1.16.1 * * Author: Rodney Rehm * Web: http://medialize.github.io/URI.js/ @@ -72,7 +72,7 @@ return this; } - URI.version = '1.16.0'; + URI.version = '1.16.1'; var p = URI.prototype; var hasOwn = Object.prototype.hasOwnProperty; diff --git a/src/URI.min.js b/src/URI.min.js index 42ad5a84..ce1d13dc 100644 --- a/src/URI.min.js +++ b/src/URI.min.js @@ -1,4 +1,4 @@ -/*! URI.js v1.16.0 http://medialize.github.io/URI.js/ */ +/*! URI.js v1.16.1 http://medialize.github.io/URI.js/ */ /* build contains: IPv6.js, punycode.js, SecondLevelDomains.js, URI.js, URITemplate.js */ (function(e,n){"object"===typeof exports?module.exports=n():"function"===typeof define&&define.amd?define(n):e.IPv6=n(e)})(this,function(e){var n=e&&e.IPv6;return{best:function(g){g=g.toLowerCase().split(":");var l=g.length,b=8;""===g[0]&&""===g[1]&&""===g[2]?(g.shift(),g.shift()):""===g[0]&&""===g[1]?g.shift():""===g[l-1]&&""===g[l-2]&&g.pop();l=g.length;-1!==g[l-1].indexOf(".")&&(b=7);var h;for(h=0;he;e++)if("0"===l[0]&&1e&&(l=k,e=n)):"0"===g[h]&&(u=!0,k=h,n=1);n>e&&(l=k,e=n);1=h||h>=b-1)return!1;var n=g.list[e.slice(b+1)] (function(e,n){"object"===typeof exports?module.exports=n(require("./punycode"),require("./IPv6"),require("./SecondLevelDomains")):"function"===typeof define&&define.amd?define(["./punycode","./IPv6","./SecondLevelDomains"],n):e.URI=n(e.punycode,e.IPv6,e.SecondLevelDomains,e)})(this,function(e,n,g,l){function b(a,c){var d=1<=arguments.length,m=2<=arguments.length;if(!(this instanceof b))return d?m?new b(a,c):new b(a):new b;if(void 0===a){if(d)throw new TypeError("undefined is not a valid argument for URI"); a="undefined"!==typeof location?location.href+"":""}this.href(a);return void 0!==c?this.absoluteTo(c):this}function h(a){return a.replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}function A(a){return void 0===a?"Undefined":String(Object.prototype.toString.call(a)).slice(8,-1)}function w(a){return"Array"===A(a)}function k(a,c){var d={},b,f;if("RegExp"===A(c))d=null;else if(w(c))for(b=0,f=c.length;b]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?\u00ab\u00bb\u201c\u201d\u2018\u2019]))/ig;b.findUri={start:/\b(?:([a-z][a-z0-9.+-]*:\/\/)|www\.)/gi,end:/[\s\r\n]|$/,trim:/[`!()\[\]{};:'".,<>?\u00ab\u00bb\u201c\u201d\u201e\u2018\u2019]+$/};b.defaultPorts={http:"80",https:"443",ftp:"21",gopher:"70",ws:"80",wss:"443"};b.invalid_hostname_characters= /[^a-zA-Z0-9\.-]/;b.domAttributes={a:"href",blockquote:"cite",link:"href",base:"href",script:"src",form:"action",img:"src",area:"href",iframe:"src",embed:"src",source:"src",track:"src",input:"src",audio:"src",video:"src"};b.getDomAttribute=function(a){if(a&&a.nodeName){var c=a.nodeName.toLowerCase();return"input"===c&&"image"!==a.type?void 0:b.domAttributes[c]}};b.encode=B;b.decode=decodeURIComponent;b.iso8859=function(){b.encode=escape;b.decode=unescape};b.unicode=function(){b.encode=B;b.decode= diff --git a/src/URITemplate.js b/src/URITemplate.js index d7a92d62..b6e082df 100644 --- a/src/URITemplate.js +++ b/src/URITemplate.js @@ -2,7 +2,7 @@ * URI.js - Mutating URLs * URI Template Support - http://tools.ietf.org/html/rfc6570 * - * Version: 1.16.0 + * Version: 1.16.1 * * Author: Rodney Rehm * Web: http://medialize.github.io/URI.js/ diff --git a/src/jquery.URI.js b/src/jquery.URI.js index a2d9fee8..1cbfd375 100644 --- a/src/jquery.URI.js +++ b/src/jquery.URI.js @@ -2,7 +2,7 @@ * URI.js - Mutating URLs * jQuery Plugin * - * Version: 1.16.0 + * Version: 1.16.1 * * Author: Rodney Rehm * Web: http://medialize.github.io/URI.js/jquery-uri-plugin.html diff --git a/src/jquery.URI.min.js b/src/jquery.URI.min.js index b77ccb31..78a46087 100644 --- a/src/jquery.URI.min.js +++ b/src/jquery.URI.min.js @@ -1,4 +1,4 @@ -/*! URI.js v1.16.0 http://medialize.github.io/URI.js/ */ +/*! URI.js v1.16.1 http://medialize.github.io/URI.js/ */ /* build contains: jquery.URI.js */ (function(d,e){"object"===typeof exports?module.exports=e(require("jquery","./URI")):"function"===typeof define&&define.amd?define(["jquery","./URI"],e):e(d.jQuery,d.URI)})(this,function(d,e){function h(a){return a.replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}function k(a){var b=a.nodeName.toLowerCase();return"input"===b&&"image"!==a.type?void 0:e.domAttributes[b]}function p(a){return{get:function(b){return d(b).uri()[a]()},set:function(b,c){d(b).uri()[a](c);return c}}}function l(a,b){var c,e,f;if(!k(a)|| !b)return!1;c=b.match(q);if(!c||!c[5]&&":"!==c[2]&&!g[c[2]])return!1;f=d(a).uri();if(c[5])return f.is(c[5]);if(":"===c[2])return e=c[1].toLowerCase()+":",g[e]?g[e](f,c[4]):!1;e=c[1].toLowerCase();return m[e]?g[c[2]](f[e](),c[4],e):!1}var m={},g={"=":function(a,b){return a===b},"^=":function(a,b){return!!(a+"").match(new RegExp("^"+h(b),"i"))},"$=":function(a,b){return!!(a+"").match(new RegExp(h(b)+"$","i"))},"*=":function(a,b,c){"directory"===c&&(a+="/");return!!(a+"").match(new RegExp(h(b),"i"))},