[OPB-40] adding warning threshold notification

restructured template module structure and naming
This commit is contained in:
Sheldan
2021-10-25 00:15:51 +02:00
parent 60ac314ecc
commit 2c49cf2918
182 changed files with 368 additions and 123 deletions

View File

@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>dev.sheldan.oneplus.bot.templates.customizations</groupId>
<artifactId>customization-templates</artifactId>
<version>1.5.8-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>moderation-customization-templates</artifactId>
<packaging>pom</packaging>
</project>

View File

@@ -0,0 +1,15 @@
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>zip</id>
<includeBaseDirectory>false</includeBaseDirectory>
<formats>
<format>zip</format>
</formats>
<fileSets>
<fileSet>
<outputDirectory>.</outputDirectory>
<directory>${project.basedir}/src/main/resources</directory>
</fileSet>
</fileSets>
</assembly>

View File

@@ -0,0 +1,13 @@
{
"title": {
"title": "<@safe_include "warning_threshold_reached_notification_title"/>"
},
<#include "abstracto_color">,
<#assign warnedMemberMention=memberDisplay.memberMention>
<#assign warnedUserId=memberDisplay.userId>
<#assign memberMention=memberDisplay.memberMention>
<#assign warnCount=warnCount>
<#assign channelDisplay=channelDisplay>
<#assign messageId=messageId>
"description": "<@safe_include "warning_threshold_reached_notification_description"/>"
}

View File

@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>dev.sheldan.oneplus.bot.templates</groupId>
<artifactId>oneplus-bot-templates</artifactId>
<version>1.5.8-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<groupId>dev.sheldan.oneplus.bot.templates.customizations</groupId>
<artifactId>customization-templates</artifactId>
<packaging>pom</packaging>
<modules>
<module>starboard-customization-templates</module>
<module>moderation-customization-templates</module>
</modules>
</project>

View File

@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>dev.sheldan.oneplus.bot.templates.customizations</groupId>
<artifactId>customization-templates</artifactId>
<version>1.5.8-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>starboard-customization-templates</artifactId>
<packaging>pom</packaging>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>single</goal>
</goals>
<configuration>
<finalName>starboard-custom-templates-${project.version}</finalName>
<appendAssemblyId>false</appendAssemblyId>
<descriptors>
<descriptor>src/main/assembly/assembly.xml</descriptor>
</descriptors>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

View File

@@ -0,0 +1,15 @@
<assembly xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>zip</id>
<includeBaseDirectory>false</includeBaseDirectory>
<formats>
<format>zip</format>
</formats>
<fileSets>
<fileSet>
<outputDirectory>.</outputDirectory>
<directory>${project.basedir}/src/main/resources</directory>
</fileSet>
</fileSets>
</assembly>

View File

@@ -0,0 +1,41 @@
{
"title": {
"title": "<@safe_include "starboard_post_created_title"/>"
},
<#include "abstracto_color">,
"description": "<@safe_include "starboard_post_created_description"/>",
"fields": [
{
"name": "<@safe_include "starboard_post_notification_field_starboard_message"/>",
<#if starboardMessage??>
"value": "[<@safe_include "starboard_post_notification_field_starboard_message_jump"/>](${starboardMessage.jumpUrl})"
<#else>
"value": "${post.starboardMessageId?c}"
</#if>
},
{
"name": "<@safe_include "starboard_post_notification_field_starred_message"/>",
<#if starredMessage??>
"value": "[<@safe_include "starboard_post_notification_field_starboard_message_jump"/>](${starredMessage.jumpUrl})"
<#else>
"value": "${post.postMessageId?c}"
</#if>
},
{
"name": "<@safe_include "starboard_post_notification_field_starred_user"/>",
<#if starredMember??>
"value": "${starredMember.asMention}"
<#else>
"value": "${starredUserId?c} (<@safe_include "user_left_server"/>)"
</#if>
},
{
"name": "<@safe_include "starboard_post_notification_field_starring_user"/>",
<#if starringMember??>
"value": "${starringMember.asMention}"
<#else>
"value": "${starringUserId?c} (<@safe_include "user_left_server"/>)"
</#if>
}
]
}

View File

@@ -0,0 +1,33 @@
{
"title": {
"title": "<@safe_include "starboard_post_deleted_title"/>"
},
<#include "abstracto_color">,
"description": "<@safe_include "starboard_post_deleted_description"/>",
"fields": [
{
"name": "<@safe_include "starboard_post_notification_field_starred_message"/>",
<#if starredMessage??>
"value": "[<@safe_include "starboard_post_notification_field_starboard_message_jump"/>](${starredMessage.jumpUrl})"
<#else>
"value": "${starredMessageSimple.jumpUrl}"
</#if>
},
{
"name": "<@safe_include "starboard_post_notification_field_starred_user"/>",
<#if starredMember??>
"value": "${starredMember.asMention}"
<#else>
"value": "${starredUserId?c} (<@safe_include "user_left_server"/>)"
</#if>
},
{
"name": "<@safe_include "starboard_post_notification_field_starring_user"/>",
<#if starringMember??>
"value": "${starringMember.asMention}"
<#else>
"value": "${starringUserId?c} (<@safe_include "user_left_server"/>)"
</#if>
}
]
}