UNPKG

@automattic/social-previews

Version:

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

8 lines 710 B
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime"; import { blueskyBody, blueskyUrl } from '../../helpers'; import './styles.scss'; const BlueskyPostBody = ({ customText, url, children, appendUrl }) => { return (_jsxs("div", { className: "bluesky-preview__body", children: [customText ? (_jsxs(_Fragment, { children: [_jsx("div", { children: blueskyBody(customText) }), appendUrl && url ? (_jsxs(_Fragment, { children: [_jsx("br", {}), _jsx("a", { href: url, target: "_blank", rel: "noreferrer noopener", children: blueskyUrl(url.replace(/^https?:\/\//, '')) })] })) : null] })) : null, children] })); }; export default BlueskyPostBody; //# sourceMappingURL=index.js.map