UNPKG

@wordpress/block-library

Version:
1 lines • 967 B
{"version":3,"file":"save.mjs","names":[],"sources":["../../src/quote/save.jsx"],"sourcesContent":["import clsx from 'clsx';\nimport { InnerBlocks, RichText, useBlockProps } from '@wordpress/block-editor';\n\nexport default function save( { attributes } ) {\n\tconst { textAlign, citation } = attributes;\n\n\tconst className = clsx( {\n\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t} );\n\n\treturn (\n\t\t<blockquote { ...useBlockProps.save( { className } ) }>\n\t\t\t<InnerBlocks.Content />\n\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t) }\n\t\t</blockquote>\n\t);\n}\n"],"mappings":";;;;AAGA,SAAwB,KAAM,EAAE,cAAe;CAC9C,MAAM,EAAE,WAAW,aAAa;CAEhC,MAAM,YAAY,KAAM,GACrB,kBAAmB,cAAgB,UACtC,CAAE;CAEF,OACC,qBAAC,cAAD;EAAY,GAAK,cAAc,KAAM,EAAE,UAAU,CAAE;EAAnD,UAAA,CACC,oBAAC,YAAY,SAAb,CAAsB,CAAA,GACpB,CAAE,SAAS,QAAS,QAAS,KAC9B,oBAAC,SAAS,SAAV;GAAkB,SAAQ;GAAO,OAAQ;EAAY,CAAA,CAE3C;;AAEd"}