From 71851ae843e9aab83ecbe674a4d90b3c1d30ced2 Mon Sep 17 00:00:00 2001 From: Julio Gutierrez Date: Wed, 8 Jun 2016 15:36:36 -0500 Subject: [PATCH 1/4] Update utils.js update libphonenumber to v7.4.2 --- build/js/utils.js | 153 ++++++++++++++++++++++++++++------------------ 1 file changed, 92 insertions(+), 61 deletions(-) diff --git a/build/js/utils.js b/build/js/utils.js index 6a97ce45a..13685f2f6 100644 --- a/build/js/utils.js +++ b/build/js/utils.js @@ -1,6 +1,18 @@ -(function(){var aa=this;function k(a,b){var c=a.split("."),d=aa;c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(var f;c.length&&(f=c.shift());)c.length||void 0===b?d[f]?d=d[f]:d=d[f]={}:d[f]=b}function m(a,b){function c(){}c.prototype=b.prototype;a.o=b.prototype;a.prototype=new c;a.prototype.constructor=a;a.$=function(a,c,e){for(var g=Array(arguments.length-2),h=2;hb?1:ab?1:0};function fa(a,b){b.unshift(a);p.call(this,ca.apply(null,b));b.shift()}n(fa,p);fa.prototype.name="AssertionError";function ga(a,b){throw new fa("Failure"+(a?": "+a:""),Array.prototype.slice.call(arguments,1));};var ha=Array.prototype.indexOf?function(a,b,c){return Array.prototype.indexOf.call(a,b,c)}:function(a,b,c){c=null==c?0:0>c?Math.max(0,a.length+c):c;if(k(a))return k(b)&&1==b.length?a.indexOf(b,c):-1;for(;cb?1:aparseFloat(ua)){ta=String(wa);break a}}ta=ua}var xa={}; +function ya(a){if(!xa[a]){for(var b=0,c=da(String(ta)).split("."),d=da(String(a)).split("."),e=Math.max(c.length,d.length),f=0;0==b&&fa.length?!1:P(ya,a)}function Ca(a){return P(wa,a)?Q(a,ra):Q(a,qa)}function Da(a){var b=Ca(a.toString());a.b="";a.a(b)}function Q(a,b){for(var c=new C,d,f=a.length,e=0;e=a.b.length)throw"Phone number too short after IDD"; -a:{d=a.toString();if(0!=d.length&&"0"!=d.charAt(0))for(b=d.length,e=1;3>=e&&e<=b;++e)if(a=parseInt(d.substring(0,e),10),a in L){c.a(d.substring(e));c=a;break a}c=0}if(0!=c)return p(f,1,c),c;throw"Invalid country calling code";}if(null!=b&&(e=v(b,10),g=""+e,h=a.toString(),0==h.lastIndexOf(g,0))){var l=new C(h.substring(g.length)),h=u(b,1),g=new RegExp(v(h,2));Ja(l,b,null);b=l.toString();h=v(h,3);if(!P(g,a.toString())&&P(g,b)||3==Y(h,a.toString()))return c.a(b),d&&p(f,6,10),p(f,1,e),e}p(f,1,0);return 0} -function Ja(a,b,c){var d=a.toString(),f=d.length,e=u(b,15);if(0!=f&&null!=e&&0!=e.length){var g=new RegExp("^(?:"+e+")");if(f=g.exec(d)){var e=new RegExp(v(u(b,1),2)),h=P(e,d),l=f.length-1;b=u(b,16);if(null==b||0==b.length||null==f[l]||0==f[l].length){if(!h||P(e,d.substring(f[0].length)))null!=c&&0b.b.length)throw"The string supplied is too short to be a phone number";null!=g&&(a=new C,c=new C(b.toString()),Ja(c,g,a),f=c.toString(),g=v(u(g,1),3),2!=Y(g,f)&&(b=c,d&&p(e,7,a.toString())));d=b.toString();a=d.length;if(2>a)throw"The string supplied is too short to be a phone number";if(17a.length?!1:Q(rb,a)}function zb(a){return Q(pb,a)?R(a,ib):R(a,O)}function Ab(a){var b=zb(a.toString());F(a);a.a(b)}function R(a,b){for(var c=new E,d,e=a.length,f=0;f=e?a=c:(d=d.substring(0,e),d=R(d,O),0==d.length?a=c:(g=g.clone(),Ya(g,4),d=[g],g=A(b,1),c=U(b),g in L?(a=V(a,g,W(g)),e=Ib(d,c),null!=e&&(d=e.clone(),e=A(e,4),0=f&&f<=e;++f)if(d=parseInt(c.substring(0,f),10),d in L)return b.a(c.substring(f)),d;return 0} +function Ub(a,b,c,d,e){if(0==a.length)return 0;a=new E(a);var f;null!=b&&(f=v(b,11));null==f&&(f="NonMatch");var g=a.toString();if(0==g.length)f=20;else if(P.test(g))g=g.replace(P,""),F(a),a.a(zb(g)),f=1;else{g=new RegExp(f);Ab(a);f=a.toString();if(0==f.search(g)){var g=f.match(g)[0].length,h=f.substring(g).match(lb);h&&null!=h[1]&&0=a.b.length)throw"Phone number too short after IDD";c= +Tb(a,c);if(0!=c)return w(e,1,c),c;throw"Invalid country calling code";}if(null!=b&&(f=A(b,10),g=""+f,h=a.toString(),0==h.lastIndexOf(g,0))){var m=new E(h.substring(g.length)),h=v(b,1),g=new RegExp(A(h,2));Vb(m,b,null);b=m.toString();h=A(h,3);if(!Q(g,a.toString())&&Q(g,b)||3==Rb(h,a.toString()))return c.a(b),d&&w(e,6,10),w(e,1,f),f}w(e,1,0);return 0} +function Vb(a,b,c){var d=a.toString(),e=d.length,f=v(b,15);if(0!=e&&null!=f&&0!=f.length){var g=new RegExp("^(?:"+f+")");if(e=g.exec(d)){var f=new RegExp(A(v(b,1),2)),h=Q(f,d),m=e.length-1;b=v(b,16);if(null==b||0==b.length||null==e[m]||0==e[m].length){if(!h||Q(f,d.substring(e[0].length)))null!=c&&0b.b.length)throw"The string supplied is too short to be a phone number";null!=g&&(a=new E,c=new E(b.toString()),Vb(c,g,a),e=c.toString(),g=A(v(g,1),3),2!=Rb(g,e)&&(b=c,d&&w(f,7,a.toString())));d=b.toString();a=d.length;if(2>a)throw"The string supplied is too short to be a phone number";if(17 Date: Thu, 9 Jun 2016 14:22:46 -0700 Subject: [PATCH 2/4] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e8f7c8b16..03c3c7b75 100644 --- a/README.md +++ b/README.md @@ -334,7 +334,7 @@ The dropdown should automatically appear above/below the input depending on the In order to get the automatic country-specific placeholders, simply omit the placeholder attribute on the ``. **Bootstrap input groups** -Simply add this line to get [input groups](http://getbootstrap.com/components/#input-groups) working properly. +Simply add the following line of CSS to get Bootstrap [input groups](http://getbootstrap.com/components/#input-groups) working properly. You can view an example [here](http://codepen.io/jackocnr/pen/EyPXed). ```css .intl-tel-input {display: table-cell;} ``` From dc93cea707df8f503ac06fafc59f8fb64178aa77 Mon Sep 17 00:00:00 2001 From: NejcZdovc Date: Fri, 10 Jun 2016 11:27:29 +0200 Subject: [PATCH 3/4] Added support for jQuery 3 --- .gitignore | 4 +++- build/js/intlTelInput.js | 4 ++-- build/js/intlTelInput.min.js | 2 +- src/js/intlTelInput.js.ejs | 4 ++-- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index 635d24492..ed49a208a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,11 +1,13 @@ /bower_components/ /node_modules/ /lib/* -!/lib/libphonenumber +!/lib/libphonenumber /.bower_cache/ /.sass-cache/ /.grunt/ /tmp/ +/.idea/ +*.iml .DS_Store # these files are now auto-generated diff --git a/build/js/intlTelInput.js b/build/js/intlTelInput.js index f2fc2f73e..fef5983c7 100644 --- a/build/js/intlTelInput.js +++ b/build/js/intlTelInput.js @@ -61,7 +61,7 @@ TAB: 9 }; // keep track of if the window.load event has fired as impossible to check after the fact - $(window).load(function() { + $(window).on("load", function() { // UPDATE: use a public static field so we can fudge it in the tests $.fn[pluginName].windowLoaded = true; }); @@ -371,7 +371,7 @@ $.fn[pluginName].loadUtils(this.options.utilsScript, this.utilsScriptDeferred); } else { // wait until the load event so we don't block any other requests e.g. the flags image - $(window).load(function() { + $(window).on("load", function() { $.fn[pluginName].loadUtils(that.options.utilsScript, that.utilsScriptDeferred); }); } diff --git a/build/js/intlTelInput.min.js b/build/js/intlTelInput.min.js index 01d58145e..c60ba0044 100644 --- a/build/js/intlTelInput.min.js +++ b/build/js/intlTelInput.min.js @@ -3,4 +3,4 @@ * https://github.com/jackocnr/intl-tel-input.git * Licensed under the MIT license */ -!function(a){"function"==typeof define&&define.amd?define(["jquery"],function(b){a(b,window,document)}):"object"==typeof module&&module.exports?module.exports=a(require("jquery"),window,document):a(jQuery,window,document)}(function(a,b,c,d){"use strict";function e(b,c){this.a=a(b),c&&(a.extend(c,c,{a:c.allowDropdown,b:c.autoHideDialCode,c:c.autoPlaceholder,c2:c.customPlaceholder,d:c.dropdownContainer,e:c.excludeCountries,f:c.formatOnInit,g:c.geoIpLookup,h:c.initialCountry,i:c.nationalMode,j:c.numberType,k:c.onlyCountries,l:c.preferredCountries,m:c.separateDialCode,n:c.utilsScript})),this.b=a.extend({},h,c),this.ns="."+f+g++,this.d=Boolean(b.setSelectionRange),this.e=Boolean(a(b).attr("placeholder"))}var f="intlTelInput",g=1,h={a:!0,b:!0,c:!0,c2:null,d:"",e:[],f:!0,g:null,h:"",i:!0,j:"MOBILE",k:[],l:["us","gb"],m:!1,n:""},i={b:38,c:40,d:13,e:27,f:43,A:65,Z:90,j:32,k:9};a(b).load(function(){a.fn[f].windowLoaded=!0}),e.prototype={_a:function(){return this.b.i&&(this.b.b=!1),this.b.m&&(this.b.b=this.b.i=!1,this.b.a=!0),this.g=/Android.+Mobile|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),this.g&&(a("body").addClass("iti-mobile"),this.b.d||(this.b.d="body")),this.h=new a.Deferred,this.i=new a.Deferred,this._b(),this._f(),this._h(),this._i(),this._i2(),[this.h,this.i]},_b:function(){this._d(),this._d2(),this._e()},_c:function(a,b,c){b in this.q||(this.q[b]=[]);var d=c||0;this.q[b][d]=a},_c2:function(b,c){var d;for(d=0;d",{"class":b})),this.k=a("
",{"class":"flag-container"}).insertBefore(this.a);var c=a("
",{"class":"selected-flag"});c.appendTo(this.k),this.l=a("
",{"class":"iti-flag"}).appendTo(c),this.b.m&&(this.t=a("
",{"class":"selected-dial-code"}).appendTo(c)),this.b.a?(c.attr("tabindex","0"),a("
",{"class":"iti-arrow"}).appendTo(c),this.m=a("
    ",{"class":"country-list hide"}),this.r.length&&(this._g(this.r,"preferred"),a("
  • ",{"class":"divider"}).appendTo(this.m)),this._g(this.p,""),this.o=this.m.children(".country"),this.b.d?this.dropdown=a("
    ",{"class":"intl-tel-input iti-container"}).append(this.m):this.m.appendTo(this.k)):this.o=a()},_g:function(a,b){for(var c="",d=0;d",c+="
    ",c+=""+e.name+"",c+="+"+e.dialCode+"",c+="
  • "}this.m.append(c)},_h:function(){var a=this.a.val();this._af(a)?this._v(a,!0):"auto"!==this.b.h&&(this.b.h?this._z(this.b.h,!0):(this.j=this.r.length?this.r[0].iso2:this.p[0].iso2,a||this._z(this.j,!0)),a||this.b.i||this.b.b||this.b.m||this.a.val("+"+this.s.dialCode)),a&&this._u(a,this.b.f)},_i:function(){this._j(),this.b.b&&this._l(),this.b.a&&this._i1()},_i1:function(){var a=this,b=this.a.closest("label");b.length&&b.on("click"+this.ns,function(b){a.m.hasClass("hide")?a.a.focus():b.preventDefault()});var c=this.l.parent();c.on("click"+this.ns,function(){!a.m.hasClass("hide")||a.a.prop("disabled")||a.a.prop("readonly")||a._n()}),this.k.on("keydown"+a.ns,function(b){var c=a.m.hasClass("hide");!c||b.which!=i.b&&b.which!=i.c&&b.which!=i.j&&b.which!=i.d||(b.preventDefault(),b.stopPropagation(),a._n()),b.which==i.k&&a._ac()})},_i2:function(){var c=this;this.b.n?a.fn[f].windowLoaded?a.fn[f].loadUtils(this.b.n,this.i):a(b).load(function(){a.fn[f].loadUtils(c.b.n,c.i)}):this.i.resolve(),"auto"===this.b.h?this._i3():this.h.resolve()},_i3:function(){a.fn[f].autoCountry?this.handleAutoCountry():a.fn[f].startedLoadingAutoCountry||(a.fn[f].startedLoadingAutoCountry=!0,"function"==typeof this.b.g&&this.b.g(function(b){a.fn[f].autoCountry=b.toLowerCase(),setTimeout(function(){a(".intl-tel-input input").intlTelInput("handleAutoCountry")})}))},_j:function(){var a=this;this.a.on("keyup"+this.ns,function(){a._v(a.a.val())}),this.a.on("cut"+this.ns+" paste"+this.ns+" keyup"+this.ns,function(){setTimeout(function(){a._v(a.a.val())})})},_j2:function(a){var b=this.a.attr("maxlength");return b&&a.length>b?a.substr(0,b):a},_l:function(){var b=this;this.a.on("mousedown"+this.ns,function(a){b.a.is(":focus")||b.a.val()||(a.preventDefault(),b.a.focus())}),this.a.on("focus"+this.ns,function(){b.a.val()||b.a.prop("readonly")||!b.s.dialCode||(b.a.val("+"+b.s.dialCode),b.a.one("keypress.plus"+b.ns,function(a){a.which==i.f&&b.a.val("")}),setTimeout(function(){var a=b.a[0];if(b.d){var c=b.a.val().length;a.setSelectionRange(c,c)}}))});var c=this.a.prop("form");c&&a(c).on("submit"+this.ns,function(){b._removeEmptyDialCode()}),this.a.on("blur"+this.ns,function(){b._removeEmptyDialCode()})},_removeEmptyDialCode:function(){var a=this.a.val(),b="+"==a.charAt(0);if(b){var c=this._m(a);c&&this.s.dialCode!=c||this.a.val("")}this.a.off("keypress.plus"+this.ns)},_m:function(a){return a.replace(/\D/g,"")},_n:function(){this._o();var a=this.m.children(".active");a.length&&(this._x(a),this._ad(a)),this._p(),this.l.children(".iti-arrow").addClass("up")},_o:function(){var c=this;if(this.b.d&&this.dropdown.appendTo(this.b.d),this.n=this.m.removeClass("hide").outerHeight(),!this.g){var d=this.a.offset(),e=d.top,f=a(b).scrollTop(),g=e+this.a.outerHeight()+this.nf;if(this.m.toggleClass("dropup",!g&&h),this.b.d){var i=!g&&h?0:this.a.innerHeight();this.dropdown.css({top:e+i,left:d.left}),a(b).on("scroll"+this.ns,function(){c._ac()})}}},_p:function(){var b=this;this.m.on("mouseover"+this.ns,".country",function(){b._x(a(this))}),this.m.on("click"+this.ns,".country",function(){b._ab(a(this))});var d=!0;a("html").on("click"+this.ns,function(){d||b._ac(),d=!1});var e="",f=null;a(c).on("keydown"+this.ns,function(a){a.preventDefault(),a.which==i.b||a.which==i.c?b._q(a.which):a.which==i.d?b._r():a.which==i.e?b._ac():(a.which>=i.A&&a.which<=i.Z||a.which==i.j)&&(f&&clearTimeout(f),e+=String.fromCharCode(a.which),b._s(e),f=setTimeout(function(){e=""},1e3))})},_q:function(a){var b=this.m.children(".highlight").first(),c=a==i.b?b.prev():b.next();c.length&&(c.hasClass("divider")&&(c=a==i.b?c.prev():c.next()),this._x(c),this._ad(c))},_r:function(){var a=this.m.children(".highlight").first();a.length&&this._ab(a)},_s:function(a){for(var b=0;b=4},_x:function(a){this.o.removeClass("highlight"),a.addClass("highlight")},_y:function(a,b,c){for(var d=b?j:this.p,e=0;eh)b&&(j-=k),c.scrollTop(j);else if(i>f){b&&(j+=k);var l=d-g;c.scrollTop(j-l)}},_ae:function(a,b){var c,d=this.a.val();if(a="+"+a,"+"==d.charAt(0)){var e=this._af(d);c=e?d.replace(e,a):a}else{if(this.b.i||this.b.m)return;if(d)c=a+d;else{if(!b&&this.b.b)return;c=a}}this.a.val(c)},_af:function(b){var c="";if("+"==b.charAt(0))for(var d="",e=0;e",{"class":b})),this.k=a("
    ",{"class":"flag-container"}).insertBefore(this.a);var c=a("
    ",{"class":"selected-flag"});c.appendTo(this.k),this.l=a("
    ",{"class":"iti-flag"}).appendTo(c),this.b.m&&(this.t=a("
    ",{"class":"selected-dial-code"}).appendTo(c)),this.b.a?(c.attr("tabindex","0"),a("
    ",{"class":"iti-arrow"}).appendTo(c),this.m=a("
      ",{"class":"country-list hide"}),this.r.length&&(this._g(this.r,"preferred"),a("
    • ",{"class":"divider"}).appendTo(this.m)),this._g(this.p,""),this.o=this.m.children(".country"),this.b.d?this.dropdown=a("
      ",{"class":"intl-tel-input iti-container"}).append(this.m):this.m.appendTo(this.k)):this.o=a()},_g:function(a,b){for(var c="",d=0;d",c+="
      ",c+=""+e.name+"",c+="+"+e.dialCode+"",c+="
    • "}this.m.append(c)},_h:function(){var a=this.a.val();this._af(a)?this._v(a,!0):"auto"!==this.b.h&&(this.b.h?this._z(this.b.h,!0):(this.j=this.r.length?this.r[0].iso2:this.p[0].iso2,a||this._z(this.j,!0)),a||this.b.i||this.b.b||this.b.m||this.a.val("+"+this.s.dialCode)),a&&this._u(a,this.b.f)},_i:function(){this._j(),this.b.b&&this._l(),this.b.a&&this._i1()},_i1:function(){var a=this,b=this.a.closest("label");b.length&&b.on("click"+this.ns,function(b){a.m.hasClass("hide")?a.a.focus():b.preventDefault()});var c=this.l.parent();c.on("click"+this.ns,function(b){!a.m.hasClass("hide")||a.a.prop("disabled")||a.a.prop("readonly")||a._n()}),this.k.on("keydown"+a.ns,function(b){var c=a.m.hasClass("hide");!c||b.which!=i.b&&b.which!=i.c&&b.which!=i.j&&b.which!=i.d||(b.preventDefault(),b.stopPropagation(),a._n()),b.which==i.k&&a._ac()})},_i2:function(){var c=this;this.b.n?a.fn[f].windowLoaded?a.fn[f].loadUtils(this.b.n,this.i):a(b).on("load",function(){a.fn[f].loadUtils(c.b.n,c.i)}):this.i.resolve(),"auto"===this.b.h?this._i3():this.h.resolve()},_i3:function(){a.fn[f].autoCountry?this.handleAutoCountry():a.fn[f].startedLoadingAutoCountry||(a.fn[f].startedLoadingAutoCountry=!0,"function"==typeof this.b.g&&this.b.g(function(b){a.fn[f].autoCountry=b.toLowerCase(),setTimeout(function(){a(".intl-tel-input input").intlTelInput("handleAutoCountry")})}))},_j:function(){var a=this;this.a.on("keyup"+this.ns,function(){a._v(a.a.val())}),this.a.on("cut"+this.ns+" paste"+this.ns+" keyup"+this.ns,function(){setTimeout(function(){a._v(a.a.val())})})},_j2:function(a){var b=this.a.attr("maxlength");return b&&a.length>b?a.substr(0,b):a},_l:function(){var b=this;this.a.on("mousedown"+this.ns,function(a){b.a.is(":focus")||b.a.val()||(a.preventDefault(),b.a.focus())}),this.a.on("focus"+this.ns,function(a){b.a.val()||b.a.prop("readonly")||!b.s.dialCode||(b.a.val("+"+b.s.dialCode),b.a.one("keypress.plus"+b.ns,function(a){a.which==i.f&&b.a.val("")}),setTimeout(function(){var a=b.a[0];if(b.d){var c=b.a.val().length;a.setSelectionRange(c,c)}}))});var c=this.a.prop("form");c&&a(c).on("submit"+this.ns,function(){b._removeEmptyDialCode()}),this.a.on("blur"+this.ns,function(){b._removeEmptyDialCode()})},_removeEmptyDialCode:function(){var a=this.a.val(),b="+"==a.charAt(0);if(b){var c=this._m(a);c&&this.s.dialCode!=c||this.a.val("")}this.a.off("keypress.plus"+this.ns)},_m:function(a){return a.replace(/\D/g,"")},_n:function(){this._o();var a=this.m.children(".active");a.length&&(this._x(a),this._ad(a)),this._p(),this.l.children(".iti-arrow").addClass("up")},_o:function(){var c=this;if(this.b.d&&this.dropdown.appendTo(this.b.d),this.n=this.m.removeClass("hide").outerHeight(),!this.g){var d=this.a.offset(),e=d.top,f=a(b).scrollTop(),g=e+this.a.outerHeight()+this.nf;if(this.m.toggleClass("dropup",!g&&h),this.b.d){var i=!g&&h?0:this.a.innerHeight();this.dropdown.css({top:e+i,left:d.left}),a(b).on("scroll"+this.ns,function(){c._ac()})}}},_p:function(){var b=this;this.m.on("mouseover"+this.ns,".country",function(c){b._x(a(this))}),this.m.on("click"+this.ns,".country",function(c){b._ab(a(this))});var d=!0;a("html").on("click"+this.ns,function(a){d||b._ac(),d=!1});var e="",f=null;a(c).on("keydown"+this.ns,function(a){a.preventDefault(),a.which==i.b||a.which==i.c?b._q(a.which):a.which==i.d?b._r():a.which==i.e?b._ac():(a.which>=i.A&&a.which<=i.Z||a.which==i.j)&&(f&&clearTimeout(f),e+=String.fromCharCode(a.which),b._s(e),f=setTimeout(function(){e=""},1e3))})},_q:function(a){var b=this.m.children(".highlight").first(),c=a==i.b?b.prev():b.next();c.length&&(c.hasClass("divider")&&(c=a==i.b?c.prev():c.next()),this._x(c),this._ad(c))},_r:function(){var a=this.m.children(".highlight").first();a.length&&this._ab(a)},_s:function(a){for(var b=0;b=4},_x:function(a){this.o.removeClass("highlight"),a.addClass("highlight")},_y:function(a,b,c){for(var d=b?j:this.p,e=0;eh)b&&(j-=k),c.scrollTop(j);else if(i>f){b&&(j+=k);var l=d-g;c.scrollTop(j-l)}},_ae:function(a,b){var c,d=this.a.val();if(a="+"+a,"+"==d.charAt(0)){var e=this._af(d);c=e?d.replace(e,a):a}else{if(this.b.i||this.b.m)return;if(d)c=a+d;else{if(!b&&this.b.b)return;c=a}}this.a.val(c)},_af:function(b){var c="";if("+"==b.charAt(0))for(var d="",e=0;e Date: Sat, 11 Jun 2016 14:47:22 -0700 Subject: [PATCH 4/4] Update README.md --- README.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/README.md b/README.md index 03c3c7b75..5bac93248 100644 --- a/README.md +++ b/README.md @@ -334,10 +334,7 @@ The dropdown should automatically appear above/below the input depending on the In order to get the automatic country-specific placeholders, simply omit the placeholder attribute on the ``. **Bootstrap input groups** -Simply add the following line of CSS to get Bootstrap [input groups](http://getbootstrap.com/components/#input-groups) working properly. You can view an example [here](http://codepen.io/jackocnr/pen/EyPXed). -```css -.intl-tel-input {display: table-cell;} -``` +A couple of CSS fixes are required to get the plugin to play nice with Bootstrap [input groups](http://getbootstrap.com/components/#input-groups). You can see a Codepen [here](http://codepen.io/jackocnr/pen/EyPXed). _Note: there is currently [a bug](https://bugs.webkit.org/show_bug.cgi?id=141822) in Mobile Safari which causes a crash when you click the dropdown arrow (a CSS triangle) inside an input group. The simplest workaround is to remove the CSS triangle with this line: `.intl-tel-input .iti-flag .arrow {border: none;}`_ ## Contributing