mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-10 04:25:01 +00:00
feat: update knub; use base Knub types for plugins
This commit is contained in:
parent
4597b83cda
commit
c2ae6d53d8
90 changed files with 713 additions and 607 deletions
|
@ -1,8 +1,6 @@
|
|||
import { PluginOptions } from "knub";
|
||||
import { PluginOptions, guildPlugin } from "knub";
|
||||
import { GuildMemberTimezones } from "../../data/GuildMemberTimezones";
|
||||
import { mapToPublicFn } from "../../pluginUtils";
|
||||
import { trimPluginDescription } from "../../utils";
|
||||
import { zeppelinGuildPlugin } from "../ZeppelinPluginBlueprint";
|
||||
import { ResetTimezoneCmd } from "./commands/ResetTimezoneCmd";
|
||||
import { SetTimezoneCmd } from "./commands/SetTimezoneCmd";
|
||||
import { ViewTimezoneCmd } from "./commands/ViewTimezoneCmd";
|
||||
|
@ -31,16 +29,8 @@ const defaultOptions: PluginOptions<TimeAndDatePluginType> = {
|
|||
],
|
||||
};
|
||||
|
||||
export const TimeAndDatePlugin = zeppelinGuildPlugin<TimeAndDatePluginType>()({
|
||||
export const TimeAndDatePlugin = guildPlugin<TimeAndDatePluginType>()({
|
||||
name: "time_and_date",
|
||||
showInDocs: true,
|
||||
info: {
|
||||
prettyName: "Time and date",
|
||||
description: trimPluginDescription(`
|
||||
Allows controlling the displayed time/date formats and timezones
|
||||
`),
|
||||
configSchema: zTimeAndDateConfig,
|
||||
},
|
||||
|
||||
configParser: (input) => zTimeAndDateConfig.parse(input),
|
||||
defaultOptions,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue