import React from 'react'; import cx from 'classnames'; import { getHtmlFragments, overridable, initials, prepareTitle } from './helpers'; import { CoverProps } from '@friends-library/types'; type Props = Pick< CoverProps, 'title' | 'customHtml' | 'author' | 'showGuides' | 'lang' | 'isCompilation' >; const FrontMain: React.FC = ({ showGuides, author, title, lang, isCompilation, customHtml, }) => { const fragments = getHtmlFragments(customHtml); const [firstInitial, lastInitial] = initials(author, title, lang, isCompilation); return (
{showGuides ? ( <>
) : null}
{firstInitial}
{lastInitial}
{overridable( `title-wrap`, fragments,

, )}
); }; export default FrontMain;