{"version":3,"file":"edit.mjs","names":[],"sources":["../../src/query-pagination-next/edit.jsx"],"sourcesContent":["import { __ } from '@wordpress/i18n';\nimport { useBlockProps, PlainText } from '@wordpress/block-editor';\n\nconst arrowMap = {\n\tnone: '',\n\tarrow: '→',\n\tchevron: '»',\n};\n\nexport default function QueryPaginationNextEdit( {\n\tattributes: { label },\n\tsetAttributes,\n\tcontext: { paginationArrow, showLabel },\n} ) {\n\tconst displayArrow = arrowMap[ paginationArrow ];\n\treturn (\n\t\t<a\n\t\t\thref=\"#pagination-next-pseudo-link\"\n\t\t\tonClick={ ( event ) => event.preventDefault() }\n\t\t\t{ ...useBlockProps() }\n\t\t>\n\t\t\t{ showLabel && (\n\t\t\t\t<PlainText\n\t\t\t\t\t__experimentalVersion={ 2 }\n\t\t\t\t\ttagName=\"span\"\n\t\t\t\t\taria-label={ __( 'Next page link' ) }\n\t\t\t\t\tplaceholder={ __( 'Next Page' ) }\n\t\t\t\t\tvalue={ label }\n\t\t\t\t\tonChange={ ( newLabel ) =>\n\t\t\t\t\t\tsetAttributes( { label: newLabel } )\n\t\t\t\t\t}\n\t\t\t\t/>\n\t\t\t) }\n\t\t\t{ displayArrow && (\n\t\t\t\t<span\n\t\t\t\t\tclassName={ `wp-block-query-pagination-next-arrow is-arrow-${ paginationArrow }` }\n\t\t\t\t\taria-hidden\n\t\t\t\t>\n\t\t\t\t\t{ displayArrow }\n\t\t\t\t</span>\n\t\t\t) }\n\t\t</a>\n\t);\n}\n"],"mappings":";;;;AAGA,MAAM,WAAW;CAChB,MAAM;CACN,OAAO;CACP,SAAS;AACV;AAEA,SAAwB,wBAAyB,EAChD,YAAY,EAAE,SACd,eACA,SAAS,EAAE,iBAAiB,eACzB;CACH,MAAM,eAAe,SAAU;CAC/B,OACC,qBAAC,KAAD;EACC,MAAK;EACL,UAAY,UAAW,MAAM,eAAe;EAC5C,GAAK,cAAc;EAHpB,UAAA,CAKG,aACD,oBAAC,WAAD;GACC,uBAAwB;GACxB,SAAQ;GACR,cAAa,GAAI,gBAAiB;GAClC,aAAc,GAAI,WAAY;GAC9B,OAAQ;GACR,WAAa,aACZ,cAAe,EAAE,OAAO,SAAS,CAAE;EAEpC,CAAA,GAEA,gBACD,oBAAC,QAAD;GACC,WAAY,iDAAkD;GAC9D,eAAA;GAEE,UAAA;EACG,CAAA,CAEL;;AAEL"}