import labels from '../labels'; import formState from '../state'; /** * Get the html markup for the message details section of the modal. * * @since 4.6.6 * * @returns {string} Section html markup. */ export default function messageDetailsSectionMarkup() { if ('pushengage' !== formState.get('option')) { return ''; } return `
3

${getSectionTitle(formState.get('option'))}

${getSectionContent(formState.get('option'))}
`; } /** * Get the title for the "details" section of the modal. * * @since 4.6.6 * * @param {string} option The option to pass to the section renderer. * @returns {string} Section HTML markup. */ function getSectionTitle(option: string) { switch (option) { case 'pushengage': return labels.pushengage.message_details; } return ''; } /** * Get the HTML markup for the "details" section of the modal. * * @since 4.6.6 * * @param {string} option The option to pass to the section renderer. * @returns {string} Section HTML markup. */ function getSectionContent(option: string) { switch (option) { case 'pushengage': return `
`; } return ''; }