- md5
- 51cb2296a7232516277407c8235a3f9a
- sha1
- d564cb15aadcd6c0c70c5a5969eb061089f9e1db
- sha256
- 8ba6076426879570042eb415bd1f2a776de7ef22dde811da86d1157671b731a9
(function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i<t.length;i++)o(t[i]);return o}return r})()({1:[function(require,module,exports){
'use strict';var _typeof='function'==typeof Symbol&&'symbol'==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&'function'==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?'symbol':typeof a},_createClass=function(){function a(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,'value'in c&&(c.writable=!0),Object.defineProperty(a,c.key,c)}return function(b,c,d){return c&&a(b.prototype,c),d&&a(b,d),b}}();function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError('Cannot call a class as a function')}function _possibleConstructorReturn(a,b){if(!a)throw new ReferenceError('this hasn\'t been initialised - super() hasn\'t been called');return b&&('object'==typeof b||'function'==typeof b)?b:a}function _inherits(a,b){if('function'!=typeof b&&null!==b)throw new TypeError('Super expression must either be null or a function, not '+typeof b);a.prototype=Object.create(b&&b.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(a,b):a.__proto__=b)}(function(a,b){var c=function(a){function c(){_classCallCheck(this,c);var a=_possibleConstructorReturn(this,(c.__proto__||Object.getPrototypeOf(c)).call(this));if(!b)throw new Error('Joomla API is not properly initiated');if(!a.getAttribute('data-uri'))throw new Error('No valid url for validation');return a}return _inherits(c,a),_createClass(c,[{key:'connectedCallback',value:function connectedCallback(){var a=this,b='data-onchange-task',c=[].slice.call(document.querySelectorAll('['+b+']'));c&&c.forEach(function(c){c.addEventListener('change',function(c){c.preventDefault();var d=c.target.getAttribute(b);'permissions.apply'==d&&a.sendPermissions(c)})})}},{key:'sendPermissions',value:function sendPermissions(a){var c=a.target,d=document.getElementById('icon_'+c.id);d.removeAttribute('class'),d.setAttribute('class','fa fa-spinner fa-spin');var e='not',f=this.getUrlParam('component'),g=this.getUrlParam('extension'),h=this.getUrlParam('option'),i=this.getUrlParam('view'),j=f,k=c.value,l='';document.getElementById('jform_context')&&(l=document.getElementById('jform_context').value,l=l.split('.')[0]),'com_config'==h&&!1==f&&!1==g?e='root.1':!1==g&&'component'==i?e=f:l?(e='group'==i?l+'.fieldgroup.'+this.getUrlParam('id'):l+'.field.'+this.getUrlParam('id'),j=document.getElementById('jform_title').value):!1!=g&&!1!=i?(e=g+'.'+i+'.'+this.getUrlParam('id'),j=document.getElementById('jform_title').value):!1==g&&!1!=i&&(e=h+'.'+i+'.'+this.getUrlParam('id'),j=document.getElementById('jform_title').value);var m=c.id.replace('jform_rules_',''),n=m.lastIndexOf('_'),o={comp:e,action:m.substring(0,n),rule:m.substring(n+1),value:k,title:j};b.removeMessages(),b.request({url:this.getAttribute('data-uri'),method:'POST',data:JSON.stringify(o),perform:!0,headers:{"Content-Type":'application/json'},onSuccess:function onSuccess(a){try{a=JSON.parse(a)}catch(a){console.log(a)}if(d.removeAttribute('class'),a.data&&!0===a.data.result){d.setAttribute('class','fa fa-check');var e=c.parentNode.parentNode.nextElementSibling.querySelector('span');e.removeAttribute('class'),e.setAttribute('class',a.data['class']),e.innerHTML=a.data.text}'object'===_typeof(a.messages)&&null!==a.messages&&(b.renderMessages(a.messages),a.data&&!0===a.data.result?d.setAttribute('class','fa fa-check'):d.setAttribute('class','fa fa-times'))},onError:function onError(){d.removeAttribute('style'),b.renderMessages(b.ajaxErrorsMessages(jqXHR,textStatus,error)),d.setAttribute('class','fa fa-times')}})}},{key:'getUrlParam',value:function getUrlParam(a){for(var b,c=window.location.search.substring(1),d=c.split('&'),e=0;e<d.length;e+=1)if(b=d[e].split('='),b[0]==a)return b[1];return!1}}]),c}(HTMLElement);a.define('joomla-field-permissions',c)})(customElements,Joomla);
},{}]},{},[1]);
No other release has this exact content. See every version of this file.