mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-28 09:33:46 +00:00
feat(admin): show common placeholders group in email template editor
Companion to the bot-side change: the variables hint now renders two
groups — type-specific vars and common ones ({service_name},
{cabinet_url}, {support_username}, {username}, {email}, {date}) that
work in every template. The block is visible even for types with no
vars of their own (previously it was hidden entirely, looking like
placeholders didn't exist). Common chips insert at cursor the same way.
This commit is contained in:
@@ -15,6 +15,8 @@ export interface EmailTemplateType {
|
||||
export interface EmailTemplateListResponse {
|
||||
items: EmailTemplateType[];
|
||||
available_languages: string[];
|
||||
/** Placeholders available in every template regardless of type */
|
||||
common_context_vars: string[];
|
||||
}
|
||||
|
||||
export interface EmailTemplateLanguageData {
|
||||
@@ -30,6 +32,8 @@ export interface EmailTemplateDetail {
|
||||
label: Record<string, string>;
|
||||
description: Record<string, string>;
|
||||
context_vars: string[];
|
||||
/** Placeholders available in every template regardless of type */
|
||||
common_context_vars?: string[];
|
||||
languages: Record<string, EmailTemplateLanguageData>;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user