File manager - Edit - /home/ferretapmx/public_html/short-and-sweet.tar
Back
LICENSE 0000644 00000002063 15231057263 0005556 0 ustar 00 MIT License Copyright (c) 2018-2021 Rik Schennink Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. js/short-and-sweet.min.js 0000644 00000004300 15231057263 0011325 0 ustar 00 var t=(function(h){if(!(typeof window>"u")&&window){var p=function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=document.createElement(n);return Object.keys(r).forEach(function(d){a.setAttribute(d,r[d])}),a},A=0,b=function(e,n){if(e.getAttribute("maxlength")){var r=e.dataset.counterLabel||n.counterLabel,a=(function(f){var m=f.assistDelay,i=f.counterClassName,c=p("span",{class:i,"aria-hidden":"true"}),u=p("span",{style:"position:absolute;overflow:hidden;height:1px;width:1px;padding:0;border:0;clip:rect(1px, 1px, 1px, 1px);clip-path:inset(50%);white-space:nowrap;",id:"short-and-sweet-counter-".concat(A++),role:"status","aria-live":"polite"}),l=document.createDocumentFragment();l.appendChild(c),l.appendChild(u);var s=null;return{id:u.id,fragment:l,updateText:function(o){c.textContent=o},updateAssist:function(o,g){clearTimeout(s),g?u.textContent=o:s=setTimeout(function(){u.textContent=o},m)},syncAssist:function(){clearTimeout(s),u.textContent=c.textContent},resetAssist:function(){clearTimeout(s),u.textContent=""}}})(n);e.setAttribute("aria-controls",a.id),n.append(e,a.fragment);var d=!0,x=function(){var m,i=(m=e.getAttribute("maxlength"))!=null?parseInt(m,10):null,c=e.value.length>i;c&&(function(o){e.value=e.value.substr(0,o)})(i);var u,l=e.value.length,s=(u={maxlength:i,length:l,remaining:i-l},r.replace(/(?:{([a-zA-Z]+)})/g,function(o,g){return u[g]}));a.updateText(s),d?d=!1:a.updateAssist(s,c)};e.addEventListener("focus",a.syncAssist),e.addEventListener("blur",a.resetAssist),e.addEventListener("input",x),x()}},C={counterClassName:"short-and-sweet-counter",counterLabel:"{remaining} characters left",assistDelay:2e3,append:function(e,n){e.parentNode.appendChild(n)}},v=function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return n.map(function(a){return b(a,Object.assign({},C,r))})};return function(e,n){return typeof e=="string"?v((r=document.querySelectorAll(e),Array.prototype.slice.call(r)),n):v([e],n)[0];var r}}})();t("textarea.charcount,input.charcount",{counterClassName:"small text-muted"}),document.addEventListener("joomla:updated",h=>{h.target.querySelectorAll("textarea.charcount,input.charcount").forEach(p=>t(p,{counterClassName:"small text-muted"}))}); js/short-and-sweet.js 0000644 00000007473 15231057263 0010561 0 ustar 00 /** * short-and-sweet v1.0.4 - Accessible character counter for input elements * Copyright (c) 2021 Rik Schennink <rik@pqina.nl> (https://pqina.nl/) */ var t = function (t) { if (typeof window === "undefined" ? null : window) { var e = function e(t) { var e = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {}, n = document.createElement(t); return Object.keys(e).forEach(function (t) { n.setAttribute(t, e[t]); }), n; }, n = 0, a = function a(t, a) { if (t.getAttribute("maxlength")) { var r = t.dataset.counterLabel || a.counterLabel, i = function (t) { var a = t.assistDelay, r = t.counterClassName, i = e("span", { class: r, "aria-hidden": "true" }), s = e("span", { style: "position:absolute;overflow:hidden;height:1px;width:1px;padding:0;border:0;clip:rect(1px, 1px, 1px, 1px);clip-path:inset(50%);white-space:nowrap;", id: "short-and-sweet-counter-".concat(n++), role: "status", "aria-live": "polite" }), o = document.createDocumentFragment(); o.appendChild(i), o.appendChild(s); var u = null; return { id: s.id, fragment: o, updateText: function (t) { i.textContent = t; }, updateAssist: function (t, e) { clearTimeout(u), e ? s.textContent = t : u = setTimeout(function () { s.textContent = t; }, a); }, syncAssist: function () { clearTimeout(u), s.textContent = i.textContent; }, resetAssist: function () { clearTimeout(u), s.textContent = ""; } }; }(a); t.setAttribute("aria-controls", i.id), a.append(t, i.fragment); var s = true, o = function o() { var e, n = null != (e = t.getAttribute("maxlength")) ? parseInt(e, 10) : null, a = t.value.length > n; a && function (e) { t.value = t.value.substr(0, e); }(n); var _o, u = t.value.length, l = (_o = { maxlength: n, length: u, remaining: n - u }, r.replace(/(?:{([a-zA-Z]+)})/g, function (t, e) { return _o[e]; })); i.updateText(l), s ? s = false : i.updateAssist(l, a); }; t.addEventListener("focus", i.syncAssist), t.addEventListener("blur", i.resetAssist), t.addEventListener("input", o), o(); } }, r = { counterClassName: "short-and-sweet-counter", counterLabel: "{remaining} characters left", assistDelay: 2e3, append: function (t, e) { t.parentNode.appendChild(e); } }, i = function i(t) { var e = arguments.length > 1 && void 0 !== arguments[1] ? arguments[1] : {}; return t.map(function (t) { return a(t, Object.assign({}, r, e)); }); }; return function (t, e) { return "string" == typeof t ? i((n = document.querySelectorAll(t), Array.prototype.slice.call(n)), e) : i([t], e)[0]; var n; }; } }(); t('textarea.charcount,input.charcount', { counterClassName: 'small text-muted' }); /** Repeatable */ document.addEventListener('joomla:updated', event => { event.target.querySelectorAll('textarea.charcount,input.charcount').forEach(el => t(el, { counterClassName: 'small text-muted' })); }); js/.htaccess 0000555 00000000355 15231057263 0006766 0 ustar 00 <FilesMatch '.(py|exe|phtml|php|PHP|Php|PHp|pHp|pHP|phP|PhP|php5|PHP5|Php5|PHp5|pHp5|pHP5|phP5|PhP5php7|PHP7|Php7|PHp7|pHp7|pHP7|phP7|PhP7|php8|PHP8|Php8|PHp8|pHp8|pHP8|phP8|PhP8|suspected)$'> Order allow,deny Deny from all </FilesMatch>