File "order-confirmation-billing-address.js"
Full Path: /home/jlklyejr/public_html/wp-content/test/wp-content/plugins/woocommerce/assets/client/blocks/order-confirmation-billing-address.js
File size: 5.63 KB
MIME-type: text/plain
Charset: utf-8
(()=>{var e,t={519:(e,t,r)=>{"use strict";r.r(t);var l=r(9196);const i=window.wp.blocks;var o=r(2911),n=r(1873);const a=JSON.parse('{"name":"woocommerce/order-confirmation-billing-address","version":"1.0.0","title":"Billing Address","description":"Display the order confirmation billing address.","category":"woocommerce","keywords":["WooCommerce"],"supports":{"multiple":false,"align":["wide","full"],"inserter":false,"html":false,"color":{"text":true,"background":true,"__experimentalDefaultControls":{"background":true,"text":true}},"typography":{"fontSize":true,"lineHeight":true,"__experimentalFontFamily":true,"__experimentalFontWeight":true,"__experimentalFontStyle":true,"__experimentalTextTransform":true,"__experimentalTextDecoration":true,"__experimentalLetterSpacing":true,"__experimentalDefaultControls":{"fontSize":true}},"__experimentalBorder":{"color":true,"radius":true,"width":true,"style":true,"__experimentalDefaultControls":{"width":true,"color":true}},"spacing":{"padding":true,"margin":true,"__experimentalDefaultControls":{"margin":false,"padding":false}}},"attributes":{"align":{"type":"string","default":"wide"}},"textdomain":"woocommerce","apiVersion":2,"$schema":"https://schemas.wp.org/trunk/block.json"}'),s=window.wp.blockEditor;var c=r(5736);r(8679);const d=({additionalFields:e=[]})=>(0,l.createElement)("dl",{className:"wc-block-components-additional-fields-list"},Object.entries(e).map((([,e])=>{const{label:t,type:r,options:i}=e;let o=(0,c.__)("Placeholder","woocommerce");return"checkbox"===r&&(o=(0,c.__)("Yes","woocommerce")),"select"===r&&(o=i[0].label),(0,l.createElement)(l.Fragment,null,(0,l.createElement)("dt",null,t),(0,l.createElement)("dd",null,o))}))),u=window.wc.wcSettings;var p,m,g,b,f,w,S,_,k,v;const E=(0,u.getSetting)("wcBlocksConfig",{buildPhase:1,pluginUrl:"",productCount:0,defaultAvatar:"",restApiRoutes:{},wordCountType:"words"}),y=(E.pluginUrl,E.pluginUrl,E.buildPhase,null===(p=u.STORE_PAGES.shop)||void 0===p||p.permalink,null===(m=u.STORE_PAGES.checkout)||void 0===m||m.id,null===(g=u.STORE_PAGES.checkout)||void 0===g||g.permalink,null===(b=u.STORE_PAGES.privacy)||void 0===b||b.permalink,null===(f=u.STORE_PAGES.privacy)||void 0===f||f.title,null===(w=u.STORE_PAGES.terms)||void 0===w||w.permalink,null===(S=u.STORE_PAGES.terms)||void 0===S||S.title,null===(_=u.STORE_PAGES.cart)||void 0===_||_.id,null===(k=u.STORE_PAGES.cart)||void 0===k||k.permalink,null!==(v=u.STORE_PAGES.myaccount)&&void 0!==v&&v.permalink?u.STORE_PAGES.myaccount.permalink:(0,u.getSetting)("wpLoginUrl","/wp-login.php"),(0,u.getSetting)("localPickupEnabled",!1),(0,u.getSetting)("countries",{})),O=(0,u.getSetting)("countryData",{}),h=(Object.fromEntries(Object.keys(O).filter((e=>!0===O[e].allowBilling)).map((e=>[e,y[e]||""]))),Object.fromEntries(Object.keys(O).filter((e=>!0===O[e].allowBilling)).map((e=>[e,O[e].states||[]]))),Object.fromEntries(Object.keys(O).filter((e=>!0===O[e].allowShipping)).map((e=>[e,y[e]||""]))),Object.fromEntries(Object.keys(O).filter((e=>!0===O[e].allowShipping)).map((e=>[e,O[e].states||[]]))),Object.fromEntries(Object.keys(O).map((e=>[e,O[e].locale||[]]))),{address:["first_name","last_name","company","address_1","address_2","city","postcode","country","state","phone"],contact:["email"],additional:[]}),x=((0,u.getSetting)("addressFieldsLocations",h).address,(0,u.getSetting)("addressFieldsLocations",h).contact,(0,u.getSetting)("addressFieldsLocations",h).additional,(0,u.getSetting)("additionalFields",{}),(0,u.getSetting)("additionalContactFields",{}),(0,u.getSetting)("additionalAddressFields",{}));r(8104);(0,i.registerBlockType)(a,{icon:{src:(0,l.createElement)(o.Z,{icon:n.Z,className:"wc-block-editor-components-block-icon"})},attributes:{...a.attributes},edit:()=>{const e=(0,s.useBlockProps)({className:"wc-block-order-confirmation-billing-address"});return(0,l.createElement)("div",{...e},(0,l.createElement)("address",null,"Test address 1",(0,l.createElement)("br",null),"Test address 2",(0,l.createElement)("br",null),"San Francisco, CA 94110",(0,l.createElement)("br",null),"United States",(0,l.createElement)(d,{additionalFields:x})))},save:()=>null})},8679:()=>{},8104:()=>{},9196:e=>{"use strict";e.exports=window.React},9307:e=>{"use strict";e.exports=window.wp.element},5736:e=>{"use strict";e.exports=window.wp.i18n},444:e=>{"use strict";e.exports=window.wp.primitives}},r={};function l(e){var i=r[e];if(void 0!==i)return i.exports;var o=r[e]={exports:{}};return t[e].call(o.exports,o,o.exports,l),o.exports}l.m=t,e=[],l.O=(t,r,i,o)=>{if(!r){var n=1/0;for(d=0;d<e.length;d++){for(var[r,i,o]=e[d],a=!0,s=0;s<r.length;s++)(!1&o||n>=o)&&Object.keys(l.O).every((e=>l.O[e](r[s])))?r.splice(s--,1):(a=!1,o<n&&(n=o));if(a){e.splice(d--,1);var c=i();void 0!==c&&(t=c)}}return t}o=o||0;for(var d=e.length;d>0&&e[d-1][2]>o;d--)e[d]=e[d-1];e[d]=[r,i,o]},l.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return l.d(t,{a:t}),t},l.d=(e,t)=>{for(var r in t)l.o(t,r)&&!l.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},l.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),l.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},l.j=5653,(()=>{var e={5653:0};l.O.j=t=>0===e[t];var t=(t,r)=>{var i,o,[n,a,s]=r,c=0;if(n.some((t=>0!==e[t]))){for(i in a)l.o(a,i)&&(l.m[i]=a[i]);if(s)var d=s(l)}for(t&&t(r);c<n.length;c++)o=n[c],l.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return l.O(d)},r=self.webpackChunkwebpackWcBlocksJsonp=self.webpackChunkwebpackWcBlocksJsonp||[];r.forEach(t.bind(null,0)),r.push=t.bind(null,r.push.bind(r))})();var i=l.O(void 0,[2869],(()=>l(519)));i=l.O(i),((this.wc=this.wc||{}).blocks=this.wc.blocks||{})["order-confirmation-billing-address"]=i})();