[AB-xxx] adding templates for wikipedia and dictionary feature

This commit is contained in:
Sheldan
2023-12-28 22:28:36 +01:00
parent 4bc06cbb07
commit d8923adae1
21 changed files with 63 additions and 0 deletions

View File

@@ -0,0 +1,21 @@
{
"embeds": [
{
<#include "abstracto_color">,
"title": {
"title": "${word?json_string}"
},
<#macro definitionDisplay definition>
<#assign meaning=definition.definition>
<#assign hasExample=definition.example?has_content>
<#if hasExample>
<#assign example=definition.example>
</#if>
<@safe_include "dictionaryDefinition_response_meaning_display"/>
</#macro>
"description": "<#list definitions as definition>${definition?index + 1}: <@definitionDisplay definition=definition /></#list>"
}
]
}

View File

@@ -0,0 +1 @@
<#include "dictionary_api_request_exception_text">

View File

@@ -0,0 +1 @@
<#include "no_dictionary_api_definition_found_exception_text">

View File

@@ -0,0 +1,21 @@
{
"embeds": [
{
<#include "abstracto_color">,
"title": {
"title": "${title?json_string}"
},
"description": "${summary?json_string}"
}
],
"buttons": [
{
"label": "<@safe_include "wikipediaArticleSummary_jump_link"/>",
"url": "${fullURL?json_string}",
"buttonStyle": "link",
"metaConfig": {
"persistCallback": false
}
}
]
}

View File

@@ -0,0 +1 @@
<#include "no_wikipedia_article_found_exception_text">

View File

@@ -0,0 +1 @@
<#include "wikipedia_request_exception_text">