@wordpress/block-library
Version:
Block library for the WordPress editor.
25 lines (24 loc) • 987 B
JavaScript
;
Object.defineProperties(exports, {
__esModule: { value: true },
[Symbol.toStringTag]: { value: "Module" }
});
let _wordpress_block_editor = require("@wordpress/block-editor");
let react_jsx_runtime = require("react/jsx-runtime");
// packages/block-library/src/pullquote/save.jsx
function save({ attributes }) {
const { citation, value } = attributes;
const shouldShowCitation = !_wordpress_block_editor.RichText.isEmpty(citation);
return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("figure", {
..._wordpress_block_editor.useBlockProps.save(),
children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("blockquote", { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_wordpress_block_editor.RichText.Content, {
tagName: "p",
value
}), shouldShowCitation && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_wordpress_block_editor.RichText.Content, {
tagName: "cite",
value: citation
})] })
});
}
exports.default = save;
//# sourceMappingURL=save.cjs.map