UNPKG

@automattic/social-previews

Version:

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

13 lines 1.58 kB
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime"; import { __ } from '@wordpress/i18n'; import SectionHeading from '../shared/section-heading'; import { LinkedInLinkPreview } from './link-preview'; import { LinkedInPostPreview } from './post-preview'; export const LinkedInPreviews = ({ headingLevel, hideLinkPreview, hidePostPreview, ...props }) => { return (_jsxs("div", { className: "social-preview linkedin-preview", children: [!hidePostPreview && (_jsxs("section", { className: "social-preview__section linkedin-preview__section", children: [_jsx(SectionHeading, { level: headingLevel, children: // translators: refers to a social post on LinkedIn __('Your post', 'social-previews') }), _jsx("p", { className: "social-preview__section-desc", children: __('This is what your social post will look like on LinkedIn:', 'social-previews') }), _jsx(LinkedInPostPreview, { ...props })] })), !hideLinkPreview && (_jsxs("section", { className: "social-preview__section linkedin-preview__section", children: [_jsx(SectionHeading, { level: headingLevel, children: // translators: refers to a link to a LinkedIn post __('Link preview', 'social-previews') }), _jsx("p", { className: "social-preview__section-desc", children: __('This is what it will look like when someone shares the link to your WordPress post on LinkedIn.', 'social-previews') }), _jsx(LinkedInLinkPreview, { ...props, name: "", profileImage: "" })] }))] })); }; //# sourceMappingURL=previews.js.map