message_as_html.naml

<override_macro name="message_as_html" requires="message">
    <n.if.either condition1="[n.is_deleted/]" condition2="[n.is_deactivated/]">
        <then>
            <b><t>CONTENTS DELETED</t></b>
            <div class="weak-color"><t>The author has deleted this message.</t></div>
        </then>
        <else>
            <n.set_var. name="output">
                <n.as_html_list.process_message_html />
            </n.set_var.>
            <n.if.is_imported_mail>
                <then>
                    <n.set_var. name="output">
                        <n.regex_replace_all. pattern='(To post to this group, send email to|You received this message because you are subscribed to the Google Groups|To unsubscribe from this group and stop receiving emails|To view this discussion on the web visit|For more options, visit)[^\n]+\n' replacement=''>
                            <n.remove_unsubscription_link.var name="output" />                                                    
                        </n.regex_replace_all.>                        
                    </n.set_var.>
                </then>            
            </n.if.is_imported_mail>
            <n.var name="output" />
        </else>
    </n.if.either>
</override_macro>