From 272320ef3a747955b78bbe21e2fc385159d4d731 Mon Sep 17 00:00:00 2001 From: Tarek Raafat Date: Sun, 4 Jul 2021 08:32:05 +0200 Subject: [PATCH] v10.2.1 => Release Notes for details --- README.md | 4 ++-- dist/autoComplete.js | 5 +---- dist/autoComplete.js.gz | Bin 5481 -> 5469 bytes dist/autoComplete.min.js | 2 +- dist/autoComplete.min.js.gz | Bin 3785 -> 3776 bytes docs/demo/index.html | 4 ++-- docs/demo/js/autoComplete.js | 5 +---- docs/demo/js/autoComplete.js.gz | Bin 5481 -> 5469 bytes docs/demo/js/autoComplete.min.js | 2 +- docs/demo/js/autoComplete.min.js.gz | Bin 3785 -> 3776 bytes docs/demo/js/index.js | 2 +- docs/how-to-guides.md | 16 +++++++++------- docs/index.html | 6 +++--- docs/release-notes.md | 6 +++++- docs/sitemap.xml | 26 +++++++++++++------------- package.json | 2 +- src/controllers/listController.js | 9 ++------- 17 files changed, 42 insertions(+), 47 deletions(-) diff --git a/README.md b/README.md index ff8e6f8..3b5a5b2 100644 --- a/README.md +++ b/README.md @@ -51,13 +51,13 @@ autoComplete.js is a simple, pure vanilla Javascript library progressively desig `JS` ```html - + ``` `CSS` ```html - + ``` #### Package Manager diff --git a/dist/autoComplete.js b/dist/autoComplete.js index b2ac08a..f28e2ac 100644 --- a/dist/autoComplete.js +++ b/dist/autoComplete.js @@ -464,10 +464,7 @@ if (ctx.cursor >= 0) select(ctx, event); break; case 9: - if (ctx.resultsList.tabSelect && ctx.cursor >= 0) { - event.preventDefault(); - select(ctx, event); - } + if (ctx.resultsList.tabSelect && ctx.cursor >= 0) select(ctx, event); break; case 27: ctx.input.value = ""; diff --git a/dist/autoComplete.js.gz b/dist/autoComplete.js.gz index 3640c18e95eb5976d1c60481ddbfd655a7acaacf..4d33b55c863ef849081aa27a6c4330fe8e41eb69 100644 GIT binary patch delta 5436 zcmV-C6~pT3D%~o7ABzY800000029qTYjfN-lHc%yW!E|J z-bS1Ipw+23Bu2xSLyk#~WUa0H?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OM6e0wzK zuit!UUiGTyXaMm0Laqu}4PGJe&?*^xi<;?7a_(D?8@YrX!iNQ)_whGwUYlGEyX6LN z&fZ3d3ESEZ(L%DRTo2CwuYdCiHl9b1#gfzr*M2e;-!j}rYh=Nr1@kG1PyWTx=;DL9 zv|x6UQ&XJayRn4}=Yl}-M?o}w^v+iC!%s}1;fF^5UWYFu9qY4Ge6Q4_;eNsIa_t%Z zZ$GRV?d1aO(r>oYP++?Gg#hCDK)J%3`xkXV>LaH8_D&4t{xLA`uz$yN*eeRZxO+VA zM#FLBQiKxHRGxk+V=zQ6Z15wtJ;yLld@T*c}cpk|4;@0O^!Bb>4Srr z$-Xz^6(%3j%=cz>{+O;YD{b}*s)vtr?r@;v6=f%9VABhq5!<|tP&0vD6$Kf)dNYwN zFVEh1_d|xCina*u+kbc+6gGyLz0WiGG}u&xYBSPNc72IAQ4Q$8%;H^tgFZLD3b~f8@wT&r#Kx}*P@QDz4S73vh&~g}hy24Vun9sg9M;=-;8|$h z*5l+Omftf2rCW?T4^@|$UPGRQNt2g(s*4kXE_`G0#eW8i;MM7SYa9f612X~f&}rT(Ke0Guqlah+IS>n(tHwxc@Ms$j=6nG+KpIPTLNZ5+tE zZyR)a0$utT#YvQ*+H+VK92NSYR;#?#aJK~imw)zT|1UN`x9?s2v^}UV*{UN3hsjO7 z!`q(QB*3;sZVU7Y0$C+e{@1X0IC6hm-9&*Uv!2o|}~hjLq(wJEtV2ud3bO-vFg! zA4RLqh3it^vU;4Dk{5!fdwRZn!HTgxk5ZU)T56f_AqneuxdR`?tCqZ-eJXaun*B7> zF1rq$5cG-__*w9MHXuR@0L{B5aX0A9?Yp`7BVSK8fj;K{?BQtYgoE3!*SWHh<0U6e j>f^a!eFWngHe.length)&&(t=e.length);for(var n=0,r=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw s}}}}(n.keys);try{for(f.s();!(l=f.n()).done;)c(l.value)}catch(e){f.e(e)}finally{f.f()}}else c()})),n.filter&&(u=n.filter(u));var c=u.slice(0,s.maxResults);t.feedback={query:e,matches:u,results:c},f("results",t)},m="aria-expanded",v="aria-activedescendant",y="aria-selected",b=function(e,n){e.feedback.selection=t({index:n},e.feedback.results[n])},g=function(e){e.isOpen||((e.wrapper||e.input).setAttribute(m,!0),e.list.removeAttribute("hidden"),e.isOpen=!0,f("open",e))},w=function(e){e.isOpen&&((e.wrapper||e.input).setAttribute(m,!1),e.input.setAttribute(v,""),e.list.setAttribute("hidden",""),e.isOpen=!1,f("close",e))},O=function(e,t){var n=t.list,r=t.resultItem,o=n.getElementsByTagName(r.tag),s=!!r.selected&&r.selected.split(" ");if(t.isOpen&&o.length){var a,u,c=t.cursor;e>=o.length&&(e=0),e<0&&(e=o.length-1),t.cursor=e,c>-1&&(o[c].removeAttribute(y),s&&(u=o[c].classList).remove.apply(u,i(s))),o[e].setAttribute(y,!0),s&&(a=o[e].classList).add.apply(a,i(s)),t.input.setAttribute(v,o[t.cursor].id),n.scrollTop=o[e].offsetTop-n.clientHeight+o[e].clientHeight+5,t.feedback.cursor=t.cursor,b(t,e),f("navigate",t)}},A=function(e){var t=e.cursor+1;O(t,e)},S=function(e){var t=e.cursor-1;O(t,e)},k=function(e,t,n){(n=n>=0?n:e.cursor)<0||(e.feedback.event=t,b(e,n),f("selection",e),w(e))};function j(e,n){var r=this;return new Promise((function(i,o){var s,a,c,l,f,p,m;return s=e.input,a=e.query,c=e.trigger,l=e.threshold,f=e.resultsList,p=n||((m=s)instanceof HTMLInputElement||m instanceof HTMLTextAreaElement?m.value:m.innerHTML),function(e,t,n){return t?t(e):e.length>=n}(p=a?a(p):p,c,l)?d(e).then((function(n){try{return e.feedback instanceof Error?i():(h(p,e),f&&function(e){var n=e.resultsList,r=e.list,i=e.resultItem,o=e.feedback;o.query;var s=o.matches,a=o.results;if(e.cursor=-1,r.innerHTML="",s.length||n.noResults){var c=document.createDocumentFragment();a.forEach((function(e,n){var r=u(i.tag,t({id:"".concat(i.id,"_").concat(n),role:"option",innerHTML:e.match,inside:c},i.class&&{class:i.class}));i.element&&i.element(r,e)})),r.append(c),n.element&&n.element(r,o),g(e)}else w(e)}(e),v.call(r))}catch(e){return o(e)}}),o):(w(e),v.call(r));function v(){return i()}}))}var L=function(e,t){for(var n in e)for(var r in e[n])t(n,r)},T=function(e){var n=e.events;e.trigger;var r=e.debounce,i=e.resultsList,o=function(e,t){var n;return function(){clearTimeout(n),n=setTimeout((function(){return e()}),t)}}((function(){return j(e)}),r),s=e.events=t({input:t({},n&&n.input)},i&&{list:n?t({},n.list):{}}),a={input:{input:function(){o()},keydown:function(t){!function(e,t){switch(e.keyCode){case 40:case 38:e.preventDefault(),40===e.keyCode?A(t):S(t);break;case 13:t.submit||e.preventDefault(),t.cursor>=0&&k(t,e);break;case 9:t.resultsList.tabSelect&&t.cursor>=0&&(e.preventDefault(),k(t,e));break;case 27:t.input.value="",w(t)}}(t,e)},blur:function(){w(e)}},list:{mousedown:function(e){e.preventDefault()},click:function(t){!function(e,t){var n=t.resultItem.tag.toUpperCase(),r=Array.from(t.list.querySelectorAll(n)),i=e.target.closest(n);if(i&&i.nodeName===n){var o=r.indexOf(i);k(t,e,o)}}(t,e)}}};L(a,(function(e,t){(i||"input"===t)&&(s[e][t]||(s[e][t]=a[e][t]))})),L(s,(function(t,n){e[t].addEventListener(n,s[t][n])}))};function E(e){var n=this;return new Promise((function(r,i){var o,s,a,c,l,p;if(o=e.name,s=e.input,a=e.placeHolder,c=e.resultsList,l=e.data,p={role:"combobox","aria-owns":c.id,"aria-haspopup":!0,"aria-expanded":!1},u(s,t(t({"aria-controls":c.id,"aria-autocomplete":"both"},a&&{placeholder:a}),!e.wrapper&&t({},p))),e.wrapper&&(e.wrapper=u("div",t({around:s,class:o+"_wrapper"},p))),c&&(e.list=u(c.tag,t({dest:["string"==typeof c.destination?document.querySelector(c.destination):c.destination(),c.position],id:c.id,role:"listbox",hidden:"hidden"},c.class&&{class:c.class}))),l.cache)return d(e).then((function(e){try{return h.call(n)}catch(e){return i(e)}}),i);function h(){return T(e),f("init",e),r()}return h.call(n)}))}function x(e){var t=e.prototype;t.init=function(){E(this)},t.start=function(e){j(this,e)},t.unInit=function(){if(this.wrapper){var e=this.wrapper.parentNode;e.insertBefore(this.input,this.wrapper),e.removeChild(this.wrapper)}var t;L((t=this).events,(function(e,n){t[e].removeEventListener(n,t.events[e][n])}))},t.open=function(){g(this)},t.close=function(){w(this)},t.goTo=function(e){O(e,this)},t.next=function(){A(this)},t.previous=function(){S(this)},t.select=function(e){k(this,null,e)},e.search=t.search=function(e,t,n){p(e,t,n)}}return function e(t){this.options=t,this.id=e.instances=(e.instances||0)+1,this.name="autoComplete",this.wrapper=1,this.threshold=1,this.debounce=0,this.resultsList={position:"afterend",tag:"ul",maxResults:5},this.resultItem={tag:"li"},function(e){var t=e.id,r=e.name,i=e.options,o=e.resultsList,s=e.resultItem;for(var a in i)if("object"===n(i[a]))for(var u in e[a]||(e[a]={}),i[a])e[a][u]=i[a][u];else e[a]=i[a];e.selector=e.selector||"#"+r,o.destination=o.destination||e.selector,o.id=o.id||r+"_list_"+t,s.id=s.id||r+"_result",e.input="string"==typeof e.selector?document.querySelector(e.selector):e.selector()}(this),x.call(this,e),E(this)}},"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).autoComplete=t(); +var e,t;e=this,t=function(){"use strict";function e(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function t(t){for(var n=1;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw s}}}}(n.keys);try{for(f.s();!(l=f.n()).done;)c(l.value)}catch(e){f.e(e)}finally{f.f()}}else c()})),n.filter&&(u=n.filter(u));var c=u.slice(0,s.maxResults);t.feedback={query:e,matches:u,results:c},f("results",t)},m="aria-expanded",v="aria-activedescendant",y="aria-selected",b=function(e,n){e.feedback.selection=t({index:n},e.feedback.results[n])},g=function(e){e.isOpen||((e.wrapper||e.input).setAttribute(m,!0),e.list.removeAttribute("hidden"),e.isOpen=!0,f("open",e))},w=function(e){e.isOpen&&((e.wrapper||e.input).setAttribute(m,!1),e.input.setAttribute(v,""),e.list.setAttribute("hidden",""),e.isOpen=!1,f("close",e))},O=function(e,t){var n=t.list,r=t.resultItem,o=n.getElementsByTagName(r.tag),s=!!r.selected&&r.selected.split(" ");if(t.isOpen&&o.length){var a,u,c=t.cursor;e>=o.length&&(e=0),e<0&&(e=o.length-1),t.cursor=e,c>-1&&(o[c].removeAttribute(y),s&&(u=o[c].classList).remove.apply(u,i(s))),o[e].setAttribute(y,!0),s&&(a=o[e].classList).add.apply(a,i(s)),t.input.setAttribute(v,o[t.cursor].id),n.scrollTop=o[e].offsetTop-n.clientHeight+o[e].clientHeight+5,t.feedback.cursor=t.cursor,b(t,e),f("navigate",t)}},A=function(e){var t=e.cursor+1;O(t,e)},S=function(e){var t=e.cursor-1;O(t,e)},k=function(e,t,n){(n=n>=0?n:e.cursor)<0||(e.feedback.event=t,b(e,n),f("selection",e),w(e))};function j(e,n){var r=this;return new Promise((function(i,o){var s,a,c,l,f,p,m;return s=e.input,a=e.query,c=e.trigger,l=e.threshold,f=e.resultsList,p=n||((m=s)instanceof HTMLInputElement||m instanceof HTMLTextAreaElement?m.value:m.innerHTML),function(e,t,n){return t?t(e):e.length>=n}(p=a?a(p):p,c,l)?d(e).then((function(n){try{return e.feedback instanceof Error?i():(h(p,e),f&&function(e){var n=e.resultsList,r=e.list,i=e.resultItem,o=e.feedback;o.query;var s=o.matches,a=o.results;if(e.cursor=-1,r.innerHTML="",s.length||n.noResults){var c=document.createDocumentFragment();a.forEach((function(e,n){var r=u(i.tag,t({id:"".concat(i.id,"_").concat(n),role:"option",innerHTML:e.match,inside:c},i.class&&{class:i.class}));i.element&&i.element(r,e)})),r.append(c),n.element&&n.element(r,o),g(e)}else w(e)}(e),v.call(r))}catch(e){return o(e)}}),o):(w(e),v.call(r));function v(){return i()}}))}var L=function(e,t){for(var n in e)for(var r in e[n])t(n,r)},T=function(e){var n=e.events;e.trigger;var r=e.debounce,i=e.resultsList,o=function(e,t){var n;return function(){clearTimeout(n),n=setTimeout((function(){return e()}),t)}}((function(){return j(e)}),r),s=e.events=t({input:t({},n&&n.input)},i&&{list:n?t({},n.list):{}}),a={input:{input:function(){o()},keydown:function(t){!function(e,t){switch(e.keyCode){case 40:case 38:e.preventDefault(),40===e.keyCode?A(t):S(t);break;case 13:t.submit||e.preventDefault(),t.cursor>=0&&k(t,e);break;case 9:t.resultsList.tabSelect&&t.cursor>=0&&k(t,e);break;case 27:t.input.value="",w(t)}}(t,e)},blur:function(){w(e)}},list:{mousedown:function(e){e.preventDefault()},click:function(t){!function(e,t){var n=t.resultItem.tag.toUpperCase(),r=Array.from(t.list.querySelectorAll(n)),i=e.target.closest(n);if(i&&i.nodeName===n){var o=r.indexOf(i);k(t,e,o)}}(t,e)}}};L(a,(function(e,t){(i||"input"===t)&&(s[e][t]||(s[e][t]=a[e][t]))})),L(s,(function(t,n){e[t].addEventListener(n,s[t][n])}))};function E(e){var n=this;return new Promise((function(r,i){var o,s,a,c,l,p;if(o=e.name,s=e.input,a=e.placeHolder,c=e.resultsList,l=e.data,p={role:"combobox","aria-owns":c.id,"aria-haspopup":!0,"aria-expanded":!1},u(s,t(t({"aria-controls":c.id,"aria-autocomplete":"both"},a&&{placeholder:a}),!e.wrapper&&t({},p))),e.wrapper&&(e.wrapper=u("div",t({around:s,class:o+"_wrapper"},p))),c&&(e.list=u(c.tag,t({dest:["string"==typeof c.destination?document.querySelector(c.destination):c.destination(),c.position],id:c.id,role:"listbox",hidden:"hidden"},c.class&&{class:c.class}))),l.cache)return d(e).then((function(e){try{return h.call(n)}catch(e){return i(e)}}),i);function h(){return T(e),f("init",e),r()}return h.call(n)}))}function x(e){var t=e.prototype;t.init=function(){E(this)},t.start=function(e){j(this,e)},t.unInit=function(){if(this.wrapper){var e=this.wrapper.parentNode;e.insertBefore(this.input,this.wrapper),e.removeChild(this.wrapper)}var t;L((t=this).events,(function(e,n){t[e].removeEventListener(n,t.events[e][n])}))},t.open=function(){g(this)},t.close=function(){w(this)},t.goTo=function(e){O(e,this)},t.next=function(){A(this)},t.previous=function(){S(this)},t.select=function(e){k(this,null,e)},e.search=t.search=function(e,t,n){p(e,t,n)}}return function e(t){this.options=t,this.id=e.instances=(e.instances||0)+1,this.name="autoComplete",this.wrapper=1,this.threshold=1,this.debounce=0,this.resultsList={position:"afterend",tag:"ul",maxResults:5},this.resultItem={tag:"li"},function(e){var t=e.id,r=e.name,i=e.options,o=e.resultsList,s=e.resultItem;for(var a in i)if("object"===n(i[a]))for(var u in e[a]||(e[a]={}),i[a])e[a][u]=i[a][u];else e[a]=i[a];e.selector=e.selector||"#"+r,o.destination=o.destination||e.selector,o.id=o.id||r+"_list_"+t,s.id=s.id||r+"_result",e.input="string"==typeof e.selector?document.querySelector(e.selector):e.selector()}(this),x.call(this,e),E(this)}},"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).autoComplete=t(); diff --git a/dist/autoComplete.min.js.gz b/d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HLQnV2Iu-8MePgpj z=*^P*+opWKZz2HxXK)RMJjSqe@ + href="https://cdn.jsdelivr.net/npm/@tarekraafat/autocomplete.js@10.2.1/dist/css/autoComplete.min.css"> @@ -150,7 +150,7 @@

mode

- + diff --git a/docs/demo/js/autoComplete.js b/docs/demo/js/autoComplete.js index b2ac08a..f28e2ac 100644 --- a/docs/demo/js/autoComplete.js +++ b/docs/demo/js/autoComplete.js @@ -464,10 +464,7 @@ if (ctx.cursor >= 0) select(ctx, event); break; case 9: - if (ctx.resultsList.tabSelect && ctx.cursor >= 0) { - event.preventDefault(); - select(ctx, event); - } + if (ctx.resultsList.tabSelect && ctx.cursor >= 0) select(ctx, event); break; case 27: ctx.input.value = ""; diff --git a/docs/demo/js/autoComplete.js.gz b/docs/demo/js/autoComplete.js.gz index 3640c18e95eb5976d1c60481ddbfd655a7acaacf..4d33b55c863ef849081aa27a6c4330fe8e41eb69 100644 GIT binary patch delta 5436 zcmV-C6~pT3D%~o7ABzY800000029qTYjfN-lHc%yW!E|J z-bS1Ipw+23Bu2xSLyk#~WUa0H?c0sUqXA+@+Fb7HT$Kz7G#cHFexU&>UG3U(th-jE z7frV;nweM?<=FMtnfUaD5aab$b}J!2Zo7UQ#PRX5__A9X{vylqOY!^Po9<0l?HVcW zVehW3Pb2lJ&q}H03wv6hfkKLQ*EFDrUh`ahy788v7XKoia5)-1 zA~B|fJ)4QK-^nZo8ebOWnk@q`>Mz4N8G(_!W^#rSnQ3BA;rT3!N?gbWG<>fHx_@;X z_^cY%o4J;Qo%=RihRu+U+r)Awfy9Ul#B!U?(sT+qi_0ydf;2-!3CVq-As9lF@0Z0= zHjmb_fvE@aP`kK7SZ-gHJ%ge3>XMejZ4I>(udX>}H>~8yR><}XuoZ%LXZ9nneO7Rtm ztXH5p0HxLDvS`34HHWxH&?;)hq2oKQeh!I~k3u)6pP6lSE^@A%fa?M2tm=zhwC}2~ zN7rtc&!S5Qv?z}NYp3RpiAaku)MN;s?XcV6OwanhxK4|{H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@wT&r#Kx}*P@QDz4S73vh&~g}hy24Vun9sg9M;=-;8|$h z*5l+Omftf2rCW?T4^@|$UPGRQNt2g(s*4kXE_`G0#eW8i;MM7SYa9f612X~f&}rT(Ke0Guqlah+IS>n(tHwxc@Ms$j=6nG+KpIPTLNZ5+tE zZyR)a0$utT#YvQ*+H+VK92NSYR;#?#aJK~imw)zT|1UN`x9?s2v^}UV*{UN3hsjO7 z!`q(QB*3;sZVU7Y0$C+e{@1X0IC6hm-9&*Uv!2o|}~hjLq(wJEtV2ud3bO-vFg! zA4RLqh3it^vU;4Dk{5!fdwRZn!HTgxk5ZU)T56f_AqneuxdR`?tCqZ-eJXaun*B7> zF1rq$5cG-__*w9MHXuR@0L{B5aX0A9?Yp`7BVSK8fj;K{?BQtYgoE3!*SWHh<0U6e j>f^a!eFWngHe.length)&&(t=e.length);for(var n=0,r=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw s}}}}(n.keys);try{for(f.s();!(l=f.n()).done;)c(l.value)}catch(e){f.e(e)}finally{f.f()}}else c()})),n.filter&&(u=n.filter(u));var c=u.slice(0,s.maxResults);t.feedback={query:e,matches:u,results:c},f("results",t)},m="aria-expanded",v="aria-activedescendant",y="aria-selected",b=function(e,n){e.feedback.selection=t({index:n},e.feedback.results[n])},g=function(e){e.isOpen||((e.wrapper||e.input).setAttribute(m,!0),e.list.removeAttribute("hidden"),e.isOpen=!0,f("open",e))},w=function(e){e.isOpen&&((e.wrapper||e.input).setAttribute(m,!1),e.input.setAttribute(v,""),e.list.setAttribute("hidden",""),e.isOpen=!1,f("close",e))},O=function(e,t){var n=t.list,r=t.resultItem,o=n.getElementsByTagName(r.tag),s=!!r.selected&&r.selected.split(" ");if(t.isOpen&&o.length){var a,u,c=t.cursor;e>=o.length&&(e=0),e<0&&(e=o.length-1),t.cursor=e,c>-1&&(o[c].removeAttribute(y),s&&(u=o[c].classList).remove.apply(u,i(s))),o[e].setAttribute(y,!0),s&&(a=o[e].classList).add.apply(a,i(s)),t.input.setAttribute(v,o[t.cursor].id),n.scrollTop=o[e].offsetTop-n.clientHeight+o[e].clientHeight+5,t.feedback.cursor=t.cursor,b(t,e),f("navigate",t)}},A=function(e){var t=e.cursor+1;O(t,e)},S=function(e){var t=e.cursor-1;O(t,e)},k=function(e,t,n){(n=n>=0?n:e.cursor)<0||(e.feedback.event=t,b(e,n),f("selection",e),w(e))};function j(e,n){var r=this;return new Promise((function(i,o){var s,a,c,l,f,p,m;return s=e.input,a=e.query,c=e.trigger,l=e.threshold,f=e.resultsList,p=n||((m=s)instanceof HTMLInputElement||m instanceof HTMLTextAreaElement?m.value:m.innerHTML),function(e,t,n){return t?t(e):e.length>=n}(p=a?a(p):p,c,l)?d(e).then((function(n){try{return e.feedback instanceof Error?i():(h(p,e),f&&function(e){var n=e.resultsList,r=e.list,i=e.resultItem,o=e.feedback;o.query;var s=o.matches,a=o.results;if(e.cursor=-1,r.innerHTML="",s.length||n.noResults){var c=document.createDocumentFragment();a.forEach((function(e,n){var r=u(i.tag,t({id:"".concat(i.id,"_").concat(n),role:"option",innerHTML:e.match,inside:c},i.class&&{class:i.class}));i.element&&i.element(r,e)})),r.append(c),n.element&&n.element(r,o),g(e)}else w(e)}(e),v.call(r))}catch(e){return o(e)}}),o):(w(e),v.call(r));function v(){return i()}}))}var L=function(e,t){for(var n in e)for(var r in e[n])t(n,r)},T=function(e){var n=e.events;e.trigger;var r=e.debounce,i=e.resultsList,o=function(e,t){var n;return function(){clearTimeout(n),n=setTimeout((function(){return e()}),t)}}((function(){return j(e)}),r),s=e.events=t({input:t({},n&&n.input)},i&&{list:n?t({},n.list):{}}),a={input:{input:function(){o()},keydown:function(t){!function(e,t){switch(e.keyCode){case 40:case 38:e.preventDefault(),40===e.keyCode?A(t):S(t);break;case 13:t.submit||e.preventDefault(),t.cursor>=0&&k(t,e);break;case 9:t.resultsList.tabSelect&&t.cursor>=0&&(e.preventDefault(),k(t,e));break;case 27:t.input.value="",w(t)}}(t,e)},blur:function(){w(e)}},list:{mousedown:function(e){e.preventDefault()},click:function(t){!function(e,t){var n=t.resultItem.tag.toUpperCase(),r=Array.from(t.list.querySelectorAll(n)),i=e.target.closest(n);if(i&&i.nodeName===n){var o=r.indexOf(i);k(t,e,o)}}(t,e)}}};L(a,(function(e,t){(i||"input"===t)&&(s[e][t]||(s[e][t]=a[e][t]))})),L(s,(function(t,n){e[t].addEventListener(n,s[t][n])}))};function E(e){var n=this;return new Promise((function(r,i){var o,s,a,c,l,p;if(o=e.name,s=e.input,a=e.placeHolder,c=e.resultsList,l=e.data,p={role:"combobox","aria-owns":c.id,"aria-haspopup":!0,"aria-expanded":!1},u(s,t(t({"aria-controls":c.id,"aria-autocomplete":"both"},a&&{placeholder:a}),!e.wrapper&&t({},p))),e.wrapper&&(e.wrapper=u("div",t({around:s,class:o+"_wrapper"},p))),c&&(e.list=u(c.tag,t({dest:["string"==typeof c.destination?document.querySelector(c.destination):c.destination(),c.position],id:c.id,role:"listbox",hidden:"hidden"},c.class&&{class:c.class}))),l.cache)return d(e).then((function(e){try{return h.call(n)}catch(e){return i(e)}}),i);function h(){return T(e),f("init",e),r()}return h.call(n)}))}function x(e){var t=e.prototype;t.init=function(){E(this)},t.start=function(e){j(this,e)},t.unInit=function(){if(this.wrapper){var e=this.wrapper.parentNode;e.insertBefore(this.input,this.wrapper),e.removeChild(this.wrapper)}var t;L((t=this).events,(function(e,n){t[e].removeEventListener(n,t.events[e][n])}))},t.open=function(){g(this)},t.close=function(){w(this)},t.goTo=function(e){O(e,this)},t.next=function(){A(this)},t.previous=function(){S(this)},t.select=function(e){k(this,null,e)},e.search=t.search=function(e,t,n){p(e,t,n)}}return function e(t){this.options=t,this.id=e.instances=(e.instances||0)+1,this.name="autoComplete",this.wrapper=1,this.threshold=1,this.debounce=0,this.resultsList={position:"afterend",tag:"ul",maxResults:5},this.resultItem={tag:"li"},function(e){var t=e.id,r=e.name,i=e.options,o=e.resultsList,s=e.resultItem;for(var a in i)if("object"===n(i[a]))for(var u in e[a]||(e[a]={}),i[a])e[a][u]=i[a][u];else e[a]=i[a];e.selector=e.selector||"#"+r,o.destination=o.destination||e.selector,o.id=o.id||r+"_list_"+t,s.id=s.id||r+"_result",e.input="string"==typeof e.selector?document.querySelector(e.selector):e.selector()}(this),x.call(this,e),E(this)}},"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).autoComplete=t(); +var e,t;e=this,t=function(){"use strict";function e(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function t(t){for(var n=1;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,s=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw s}}}}(n.keys);try{for(f.s();!(l=f.n()).done;)c(l.value)}catch(e){f.e(e)}finally{f.f()}}else c()})),n.filter&&(u=n.filter(u));var c=u.slice(0,s.maxResults);t.feedback={query:e,matches:u,results:c},f("results",t)},m="aria-expanded",v="aria-activedescendant",y="aria-selected",b=function(e,n){e.feedback.selection=t({index:n},e.feedback.results[n])},g=function(e){e.isOpen||((e.wrapper||e.input).setAttribute(m,!0),e.list.removeAttribute("hidden"),e.isOpen=!0,f("open",e))},w=function(e){e.isOpen&&((e.wrapper||e.input).setAttribute(m,!1),e.input.setAttribute(v,""),e.list.setAttribute("hidden",""),e.isOpen=!1,f("close",e))},O=function(e,t){var n=t.list,r=t.resultItem,o=n.getElementsByTagName(r.tag),s=!!r.selected&&r.selected.split(" ");if(t.isOpen&&o.length){var a,u,c=t.cursor;e>=o.length&&(e=0),e<0&&(e=o.length-1),t.cursor=e,c>-1&&(o[c].removeAttribute(y),s&&(u=o[c].classList).remove.apply(u,i(s))),o[e].setAttribute(y,!0),s&&(a=o[e].classList).add.apply(a,i(s)),t.input.setAttribute(v,o[t.cursor].id),n.scrollTop=o[e].offsetTop-n.clientHeight+o[e].clientHeight+5,t.feedback.cursor=t.cursor,b(t,e),f("navigate",t)}},A=function(e){var t=e.cursor+1;O(t,e)},S=function(e){var t=e.cursor-1;O(t,e)},k=function(e,t,n){(n=n>=0?n:e.cursor)<0||(e.feedback.event=t,b(e,n),f("selection",e),w(e))};function j(e,n){var r=this;return new Promise((function(i,o){var s,a,c,l,f,p,m;return s=e.input,a=e.query,c=e.trigger,l=e.threshold,f=e.resultsList,p=n||((m=s)instanceof HTMLInputElement||m instanceof HTMLTextAreaElement?m.value:m.innerHTML),function(e,t,n){return t?t(e):e.length>=n}(p=a?a(p):p,c,l)?d(e).then((function(n){try{return e.feedback instanceof Error?i():(h(p,e),f&&function(e){var n=e.resultsList,r=e.list,i=e.resultItem,o=e.feedback;o.query;var s=o.matches,a=o.results;if(e.cursor=-1,r.innerHTML="",s.length||n.noResults){var c=document.createDocumentFragment();a.forEach((function(e,n){var r=u(i.tag,t({id:"".concat(i.id,"_").concat(n),role:"option",innerHTML:e.match,inside:c},i.class&&{class:i.class}));i.element&&i.element(r,e)})),r.append(c),n.element&&n.element(r,o),g(e)}else w(e)}(e),v.call(r))}catch(e){return o(e)}}),o):(w(e),v.call(r));function v(){return i()}}))}var L=function(e,t){for(var n in e)for(var r in e[n])t(n,r)},T=function(e){var n=e.events;e.trigger;var r=e.debounce,i=e.resultsList,o=function(e,t){var n;return function(){clearTimeout(n),n=setTimeout((function(){return e()}),t)}}((function(){return j(e)}),r),s=e.events=t({input:t({},n&&n.input)},i&&{list:n?t({},n.list):{}}),a={input:{input:function(){o()},keydown:function(t){!function(e,t){switch(e.keyCode){case 40:case 38:e.preventDefault(),40===e.keyCode?A(t):S(t);break;case 13:t.submit||e.preventDefault(),t.cursor>=0&&k(t,e);break;case 9:t.resultsList.tabSelect&&t.cursor>=0&&k(t,e);break;case 27:t.input.value="",w(t)}}(t,e)},blur:function(){w(e)}},list:{mousedown:function(e){e.preventDefault()},click:function(t){!function(e,t){var n=t.resultItem.tag.toUpperCase(),r=Array.from(t.list.querySelectorAll(n)),i=e.target.closest(n);if(i&&i.nodeName===n){var o=r.indexOf(i);k(t,e,o)}}(t,e)}}};L(a,(function(e,t){(i||"input"===t)&&(s[e][t]||(s[e][t]=a[e][t]))})),L(s,(function(t,n){e[t].addEventListener(n,s[t][n])}))};function E(e){var n=this;return new Promise((function(r,i){var o,s,a,c,l,p;if(o=e.name,s=e.input,a=e.placeHolder,c=e.resultsList,l=e.data,p={role:"combobox","aria-owns":c.id,"aria-haspopup":!0,"aria-expanded":!1},u(s,t(t({"aria-controls":c.id,"aria-autocomplete":"both"},a&&{placeholder:a}),!e.wrapper&&t({},p))),e.wrapper&&(e.wrapper=u("div",t({around:s,class:o+"_wrapper"},p))),c&&(e.list=u(c.tag,t({dest:["string"==typeof c.destination?document.querySelector(c.destination):c.destination(),c.position],id:c.id,role:"listbox",hidden:"hidden"},c.class&&{class:c.class}))),l.cache)return d(e).then((function(e){try{return h.call(n)}catch(e){return i(e)}}),i);function h(){return T(e),f("init",e),r()}return h.call(n)}))}function x(e){var t=e.prototype;t.init=function(){E(this)},t.start=function(e){j(this,e)},t.unInit=function(){if(this.wrapper){var e=this.wrapper.parentNode;e.insertBefore(this.input,this.wrapper),e.removeChild(this.wrapper)}var t;L((t=this).events,(function(e,n){t[e].removeEventListener(n,t.events[e][n])}))},t.open=function(){g(this)},t.close=function(){w(this)},t.goTo=function(e){O(e,this)},t.next=function(){A(this)},t.previous=function(){S(this)},t.select=function(e){k(this,null,e)},e.search=t.search=function(e,t,n){p(e,t,n)}}return function e(t){this.options=t,this.id=e.instances=(e.instances||0)+1,this.name="autoComplete",this.wrapper=1,this.threshold=1,this.debounce=0,this.resultsList={position:"afterend",tag:"ul",maxResults:5},this.resultItem={tag:"li"},function(e){var t=e.id,r=e.name,i=e.options,o=e.resultsList,s=e.resultItem;for(var a in i)if("object"===n(i[a]))for(var u in e[a]||(e[a]={}),i[a])e[a][u]=i[a][u];else e[a]=i[a];e.selector=e.selector||"#"+r,o.destination=o.destination||e.selector,o.id=o.id||r+"_list_"+t,s.id=s.id||r+"_result",e.input="string"==typeof e.selector?document.querySelector(e.selector):e.selector()}(this),x.call(this,e),E(this)}},"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).autoComplete=t(); diff --git a/docs/demo/js/autoComplete.min.js.gz b/docs/demo/js/autoComplete.min.js.gz index 0d94ffc2d611cf4db097b2163cffef96bf23d61d..1dca7f4d7d0030b095c354065b272fba853f9c07 100644 GIT binary patch delta 3683 zcmV-p4xI7H9l#xbABzY8000000294gYm?i!mHnPyq2_K>WHroD&m`FiWm@TYoEld- zGW%3Xc;q~hdR~qR+NV8FznBSeKj|Yma~gX{KV^Ai^?c%&lq#r z9JtOlC2ylBVlu9pdLL(1RX&B1>8SOK$+o|pp*^-(z}@d=DPLxKhh?Oxt&rRg5WL1J-$%RgiHNU(ak8>qq>`jif(=_ehUv=%c(#j~Bw(8E7^czOlXt<=cKPHEB z%>?$psIezI6y{VmJdtcL+2m@$aHOr+HU0CW7RI+*Xz<>wQ%o856{G8pB>=y?)jE5M zMQwlaF7m_3;adEiPG=K>M!JI*!PS4cu$1 zO}CDYX0O%bO!CLs9rk>qHOwh^DBWN*7$y&<%S05N0Q2b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y2g9Uo+knM&EVR<9ge9I=}yPGfLxIdC|FR9 zoJ}LLtqT2rgxHH%oS$Jr>FYQM!$$|nxk47WQJ+C{ZQ1}MsDmW85N==Wv$|4MQw3D& zJ4-{5@wTjiGE4~Pb)CR`1JP3h%3^Kb+L zgo?=I=;gro5rBe1JlOiDs~;ydb3sF02fzAJfftc~+o@z~n3s2fiwf4s{j-8;9#aQ0 zK)Qf0)!iq9qGa+2BhTYX)q)<@4Dr!w!|9whVO8#OjHJso;9h6JFYkk2#7b9t>k5RI z_zIu!mAwmA@_AenKCX#T7~2mReiu68E2J=%PwKEQg%3ib(Kn>eV~*Q@5?T@@iOHAv zHzC=7JAee(3CA{*SohI(TDUTCBj29QrNjsQ-Su~6hVi@6*MjBQ_X0c2dC5cy<353T zy%%LMUBL!&1I(a$Gws_4G^45b!M%DMj=KZW4K!vNk9mNhZ`?2fxzv8idEH^iL&LqgThQn+MNX>Rh(3Ali$~MXO?RYXpwDf4ll>#1nDaj*8@35I7m_N0D zW%pw=t|#Qb|M->>B@_{T7E{Cb(oo!I2tVDR#_`6CVif(PNAhPHLQnV2Iu-8MePgpj z=*^P*+opWKZz2HxXK)RMJjSqe@ { const info = document.createElement("p"); - if (data.results.length > 0) { + if (data.results.length) { info.innerHTML = `Displaying ${data.results.length} out of ${data.matches.length} results`; } else { info.innerHTML = `Found ${data.matches.length} matching results for "${data.query}"`; diff --git a/docs/how-to-guides.md b/docs/how-to-guides.md index daa4b32..6f0e412 100644 --- a/docs/how-to-guides.md +++ b/docs/how-to-guides.md @@ -44,13 +44,15 @@ events: { // autoComplete.js Config Options resultsList: { element: (list, query) => { - // Create "No Results" message list element - const message = document.createElement("div"); - message.setAttribute("class", "no_result"); - // Add message text content - message.innerHTML = `Found No Results for "${query}"`; - // Add message list element to the list - list.appendChild(message); + if (!data.results.length) { + // Create "No Results" message list element + const message = document.createElement("div"); + message.setAttribute("class", "no_result"); + // Add message text content + message.innerHTML = `Found No Results for "${query}"`; + // Add message list element to the list + list.appendChild(message); + } }, noResults: true, } diff --git a/docs/index.html b/docs/index.html index 56df251..4d51e60 100644 --- a/docs/index.html +++ b/docs/index.html @@ -158,7 +158,7 @@ src="//platform-api.sharethis.com/js/sharethis.js#property=5c213660c276020011d38212&product=inline-share-buttons" async="async"> + href="https://cdn.jsdelivr.net/npm/@tarekraafat/autocomplete.js@10.2.1/dist/css/autoComplete.min.css"> @@ -209,7 +209,7 @@ mustache: { data: ["../package.json", { minVersion: "10.2", - version: "10.2.0" + version: "10.2.1" }] } } @@ -224,7 +224,7 @@ - + \ No newline at end of file diff --git a/docs/release-notes.md b/docs/release-notes.md index 1e84342..23d8d14 100644 --- a/docs/release-notes.md +++ b/docs/release-notes.md @@ -35,7 +35,11 @@ For more information on semantic versioning, please visit . *** -### v10.2.0 โœจ +### v10.2.1 โœจ +- ๐Ÿงน Removed: `preventDefault` on `Tab` key press event +- ๐ŸŽ›๏ธ Updated: `No Results Found` example under `How-to Guides` in documentation + +### v10.2.0 - โž• Added: `submit` API property controls `Enter` button default behavior (Thanks ๐Ÿ‘ @CodeWithOz) #249 #224 #189 - โž• Added: `query` parameter to the `start("query")` API method for programmatic operations - ๐Ÿ”ง Fixed: Generated errors when `resultsList` is disabled due to the attachment of the `keydown` event diff --git a/docs/sitemap.xml b/docs/sitemap.xml index 7a53676..3e18ccf 100644 --- a/docs/sitemap.xml +++ b/docs/sitemap.xml @@ -2,54 +2,54 @@ https://tarekraafat.github.io/autoComplete.js/ - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/getting-started - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/installation - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/usage - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/configuration - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/playground - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/styles - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/plugins - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/browsers-support - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/how-to-guides - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/support - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/release-notes - 2021-05-29 + 2021-07-04 https://tarekraafat.github.io/autoComplete.js/#/contributions - 2021-05-29 + 2021-07-04 \ No newline at end of file diff --git a/package.json b/package.json index 72359aa..95509c3 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "version": "10.2.0", + "version": "10.2.1", "name": "@tarekraafat/autocomplete.js", "description": "Simple autocomplete pure vanilla Javascript library.", "keywords": [ diff --git a/src/controllers/listController.js b/src/controllers/listController.js index e0da3e5..bc48442 100644 --- a/src/controllers/listController.js +++ b/src/controllers/listController.js @@ -240,7 +240,6 @@ const navigate = function (event, ctx) { case 40: case 38: event.preventDefault(); - // Move cursor based on pressed key event.keyCode === 40 ? next(ctx) : previous(ctx); @@ -248,18 +247,14 @@ const navigate = function (event, ctx) { // Enter case 13: if (!ctx.submit) event.preventDefault(); - // If cursor moved if (ctx.cursor >= 0) select(ctx, event); break; // Tab case 9: - if (ctx.resultsList.tabSelect && ctx.cursor >= 0) { - event.preventDefault(); - - select(ctx, event); - } + // Select on Tab if enabled + if (ctx.resultsList.tabSelect && ctx.cursor >= 0) select(ctx, event); break; // Esc