mirror of
https://github.com/Sheldan/abstracto-templates.git
synced 2026-04-13 03:26:36 +00:00
[AB-349] refactoring templates to have the new multi embed structure
This commit is contained in:
@@ -1,12 +1,16 @@
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
<#include "modmail_color">,
|
||||
"description": "<@safe_include "modmail_thread_already_exists"/>",
|
||||
"fields": [
|
||||
{
|
||||
"name": "<@safe_include "modmail_existing_thread_link_field_title"/>",
|
||||
"value": "[<@safe_include "modmail_existing_thread_link_content_display_text"/>](${threadUrl})"
|
||||
}
|
||||
]
|
||||
"embeds": [
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
<#include "modmail_color">,
|
||||
"description": "<@safe_include "modmail_thread_already_exists"/>",
|
||||
"fields": [
|
||||
{
|
||||
"name": "<@safe_include "modmail_existing_thread_link_field_title"/>",
|
||||
"value": "[<@safe_include "modmail_existing_thread_link_content_display_text"/>](${threadUrl})"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,12 +1,16 @@
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=targetMember/>,
|
||||
"description": "<@safe_include "modmail_thread_created_description"/>",
|
||||
<#include "modmail_color">,
|
||||
"fields": [
|
||||
{
|
||||
"name": "<@safe_include "modmail_thread_created_link_field_title"/>",
|
||||
"value": "${createdChannel.asMention}"
|
||||
}
|
||||
]
|
||||
"embeds": [
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=targetMember/>,
|
||||
"description": "<@safe_include "modmail_thread_created_description"/>",
|
||||
<#include "modmail_color">,
|
||||
"fields": [
|
||||
{
|
||||
"name": "<@safe_include "modmail_thread_created_link_field_title"/>",
|
||||
"value": "${createdChannel.asMention}"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
{
|
||||
<#include "warning_color">,
|
||||
"description": "<@safe_include "modmail_no_server_available"/>"
|
||||
"embeds": [
|
||||
{
|
||||
<#include "warning_color">,
|
||||
"description": "<@safe_include "modmail_no_server_available"/>"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1,22 +1,26 @@
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_notification_message_title"/>"
|
||||
},
|
||||
"metaConfig": {
|
||||
"allowsRoleMention": true
|
||||
},
|
||||
<#include "modmail_color">,
|
||||
<#assign user><@member_user_name member=member/>(${member.user.id})</#assign>
|
||||
"description": "<@safe_include "modmail_notification_message_description"/>",
|
||||
"fields": [
|
||||
"embeds": [
|
||||
{
|
||||
"name": "<@safe_include "modmail_notification_field_title_channel"/>",
|
||||
"value": "${channel.asMention}"
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_notification_message_title"/>"
|
||||
},
|
||||
<#include "modmail_color">,
|
||||
<#assign user><@member_user_name member=member/>(${member.user.id})</#assign>
|
||||
"description": "<@safe_include "modmail_notification_message_description"/>",
|
||||
"fields": [
|
||||
{
|
||||
"name": "<@safe_include "modmail_notification_field_title_channel"/>",
|
||||
"value": "${channel.asMention}"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
<#if roles?size gt 0>
|
||||
,"additionalMessage": "<#list roles as role>${role.role.asMention?json_string}<#sep>,</#list>"
|
||||
</#if>
|
||||
],
|
||||
"messageConfig": {
|
||||
"allowsRoleMention": true
|
||||
},
|
||||
<#if roles?size gt 0>
|
||||
,"additionalMessage": "<#list roles as role>${role.role.asMention?json_string}<#sep>,</#list>"
|
||||
</#if>
|
||||
}
|
||||
@@ -1,19 +1,23 @@
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_thread_user_message_title"/>"
|
||||
},
|
||||
<#include "modmail_color">,
|
||||
<#if subscribers?size gt 0>
|
||||
"additionalMessage": "<#list subscribers as subscriber>${subscriber.asMention?json_string}<#sep>, </#list>",
|
||||
</#if>
|
||||
<#if postedMessage.contentRaw?has_content>
|
||||
"description": "${postedMessage.contentRaw?json_string}"
|
||||
<#else>
|
||||
"description": "<@safe_include "modmail_no_message_provided"/>"
|
||||
</#if>
|
||||
<#if postedMessage.attachments?size gt 0>
|
||||
,"imageUrl": "${postedMessage.attachments[0].proxyUrl}"
|
||||
</#if>
|
||||
"embeds": [
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_thread_user_message_title"/>"
|
||||
},
|
||||
<#include "modmail_color">,
|
||||
<#if postedMessage.contentRaw?has_content>
|
||||
"description": "${postedMessage.contentRaw?json_string}"
|
||||
<#else>
|
||||
"description": "<@safe_include "modmail_no_message_provided"/>"
|
||||
</#if>
|
||||
<#if postedMessage.attachments?size gt 0>
|
||||
,"imageUrl": "${postedMessage.attachments[0].proxyUrl}"
|
||||
</#if>
|
||||
}
|
||||
]
|
||||
<#if subscribers?size gt 0>
|
||||
,"additionalMessage": "<#list subscribers as subscriber>${subscriber.asMention?json_string}<#sep>, </#list>"
|
||||
</#if>
|
||||
}
|
||||
@@ -1,15 +1,19 @@
|
||||
<#include "format_instant">
|
||||
{
|
||||
<#include "user_detail">
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_closing_notification_title"/>"
|
||||
},
|
||||
<#include "modmail_color">,
|
||||
<#assign messageCount>${messageCount}</#assign>
|
||||
<#assign user><#if user??><@user_detail user=user/><#else>${userId}</#if></#assign>
|
||||
<#assign closingUserDescription><@member_user_name member=closingMember/> (${closingMember.idLong?c})</#assign>
|
||||
<#assign startDate><@format_instant_date_time instant=startDate/></#assign>
|
||||
<#assign duration>${fmtDuration(duration)}</#assign>
|
||||
<#assign closedSilently=silently>
|
||||
"description": "<@safe_include "close_closing_description"/>"
|
||||
"embeds": [
|
||||
{
|
||||
<#include "user_detail">
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_closing_notification_title"/>"
|
||||
},
|
||||
<#include "modmail_color">,
|
||||
<#assign messageCount>${messageCount}</#assign>
|
||||
<#assign user><#if user??><@user_detail user=user/><#else>${userId}</#if></#assign>
|
||||
<#assign closingUserDescription><@member_user_name member=closingMember/> (${closingMember.idLong?c})</#assign>
|
||||
<#assign startDate><@format_instant_date_time instant=startDate/></#assign>
|
||||
<#assign duration>${fmtDuration(duration)}</#assign>
|
||||
<#assign closedSilently=silently>
|
||||
"description": "<@safe_include "close_closing_description"/>"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -1,15 +1,19 @@
|
||||
{
|
||||
<#include "user_author">
|
||||
<@user_author user=author/>,
|
||||
<#include "modmail_color">
|
||||
<#if message.embeds[0].description?has_content>
|
||||
,"description": "${message.embeds[0].description?json_string}"
|
||||
</#if>
|
||||
<#if message.embeds[0].image?has_content>
|
||||
,"imageUrl": "${message.embeds[0].image.proxyUrl}"
|
||||
</#if>
|
||||
<#if modMailMessage.anonymous>
|
||||
, "additionalMessage": "<@safe_include "modmail_anonymous_message_note"/>"
|
||||
</#if>
|
||||
,"timeStamp": "${message.timeCreated}"
|
||||
"embeds": [
|
||||
{
|
||||
<#include "user_author">
|
||||
<@user_author user=author/>,
|
||||
<#include "modmail_color">
|
||||
<#if message.embeds[0].description?has_content>
|
||||
,"description": "${message.embeds[0].description?json_string}"
|
||||
</#if>
|
||||
<#if message.embeds[0].image?has_content>
|
||||
,"imageUrl": "${message.embeds[0].image.proxyUrl}"
|
||||
</#if>
|
||||
,"timeStamp": "${message.timeCreated}"
|
||||
}
|
||||
]
|
||||
<#if modMailMessage.anonymous>
|
||||
,"additionalMessage": "<@safe_include "modmail_anonymous_message_note"/>"
|
||||
</#if>
|
||||
}
|
||||
|
||||
@@ -1,4 +1,8 @@
|
||||
{
|
||||
<#include "modmail_color">,
|
||||
"description": "${closingMessage?json_string}"
|
||||
"embeds": [
|
||||
{
|
||||
<#include "modmail_color">,
|
||||
"description": "${closingMessage?json_string}"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1,14 +1,18 @@
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=moderator/>,
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_thread_staff_message_title"/>"
|
||||
},
|
||||
<#include "modmail_color">
|
||||
<#if text?has_content>
|
||||
, "description": "${text?json_string}"
|
||||
</#if>
|
||||
<#if postedMessage.attachments?size gt 0>
|
||||
,"imageUrl": "${postedMessage.attachments[0].proxyUrl}"
|
||||
</#if>
|
||||
"embeds": [
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=moderator/>,
|
||||
"title": {
|
||||
"title": "<@safe_include "modmail_thread_staff_message_title"/>"
|
||||
},
|
||||
<#include "modmail_color">
|
||||
<#if text?has_content>
|
||||
,"description": "${text?json_string}"
|
||||
</#if>
|
||||
<#if postedMessage.attachments?size gt 0>
|
||||
,"imageUrl": "${postedMessage.attachments[0].proxyUrl}"
|
||||
</#if>
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1,10 +1,14 @@
|
||||
<#include "format_instant">
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
<#include "modmail_color">,
|
||||
<#assign user><@member_user_name member=member/> (${member.user.id})</#assign>
|
||||
<#assign joinDate><@format_instant_date_time instant=memberJoinDate/></#assign>
|
||||
<#assign roles><#list member.roles as role>${role.asMention?json_string}<#sep>,<#else><@safe_include "modmail_thread_header_no_roles"/></#list></#assign>
|
||||
"description": "<@safe_include "modmail_thread_header_embed_description"/>"
|
||||
"embeds": [
|
||||
{
|
||||
<#include "member_author">
|
||||
<@member_author member=member/>,
|
||||
<#include "modmail_color">,
|
||||
<#assign user><@member_user_name member=member/> (${member.user.id})</#assign>
|
||||
<#assign joinDate><@format_instant_date_time instant=memberJoinDate/></#assign>
|
||||
<#assign roles><#list member.roles as role>${role.asMention?json_string}<#sep>,<#else><@safe_include "modmail_thread_header_no_roles"/></#list></#assign>
|
||||
"description": "<@safe_include "modmail_thread_header_embed_description"/>"
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user