(()=>{"use strict";var e,t={973:()=>{const e=window.wp.blocks,t=window.wp.primitives,n=window.ReactJSXRuntime,o=(0,n.jsx)(t.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,n.jsx)(t.Path,{d:"M4 13.5h6v-3H4v3zm8 0h3v-3h-3v3zm5-3v3h3v-3h-3z"})}),i=JSON.parse('{"UU":"remote-data-blocks/pagination"}'),r=window.wp.blockEditor,a=window.wp.components,s=(0,n.jsx)(t.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,n.jsx)(t.Path,{d:"M19 8h-1V6h-5v2h-2V6H6v2H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-8c0-1.1-.9-2-2-2zm.5 10c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-8c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v8z"})});var l;null===(l=window.REMOTE_DATA_BLOCKS)||void 0===l||l.rest_url,function(...e){e.filter(Boolean).join(" ")}(undefined,`rdb-${"container".replace(/[^a-zA-Z\d\u00C0-\u00FF]/g,"-").toLowerCase()}`);const c=window.wp.data,d=window.wp.editor;function u(e){var t;const{postMeta:n,postType:o}=(i=e=>{var t,n;return{postMeta:null!==(t=e("meta"))&&void 0!==t?t:{},postType:null!==(n=e("type"))&&void 0!==n?n:""}},(0,c.useSelect)((e=>{const{getEditedPostAttribute:t}=e(d.store);return i(t)}),[]));var i;if("wp_block"===o){const e=String(null!==(t=n._remote_data_blocks_block_type)&&void 0!==t?t:""),o=function(e){var t,n;return null===(n=null===(t=window.REMOTE_DATA_BLOCKS)||void 0===t?void 0:t.config)||void 0===n?void 0:n[e]}(e);if(o)return{remoteData:{blockName:e,metadata:{},queryInputs:[],queryKey:"Example Query Key",resultId:"",results:[{result:Object.fromEntries(Object.entries(o.availableBindings).map((([e,t])=>[e,{name:t.name,type:t.type,value:t.name}]))),uuid:"Example Entity ID"}]}}}return{remoteData:e["remote-data-blocks/remoteData"]}}const p=window.wp.i18n;function __(e){return(0,p.__)(e,"remote-data-blocks")}(0,e.registerBlockType)(i.UU,{edit:function(e){const{context:t}=e,o=(0,r.useBlockProps)(),{remoteData:i}=u(t);return(null==i?void 0:i.blockName)?(null==i?void 0:i.pagination)?(0,n.jsx)("div",Object.assign({},o,{children:(0,n.jsxs)("div",{className:"remote-data-pagination",children:[(0,n.jsx)("a",{href:"#pagination-previous-pseudo-link",onClick:e=>e.preventDefault(),children:(0,n.jsx)("span",{children:"Previous"})}),(0,n.jsx)("a",{href:"#pagination-next-pseudo-link",onClick:e=>e.preventDefault(),children:(0,n.jsx)("span",{children:"Next"})})]})})):(0,n.jsx)("div",Object.assign({},o,{children:(0,n.jsx)(a.Placeholder,{label:__("Remote Data Pagination"),instructions:__("This block only works when placed inside a remote data block using data that supports pagination. This block will be ignored as currently configured.")})})):(0,n.jsx)(a.Placeholder,{label:__("Remote Data Pagination"),icon:s,instructions:__("This block must be placed inside a remote data block. This block will be ignored as currently configured.")})},icon:{src:o},save:function(){return(0,n.jsx)(r.InnerBlocks.Content,{})}})}},n={};function o(e){var i=n[e];if(void 0!==i)return i.exports;var r=n[e]={exports:{}};return t[e](r,r.exports,o),r.exports}o.m=t,e=[],o.O=(t,n,i,r)=>{if(!n){var a=1/0;for(d=0;d<e.length;d++){for(var[n,i,r]=e[d],s=!0,l=0;l<n.length;l++)(!1&r||a>=r)&&Object.keys(o.O).every((e=>o.O[e](n[l])))?n.splice(l--,1):(s=!1,r<a&&(a=r));if(s){e.splice(d--,1);var c=i();void 0!==c&&(t=c)}}return t}r=r||0;for(var d=e.length;d>0&&e[d-1][2]>r;d--)e[d]=e[d-1];e[d]=[n,i,r]},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={137:0,325:0};o.O.j=t=>0===e[t];var t=(t,n)=>{var i,r,[a,s,l]=n,c=0;if(a.some((t=>0!==e[t]))){for(i in s)o.o(s,i)&&(o.m[i]=s[i]);if(l)var d=l(o)}for(t&&t(n);c<a.length;c++)r=a[c],o.o(e,r)&&e[r]&&e[r][0](),e[r]=0;return o.O(d)},n=globalThis.webpackChunkremote_data_blocks=globalThis.webpackChunkremote_data_blocks||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))})();var i=o.O(void 0,[325],(()=>o(973)));i=o.O(i)})();