芝麻web文件管理V1.00
编辑当前文件:/home/paymbalq/www/wp-content/plugins/woocommerce/assets/client/blocks/wc-payment-method-cod.js
(()=>{var e={674:function(e){e.exports=function(){"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function t(e,n){return t=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},t(e,n)}function n(e,r,o){return n=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}()?Reflect.construct:function(e,n,r){var o=[null];o.push.apply(o,n);var a=new(Function.bind.apply(e,o));return r&&t(a,r.prototype),a},n.apply(null,arguments)}function r(e){return function(e){if(Array.isArray(e))return o(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return o(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n
1?n-1:0),o=1;o
/gm),q=m(/\${[\w\W]*}/gm),Y=m(/^data-[\-\w.\u00B7-\uFFFF]/),$=m(/^aria-[\-\w]+$/),V=m(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),K=m(/^(?:\w+script|data):/i),X=m(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Z=m(/^html$/i),J=m(/^[a-z][.\w]*(-[.\w]+)+$/i),Q=function(){return"undefined"==typeof window?null:window};return function t(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Q(),o=function(e){return t(e)};if(o.version="2.5.7",o.removed=[],!n||!n.document||9!==n.document.nodeType)return o.isSupported=!1,o;var a=n.document,i=n.document,l=n.DocumentFragment,c=n.HTMLTemplateElement,s=n.Node,m=n.Element,p=n.NodeFilter,f=n.NamedNodeMap,d=void 0===f?n.NamedNodeMap||n.MozNamedAttrMap:f,h=n.HTMLFormElement,g=n.DOMParser,O=n.trustedTypes,ee=m.prototype,te=M(ee,"cloneNode"),ne=M(ee,"nextSibling"),re=M(ee,"childNodes"),oe=M(ee,"parentNode");if("function"==typeof c){var ae=i.createElement("template");ae.content&&ae.content.ownerDocument&&(i=ae.content.ownerDocument)}var ie=function(t,n){if("object"!==e(t)||"function"!=typeof t.createPolicy)return null;var r=null,o="data-tt-policy-suffix";n.currentScript&&n.currentScript.hasAttribute(o)&&(r=n.currentScript.getAttribute(o));var a="dompurify"+(r?"#"+r:"");try{return t.createPolicy(a,{createHTML:function(e){return e},createScriptURL:function(e){return e}})}catch(e){return console.warn("TrustedTypes policy "+a+" could not be created."),null}}(O,a),le=ie?ie.createHTML(""):"",ce=i,se=ce.implementation,ue=ce.createNodeIterator,me=ce.createDocumentFragment,pe=ce.getElementsByTagName,fe=a.importNode,de={};try{de=k(i).documentMode?i.documentMode:{}}catch(e){}var he={};o.isSupported="function"==typeof oe&&se&&void 0!==se.createHTMLDocument&&9!==de;var ge,ye,be=W,ve=G,Te=q,Ee=Y,Ne=$,we=K,Ae=X,Se=J,_e=V,xe=null,Oe=L({},[].concat(r(R),r(C),r(D),r(F),r(U))),Le=null,ke=L({},[].concat(r(z),r(P),r(j),r(B))),Me=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Re=null,Ce=null,De=!0,Ie=!0,Fe=!1,He=!0,Ue=!1,ze=!0,Pe=!1,je=!1,Be=!1,We=!1,Ge=!1,qe=!1,Ye=!0,$e=!1,Ve=!0,Ke=!1,Xe={},Ze=null,Je=L({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Qe=null,et=L({},["audio","video","img","source","image","track"]),tt=null,nt=L({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),rt="http://www.w3.org/1998/Math/MathML",ot="http://www.w3.org/2000/svg",at="http://www.w3.org/1999/xhtml",it=at,lt=!1,ct=null,st=L({},[rt,ot,at],E),ut=["application/xhtml+xml","text/html"],mt=null,pt=i.createElement("form"),ft=function(e){return e instanceof RegExp||e instanceof Function},dt=function(t){mt&&mt===t||(t&&"object"===e(t)||(t={}),t=k(t),ge=ge=-1===ut.indexOf(t.PARSER_MEDIA_TYPE)?"text/html":t.PARSER_MEDIA_TYPE,ye="application/xhtml+xml"===ge?E:T,xe="ALLOWED_TAGS"in t?L({},t.ALLOWED_TAGS,ye):Oe,Le="ALLOWED_ATTR"in t?L({},t.ALLOWED_ATTR,ye):ke,ct="ALLOWED_NAMESPACES"in t?L({},t.ALLOWED_NAMESPACES,E):st,tt="ADD_URI_SAFE_ATTR"in t?L(k(nt),t.ADD_URI_SAFE_ATTR,ye):nt,Qe="ADD_DATA_URI_TAGS"in t?L(k(et),t.ADD_DATA_URI_TAGS,ye):et,Ze="FORBID_CONTENTS"in t?L({},t.FORBID_CONTENTS,ye):Je,Re="FORBID_TAGS"in t?L({},t.FORBID_TAGS,ye):{},Ce="FORBID_ATTR"in t?L({},t.FORBID_ATTR,ye):{},Xe="USE_PROFILES"in t&&t.USE_PROFILES,De=!1!==t.ALLOW_ARIA_ATTR,Ie=!1!==t.ALLOW_DATA_ATTR,Fe=t.ALLOW_UNKNOWN_PROTOCOLS||!1,He=!1!==t.ALLOW_SELF_CLOSE_IN_ATTR,Ue=t.SAFE_FOR_TEMPLATES||!1,ze=!1!==t.SAFE_FOR_XML,Pe=t.WHOLE_DOCUMENT||!1,We=t.RETURN_DOM||!1,Ge=t.RETURN_DOM_FRAGMENT||!1,qe=t.RETURN_TRUSTED_TYPE||!1,Be=t.FORCE_BODY||!1,Ye=!1!==t.SANITIZE_DOM,$e=t.SANITIZE_NAMED_PROPS||!1,Ve=!1!==t.KEEP_CONTENT,Ke=t.IN_PLACE||!1,_e=t.ALLOWED_URI_REGEXP||_e,it=t.NAMESPACE||at,Me=t.CUSTOM_ELEMENT_HANDLING||{},t.CUSTOM_ELEMENT_HANDLING&&ft(t.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Me.tagNameCheck=t.CUSTOM_ELEMENT_HANDLING.tagNameCheck),t.CUSTOM_ELEMENT_HANDLING&&ft(t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Me.attributeNameCheck=t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),t.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(Me.allowCustomizedBuiltInElements=t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Ue&&(Ie=!1),Ge&&(We=!0),Xe&&(xe=L({},r(U)),Le=[],!0===Xe.html&&(L(xe,R),L(Le,z)),!0===Xe.svg&&(L(xe,C),L(Le,P),L(Le,B)),!0===Xe.svgFilters&&(L(xe,D),L(Le,P),L(Le,B)),!0===Xe.mathMl&&(L(xe,F),L(Le,j),L(Le,B))),t.ADD_TAGS&&(xe===Oe&&(xe=k(xe)),L(xe,t.ADD_TAGS,ye)),t.ADD_ATTR&&(Le===ke&&(Le=k(Le)),L(Le,t.ADD_ATTR,ye)),t.ADD_URI_SAFE_ATTR&&L(tt,t.ADD_URI_SAFE_ATTR,ye),t.FORBID_CONTENTS&&(Ze===Je&&(Ze=k(Ze)),L(Ze,t.FORBID_CONTENTS,ye)),Ve&&(xe["#text"]=!0),Pe&&L(xe,["html","head","body"]),xe.table&&(L(xe,["tbody"]),delete Re.tbody),u&&u(t),mt=t)},ht=L({},["mi","mo","mn","ms","mtext"]),gt=L({},["annotation-xml"]),yt=L({},["title","style","font","a","script"]),bt=L({},C);L(bt,D),L(bt,I);var vt=L({},F);L(vt,H);var Tt=function(e){v(o.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){try{e.outerHTML=le}catch(t){e.remove()}}},Et=function(e,t){try{v(o.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){v(o.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e&&!Le[e])if(We||Ge)try{Tt(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},Nt=function(e){var t,n;if(Be)e="
"+e;else{var r=N(e,/^[\r\n\t ]+/);n=r&&r[0]}"application/xhtml+xml"===ge&&it===at&&(e=''+e+"");var o=ie?ie.createHTML(e):e;if(it===at)try{t=(new g).parseFromString(o,ge)}catch(e){}if(!t||!t.documentElement){t=se.createDocument(it,"template",null);try{t.documentElement.innerHTML=lt?le:o}catch(e){}}var a=t.body||t.documentElement;return e&&n&&a.insertBefore(i.createTextNode(n),a.childNodes[0]||null),it===at?pe.call(t,Pe?"html":"body")[0]:Pe?t.documentElement:a},wt=function(e){return ue.call(e.ownerDocument||e,e,p.SHOW_ELEMENT|p.SHOW_COMMENT|p.SHOW_TEXT|p.SHOW_PROCESSING_INSTRUCTION|p.SHOW_CDATA_SECTION,null,!1)},At=function(e){return e instanceof h&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof d)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes)},St=function(t){return"object"===e(s)?t instanceof s:t&&"object"===e(t)&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName},_t=function(e,t,n){he[e]&&y(he[e],(function(e){e.call(o,t,n,mt)}))},xt=function(e){var t;if(_t("beforeSanitizeElements",e,null),At(e))return Tt(e),!0;if(_(/[\u0080-\uFFFF]/,e.nodeName))return Tt(e),!0;var n=ye(e.nodeName);if(_t("uponSanitizeElement",e,{tagName:n,allowedTags:xe}),e.hasChildNodes()&&!St(e.firstElementChild)&&(!St(e.content)||!St(e.content.firstElementChild))&&_(/<[/\w]/g,e.innerHTML)&&_(/<[/\w]/g,e.textContent))return Tt(e),!0;if("select"===n&&_(/
=0;--i){var l=te(a[i],!0);l.__removalCount=(e.__removalCount||0)+1,r.insertBefore(l,ne(e))}}return Tt(e),!0}return e instanceof m&&!function(e){var t=oe(e);t&&t.tagName||(t={namespaceURI:it,tagName:"template"});var n=T(e.tagName),r=T(t.tagName);return!!ct[e.namespaceURI]&&(e.namespaceURI===ot?t.namespaceURI===at?"svg"===n:t.namespaceURI===rt?"svg"===n&&("annotation-xml"===r||ht[r]):Boolean(bt[n]):e.namespaceURI===rt?t.namespaceURI===at?"math"===n:t.namespaceURI===ot?"math"===n&>[r]:Boolean(vt[n]):e.namespaceURI===at?!(t.namespaceURI===ot&&!gt[r])&&!(t.namespaceURI===rt&&!ht[r])&&!vt[n]&&(yt[n]||!bt[n]):!("application/xhtml+xml"!==ge||!ct[e.namespaceURI]))}(e)?(Tt(e),!0):"noscript"!==n&&"noembed"!==n&&"noframes"!==n||!_(/<\/no(script|embed|frames)/i,e.innerHTML)?(Ue&&3===e.nodeType&&(t=e.textContent,t=w(t,be," "),t=w(t,ve," "),t=w(t,Te," "),e.textContent!==t&&(v(o.removed,{element:e.cloneNode()}),e.textContent=t)),_t("afterSanitizeElements",e,null),!1):(Tt(e),!0)},Ot=function(e,t,n){if(Ye&&("id"===t||"name"===t)&&(n in i||n in pt))return!1;if(Ie&&!Ce[t]&&_(Ee,t));else if(De&&_(Ne,t));else if(!Le[t]||Ce[t]){if(!(Lt(e)&&(Me.tagNameCheck instanceof RegExp&&_(Me.tagNameCheck,e)||Me.tagNameCheck instanceof Function&&Me.tagNameCheck(e))&&(Me.attributeNameCheck instanceof RegExp&&_(Me.attributeNameCheck,t)||Me.attributeNameCheck instanceof Function&&Me.attributeNameCheck(t))||"is"===t&&Me.allowCustomizedBuiltInElements&&(Me.tagNameCheck instanceof RegExp&&_(Me.tagNameCheck,n)||Me.tagNameCheck instanceof Function&&Me.tagNameCheck(n))))return!1}else if(tt[t]);else if(_(_e,w(n,Ae,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==A(n,"data:")||!Qe[e])if(Fe&&!_(we,w(n,Ae,"")));else if(n)return!1;return!0},Lt=function(e){return"annotation-xml"!==e&&N(e,Se)},kt=function(t){var n,r,a,i;_t("beforeSanitizeAttributes",t,null);var l=t.attributes;if(l){var c={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Le};for(i=l.length;i--;){var s=n=l[i],u=s.name,m=s.namespaceURI;if(r="value"===u?n.value:S(n.value),a=ye(u),c.attrName=a,c.attrValue=r,c.keepAttr=!0,c.forceKeepAttr=void 0,_t("uponSanitizeAttribute",t,c),r=c.attrValue,!c.forceKeepAttr&&(Et(u,t),c.keepAttr))if(He||!_(/\/>/i,r)){Ue&&(r=w(r,be," "),r=w(r,ve," "),r=w(r,Te," "));var p=ye(t.nodeName);if(Ot(p,a,r))if(!$e||"id"!==a&&"name"!==a||(Et(u,t),r="user-content-"+r),ze&&_(/((--!?|])>)|<\/(style|title)/i,r))Et(u,t);else{if(ie&&"object"===e(O)&&"function"==typeof O.getAttributeType)if(m);else switch(O.getAttributeType(p,a)){case"TrustedHTML":r=ie.createHTML(r);break;case"TrustedScriptURL":r=ie.createScriptURL(r)}try{m?t.setAttributeNS(m,u,r):t.setAttribute(u,r),At(t)?Tt(t):b(o.removed)}catch(e){}}}else Et(u,t)}_t("afterSanitizeAttributes",t,null)}},Mt=function e(t){var n,r=wt(t);for(_t("beforeSanitizeShadowDOM",t,null);n=r.nextNode();)_t("uponSanitizeShadowNode",n,null),xt(n)||(n.content instanceof l&&e(n.content),kt(n));_t("afterSanitizeShadowDOM",t,null)};return o.sanitize=function(t){var r,i,c,u,m,p=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if((lt=!t)&&(t="\x3c!--\x3e"),"string"!=typeof t&&!St(t)){if("function"!=typeof t.toString)throw x("toString is not a function");if("string"!=typeof(t=t.toString()))throw x("dirty is not a string, aborting")}if(!o.isSupported){if("object"===e(n.toStaticHTML)||"function"==typeof n.toStaticHTML){if("string"==typeof t)return n.toStaticHTML(t);if(St(t))return n.toStaticHTML(t.outerHTML)}return t}if(je||dt(p),o.removed=[],"string"==typeof t&&(Ke=!1),Ke){if(t.nodeName){var f=ye(t.nodeName);if(!xe[f]||Re[f])throw x("root node is forbidden and cannot be sanitized in-place")}}else if(t instanceof s)1===(i=(r=Nt("\x3c!----\x3e")).ownerDocument.importNode(t,!0)).nodeType&&"BODY"===i.nodeName||"HTML"===i.nodeName?r=i:r.appendChild(i);else{if(!We&&!Ue&&!Pe&&-1===t.indexOf("<"))return ie&&qe?ie.createHTML(t):t;if(!(r=Nt(t)))return We?null:qe?le:""}r&&Be&&Tt(r.firstChild);for(var d=wt(Ke?t:r);c=d.nextNode();)3===c.nodeType&&c===u||xt(c)||(c.content instanceof l&&Mt(c.content),kt(c),u=c);if(u=null,Ke)return t;if(We){if(Ge)for(m=me.call(r.ownerDocument);r.firstChild;)m.appendChild(r.firstChild);else m=r;return(Le.shadowroot||Le.shadowrootmod)&&(m=fe.call(a,m,!0)),m}var h=Pe?r.outerHTML:r.innerHTML;return Pe&&xe["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&_(Z,r.ownerDocument.doctype.name)&&(h="\n"+h),Ue&&(h=w(h,be," "),h=w(h,ve," "),h=w(h,Te," ")),ie&&qe?ie.createHTML(h):h},o.setConfig=function(e){dt(e),je=!0},o.clearConfig=function(){mt=null,je=!1},o.isValidAttribute=function(e,t,n){mt||dt({});var r=ye(e),o=ye(t);return Ot(r,o,n)},o.addHook=function(e,t){"function"==typeof t&&(he[e]=he[e]||[],v(he[e],t))},o.removeHook=function(e){if(he[e])return b(he[e])},o.removeHooks=function(e){he[e]&&(he[e]=[])},o.removeAllHooks=function(){he={}},o}()}()}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var a=t[r]={exports:{}};return e[r].call(a.exports,a,a.exports,n),a.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=window.React,t=window.wc.wcBlocksRegistry,r=window.wp.i18n,o=window.wc.wcSettings,a=window.wp.htmlEntities;var i=n(674),l=n.n(i);const c=["a","b","em","i","strong","p","br"],s=["target","href","rel","name","download"],u=window.wp.element;var m;const p=(0,o.getPaymentMethodData)("cod",{}),f=(0,r.__)("Cash on delivery","woocommerce"),d=(0,a.decodeEntities)((null==p?void 0:p.title)||"")||f,h=()=>(0,e.createElement)(u.RawHTML,null,(e=>{const t=c,n=s;return l().sanitize(e,{ALLOWED_TAGS:t,ALLOWED_ATTR:n})})(p.description||"")),g={name:"cod",label:(0,e.createElement)((t=>{const{PaymentMethodLabel:n}=t.components;return(0,e.createElement)(n,{text:d})}),null),content:(0,e.createElement)(h,null),edit:(0,e.createElement)(h,null),canMakePayment:({cartNeedsShipping:e,selectedShippingMethods:t})=>{if(p.enableForVirtual&&!e)return!0;if(!p.enableForShippingMethods.length)return!0;const n=Object.values(t);return 0===n.length||p.enableForShippingMethods.some((e=>n.some((t=>t.includes(e)))))},ariaLabel:d,supports:{features:null!==(m=null==p?void 0:p.supports)&&void 0!==m?m:[]}};(0,t.registerPaymentMethod)(g)})()})();