This PR introduces a comprehensive, display-only template preview system for both WhatsApp and Twilio templates rendering of all supported template types. This lays the foundation for rich template previews across: - Template selection modals - Campaign creation flows - Message composer - Message screen. <img width="1818" height="2058" alt="template-preview" src="https://github.com/user-attachments/assets/9833b28c-f824-4568-8f74-6da09ac61f62" /> --------- Co-authored-by: Sivin Varghese <64252451+iamsivin@users.noreply.github.com> Co-authored-by: iamsivin <iamsivin@gmail.com> Co-authored-by: Muhsin <12408980+muhsin-k@users.noreply.github.com>
27 lines
580 B
Vue
27 lines
580 B
Vue
<script setup>
|
|
defineProps({
|
|
message: {
|
|
type: Object,
|
|
required: true,
|
|
},
|
|
});
|
|
</script>
|
|
|
|
<template>
|
|
<div
|
|
class="flex flex-col gap-2 p-3 rounded-xl bg-n-alpha-2 text-n-slate-12 max-w-80"
|
|
>
|
|
<div v-if="message.title" class="text-base font-bold">
|
|
{{ message.title }}
|
|
</div>
|
|
|
|
<div v-if="message.content" class="text-sm font-medium prose prose-bubble">
|
|
<span v-dompurify-html="message.content" />
|
|
</div>
|
|
|
|
<div v-if="message.footer" class="text-xs opacity-70 text-n-slate-11">
|
|
{{ message.footer }}
|
|
</div>
|
|
</div>
|
|
</template>
|