UNPKG

@automattic/social-previews

Version:

A suite of components to generate previews for a post for both social and search engines.

13 lines 809 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.QuoteTweet = void 0; const jsx_runtime_1 = require("react/jsx-runtime"); const components_1 = require("@wordpress/components"); const QuoteTweet = ({ tweet }) => { if (!tweet) { return null; } return ((0, jsx_runtime_1.jsxs)("div", { className: "twitter-preview__quote-tweet", children: [(0, jsx_runtime_1.jsx)(components_1.SandBox, { html: `<blockquote class="twitter-tweet" data-conversation="none" data-dnt="true"><a href="${tweet}"></a></blockquote>`, scripts: ['https://platform.twitter.com/widgets.js'], title: "Embedded tweet" }), (0, jsx_runtime_1.jsx)("div", { className: "twitter-preview__quote-tweet-overlay" })] })); }; exports.QuoteTweet = QuoteTweet; //# sourceMappingURL=quote-tweet.js.map