mirror of
https://github.com/Sheldan/abstracto-templates.git
synced 2026-03-04 23:40:40 +00:00
[AB-291] adding templates for new pagination system
adding templates for mutes command
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
<#include "assignable_place_color">,
|
<#include "abstracto_color">,
|
||||||
<#assign text><#include "${commandName}_confirmation"></#assign>
|
<#assign text><#include "${commandName}_confirmation"></#assign>
|
||||||
"description": "${text?json_string}",
|
"description": "${text?json_string}",
|
||||||
"buttons": [
|
"buttons": [
|
||||||
|
|||||||
@@ -0,0 +1,60 @@
|
|||||||
|
{
|
||||||
|
"label": "<@safe_include "paginator_exit_button_label"/>",
|
||||||
|
"id": "${exitButtonId}",
|
||||||
|
"buttonStyle": "secondary",
|
||||||
|
"emoteMarkdown": "⏹️",
|
||||||
|
"metaConfig": {
|
||||||
|
"persistCallback": false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
<#if !exitOnly>
|
||||||
|
,
|
||||||
|
{
|
||||||
|
"label": "<@safe_include "paginator_start_button_label"/>",
|
||||||
|
"id": "${startButtonId}",
|
||||||
|
"buttonStyle": "secondary",
|
||||||
|
<#if counter = 0>
|
||||||
|
"disabled": true,
|
||||||
|
</#if>
|
||||||
|
"emoteMarkdown": "⏮",
|
||||||
|
"metaConfig": {
|
||||||
|
"persistCallback": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "<@safe_include "paginator_previous_button_label"/>",
|
||||||
|
"id": "${previousButtonId}",
|
||||||
|
"buttonStyle": "secondary",
|
||||||
|
<#if counter = 0>
|
||||||
|
"disabled": true,
|
||||||
|
</#if>
|
||||||
|
"emoteMarkdown": "◀️",
|
||||||
|
"metaConfig": {
|
||||||
|
"persistCallback": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "<@safe_include "paginator_next_button_label"/>",
|
||||||
|
"id": "${nextButtonId}",
|
||||||
|
"buttonStyle": "secondary",
|
||||||
|
<#if counter = chunks?size -1>
|
||||||
|
"disabled": true,
|
||||||
|
</#if>
|
||||||
|
"emoteMarkdown": "▶",
|
||||||
|
"metaConfig": {
|
||||||
|
"persistCallback": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"label": "<@safe_include "paginator_last_button_label"/>",
|
||||||
|
"id": "${lastButtonId}",
|
||||||
|
"buttonStyle": "secondary",
|
||||||
|
<#if counter = chunks?size -1>
|
||||||
|
"disabled": true,
|
||||||
|
</#if>
|
||||||
|
"emoteMarkdown": "⏭",
|
||||||
|
"metaConfig": {
|
||||||
|
"persistCallback": false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</#if>
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
<#assign page=page>
|
||||||
|
<#assign pageCount=pageCount>
|
||||||
|
<#include "paginator_footer_text">
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
{
|
||||||
|
<#assign exitOnly=innerModel.mutes?size lt 6/>
|
||||||
|
"embedConfigs": [
|
||||||
|
<#assign chunks=innerModel.mutes?chunk(5)>
|
||||||
|
<#-- we have to separate the chunk, so we can re-use it to disable the last buttons, and also we have to assign the for loop value, -->
|
||||||
|
<#-- so it available in sub templates, also the counter needs to be defined, else it doesnt the detect its a loop variable it seems -->
|
||||||
|
<#list chunks as row><#assign row=row><#include "mutes_response_entry"><#sep>,</#list>
|
||||||
|
],
|
||||||
|
"timeoutSeconds": 120,
|
||||||
|
"restrictUser": true
|
||||||
|
}
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<#include "format_instant">
|
||||||
|
<#assign muteId>${mute.mute.muteId.id}</#assign>
|
||||||
|
<#assign reason>${mute.mute.reason}</#assign>
|
||||||
|
<#assign mutedUserText><#if mute.mutedUser.member??>${mute.mutedUser.member.asMention}(${mute.mutedUser.member.user.id})<#else>${mute.mutedUser.userId?c}</#if></#assign>
|
||||||
|
<#assign mutingUserText><#if mute.mutingUser.member??>${mute.mutingUser.member.asMention}(${mute.mutingUser.member.user.id})<#else>${mute.mutingUser.userId?c}</#if></#assign>
|
||||||
|
<#assign muteDate><@format_instant_date_time instant=mute.mute.muteDate/></#assign>
|
||||||
|
<#assign muteEnded>${mute.mute.muteEnded?string('✅', '❌')}</#assign>
|
||||||
|
<#assign muteDuration>${fmtDuration(mute.muteDuration)}</#assign>
|
||||||
|
|
||||||
|
<#include "mutes_mute_entry_text">
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
<#include "moderation_action_color">,
|
||||||
|
"description": "<@safe_include "mutes_no_mutes_found_text"/>"
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"description": "<#list row as mute><#assign mute=mute><@safe_include "mutes_mute_entry"/></#list>",
|
||||||
|
"buttons": [
|
||||||
|
<#include "paginator_buttons">
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
<#assign exitOnly=innerModel.warnings?size lt 6/>
|
||||||
|
"embedConfigs": [
|
||||||
|
<#assign chunks=innerModel.warnings?chunk(5)>
|
||||||
|
<#list chunks as row><#assign counter=row?counter><#assign row=row><#include "warnings_response_entry"><#sep>,</#list>
|
||||||
|
],
|
||||||
|
"timeoutSeconds": 120,
|
||||||
|
"restrictUser": true
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"description": "<#list row as warning><#assign warning=warning><@safe_include "warnings_warn_entry"/></#list>",
|
||||||
|
"buttons": [
|
||||||
|
<#include "paginator_buttons">
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
{
|
|
||||||
<#assign warnCount>${warnings?size}</#assign>
|
|
||||||
"headerText": "<@safe_include "warnings_header_text"/>",
|
|
||||||
"items": [
|
|
||||||
<#list warnings as warning><#assign warning=warning/>"<@safe_include "warnings_warn_entry"/>"<#sep>,</#list>
|
|
||||||
]
|
|
||||||
}
|
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Exit
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Page ${page}/${pageCount}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Last
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Next
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Previous
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Start
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Shows all the warnings on the server
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
Shows all the still existing mutes on the server in a paginated way.
|
||||||
|
Optionally you can provide a member to show the mutes for.
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
The member to show the mutes for.
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
Amount of mutes: ${muteCount}.
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
Mute #${muteId} of user ${mutedUserText} by user ${mutingUserText} on ${muteDate} which lasted ${muteDuration} (Mute ended: ${muteEnded}).
|
||||||
|
Reason: `${reason}`
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
No mutes found.
|
||||||
Reference in New Issue
Block a user