(()=>{"use strict";var e,t={493:()=>{const e=window.wp.i18n,t=window.wp.blocks,n=window.wp.blockEditor,s=window.wp.components,i=window.wp.element,r=window.ReactJSXRuntime,o=window.winp_snippets?.data||{},l=window.winp_snippets?.createUrl||"",a=o[Object.keys(o)[0]]||{id:"",tags:[]},p=({blockProps:t,createUrl:n})=>(0,r.jsx)("div",{...t,children:(0,r.jsx)(s.Placeholder,{label:(0,e.__)("No shortcode snippets available","insert-php"),instructions:(0,e.__)("Create and activate a snippet configured to run where there is a shortcode, then return to this editor.","insert-php"),children:n&&(0,r.jsx)(s.Button,{variant:"primary",href:n,children:(0,e.__)("Create a snippet","insert-php")})})});(0,t.registerBlockType)("wp-plugin-insert-php/winp-snippet",{title:(0,e.__)("Woody Snippets","insert-php"),description:(0,e.__)("Execute PHP code and insert ads, text, and media with conditional logic. Prevents content duplication.","insert-php"),icon:(0,r.jsxs)("svg",{width:"25",height:"25",viewBox:"0 0 254 254",shapeRendering:"geometricPrecision",textRendering:"geometricPrecision",imageRendering:"optimizeQuality",fillRule:"evenodd",clipRule:"evenodd",children:[(0,r.jsx)("path",{d:"M76 187l44 48 45-49c1-1-12 5-22 5-10-1-23-15-23-15s-3 9-19 13c-11 4-25-2-25-2z"}),(0,r.jsx)("ellipse",{cx:99,cy:134,rx:11,ry:12}),(0,r.jsx)("ellipse",{cx:143,cy:135,rx:11,ry:12}),(0,r.jsx)("path",{d:"M103 103s-10-12-4-35c6-22 16-29 23-33 8-5-5 16-4 20 2 3 14-25 39-27 25-1 41 21 41 21l-13-1s13 5 18 11 11 15 10 18-5 1-5 1 19 13 20 24c1 10-11-10-39-14-29-4-50 14-45 8s17-16 29-17 27 3 27 3-21-12-19-16c2-5 16-2 16-2s-9-8-20-9c-10-2-19 3-18-1 1-5 10-13 15-12 6 1-12-6-24-2-11 5-19 11-26 25s-9 22-13 20c-3-1-4-17-4-17l-4 35zm-60 35l16-21s3-8-1-12c-5-3-9-1-9-1l-22 28s-3 3-2 6c0 2 2 5 2 5l21 28s7 3 10-2c4-5 2-9 2-9l-17-22z"}),(0,r.jsx)("path",{d:"M199 138l-17-21s-3-8 2-12c4-3 9-1 9-1l23 28s3 3 3 6c0 2-3 5-3 5l-22 28s-7 3-11-2-2-9-2-9l18-22z"})]}),category:"formatting",attributes:{id:{type:"int",default:""},attrs:{type:"array",default:a.tags||[]},attrValues:{type:"array",default:[]}},edit(t){const{id:c,attrValues:d,attrs:h}=t.attributes,u=(0,n.useBlockProps)({className:"winp-snippet-gb-container"});(0,i.useEffect)(()=>{!c&&a.id&&t.setAttributes({id:parseInt(a.id,10),attrs:a.tags||[]})},[]);const w=Object.keys(o);if(0===w.length)return(0,r.jsx)(p,{blockProps:u,createUrl:l});const g=[];let v=0;for(;vb(i,e)})}))}return t}()})})]})]},save(){const e=n.useBlockProps.save();return(0,r.jsx)("div",{...e,children:(0,r.jsx)(n.InnerBlocks.Content,{})})}})}},n={};function s(e){var i=n[e];if(void 0!==i)return i.exports;var r=n[e]={exports:{}};return t[e](r,r.exports,s),r.exports}s.m=t,e=[],s.O=(t,n,i,r)=>{if(!n){var o=1/0;for(c=0;c=r)&&Object.keys(s.O).every(e=>s.O[e](n[a]))?n.splice(a--,1):(l=!1,r0&&e[c-1][2]>r;c--)e[c]=e[c-1];e[c]=[n,i,r]},s.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={57:0,350:0};s.O.j=t=>0===e[t];var t=(t,n)=>{var i,r,[o,l,a]=n,p=0;if(o.some(t=>0!==e[t])){for(i in l)s.o(l,i)&&(s.m[i]=l[i]);if(a)var c=a(s)}for(t&&t(n);ps(493));i=s.O(i)})();