diff --git a/locales/af.yml b/locales/af.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/af.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/ar.yml b/locales/ar.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/ar.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/ca.yml b/locales/ca.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/ca.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/cs.yml b/locales/cs.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/cs.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/da.yml b/locales/da.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/da.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/de.yml b/locales/de.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/de.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/el.yml b/locales/el.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/el.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/en.yml b/locales/en.yml index 0c61b78a..7c5ccba5 100644 --- a/locales/en.yml +++ b/locales/en.yml @@ -138,7 +138,7 @@ hub: invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' join: success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. + Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers from this channel. - Use `/connection` to explore various customizations for this connection. - Use `/hub leave` to stop receiving messages from this hub. - Use **`/connection edit`** to change channels. diff --git a/locales/fi.yml b/locales/fi.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/fi.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/fr.yml b/locales/fr.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/fr.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/he.yml b/locales/he.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/he.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/hu.yml b/locales/hu.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/hu.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/it.yml b/locales/it.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/it.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/ja.yml b/locales/ja.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/ja.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/ko.yml b/locales/ko.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/ko.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/nl.yml b/locales/nl.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/nl.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/no.yml b/locales/no.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/no.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/pl.yml b/locales/pl.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/pl.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/pt.yml b/locales/pt.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/pt.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/ro.yml b/locales/ro.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/ro.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/ru.yml b/locales/ru.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/ru.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/sr.yml b/locales/sr.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/sr.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/sv.yml b/locales/sv.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/sv.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/tr.yml b/locales/tr.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/tr.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/uk.yml b/locales/uk.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/uk.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/vi.yml b/locales/vi.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/vi.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/locales/zh.yml b/locales/zh.yml deleted file mode 100644 index 81f83e1e..00000000 --- a/locales/zh.yml +++ /dev/null @@ -1,358 +0,0 @@ -rules: - rules: | - ### Rules: - These rules are in place to make a safe and enjoyable experience for everyone. Read and follow them carefully: - - 1. **No NSFW, NSFL, or Gore Content** - -# Applies to profile images, usernames, explicit images, videos, and text. - 2. **No Racism or Discrimination** - -# Treat everyone respectfully and kindly. Hate speech and slurs are prohibited. - 3. **No Sexual Content** - -# This includes suggestive jokes, gifs, and any other form of innuendo. Keep it friendly for everyone. - 4. **No Advertising or Self-Promotion** - -# Avoid sharing links to personal servers, social media, or other bots on InterChat. - 5. **No Harassment or Doxxing** - -# Respect everyone’s privacy and well-being. Harassment, doxxing, and encouraging self-harm are strictly forbidden. - 6. **No Spam or Flooding** - -# Don’t send repetitive messages or flood the chat. Excessive spamming may result in harsher penalties and impacts bot performance. - 7. **No Controversial Discussions** - -# Maintain a friendly, welcoming environment for everyone. Avoid discussing politics, religion, or other controversial topics. - 8. **Use Common Sense** - -# If you think something might not be appropriate, avoid it. - 9. **Report Violations** - -# Use the `Apps > Message Info/Report` command to notify moderators of any rule-breaking content. - - And remember to follow [Discord's Terms of Service](https://discord.com/terms) and [Community Guidelines](https://discord.com/guidelines). - welcome: | - {emoji} Hey {user}, welcome to InterChat! - To use InterChat you need to accept the guidelines. Please read and accept them by clicking continue. - accepted: | - {emoji} Welcome to InterChat! You have accepted the rules and are now ready to chat with members from other servers! - If you are not already in a hub, use `/hub browse` to join one and start chatting. We have a simple [wiki and guide]({guide}) for more tips and tricks. Good luck! - alreadyAccepted: '{emoji} You have already accepted the rules. You can now use InterChat to its full extent.' -vote: - description: By voting you support us by helping InterChat rank higher on topgg searches. - footer: Thank you for supporting! -network: - accountTooNew: '{emoji} {user} Your account is too new to send messages using InterChat. Please try again later.' - deleteSuccess: '{emoji} Message by {user} has been deleted from __**{deleted}/{total}**__ servers.' - editSuccess: '{emoji} Message by {user} has been edited in __**{edited}/{total}**__ servers.' - onboarding: - embed: - title: '👋 Hey there, welcome to {hubName}!' - description: | - To keep things organized, it's recommended to use a separate channel for just for this hub. But don't worry, you can always change this later. - - **How it works:** The InterChat Network is like a magic bridge that links channels on different servers that are with us in this hub. Learn more at our [guide]({docs_link}). - footer: InterChat Network | Version {version} - inProgress: '{emoji} {channel} is already in the process of being setup to join a hub. Please wait for the setup to complete or cancel it if you were the one who initiated it.' -blacklist: - success: '{emoji} **{name}** has been successfully blacklisted!' - removed: '{emoji} **{name}** has been removed from the blacklist!' - modal: - reason: - label: Reason - placeholder: Reason for blacklisting - duration: - label: Duration - placeholder: 'Duration of blacklist. Eg: 1d, 1w, 1m, 1y. Leave blank for permanent.' - user: - alreadyBlacklisted: '{emoji} This user is already blacklisted.' - easterEggs: - blacklistBot: You can't blacklist me wtf. - server: - alreadyBlacklisted: '{emoji} This server is already blacklisted.' - unknownError: Failed to blacklist **{server}**. Enquire with the developers for more information. - list: - user: | - **UserID:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} - server: | - **ServerId:** {id} - **Moderator:** {moderator} - **Reason:** {reason} - **Expires:** {expires} -msgInfo: - buttons: - message: Message Info - server: Server Info - user: User Info - report: Report - report: - notEnabled: '{emoji} Reporting is not enabled for this hub.' - success: '{emoji} Report submitted successfully. Thank you!' -invite: | - Thank you for choosing to invite InterChat! If you have any questions or need help, we are always here to help you in the support server! - - **[{invite_emoji} `Invite Link`]( {invite} ) [{support_emoji} `Support Server`]( {support} )** -connection: - notFound: '{emoji} Invalid connection. Verify the channel ID or select from displayed options.' - channelNotFound: '{emoji} Unable to find connected channel. To talk again choose a new channel.' - alreadyConnected: '{emoji} Channel {channel} is already connected to a hub.' - switchChannel: '{emoji} Select a channel to switch to using the select menu below:' - switchCalled: '{emoji} Channel switch called, use the command again to view new connection.' - switchSuccess: '{emoji} Channel switched. You are now connected from **{channel}**.' - inviteRemoved: '{emoji} Server Invite removed for this hub.' - inviteInvalid: '{emoji} Invalid invite. Please make sure you have entered a valid invite link.' - inviteAdded: '{emoji} Invite Added. Others can now join this server by using `Apps > Message Info/Report` command.' - emColorInvalid: '{emoji} Invalid color. Please make sure you have entered a valid hex color code.' - emColorChange: '{emoji} Embed color successfully {action}' - embed: - title: Connection Details - fields: - hub: Hub - channel: Channel - invite: Invite - connected: Connected - emColor: Embed Color - compact: Compact Mode - profanity: Profanity Filter - footer: Use the button & dropdown below to manage your connection. - selects: - placeholder: '🛠️ Select an option to edit this connection' - unpaused: - desc: | - ### {tick_emoji} Unpaused Connection - - Unpaused connection for {channel}! Messages from the hub will start coming into the channel and you can send messages to the hub again. - tips: | - **💡 Tip:** Use {pause_cmd} to pause the connection or {edit_cmd} to set embed colors, toggle profanity filter, and more. - paused: - desc: | - ### {clock_emoji} Paused Connection - Paused connection for {channel}! Messages from the hub will no longer come into the channel and your messages won't be broadcasted to them. - tips: | - **💡 Tip:** Use {unpause_cmd} to unpause the connection or {leave_cmd} to permanently stop recieving messages. -hub: - notFound: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name.' - notFound_mod: '{emoji} Unable to find hub. Please make sure you have entered the correct hub name & that you are the owner or a moderator of the hub.' - alreadyJoined: '{emoji} You have already joined **{hub}** from {channel}!' - invalidChannel: '{emoji} Invalid channel. Only text and thread channels are supported!' - invalidImgurUrl: '{emoji} Invalid image URL for icon or banner. Please make sure you have entered a valid Imgur image URL that is not a gallery or album.' - join: - success: | - Successfully joined hub **{hub}** from {channel}! You can now chat with members from other servers in this hub. - - Use `/connection` to explore various customizations for this connection. - - Use `/hub leave` to stop receiving messages from this hub. - servers: - total: 'Current connected servers: {from}-{to} / **{total}**' - noConnections: '{emoji} No server has joined this hub yet. Use `/hub join` to join this hub.' - notConnected: "{emoji} That server isn't a part of **{hub}**." - connectionInfo: | - Channel: #{channelName} `({channelId})` - Joined At: {joinedAt} - Invite: {invite} - Connected: {connected} - create: - modal: - title: Create Hub - name: - label: Hub Name - placeholder: Enter a name for your hub. - description: - label: Description - placeholder: Enter a description for your hub. - icon: - label: Icon URL - placeholder: Enter an Imgur image URL. - banner: - label: Banner URL - placeholder: Enter an Imgur image URL. - maxHubs: '{emoji} You have reached the maximum number of hubs (3) you can create. Please delete a hub before creating another one.' - invalidName: '{emoji} Invalid hub name. It must not contain `discord`, `clyde` or \`\`\` . Please choose another name.' - nameTaken: '{emoji} This hub name is already taken. Please choose another name.' - success: | - ### Hub Created! - - Congratulations! Your private hub, **{name}**, has been successfully created. - To join, create an invite using `/hub invite create` and share the generated code. Then join using `/hub join`. - - - **Generate invite:** `/hub invite create` - - **Make private:** `/hub visibility` - - **Join hub:** `/hub join` - - **Edit hub:** `/hub edit` - - **Add moderators:** `/hub moderator add` - - Learn more about hubs in our [guide]({docs_link}). Join the [support server]({support_invite}) for help. - delete: - confirm: Are you sure you wish to delete **{hub}**? This action is irreversible. All connected servers, invites and message data will be removed from this hub. - ownerOnly: '{emoji} Only the owner of this hub can delete it.' - success: '{emoji} Hub **{hub}** has been deleted.' - cancelled: '{emoji} Hub deletion has been cancelled.' - browse: - joinConfirm: | - Are you sure you wish to join {hub} from {channel}? - - **Note:** You can always change this later using `/connection`. - joinFooter: Want to use a different channel? Use the dropdown below. - noHubs: '{emoji} There are no hubs listed here at the moment. Please try again later!' - rating: - invalid: Invalid rating. You must enter a number between 1 and 5. - success: Rating submitted! Thank you for your feedback. - invite: - create: - success: | - ### Invite Created! - - Your invite has been successfully created. Others can now join this hub by using the `/hub join` command. - - - **Join using:** `/hub join invite:{inviteCode}` - - **View invites:** `/hub invite list` - - **Expiry:** {expiry} - - **Uses**: ∞ - - __Learn more about hubs in our [guide]({docs_link}).__. - revoke: - invalidCode: '{emoji} Invalid invite code. Please make sure you have entered a valid invite code.' - success: '{emoji} Invite {inviteCode} revoked.' - list: - title: '**Invite Codes:**' - noInvites: '{emoji} This hub has no invites yet. Use `/hub invite create` to create one.' - notPrivate: '{emoji} Only private hubs can have invites. Use `/hub manage` to make this hub private.' - joined: - noJoinedHubs: '{emoji} This server has not joined any hubs yet. Use `/hub browse` to view a list of hubs.' - joinedHubs: This server is a part of **{total}** hub(s). Use `/hub leave` to leave a hub. - leave: - noHub: '{emoji} That channel is invalid or has not joined any hubs.' - confirm: Are you sure you wish to leave **{hub}** from {channel}? No more messages will be sent to this server from this hub. - confirmFooter: Confirm using the button below within 10 seconds. - success: '{emoji} Left the hub from {channel}. No more messages will be sent to this server from this hub. You can rejoin using `/hub join`.' - moderator: - noModerators: '{emoji} This hub has no moderators yet. Use `/hub moderator add` to add one.' - add: - success: '{emoji} **{user}** has been added as a moderator of position **{position}**.' - alreadyModerator: '{emoji} **{user}** is already a moderator.' - remove: - success: '{emoji} **{user}** has been removed as a moderator.' - notModerator: '{emoji} **{user}** is not a moderator.' - notOwner: '{emoji} Only the owner of this hub can remove a manager.' - update: - success: "{emoji} **{user}**'s position has been updated to **{position}**." - notModerator: '{emoji} **{user}** is not a moderator.' - notAllowed: "{emoji} Only hub managers can update a moderator's position." - notOwner: "{emoji} Only the owner of this hub can update a manager's position." - manage: - enterImgurUrl: Enter a valid Imgur image URL that is not a gallery or album. - icon: - changed: Hub icon successfully changed. - modal: - title: Change Icon - label: Icon URL - selects: - label: Change Icon - description: Change the icon of this hub. - description: - changed: Hub description successfully changed. - modal: - title: Change Description - label: Description - placeholder: Enter a description for this hub. - selects: - label: Change Description - description: Change the description of this hub. - banner: - changed: Hub banner successfully changed. - removed: Hub banner successfully removed. - modal: - title: Change Banner - label: Banner URL - selects: - label: Change Banner - description: Change the banner of this hub. - visibility: - success: '{emoji} Hub visibility successfully changed to **{visibility}**.' - selects: - label: Change Visibility - description: Make this hub public or private. - logs: - title: Logs Configuration - reset: '{emoji} Successfully reset the logs configuration for `{type}` logs.' - roleSuccess: '{emoji} Logs of type `{type}` will now mention {role}!' - channelSuccess: '{emoji} Logs of type `{type}` will be sent to {channel} from now!' - channelSelect: '#️⃣ Select a channel to send the logs' - roleSelect: '🏓 Select the role to mention when a log is triggered.' - reportChannelFirst: '{emoji} Please set a log channel first.' - config: - title: Configure `{type}` Logs - description: | - {arrow} Select a log channel and/or role to be pinged from the dropdown below. - {arrow} You can also disable logging by using the button below. - fields: - channel: Channel - role: Role Mention - reports: - label: Reports - description: Receive reports from users. - modLogs: - label: Mod Logs - description: Log Moderation actions. (eg. blacklist, message deletes, etc.) - profanity: - label: Profanity Filter - description: Log messages that are caught by the profanity filter. - joinLeaves: - label: Join/Leave - description: Log when a server joins or leaves this hub. - appeals: - label: Appeals - description: Recieve appeals from blacklisted users/servers. - networkAlerts: - label: Network Alerts - description: Recieve alerts about automatically blocked messages. -report: - modal: - title: Report Details - other: - label: Report Details - placeholder: A detailed description of the report. - bug: - input1: - label: Bug Details - placeholder: Eg. Frequent interaction failures for /help command... - input2: - label: Detailed Description (Optional) - placeholder: Steps you took. Eg. 1. Run /help 2. Wait for 5 seconds... - submitted: '{emoji} Report submitted successfully. Join the {support_command} to get more details. Thank you!' - bug: - title: Bug Report - affected: Affected Components - description: Please choose what component of the bot you are facing issues with. -language: - set: Language set! I will now respond to you in **{lang}**. -errors: - messageNotSentOrExpired: This message was not sent in a hub, has expired, or you lack permissions to perform this action. - notYourAction: "{emoji} Sorry, you can't perform this action. Please run the command yourself." - notMessageAuthor: '{emoji} You are not the author of this message.' - commandError: | - {emoji} An error occurred while executing this command. It has been logged to our system. If this issue persists, please join our [support server]({support_invite}) and report the error ID! - - **Error ID:** - ```{errorId}``` - mustVote: Please [vote](https://top.gg/bot/769921109209907241/vote) for InterChat to use this command, your support is very much appreciated! - inviteLinks: '{emoji} You may not send invite links to this hub. Set an invite in `/connection` instead! Hub mods can configure this using `/hub manage settings`' - invalidLangCode: '{emoji} Invalid language code. Please make sure you have entered a correct [language code](https://cloud.google.com/translate/docs/languages).' - unknownServer: '{emoji} Unknown server. Please make sure you have entered the correct **Server ID**.' - unknownNetworkMessage: '{emoji} Unknown Message. If it has been sent in the past minute, please wait few more seconds and try again.' - userNotFound: '{emoji} User not found. Try inputting their ID instead.' - blacklisted: '{emoji} You or this server is blacklisted from this hub called {hub}.' - userBlacklisted: '{emoji} You are blacklisted from this hub.' - serverBlacklisted: '{emoji} This server is blacklisted from this hub.' - serverNotBlacklisted: '{emoji} The inputted server is not blacklisted.' - userNotBlacklisted: '{emoji} The inputted user is not blacklisted.' - missingPermissions: '{emoji} You are missing the following permissions to perform this action: **{permissions}**' - botMissingPermissions: '{emoji} Please grant me the following permissions to continue: **{permissions}**' - unknown: '{emoji} An unknown error occurred. Please try again later or contact us by joining our [support server]({support_invite}).' - notUsable: '{emoji} This is no longer usable.' - cooldown: '{emoji} You are on cooldown. Please wait until **{time}** before attempting again.' - serverNameInappropriate: '{emoji} Your server name contains inappropriate words. Please change it before joining the hub.' - banned: | - {emoji} You have been banned from using InterChat for reason **{reason}** - If you think an appeal is applicable create a ticket in the [support server]( {support_invite} ). -misc: - webhookNoLongerExists: '{emoji} The webhook for this channel no longer exists. To continue using InterChat, please re-create the webhook by using `/connection unpause`.' - noReason: No reason provided. - noDesc: No Description. - version: InterChat v{version} - loading: '{emoji} Please wait while I process your request...' - reportOptionMoved: '{emoji} This option has moved! To report a message to hub moderators, use the updated `Apps > Message Info/Report` command. For direct reporting to InterChat staff, just hop into the [support server]({support_invite}) and create a ticket with proof.' diff --git a/package.json b/package.json index 6b48008c..23fc2efc 100644 --- a/package.json +++ b/package.json @@ -22,44 +22,43 @@ }, "type": "module", "dependencies": { - "@prisma/client": "^5.22.0", - "@sentry/node": "^8.38.0", + "@prisma/client": "^6.0.0", + "@sentry/node": "^8.41.0", "common-tags": "^1.8.2", "discord-hybrid-sharding": "^2.2.3", "discord.js": "^14.16.3", "dotenv": "^16.4.5", "express": "^5.0.1", "google-translate-api-x": "^10.7.1", - "husky": "^9.1.6", + "husky": "^9.1.7", "ioredis": "^5.4.1", "js-yaml": "^4.1.0", "lodash": "^4.17.21", "lz-string": "^1.5.0", "ms": "^2.1.3", - "parse-duration": "^1.1.0", "reflect-metadata": "^0.2.2", "source-map-support": "^0.5.21", "uuid": "^11.0.3", "winston": "^3.17.0" }, "devDependencies": { - "@stylistic/eslint-plugin": "^2.10.1", + "@stylistic/eslint-plugin": "^2.11.0", "@types/common-tags": "^1.8.4", "@types/express": "^5.0.0", "@types/js-yaml": "^4.0.9", "@types/lodash": "^4.17.13", "@types/ms": "^0.7.34", - "@types/node": "^22.9.0", + "@types/node": "^22.10.1", "@types/source-map-support": "^0.5.10", "cz-conventional-changelog": "^3.3.0", "eslint": "9.14.0", "lint-staged": "^15.2.10", - "prettier": "^3.3.3", - "prisma": "^5.22.0", + "prettier": "^3.4.1", + "prisma": "^6.0.0", "release-it": "^17.10.0", "tsc-watch": "^6.2.1", - "typescript": "^5.6.3", - "typescript-eslint": "^8.14.0" + "typescript": "^5.7.2", + "typescript-eslint": "^8.16.0" }, "config": { "commitizen": { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index d6fae8ae..019ae67d 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -9,11 +9,11 @@ importers: .: dependencies: '@prisma/client': - specifier: ^5.22.0 - version: 5.22.0(prisma@5.22.0) + specifier: ^6.0.0 + version: 6.0.0(prisma@6.0.0) '@sentry/node': - specifier: ^8.38.0 - version: 8.38.0 + specifier: ^8.41.0 + version: 8.41.0 common-tags: specifier: ^1.8.2 version: 1.8.2 @@ -33,8 +33,8 @@ importers: specifier: ^10.7.1 version: 10.7.1 husky: - specifier: ^9.1.6 - version: 9.1.6 + specifier: ^9.1.7 + version: 9.1.7 ioredis: specifier: ^5.4.1 version: 5.4.1 @@ -50,9 +50,6 @@ importers: ms: specifier: ^2.1.3 version: 2.1.3 - parse-duration: - specifier: ^1.1.0 - version: 1.1.0 reflect-metadata: specifier: ^0.2.2 version: 0.2.2 @@ -67,8 +64,8 @@ importers: version: 3.17.0 devDependencies: '@stylistic/eslint-plugin': - specifier: ^2.10.1 - version: 2.10.1(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) + specifier: ^2.11.0 + version: 2.11.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) '@types/common-tags': specifier: ^1.8.4 version: 1.8.4 @@ -85,14 +82,14 @@ importers: specifier: ^0.7.34 version: 0.7.34 '@types/node': - specifier: ^22.9.0 - version: 22.9.0 + specifier: ^22.10.1 + version: 22.10.1 '@types/source-map-support': specifier: ^0.5.10 version: 0.5.10 cz-conventional-changelog: specifier: ^3.3.0 - version: 3.3.0(@types/node@22.9.0)(typescript@5.6.3) + version: 3.3.0(@types/node@22.10.1)(typescript@5.7.2) eslint: specifier: 9.14.0 version: 9.14.0(jiti@1.21.6) @@ -100,23 +97,23 @@ importers: specifier: ^15.2.10 version: 15.2.10 prettier: - specifier: ^3.3.3 - version: 3.3.3 + specifier: ^3.4.1 + version: 3.4.1 prisma: - specifier: ^5.22.0 - version: 5.22.0 + specifier: ^6.0.0 + version: 6.0.0 release-it: specifier: ^17.10.0 - version: 17.10.0(typescript@5.6.3) + version: 17.10.0(typescript@5.7.2) tsc-watch: specifier: ^6.2.1 - version: 6.2.1(typescript@5.6.3) + version: 6.2.1(typescript@5.7.2) typescript: - specifier: ^5.6.3 - version: 5.6.3 + specifier: ^5.7.2 + version: 5.7.2 typescript-eslint: - specifier: ^8.14.0 - version: 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) + specifier: ^8.16.0 + version: 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) packages: @@ -308,8 +305,8 @@ packages: resolution: {integrity: sha512-MB4AYDsM5jhIHro/dq4ix1iWTLGToIGk6cWF5L6vanFaMble5jTX/UBQyiv05HsWnwUtY8JrfHy2LWfKwihqMw==} engines: {node: '>= 18'} - '@octokit/types@13.6.1': - resolution: {integrity: sha512-PHZE9Z+kWXb23Ndik8MKPirBPziOc0D2/3KH1P+6jK5nGWe96kadZuE4jev2/Jq7FvIfTlT2Ltg8Fv2x1v0a5g==} + '@octokit/types@13.6.2': + resolution: {integrity: sha512-WpbZfZUcZU77DrSW4wbsSgTPfKcp286q3ItaIgvSbBpZJlu6mnYXAkjZz6LVZPXkEvLIM8McanyZejKTYUHipA==} '@opentelemetry/api-logs@0.52.1': resolution: {integrity: sha512-qnSqB2DQ9TPP96dl8cDubDvrUyWc0/sK81xHTK8eSUspzDM3bsewX903qclQFvVhgStjRWdC5bLb3kQqMkfV5A==} @@ -327,8 +324,8 @@ packages: resolution: {integrity: sha512-3giAOQvZiH5F9bMlMiv8+GSPMeqg0dbaeo58/0SlA9sxSqZhnUtxzX9/2FzyhS9sWQf5S0GJE0AKBrFqjpeYcg==} engines: {node: '>=8.0.0'} - '@opentelemetry/context-async-hooks@1.27.0': - resolution: {integrity: sha512-CdZ3qmHCwNhFAzjTgHqrDQ44Qxcpz43cVxZRhOs+Ns/79ug+Mr84Bkb626bkJLkA3+BLimA5YAEVRlJC6pFb7g==} + '@opentelemetry/context-async-hooks@1.28.0': + resolution: {integrity: sha512-igcl4Ve+F1N2063PJUkesk/GkYyuGIWinYkSyAFTnIj3gzrOgvOA4k747XNdL47HRRL1w/qh7UW8NDuxOLvKFA==} engines: {node: '>=14'} peerDependencies: '@opentelemetry/api': '>=1.0.0 <1.10.0' @@ -339,8 +336,8 @@ packages: peerDependencies: '@opentelemetry/api': '>=1.0.0 <1.10.0' - '@opentelemetry/core@1.27.0': - resolution: {integrity: sha512-yQPKnK5e+76XuiqUH/gKyS8wv/7qITd5ln56QkBTf3uggr0VkXOXfcaAuG330UfdYu83wsyoBwqwxigpIG+Jkg==} + '@opentelemetry/core@1.28.0': + resolution: {integrity: sha512-ZLwRMV+fNDpVmF2WYUdBHlq0eOWtEaUJSusrzjGnBt7iSRvfjFE3RXYUZJrqou/wIDWV0DwQ5KIfYe9WXg9Xqw==} engines: {node: '>=14'} peerDependencies: '@opentelemetry/api': '>=1.0.0 <1.10.0' @@ -511,14 +508,14 @@ packages: resolution: {integrity: sha512-faYX1N0gpLhej/6nyp6bgRjzAKXn5GOEMYY7YhciSfCoITAktLUtQ36d24QEWNA1/WA1y6qQunCe0OhHRkVl9g==} engines: {node: '>=14'} - '@opentelemetry/resources@1.27.0': - resolution: {integrity: sha512-jOwt2VJ/lUD5BLc+PMNymDrUCpm5PKi1E9oSVYAvz01U/VdndGmrtV3DU1pG4AwlYhJRHbHfOUIlpBeXCPw6QQ==} + '@opentelemetry/resources@1.28.0': + resolution: {integrity: sha512-cIyXSVJjGeTICENN40YSvLDAq4Y2502hGK3iN7tfdynQLKWb3XWZQEkPc+eSx47kiy11YeFAlYkEfXwR1w8kfw==} engines: {node: '>=14'} peerDependencies: '@opentelemetry/api': '>=1.0.0 <1.10.0' - '@opentelemetry/sdk-trace-base@1.27.0': - resolution: {integrity: sha512-btz6XTQzwsyJjombpeqCX6LhiMQYpzt2pIYNPnw0IPO/3AhT6yjnf8Mnv3ZC2A4eRYOjqrg+bfaXg9XHDRJDWQ==} + '@opentelemetry/sdk-trace-base@1.28.0': + resolution: {integrity: sha512-ceUVWuCpIao7Y5xE02Xs3nQi0tOGmMea17ecBdwtCvdo9ekmO+ijc9RFDgfifMl7XCBf41zne/1POM3LqSTZDA==} engines: {node: '>=14'} peerDependencies: '@opentelemetry/api': '>=1.0.0 <1.10.0' @@ -527,6 +524,10 @@ packages: resolution: {integrity: sha512-sAay1RrB+ONOem0OZanAR1ZI/k7yDpnOQSQmTMuGImUQb2y8EbSaCJ94FQluM74xoU03vlb2d2U90hZluL6nQg==} engines: {node: '>=14'} + '@opentelemetry/semantic-conventions@1.28.0': + resolution: {integrity: sha512-lp4qAiMTD4sNWW4DbKLBkfiMZ4jbAboJIGOQr5DvciMRI494OapieI9qiODpOt0XBr1LjIDy1xAGAnVs5supTA==} + engines: {node: '>=14'} + '@opentelemetry/sql-common@0.40.1': resolution: {integrity: sha512-nSDlnHSqzC3pXn/wZEZVLuAuJ1MYMXPBwtv2qAbCa3847SaHItdE7SzUq/Jtb0KZmh1zfAbNi3AAMjztTT4Ugg==} engines: {node: '>=14'} @@ -545,29 +546,29 @@ packages: resolution: {integrity: sha512-c83qWb22rNRuB0UaVCI0uRPNRr8Z0FWnEIvT47jiHAmOIUHbBOg5XvV7pM5x+rKn9HRpjxquDbXYSXr3fAKFcw==} engines: {node: '>=12'} - '@prisma/client@5.22.0': - resolution: {integrity: sha512-M0SVXfyHnQREBKxCgyo7sffrKttwE6R8PMq330MIUF0pTwjUhLbW84pFDlf06B27XyCR++VtjugEnIHdr07SVA==} - engines: {node: '>=16.13'} + '@prisma/client@6.0.0': + resolution: {integrity: sha512-tOBhG35ozqZ/5Y6B0TNOa6cwULUW8ijXqBXcgb12bfozqf6eGMyGs+jphywCsj6uojv5lAZZnxVSoLMVebIP+g==} + engines: {node: '>=18.18'} peerDependencies: prisma: '*' peerDependenciesMeta: prisma: optional: true - '@prisma/debug@5.22.0': - resolution: {integrity: sha512-AUt44v3YJeggO2ZU5BkXI7M4hu9BF2zzH2iF2V5pyXT/lRTyWiElZ7It+bRH1EshoMRxHgpYg4VB6rCM+mG5jQ==} + '@prisma/debug@6.0.0': + resolution: {integrity: sha512-eUjoNThlDXdyJ1iQ2d7U6aTVwm59EwvODb5zFVNJEokNoSiQmiYWNzZIwZyDmZ+j51j42/0iTaHIJ4/aZPKFRg==} - '@prisma/engines-version@5.22.0-44.605197351a3c8bdd595af2d2a9bc3025bca48ea2': - resolution: {integrity: sha512-2PTmxFR2yHW/eB3uqWtcgRcgAbG1rwG9ZriSvQw+nnb7c4uCr3RAcGMb6/zfE88SKlC1Nj2ziUvc96Z379mHgQ==} + '@prisma/engines-version@5.23.0-27.5dbef10bdbfb579e07d35cc85fb1518d357cb99e': + resolution: {integrity: sha512-JmIds0Q2/vsOmnuTJYxY4LE+sajqjYKhLtdOT6y4imojqv5d/aeVEfbBGC74t8Be1uSp0OP8lxIj2OqoKbLsfQ==} - '@prisma/engines@5.22.0': - resolution: {integrity: sha512-UNjfslWhAt06kVL3CjkuYpHAWSO6L4kDCVPegV6itt7nD1kSJavd3vhgAEhjglLJJKEdJ7oIqDJ+yHk6qO8gPA==} + '@prisma/engines@6.0.0': + resolution: {integrity: sha512-ZZCVP3q22ifN6Ex6C8RIcTDBlRtMJS2H1ljV0knCiWNGArvvkEbE88W3uDdq/l4+UvyvHpGzdf9ZsCWSQR7ZQQ==} - '@prisma/fetch-engine@5.22.0': - resolution: {integrity: sha512-bkrD/Mc2fSvkQBV5EpoFcZ87AvOgDxbG99488a5cexp5Ccny+UM6MAe/UFkUC0wLYD9+9befNOqGiIJhhq+HbA==} + '@prisma/fetch-engine@6.0.0': + resolution: {integrity: sha512-j2m+iO5RDPRI7SUc7sHo8wX7SA4iTkJ+18Sxch8KinQM46YiCQD1iXKN6qU79C1Fliw5Bw/qDyTHaTsa3JMerA==} - '@prisma/get-platform@5.22.0': - resolution: {integrity: sha512-pHhpQdr1UPFpt+zFfnPazhulaZYCUqeIcPpJViYoq9R+D/yw4fjE+CtnsnKzPYm0ddUbeXUzjGVGIRVgPDCk4Q==} + '@prisma/get-platform@6.0.0': + resolution: {integrity: sha512-PS6nYyIm9g8C03E4y7LknOfdCw/t2KyEJxntMPQHQZCOUgOpF82Ma60mdlOD08w90I3fjLiZZ0+MadenR3naDQ==} '@prisma/instrumentation@5.19.1': resolution: {integrity: sha512-VLnzMQq7CWroL5AeaW0Py2huiNKeoMfCH3SUxstdzPrlWQi6UQ9UrfcbUkNHlVFqOMacqy8X/8YtE0kuKDpD9w==} @@ -584,16 +585,16 @@ packages: resolution: {integrity: sha512-jjmJywLAFoWeBi1W7994zZyiNWPIiqRRNAmSERxyg93xRGzNYvGjlZ0gR6x0F4gPRi2+0O6S71kOZYyr3cxaIQ==} engines: {node: '>=v14.0.0', npm: '>=7.0.0'} - '@sentry/core@8.38.0': - resolution: {integrity: sha512-sGD+5TEHU9G7X7zpyaoJxpOtwjTjvOd1f/MKBrWW2vf9UbYK+GUJrOzLhMoSWp/pHSYgvObkJkDb/HwieQjvhQ==} + '@sentry/core@8.41.0': + resolution: {integrity: sha512-3v7u3t4LozCA5SpZY4yqUN2U3jSrkXNoLgz6L2SUUiydyCuSwXZIFEwpLJfgQyidpNDifeQbBI5E1O910XkPsA==} engines: {node: '>=14.18'} - '@sentry/node@8.38.0': - resolution: {integrity: sha512-nwW0XqZFQseXYn0i6i6nKPkbjgHMBEFSF9TnK6mHHqJHHObHIZ6qu5CfvGKgxATia8JPIg9NN8XcyYOnQMi07w==} + '@sentry/node@8.41.0': + resolution: {integrity: sha512-eYD5S8Lti9efBHFSIhZ/0C5uI1DQtGqjuNWQ62CKC47G2qgJddBtb2HgqRFAnMajYL9FXEtiDT6uqQhKQnmLcQ==} engines: {node: '>=14.18'} - '@sentry/opentelemetry@8.38.0': - resolution: {integrity: sha512-AfjmIf/v7+x2WplhkX66LyGKvrzzPeSgff9uJ0cFCC2s0yd1qA2VPuIwEyr5i/FOJOP5bvFr8tu/hz3LA4+F5Q==} + '@sentry/opentelemetry@8.41.0': + resolution: {integrity: sha512-Ld6KdBQsmSk2IfFSoZ7CMpmuQbfb3viV6nTDCz6+11wL9S+1b+hadCN+38yBW4CmI4/hEpYfwwWQPseQQTvBCg==} engines: {node: '>=14.18'} peerDependencies: '@opentelemetry/api': ^1.9.0 @@ -602,20 +603,16 @@ packages: '@opentelemetry/sdk-trace-base': ^1.26.0 '@opentelemetry/semantic-conventions': ^1.27.0 - '@sentry/types@8.38.0': - resolution: {integrity: sha512-fP5H9ZX01W4Z/EYctk3mkSHi7d06cLcX2/UWqwdWbyPWI+pL2QpUPICeO/C+8SnmYx//wFj3qWDhyPCh1PdFAA==} - engines: {node: '>=14.18'} - - '@sentry/utils@8.38.0': - resolution: {integrity: sha512-3X7MgIKIx+2q5Al7QkhaRB4wV6DvzYsaeIwdqKUzGLuRjXmNgJrLoU87TAwQRmZ6Wr3IoEpThZZMNrzYPXxArw==} + '@sentry/types@8.41.0': + resolution: {integrity: sha512-eqdnGr9k9H++b9CjVUoTNUVahPVWeNnMy0YGkqS5+cjWWC+x43p56202oidGFmWo6702ub/xwUNH6M5PC4kq6A==} engines: {node: '>=14.18'} '@sindresorhus/merge-streams@2.3.0': resolution: {integrity: sha512-LtoMMhxAlorcGhmFYI+LhPgbPZCkgP6ra1YL604EeF6U98pLlQ3iWIGMdWSC+vWmPBWBNgmDBAhnAobLROJmwg==} engines: {node: '>=18'} - '@stylistic/eslint-plugin@2.10.1': - resolution: {integrity: sha512-U+4yzNXElTf9q0kEfnloI9XbOyD4cnEQCxjUI94q0+W++0GAEQvJ/slwEj9lwjDHfGADRSr+Tco/z0XJvmDfCQ==} + '@stylistic/eslint-plugin@2.11.0': + resolution: {integrity: sha512-PNRHbydNG5EH8NK4c+izdJlxajIR6GxcUhzsYNRsn6Myep4dsZt0qFCz3rCPnkvgO5FYibDcMqgNHUT+zvjYZw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: '>=8.40.0' @@ -635,14 +632,14 @@ packages: '@types/connect@3.4.38': resolution: {integrity: sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug==} - '@types/conventional-commits-parser@5.0.0': - resolution: {integrity: sha512-loB369iXNmAZglwWATL+WRe+CRMmmBPtpolYzIebFaX4YA3x+BEfLqhUAV9WanycKI3TG1IMr5bMJDajDKLlUQ==} + '@types/conventional-commits-parser@5.0.1': + resolution: {integrity: sha512-7uz5EHdzz2TqoMfV7ee61Egf5y6NkcO4FB/1iCCQnbeiI1F3xzv3vK5dBCXUCLQgGYS+mUeigK1iKQzvED+QnQ==} '@types/estree@1.0.6': resolution: {integrity: sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==} - '@types/express-serve-static-core@5.0.1': - resolution: {integrity: sha512-CRICJIl0N5cXDONAdlTv5ShATZ4HEwk6kDDIW2/w9qOWKg+NU/5F8wYRWCrONad0/UKkloNSmmyN/wX4rtpbVA==} + '@types/express-serve-static-core@5.0.2': + resolution: {integrity: sha512-vluaspfvWEtE4vcSDlKRNer52DvOGrB2xv6diXy6UKyKW0lqZiWHGNApSyxOv+8DE5Z27IzVvE7hNkxg7EXIcg==} '@types/express@5.0.0': resolution: {integrity: sha512-DvZriSMehGHL1ZNLzi6MidnsDhUZM/x2pRdDIKdwbUNqqwHxMlRdkxtn6/EPKyqKpHqTl/4nRZsRNLpZxZRpPQ==} @@ -668,8 +665,8 @@ packages: '@types/mysql@2.15.26': resolution: {integrity: sha512-DSLCOXhkvfS5WNNPbfn2KdICAmk8lLc+/PNvnPnF7gOdMZCxopXduqv0OQ13y/yA/zXTSikZZqVgybUxOEg6YQ==} - '@types/node@22.9.0': - resolution: {integrity: sha512-vuyHg81vvWA1Z1ELfvLko2c8f34gyA0zaic0+Rllc5lbCnbSyuvb2Oxpm6TAUAC/2xZN3QGqxBNggD1nNR2AfQ==} + '@types/node@22.10.1': + resolution: {integrity: sha512-qKgsUwfHZV2WCWLAnVP1JqnpE6Im6h3Y0+fYgMTasNQ7V++CBX5OT1as0g0f+OyubbFqhf6XVNIsmN4IIhEgGQ==} '@types/pg-pool@2.0.6': resolution: {integrity: sha512-TaAUE5rq2VQYxab5Ts7WZhKNmuN78Q6PiFonTDdpbx8a1H0M1vhy3rhiMjl+e2iHmogyMw7jZF4FrE6eJUy5HQ==} @@ -704,8 +701,8 @@ packages: '@types/ws@8.5.13': resolution: {integrity: sha512-osM/gWBTPKgHV8XkTunnegTRIsvF6owmf5w+JtAfOw472dptdm0dlGv4xCt6GwQRcC2XVOvvRE/0bAoQcL2QkA==} - '@typescript-eslint/eslint-plugin@8.14.0': - resolution: {integrity: sha512-tqp8H7UWFaZj0yNO6bycd5YjMwxa6wIHOLZvWPkidwbgLCsBMetQoGj7DPuAlWa2yGO3H48xmPwjhsSPPCGU5w==} + '@typescript-eslint/eslint-plugin@8.16.0': + resolution: {integrity: sha512-5YTHKV8MYlyMI6BaEG7crQ9BhSc8RxzshOReKwZwRWN0+XvvTOm+L/UYLCYxFpfwYuAAqhxiq4yae0CMFwbL7Q==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: '@typescript-eslint/parser': ^8.0.0 || ^8.0.0-alpha.0 @@ -715,8 +712,8 @@ packages: typescript: optional: true - '@typescript-eslint/parser@8.14.0': - resolution: {integrity: sha512-2p82Yn9juUJq0XynBXtFCyrBDb6/dJombnz6vbo6mgQEtWHfvHbQuEa9kAOVIt1c9YFwi7H6WxtPj1kg+80+RA==} + '@typescript-eslint/parser@8.16.0': + resolution: {integrity: sha512-D7DbgGFtsqIPIFMPJwCad9Gfi/hC0PWErRRHFnaCWoEDYi5tQUDiJCTmGUbBiLzjqAck4KcXt9Ayj0CNlIrF+w==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 @@ -725,25 +722,26 @@ packages: typescript: optional: true - '@typescript-eslint/scope-manager@8.14.0': - resolution: {integrity: sha512-aBbBrnW9ARIDn92Zbo7rguLnqQ/pOrUguVpbUwzOhkFg2npFDwTgPGqFqE0H5feXcOoJOfX3SxlJaKEVtq54dw==} + '@typescript-eslint/scope-manager@8.16.0': + resolution: {integrity: sha512-mwsZWubQvBki2t5565uxF0EYvG+FwdFb8bMtDuGQLdCCnGPrDEDvm1gtfynuKlnpzeBRqdFCkMf9jg1fnAK8sg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/type-utils@8.14.0': - resolution: {integrity: sha512-Xcz9qOtZuGusVOH5Uk07NGs39wrKkf3AxlkK79RBK6aJC1l03CobXjJbwBPSidetAOV+5rEVuiT1VSBUOAsanQ==} + '@typescript-eslint/type-utils@8.16.0': + resolution: {integrity: sha512-IqZHGG+g1XCWX9NyqnI/0CX5LL8/18awQqmkZSl2ynn8F76j579dByc0jhfVSnSnhf7zv76mKBQv9HQFKvDCgg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: + eslint: ^8.57.0 || ^9.0.0 typescript: '*' peerDependenciesMeta: typescript: optional: true - '@typescript-eslint/types@8.14.0': - resolution: {integrity: sha512-yjeB9fnO/opvLJFAsPNYlKPnEM8+z4og09Pk504dkqonT02AyL5Z9SSqlE0XqezS93v6CXn49VHvB2G7XSsl0g==} + '@typescript-eslint/types@8.16.0': + resolution: {integrity: sha512-NzrHj6thBAOSE4d9bsuRNMvk+BvaQvmY4dDglgkgGC0EW/tB3Kelnp3tAKH87GEwzoxgeQn9fNGRyFJM/xd+GQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/typescript-estree@8.14.0': - resolution: {integrity: sha512-OPXPLYKGZi9XS/49rdaCbR5j/S14HazviBlUQFvSKz3npr3NikF+mrgK7CFVur6XEt95DZp/cmke9d5i3vtVnQ==} + '@typescript-eslint/typescript-estree@8.16.0': + resolution: {integrity: sha512-E2+9IzzXMc1iaBy9zmo+UYvluE3TW7bCGWSF41hVWUE01o8nzr1rvOQYSxelxr6StUvRcTMe633eY8mXASMaNw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: typescript: '*' @@ -751,14 +749,18 @@ packages: typescript: optional: true - '@typescript-eslint/utils@8.14.0': - resolution: {integrity: sha512-OGqj6uB8THhrHj0Fk27DcHPojW7zKwKkPmHXHvQ58pLYp4hy8CSUdTKykKeh+5vFqTTVmjz0zCOOPKRovdsgHA==} + '@typescript-eslint/utils@8.16.0': + resolution: {integrity: sha512-C1zRy/mOL8Pj157GiX4kaw7iyRLKfJXBR3L82hk5kS/GyHcOFmy4YUq/zfZti72I9wnuQtA/+xzft4wCC8PJdA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true - '@typescript-eslint/visitor-keys@8.14.0': - resolution: {integrity: sha512-vG0XZo8AdTH9OE6VFRwAZldNc7qtJ/6NLGWak+BtENuEUXGZgFpihILPiBvKXvJ2nFu27XNGC6rKiwuaoMbYzQ==} + '@typescript-eslint/visitor-keys@8.16.0': + resolution: {integrity: sha512-pq19gbaMOmFE3CbL0ZB8J8BFCo2ckfHBfaIsaOZgBIF4EoISJIdLX5xRhd0FGB0LlHReNRuzoJoMGpTjq8F2CQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@vladfrangu/async_event_emitter@2.4.6': @@ -1054,8 +1056,8 @@ packages: typescript: optional: true - cross-spawn@7.0.5: - resolution: {integrity: sha512-ZVJrKKYunU38/76t0RMOulHOnUcbU9GbpWKAOZ0mhjr7CX6FVrH+4FrAapSOekrgFQ3f/8gwMEuIft0aKq6Hug==} + cross-spawn@7.0.6: + resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==} engines: {node: '>= 8'} cz-conventional-changelog@3.3.0: @@ -1379,8 +1381,8 @@ packages: resolution: {integrity: sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==} engines: {node: '>=16'} - flatted@3.3.1: - resolution: {integrity: sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==} + flatted@3.3.2: + resolution: {integrity: sha512-AiwGJM8YcNOaobumgtng+6NHuOqC3A7MixFeDafM3X9cIUM+xUXoS5Vfgf+OihAYe20fxqNM9yPBXJzRtZ/4eA==} fn.name@1.1.0: resolution: {integrity: sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw==} @@ -1540,8 +1542,8 @@ packages: resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} engines: {node: '>=16.17.0'} - husky@9.1.6: - resolution: {integrity: sha512-sqbjZKK7kf44hfdE94EoX8MZNk0n7HeW37O4YrVGCF4wzgQjp+akPAkfUK5LZ6KuR/6sqeAVuXHji+RzQgOn5A==} + husky@9.1.7: + resolution: {integrity: sha512-5gs5ytaNjBrh5Ow3zrvdUUY+0VxIuWVL4i9irt6friV+BqdCfmV11CQTWMiBYWHbXhco+J1kHfTOUkePhCDvMA==} engines: {node: '>=18'} hasBin: true @@ -2066,9 +2068,6 @@ packages: resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} engines: {node: '>=6'} - parse-duration@1.1.0: - resolution: {integrity: sha512-z6t9dvSJYaPoQq7quMzdEagSFtpGu+utzHqqxmpVWNNZRIXnvqyCvn9XsTdh7c/w0Bqmdz3RB3YnRaKtpRtEXQ==} - parse-json@5.2.0: resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==} engines: {node: '>=8'} @@ -2164,14 +2163,14 @@ packages: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} engines: {node: '>= 0.8.0'} - prettier@3.3.3: - resolution: {integrity: sha512-i2tDNA0O5IrMO757lfrdQZCc2jPNDVntV0m/+4whiDfWaTKfMNgR7Qz0NAeGz/nRqF4m5/6CLzbP4/liHt12Ew==} + prettier@3.4.1: + resolution: {integrity: sha512-G+YdqtITVZmOJje6QkXQWzl3fSfMxFwm1tjTyo9exhkmWSqC4Yhd1+lug++IlR2mvRVAxEDDWYkQdeSztajqgg==} engines: {node: '>=14'} hasBin: true - prisma@5.22.0: - resolution: {integrity: sha512-vtpjW3XuYCSnMsNVBjLMNkTj6OZbudcPPTPYHqX0CJfpcdWciI1dM8uHETwmDxxiqEwCIE6WvXucWUetJgfu/A==} - engines: {node: '>=16.13'} + prisma@6.0.0: + resolution: {integrity: sha512-RX7KtbW7IoEByf7MR32JK1PkVYLVYFqeODTtiIX3cqekq1aKdsF3Eud4zp2sUShMLjvdb5Jow0LbUjRq5LVxPw==} + engines: {node: '>=18.18'} hasBin: true proto-list@1.2.4: @@ -2242,8 +2241,8 @@ packages: reflect-metadata@0.2.2: resolution: {integrity: sha512-urBwgfrvVP/eAyXx4hluJivBKzuEbSQs9rKWCrCkbSxNv8mxPcUZKeuoF3Uy4mJl3Lwprp6yy5/39VWigZ4K6Q==} - registry-auth-token@5.0.2: - resolution: {integrity: sha512-o/3ikDxtXaA59BmZuZrJZDJv8NMDGSj+6j6XaeBmHw8eY1i1qd9+6H+LjVvQXx3HN6aRCGa1cUdJ9RaJZUugnQ==} + registry-auth-token@5.0.3: + resolution: {integrity: sha512-1bpc9IyC+e+CNFRaWyn77tk4xGG4PPUyfakSmA6F6cvUDjrm58dfyJ3II+9yb10EDkHoy1LaPSmHaWLOH3m6HA==} engines: {node: '>=14'} registry-url@6.0.1: @@ -2517,8 +2516,8 @@ packages: resolution: {integrity: sha512-aZbgViZrg1QNcG+LULa7nhZpJTZSLm/mXnHXnbAbjmN5aSa0y7V+wvv6+4WaBtpISJzThKy+PIPxc1Nq1EJ9mg==} engines: {node: '>= 14.0.0'} - ts-api-utils@1.4.0: - resolution: {integrity: sha512-032cPxaEKwM+GT3vA5JXNzIaizx388rhsSW79vGRNGXfRRAdEAn2mvk36PvK5HnOchyWZ7afLEXqYCvPCrzuzQ==} + ts-api-utils@1.4.3: + resolution: {integrity: sha512-i3eMG77UTMD0hZhgRS562pv83RC6ukSAC2GMNWc+9dieh/+jDM5u5YG+NHX6VNDRHQcHwmsTHctP9LhbC3WxVw==} engines: {node: '>=16'} peerDependencies: typescript: '>=4.2.0' @@ -2548,8 +2547,8 @@ packages: resolution: {integrity: sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA==} engines: {node: '>=12.20'} - type-fest@4.27.0: - resolution: {integrity: sha512-3IMSWgP7C5KSQqmo1wjhKrwsvXAtF33jO3QY+Uy++ia7hqvgSK6iXbbg5PbDBc1P2ZbNEDgejOrN4YooXvhwCw==} + type-fest@4.29.0: + resolution: {integrity: sha512-RPYt6dKyemXJe7I6oNstcH24myUGSReicxcHTvCLgzm4e0n8y05dGvcGB15/SoPRBmhlMthWQ9pvKyL81ko8nQ==} engines: {node: '>=16'} type-is@1.6.18: @@ -2560,22 +2559,23 @@ packages: resolution: {integrity: sha512-gd0sGezQYCbWSbkZr75mln4YBidWUN60+devscpLF5mtRDUpiaTvKpBNrdaCvel1NdR2k6vclXybU5fBd2i+nw==} engines: {node: '>= 0.6'} - typescript-eslint@8.14.0: - resolution: {integrity: sha512-K8fBJHxVL3kxMmwByvz8hNdBJ8a0YqKzKDX6jRlrjMuNXyd5T2V02HIq37+OiWXvUUOXgOOGiSSOh26Mh8pC3w==} + typescript-eslint@8.16.0: + resolution: {integrity: sha512-wDkVmlY6O2do4V+lZd0GtRfbtXbeD0q9WygwXXSJnC1xorE8eqyC2L1tJimqpSeFrOzRlYtWnUp/uzgHQOgfBQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: + eslint: ^8.57.0 || ^9.0.0 typescript: '*' peerDependenciesMeta: typescript: optional: true - typescript@5.6.3: - resolution: {integrity: sha512-hjcS1mhfuyi4WW8IWtjP7brDrG2cuDZukyrYrSauoXGNgx0S7zceP07adYkJycEr56BOUTNPzbInooiN3fn1qw==} + typescript@5.7.2: + resolution: {integrity: sha512-i5t66RHxDvVN40HfDd1PsEThGNnlMCMT3jMUuoh9/0TaqWevNontacunWyN02LA9/fIbEWlcHZcgTKb9QoaLfg==} engines: {node: '>=14.17'} hasBin: true - undici-types@6.19.8: - resolution: {integrity: sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==} + undici-types@6.20.0: + resolution: {integrity: sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==} undici@6.19.8: resolution: {integrity: sha512-U8uCCl2x9TK3WANvmBavymRzxbfFYG+tAu+fgx3zxQy3qdagQqBLwJVrdyO1TBfUXvfKveMKJZhpvUYoOjM+4g==} @@ -2733,15 +2733,15 @@ snapshots: '@commitlint/execute-rule@19.5.0': optional: true - '@commitlint/load@19.5.0(@types/node@22.9.0)(typescript@5.6.3)': + '@commitlint/load@19.5.0(@types/node@22.10.1)(typescript@5.7.2)': dependencies: '@commitlint/config-validator': 19.5.0 '@commitlint/execute-rule': 19.5.0 '@commitlint/resolve-extends': 19.5.0 '@commitlint/types': 19.5.0 chalk: 5.3.0 - cosmiconfig: 9.0.0(typescript@5.6.3) - cosmiconfig-typescript-loader: 5.1.0(@types/node@22.9.0)(cosmiconfig@9.0.0(typescript@5.6.3))(typescript@5.6.3) + cosmiconfig: 9.0.0(typescript@5.7.2) + cosmiconfig-typescript-loader: 5.1.0(@types/node@22.10.1)(cosmiconfig@9.0.0(typescript@5.7.2))(typescript@5.7.2) lodash.isplainobject: 4.0.6 lodash.merge: 4.6.2 lodash.uniq: 4.5.0 @@ -2762,7 +2762,7 @@ snapshots: '@commitlint/types@19.5.0': dependencies: - '@types/conventional-commits-parser': 5.0.0 + '@types/conventional-commits-parser': 5.0.1 chalk: 5.3.0 optional: true @@ -2897,19 +2897,19 @@ snapshots: '@octokit/graphql': 7.1.0 '@octokit/request': 8.4.0 '@octokit/request-error': 5.1.0 - '@octokit/types': 13.6.1 + '@octokit/types': 13.6.2 before-after-hook: 2.2.3 universal-user-agent: 6.0.1 '@octokit/endpoint@9.0.5': dependencies: - '@octokit/types': 13.6.1 + '@octokit/types': 13.6.2 universal-user-agent: 6.0.1 '@octokit/graphql@7.1.0': dependencies: '@octokit/request': 8.4.0 - '@octokit/types': 13.6.1 + '@octokit/types': 13.6.2 universal-user-agent: 6.0.1 '@octokit/openapi-types@22.2.0': {} @@ -2917,7 +2917,7 @@ snapshots: '@octokit/plugin-paginate-rest@11.3.1(@octokit/core@5.2.0)': dependencies: '@octokit/core': 5.2.0 - '@octokit/types': 13.6.1 + '@octokit/types': 13.6.2 '@octokit/plugin-request-log@4.0.1(@octokit/core@5.2.0)': dependencies: @@ -2926,11 +2926,11 @@ snapshots: '@octokit/plugin-rest-endpoint-methods@13.2.2(@octokit/core@5.2.0)': dependencies: '@octokit/core': 5.2.0 - '@octokit/types': 13.6.1 + '@octokit/types': 13.6.2 '@octokit/request-error@5.1.0': dependencies: - '@octokit/types': 13.6.1 + '@octokit/types': 13.6.2 deprecation: 2.3.1 once: 1.4.0 @@ -2938,7 +2938,7 @@ snapshots: dependencies: '@octokit/endpoint': 9.0.5 '@octokit/request-error': 5.1.0 - '@octokit/types': 13.6.1 + '@octokit/types': 13.6.2 universal-user-agent: 6.0.1 '@octokit/rest@20.1.1': @@ -2948,7 +2948,7 @@ snapshots: '@octokit/plugin-request-log': 4.0.1(@octokit/core@5.2.0) '@octokit/plugin-rest-endpoint-methods': 13.2.2(@octokit/core@5.2.0) - '@octokit/types@13.6.1': + '@octokit/types@13.6.2': dependencies: '@octokit/openapi-types': 22.2.0 @@ -2966,7 +2966,7 @@ snapshots: '@opentelemetry/api@1.9.0': {} - '@opentelemetry/context-async-hooks@1.27.0(@opentelemetry/api@1.9.0)': + '@opentelemetry/context-async-hooks@1.28.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 @@ -2975,7 +2975,7 @@ snapshots: '@opentelemetry/api': 1.9.0 '@opentelemetry/semantic-conventions': 1.27.0 - '@opentelemetry/core@1.27.0(@opentelemetry/api@1.9.0)': + '@opentelemetry/core@1.28.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/semantic-conventions': 1.27.0 @@ -2983,18 +2983,18 @@ snapshots: '@opentelemetry/instrumentation-amqplib@0.43.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color '@opentelemetry/instrumentation-connect@0.40.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 '@types/connect': 3.4.36 transitivePeerDependencies: - supports-color @@ -3009,25 +3009,25 @@ snapshots: '@opentelemetry/instrumentation-express@0.44.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color '@opentelemetry/instrumentation-fastify@0.41.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color '@opentelemetry/instrumentation-fs@0.16.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) transitivePeerDependencies: - supports-color @@ -3049,9 +3049,9 @@ snapshots: '@opentelemetry/instrumentation-hapi@0.41.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color @@ -3070,7 +3070,7 @@ snapshots: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) '@opentelemetry/redis-common': 0.36.2 - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color @@ -3078,7 +3078,7 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color @@ -3086,16 +3086,16 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color '@opentelemetry/instrumentation-koa@0.43.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color @@ -3110,16 +3110,16 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color '@opentelemetry/instrumentation-mongoose@0.42.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color @@ -3127,7 +3127,7 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 '@opentelemetry/sql-common': 0.40.1(@opentelemetry/api@1.9.0) transitivePeerDependencies: - supports-color @@ -3136,7 +3136,7 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 '@types/mysql': 2.15.26 transitivePeerDependencies: - supports-color @@ -3145,7 +3145,7 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color @@ -3153,7 +3153,7 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 '@opentelemetry/sql-common': 0.40.1(@opentelemetry/api@1.9.0) '@types/pg': 8.6.1 '@types/pg-pool': 2.0.6 @@ -3165,7 +3165,7 @@ snapshots: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) '@opentelemetry/redis-common': 0.36.2 - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 transitivePeerDependencies: - supports-color @@ -3173,7 +3173,7 @@ snapshots: dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/semantic-conventions': 1.28.0 '@types/tedious': 4.0.14 transitivePeerDependencies: - supports-color @@ -3181,7 +3181,7 @@ snapshots: '@opentelemetry/instrumentation-undici@0.6.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.53.0(@opentelemetry/api@1.9.0) transitivePeerDependencies: - supports-color @@ -3224,25 +3224,27 @@ snapshots: '@opentelemetry/redis-common@0.36.2': {} - '@opentelemetry/resources@1.27.0(@opentelemetry/api@1.9.0)': + '@opentelemetry/resources@1.28.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/semantic-conventions': 1.27.0 - '@opentelemetry/sdk-trace-base@1.27.0(@opentelemetry/api@1.9.0)': + '@opentelemetry/sdk-trace-base@1.28.0(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) - '@opentelemetry/resources': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) + '@opentelemetry/resources': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/semantic-conventions': 1.27.0 '@opentelemetry/semantic-conventions@1.27.0': {} + '@opentelemetry/semantic-conventions@1.28.0': {} + '@opentelemetry/sql-common@0.40.1(@opentelemetry/api@1.9.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@pnpm/config.env-replace@1.1.0': {} @@ -3256,36 +3258,36 @@ snapshots: '@pnpm/network.ca-file': 1.0.2 config-chain: 1.1.13 - '@prisma/client@5.22.0(prisma@5.22.0)': + '@prisma/client@6.0.0(prisma@6.0.0)': optionalDependencies: - prisma: 5.22.0 + prisma: 6.0.0 - '@prisma/debug@5.22.0': {} + '@prisma/debug@6.0.0': {} - '@prisma/engines-version@5.22.0-44.605197351a3c8bdd595af2d2a9bc3025bca48ea2': {} + '@prisma/engines-version@5.23.0-27.5dbef10bdbfb579e07d35cc85fb1518d357cb99e': {} - '@prisma/engines@5.22.0': + '@prisma/engines@6.0.0': dependencies: - '@prisma/debug': 5.22.0 - '@prisma/engines-version': 5.22.0-44.605197351a3c8bdd595af2d2a9bc3025bca48ea2 - '@prisma/fetch-engine': 5.22.0 - '@prisma/get-platform': 5.22.0 + '@prisma/debug': 6.0.0 + '@prisma/engines-version': 5.23.0-27.5dbef10bdbfb579e07d35cc85fb1518d357cb99e + '@prisma/fetch-engine': 6.0.0 + '@prisma/get-platform': 6.0.0 - '@prisma/fetch-engine@5.22.0': + '@prisma/fetch-engine@6.0.0': dependencies: - '@prisma/debug': 5.22.0 - '@prisma/engines-version': 5.22.0-44.605197351a3c8bdd595af2d2a9bc3025bca48ea2 - '@prisma/get-platform': 5.22.0 + '@prisma/debug': 6.0.0 + '@prisma/engines-version': 5.23.0-27.5dbef10bdbfb579e07d35cc85fb1518d357cb99e + '@prisma/get-platform': 6.0.0 - '@prisma/get-platform@5.22.0': + '@prisma/get-platform@6.0.0': dependencies: - '@prisma/debug': 5.22.0 + '@prisma/debug': 6.0.0 '@prisma/instrumentation@5.19.1': dependencies: '@opentelemetry/api': 1.9.0 '@opentelemetry/instrumentation': 0.52.1(@opentelemetry/api@1.9.0) - '@opentelemetry/sdk-trace-base': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/sdk-trace-base': 1.28.0(@opentelemetry/api@1.9.0) transitivePeerDependencies: - supports-color @@ -3298,16 +3300,15 @@ snapshots: '@sapphire/snowflake@3.5.3': {} - '@sentry/core@8.38.0': + '@sentry/core@8.41.0': dependencies: - '@sentry/types': 8.38.0 - '@sentry/utils': 8.38.0 + '@sentry/types': 8.41.0 - '@sentry/node@8.38.0': + '@sentry/node@8.41.0': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/context-async-hooks': 1.27.0(@opentelemetry/api@1.9.0) - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/context-async-hooks': 1.28.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation-amqplib': 0.43.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation-connect': 0.40.0(@opentelemetry/api@1.9.0) @@ -3333,40 +3334,34 @@ snapshots: '@opentelemetry/instrumentation-redis-4': 0.42.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation-tedious': 0.15.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation-undici': 0.6.0(@opentelemetry/api@1.9.0) - '@opentelemetry/resources': 1.27.0(@opentelemetry/api@1.9.0) - '@opentelemetry/sdk-trace-base': 1.27.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 + '@opentelemetry/resources': 1.28.0(@opentelemetry/api@1.9.0) + '@opentelemetry/sdk-trace-base': 1.28.0(@opentelemetry/api@1.9.0) + '@opentelemetry/semantic-conventions': 1.28.0 '@prisma/instrumentation': 5.19.1 - '@sentry/core': 8.38.0 - '@sentry/opentelemetry': 8.38.0(@opentelemetry/api@1.9.0)(@opentelemetry/core@1.27.0(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.54.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.27.0(@opentelemetry/api@1.9.0))(@opentelemetry/semantic-conventions@1.27.0) - '@sentry/types': 8.38.0 - '@sentry/utils': 8.38.0 + '@sentry/core': 8.41.0 + '@sentry/opentelemetry': 8.41.0(@opentelemetry/api@1.9.0)(@opentelemetry/core@1.28.0(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.54.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.28.0(@opentelemetry/api@1.9.0))(@opentelemetry/semantic-conventions@1.28.0) + '@sentry/types': 8.41.0 import-in-the-middle: 1.11.2 transitivePeerDependencies: - supports-color - '@sentry/opentelemetry@8.38.0(@opentelemetry/api@1.9.0)(@opentelemetry/core@1.27.0(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.54.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.27.0(@opentelemetry/api@1.9.0))(@opentelemetry/semantic-conventions@1.27.0)': + '@sentry/opentelemetry@8.41.0(@opentelemetry/api@1.9.0)(@opentelemetry/core@1.28.0(@opentelemetry/api@1.9.0))(@opentelemetry/instrumentation@0.54.2(@opentelemetry/api@1.9.0))(@opentelemetry/sdk-trace-base@1.28.0(@opentelemetry/api@1.9.0))(@opentelemetry/semantic-conventions@1.28.0)': dependencies: '@opentelemetry/api': 1.9.0 - '@opentelemetry/core': 1.27.0(@opentelemetry/api@1.9.0) + '@opentelemetry/core': 1.28.0(@opentelemetry/api@1.9.0) '@opentelemetry/instrumentation': 0.54.2(@opentelemetry/api@1.9.0) - '@opentelemetry/sdk-trace-base': 1.27.0(@opentelemetry/api@1.9.0) - '@opentelemetry/semantic-conventions': 1.27.0 - '@sentry/core': 8.38.0 - '@sentry/types': 8.38.0 - '@sentry/utils': 8.38.0 - - '@sentry/types@8.38.0': {} + '@opentelemetry/sdk-trace-base': 1.28.0(@opentelemetry/api@1.9.0) + '@opentelemetry/semantic-conventions': 1.28.0 + '@sentry/core': 8.41.0 + '@sentry/types': 8.41.0 - '@sentry/utils@8.38.0': - dependencies: - '@sentry/types': 8.38.0 + '@sentry/types@8.41.0': {} '@sindresorhus/merge-streams@2.3.0': {} - '@stylistic/eslint-plugin@2.10.1(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3)': + '@stylistic/eslint-plugin@2.11.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2)': dependencies: - '@typescript-eslint/utils': 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) + '@typescript-eslint/utils': 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) eslint: 9.14.0(jiti@1.21.6) eslint-visitor-keys: 4.2.0 espree: 10.3.0 @@ -3381,28 +3376,28 @@ snapshots: '@types/body-parser@1.19.5': dependencies: '@types/connect': 3.4.38 - '@types/node': 22.9.0 + '@types/node': 22.10.1 '@types/common-tags@1.8.4': {} '@types/connect@3.4.36': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 '@types/connect@3.4.38': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 - '@types/conventional-commits-parser@5.0.0': + '@types/conventional-commits-parser@5.0.1': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 optional: true '@types/estree@1.0.6': {} - '@types/express-serve-static-core@5.0.1': + '@types/express-serve-static-core@5.0.2': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 '@types/qs': 6.9.17 '@types/range-parser': 1.2.7 '@types/send': 0.17.4 @@ -3410,7 +3405,7 @@ snapshots: '@types/express@5.0.0': dependencies: '@types/body-parser': 1.19.5 - '@types/express-serve-static-core': 5.0.1 + '@types/express-serve-static-core': 5.0.2 '@types/qs': 6.9.17 '@types/serve-static': 1.15.7 @@ -3428,11 +3423,11 @@ snapshots: '@types/mysql@2.15.26': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 - '@types/node@22.9.0': + '@types/node@22.10.1': dependencies: - undici-types: 6.19.8 + undici-types: 6.20.0 '@types/pg-pool@2.0.6': dependencies: @@ -3440,7 +3435,7 @@ snapshots: '@types/pg@8.6.1': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 pg-protocol: 1.7.0 pg-types: 2.2.0 @@ -3451,12 +3446,12 @@ snapshots: '@types/send@0.17.4': dependencies: '@types/mime': 1.3.5 - '@types/node': 22.9.0 + '@types/node': 22.10.1 '@types/serve-static@1.15.7': dependencies: '@types/http-errors': 2.0.4 - '@types/node': 22.9.0 + '@types/node': 22.10.1 '@types/send': 0.17.4 '@types/shimmer@1.2.0': {} @@ -3467,94 +3462,95 @@ snapshots: '@types/tedious@4.0.14': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 '@types/triple-beam@1.3.5': {} '@types/ws@8.5.13': dependencies: - '@types/node': 22.9.0 + '@types/node': 22.10.1 - '@typescript-eslint/eslint-plugin@8.14.0(@typescript-eslint/parser@8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3))(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3)': + '@typescript-eslint/eslint-plugin@8.16.0(@typescript-eslint/parser@8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2))(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2)': dependencies: '@eslint-community/regexpp': 4.12.1 - '@typescript-eslint/parser': 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) - '@typescript-eslint/scope-manager': 8.14.0 - '@typescript-eslint/type-utils': 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) - '@typescript-eslint/utils': 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) - '@typescript-eslint/visitor-keys': 8.14.0 + '@typescript-eslint/parser': 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) + '@typescript-eslint/scope-manager': 8.16.0 + '@typescript-eslint/type-utils': 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) + '@typescript-eslint/utils': 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) + '@typescript-eslint/visitor-keys': 8.16.0 eslint: 9.14.0(jiti@1.21.6) graphemer: 1.4.0 ignore: 5.3.2 natural-compare: 1.4.0 - ts-api-utils: 1.4.0(typescript@5.6.3) + ts-api-utils: 1.4.3(typescript@5.7.2) optionalDependencies: - typescript: 5.6.3 + typescript: 5.7.2 transitivePeerDependencies: - supports-color - '@typescript-eslint/parser@8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3)': + '@typescript-eslint/parser@8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2)': dependencies: - '@typescript-eslint/scope-manager': 8.14.0 - '@typescript-eslint/types': 8.14.0 - '@typescript-eslint/typescript-estree': 8.14.0(typescript@5.6.3) - '@typescript-eslint/visitor-keys': 8.14.0 + '@typescript-eslint/scope-manager': 8.16.0 + '@typescript-eslint/types': 8.16.0 + '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.7.2) + '@typescript-eslint/visitor-keys': 8.16.0 debug: 4.3.7 eslint: 9.14.0(jiti@1.21.6) optionalDependencies: - typescript: 5.6.3 + typescript: 5.7.2 transitivePeerDependencies: - supports-color - '@typescript-eslint/scope-manager@8.14.0': + '@typescript-eslint/scope-manager@8.16.0': dependencies: - '@typescript-eslint/types': 8.14.0 - '@typescript-eslint/visitor-keys': 8.14.0 + '@typescript-eslint/types': 8.16.0 + '@typescript-eslint/visitor-keys': 8.16.0 - '@typescript-eslint/type-utils@8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3)': + '@typescript-eslint/type-utils@8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2)': dependencies: - '@typescript-eslint/typescript-estree': 8.14.0(typescript@5.6.3) - '@typescript-eslint/utils': 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) + '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.7.2) + '@typescript-eslint/utils': 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) debug: 4.3.7 - ts-api-utils: 1.4.0(typescript@5.6.3) + eslint: 9.14.0(jiti@1.21.6) + ts-api-utils: 1.4.3(typescript@5.7.2) optionalDependencies: - typescript: 5.6.3 + typescript: 5.7.2 transitivePeerDependencies: - - eslint - supports-color - '@typescript-eslint/types@8.14.0': {} + '@typescript-eslint/types@8.16.0': {} - '@typescript-eslint/typescript-estree@8.14.0(typescript@5.6.3)': + '@typescript-eslint/typescript-estree@8.16.0(typescript@5.7.2)': dependencies: - '@typescript-eslint/types': 8.14.0 - '@typescript-eslint/visitor-keys': 8.14.0 + '@typescript-eslint/types': 8.16.0 + '@typescript-eslint/visitor-keys': 8.16.0 debug: 4.3.7 fast-glob: 3.3.2 is-glob: 4.0.3 minimatch: 9.0.5 semver: 7.6.3 - ts-api-utils: 1.4.0(typescript@5.6.3) + ts-api-utils: 1.4.3(typescript@5.7.2) optionalDependencies: - typescript: 5.6.3 + typescript: 5.7.2 transitivePeerDependencies: - supports-color - '@typescript-eslint/utils@8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3)': + '@typescript-eslint/utils@8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2)': dependencies: '@eslint-community/eslint-utils': 4.4.1(eslint@9.14.0(jiti@1.21.6)) - '@typescript-eslint/scope-manager': 8.14.0 - '@typescript-eslint/types': 8.14.0 - '@typescript-eslint/typescript-estree': 8.14.0(typescript@5.6.3) + '@typescript-eslint/scope-manager': 8.16.0 + '@typescript-eslint/types': 8.16.0 + '@typescript-eslint/typescript-estree': 8.16.0(typescript@5.7.2) eslint: 9.14.0(jiti@1.21.6) + optionalDependencies: + typescript: 5.7.2 transitivePeerDependencies: - supports-color - - typescript - '@typescript-eslint/visitor-keys@8.14.0': + '@typescript-eslint/visitor-keys@8.16.0': dependencies: - '@typescript-eslint/types': 8.14.0 - eslint-visitor-keys: 3.4.3 + '@typescript-eslint/types': 8.16.0 + eslint-visitor-keys: 4.2.0 '@vladfrangu/async_event_emitter@2.4.6': {} @@ -3677,7 +3673,7 @@ snapshots: chalk: 5.3.0 cli-boxes: 3.0.0 string-width: 7.2.0 - type-fest: 4.27.0 + type-fest: 4.29.0 widest-line: 5.0.0 wrap-ansi: 9.0.0 @@ -3796,10 +3792,10 @@ snapshots: commander@12.1.0: {} - commitizen@4.3.1(@types/node@22.9.0)(typescript@5.6.3): + commitizen@4.3.1(@types/node@22.10.1)(typescript@5.7.2): dependencies: cachedir: 2.3.0 - cz-conventional-changelog: 3.3.0(@types/node@22.9.0)(typescript@5.6.3) + cz-conventional-changelog: 3.3.0(@types/node@22.10.1)(typescript@5.7.2) dedent: 0.7.0 detect-indent: 6.1.0 find-node-modules: 2.1.3 @@ -3844,39 +3840,39 @@ snapshots: cookie@0.7.1: {} - cosmiconfig-typescript-loader@5.1.0(@types/node@22.9.0)(cosmiconfig@9.0.0(typescript@5.6.3))(typescript@5.6.3): + cosmiconfig-typescript-loader@5.1.0(@types/node@22.10.1)(cosmiconfig@9.0.0(typescript@5.7.2))(typescript@5.7.2): dependencies: - '@types/node': 22.9.0 - cosmiconfig: 9.0.0(typescript@5.6.3) + '@types/node': 22.10.1 + cosmiconfig: 9.0.0(typescript@5.7.2) jiti: 1.21.6 - typescript: 5.6.3 + typescript: 5.7.2 optional: true - cosmiconfig@9.0.0(typescript@5.6.3): + cosmiconfig@9.0.0(typescript@5.7.2): dependencies: env-paths: 2.2.1 import-fresh: 3.3.0 js-yaml: 4.1.0 parse-json: 5.2.0 optionalDependencies: - typescript: 5.6.3 + typescript: 5.7.2 - cross-spawn@7.0.5: + cross-spawn@7.0.6: dependencies: path-key: 3.1.1 shebang-command: 2.0.0 which: 2.0.2 - cz-conventional-changelog@3.3.0(@types/node@22.9.0)(typescript@5.6.3): + cz-conventional-changelog@3.3.0(@types/node@22.10.1)(typescript@5.7.2): dependencies: chalk: 2.4.2 - commitizen: 4.3.1(@types/node@22.9.0)(typescript@5.6.3) + commitizen: 4.3.1(@types/node@22.10.1)(typescript@5.7.2) conventional-commit-types: 3.0.0 lodash.map: 4.6.0 longest: 2.0.1 word-wrap: 1.2.5 optionalDependencies: - '@commitlint/load': 19.5.0(@types/node@22.9.0)(typescript@5.6.3) + '@commitlint/load': 19.5.0(@types/node@22.10.1)(typescript@5.7.2) transitivePeerDependencies: - '@types/node' - typescript @@ -3970,7 +3966,7 @@ snapshots: dot-prop@9.0.0: dependencies: - type-fest: 4.27.0 + type-fest: 4.29.0 dotenv@16.4.5: {} @@ -4043,7 +4039,7 @@ snapshots: '@types/json-schema': 7.0.15 ajv: 6.12.6 chalk: 4.1.2 - cross-spawn: 7.0.5 + cross-spawn: 7.0.6 debug: 4.3.7 escape-string-regexp: 4.0.0 eslint-scope: 8.2.0 @@ -4105,7 +4101,7 @@ snapshots: execa@5.1.1: dependencies: - cross-spawn: 7.0.5 + cross-spawn: 7.0.6 get-stream: 6.0.1 human-signals: 2.1.0 is-stream: 2.0.1 @@ -4117,7 +4113,7 @@ snapshots: execa@8.0.0: dependencies: - cross-spawn: 7.0.5 + cross-spawn: 7.0.6 get-stream: 8.0.1 human-signals: 5.0.0 is-stream: 3.0.0 @@ -4129,7 +4125,7 @@ snapshots: execa@8.0.1: dependencies: - cross-spawn: 7.0.5 + cross-spawn: 7.0.6 get-stream: 8.0.1 human-signals: 5.0.0 is-stream: 3.0.0 @@ -4254,10 +4250,10 @@ snapshots: flat-cache@4.0.1: dependencies: - flatted: 3.3.1 + flatted: 3.3.2 keyv: 4.5.4 - flatted@3.3.1: {} + flatted@3.3.2: {} fn.name@1.1.0: {} @@ -4425,7 +4421,7 @@ snapshots: human-signals@5.0.0: {} - husky@9.1.6: {} + husky@9.1.7: {} iconv-lite@0.4.24: dependencies: @@ -4933,7 +4929,7 @@ snapshots: package-json@10.0.1: dependencies: ky: 1.7.2 - registry-auth-token: 5.0.2 + registry-auth-token: 5.0.3 registry-url: 6.0.1 semver: 7.6.3 @@ -4941,8 +4937,6 @@ snapshots: dependencies: callsites: 3.1.0 - parse-duration@1.1.0: {} - parse-json@5.2.0: dependencies: '@babel/code-frame': 7.26.2 @@ -5012,11 +5006,11 @@ snapshots: prelude-ls@1.2.1: {} - prettier@3.3.3: {} + prettier@3.4.1: {} - prisma@5.22.0: + prisma@6.0.0: dependencies: - '@prisma/engines': 5.22.0 + '@prisma/engines': 6.0.0 optionalDependencies: fsevents: 2.3.3 @@ -5094,7 +5088,7 @@ snapshots: reflect-metadata@0.2.2: {} - registry-auth-token@5.0.2: + registry-auth-token@5.0.3: dependencies: '@pnpm/npm-conf': 2.3.1 @@ -5102,14 +5096,14 @@ snapshots: dependencies: rc: 1.2.8 - release-it@17.10.0(typescript@5.6.3): + release-it@17.10.0(typescript@5.7.2): dependencies: '@iarna/toml': 2.2.5 '@octokit/rest': 20.1.1 async-retry: 1.3.3 chalk: 5.3.0 ci-info: 4.1.0 - cosmiconfig: 9.0.0(typescript@5.6.3) + cosmiconfig: 9.0.0(typescript@5.7.2) execa: 8.0.0 git-url-parse: 14.0.0 globby: 14.0.2 @@ -5391,19 +5385,19 @@ snapshots: triple-beam@1.4.1: {} - ts-api-utils@1.4.0(typescript@5.6.3): + ts-api-utils@1.4.3(typescript@5.7.2): dependencies: - typescript: 5.6.3 + typescript: 5.7.2 ts-mixer@6.0.4: {} - tsc-watch@6.2.1(typescript@5.6.3): + tsc-watch@6.2.1(typescript@5.7.2): dependencies: - cross-spawn: 7.0.5 + cross-spawn: 7.0.6 node-cleanup: 2.1.2 ps-tree: 1.2.0 string-argv: 0.3.2 - typescript: 5.6.3 + typescript: 5.7.2 tslib@2.8.1: {} @@ -5415,7 +5409,7 @@ snapshots: type-fest@2.19.0: {} - type-fest@4.27.0: {} + type-fest@4.29.0: {} type-is@1.6.18: dependencies: @@ -5428,20 +5422,20 @@ snapshots: media-typer: 1.1.0 mime-types: 3.0.0 - typescript-eslint@8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3): + typescript-eslint@8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2): dependencies: - '@typescript-eslint/eslint-plugin': 8.14.0(@typescript-eslint/parser@8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3))(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) - '@typescript-eslint/parser': 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) - '@typescript-eslint/utils': 8.14.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.6.3) + '@typescript-eslint/eslint-plugin': 8.16.0(@typescript-eslint/parser@8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2))(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) + '@typescript-eslint/parser': 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) + '@typescript-eslint/utils': 8.16.0(eslint@9.14.0(jiti@1.21.6))(typescript@5.7.2) + eslint: 9.14.0(jiti@1.21.6) optionalDependencies: - typescript: 5.6.3 + typescript: 5.7.2 transitivePeerDependencies: - - eslint - supports-color - typescript@5.6.3: {} + typescript@5.7.2: {} - undici-types@6.19.8: {} + undici-types@6.20.0: {} undici@6.19.8: {} diff --git a/prisma/schema.prisma b/prisma/schema.prisma index 66c3a302..e62d1c16 100644 --- a/prisma/schema.prisma +++ b/prisma/schema.prisma @@ -7,33 +7,22 @@ datasource db { url = env("DATABASE_URL") } -enum HubModeratorPosition { - network_mod - manager +// Enums moved to top for better organization +enum Role { + MODERATOR + MANAGER + OWNER } -type HubRating { - userId String - rating Int @default(0) -} - -type HubModerator { - userId String - position HubModeratorPosition @default(network_mod) -} - -type hubLogChannelAndRole { - channelId String - roleId String? -} - -type userBan { - reason String +enum InfractionType { + BLACKLIST + WARNING } -type RecentLobbyData { - lobbyId String - timestamp Int +enum InfractionStatus { + ACTIVE + REVOKED + APPEALED } enum BlockWordAction { @@ -42,154 +31,160 @@ enum BlockWordAction { SEND_ALERT } -enum InfractionType { - BLACKLIST - WARNING +type LogChannel { + channelId String + roleId String? } -enum InfractionStatus { - ACTIVE - REVOKED - APPEALED +type RecentLobbyData { + lobbyId String + timestamp Int } -model UserInfraction { - id String @id @default(nanoid(10)) @map("_id") - userId String @db.String - hubId String @db.ObjectId - reason String - status InfractionStatus @default(ACTIVE) - type InfractionType @default(BLACKLIST) - dateIssued DateTime @default(now()) // Date when the infraction was issued - expiresAt DateTime? - appealedAt DateTime? - moderatorId String? - userData UserData @relation(fields: [userId], references: [id]) - hub Hub @relation(fields: [hubId], references: [id]) +// Models +model Hub { + id String @id @default(auto()) @map("_id") @db.ObjectId + name String + description String + ownerId String + iconUrl String + bannerUrl String? + private Boolean @default(true) + locked Boolean @default(false) + appealCooldownHours Int @default(168) + settings Int + moderators HubModerator[] + connections Connection[] + logConfig HubLogConfig? + blockWords BlockWord[] + infractions Infraction[] // Combined user and server infractions + invites HubInvite[] + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt - @@index([userId, hubId, status]) + @@unique([name]) + @@index([ownerId]) } -model ServerInfraction { - id String @id @default(nanoid(10)) @map("_id") - serverName String - serverId String - hubId String @db.ObjectId - reason String - status InfractionStatus @default(ACTIVE) - type InfractionType @default(BLACKLIST) - dateIssued DateTime @default(now()) // Date when the infraction was issued - expiresAt DateTime? - appealedAt DateTime? - appealerUserId String? - moderatorId String? - hub Hub @relation(fields: [hubId], references: [id]) +model HubModerator { + id String @id @default(auto()) @map("_id") @db.ObjectId + hubId String @db.ObjectId + userId String @db.String + role Role + hub Hub @relation(fields: [hubId], references: [id]) + user UserData @relation(fields: [userId], references: [id]) - @@index([serverId, hubId, status]) + @@unique([hubId, userId]) } -model connectedList { +model Connection { id String @id @default(auto()) @map("_id") @db.ObjectId - channelId String @unique // channel can be thread, or a normal channel - parentId String? // ID of the parent channel, if it's a thread @map("parentChannelId") + channelId String @unique + parentId String? // Parent channel ID for threads serverId String - connected Boolean - compact Boolean + hubId String @db.ObjectId + connected Boolean @default(true) + compact Boolean @default(false) invite String? - profFilter Boolean + profFilter Boolean @default(false) + createdAt DateTime @default(now()) embedColor String? webhookURL String lastActive DateTime @default(now()) - date DateTime @default(now()) - hub Hub? @relation(fields: [hubId], references: [id]) - hubId String @db.ObjectId + hub Hub @relation(fields: [hubId], references: [id]) - @@index(fields: [channelId, serverId]) + @@unique([channelId, serverId]) + @@index([hubId, channelId]) } -model Hub { - id String @id @default(auto()) @map("_id") @db.ObjectId - name String @unique - description String - rating HubRating[] - ownerId String - iconUrl String - bannerUrl String? - private Boolean @default(true) - locked Boolean @default(false) - appealCooldownHours Int @default(168) // 7 days - createdAt DateTime @default(now()) - settings Int // each bit is a setting - // relations - invites HubInvite[] - moderators HubModerator[] - connections connectedList[] - logConfig HubLogConfig[] - msgBlockList MessageBlockList[] - userInfractions UserInfraction[] - serverInfractions ServerInfraction[] +model Infraction { + id String @id @default(nanoid(10)) @map("_id") + hubId String @db.ObjectId + type InfractionType @default(BLACKLIST) + status InfractionStatus @default(ACTIVE) + moderatorId String + reason String + expiresAt DateTime? + appealedAt DateTime? + appealedBy String? // User ID + + // For user infractions + userId String? @db.String + user UserData? @relation(fields: [userId], references: [id]) + + // For server infractions + serverId String? + serverName String? + + hub Hub @relation(fields: [hubId], references: [id]) + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt - @@index([id, name, ownerId]) + @@index([status, hubId]) } -model MessageBlockList { +model BlockWord { id String @id @default(auto()) @map("_id") @db.ObjectId + hubId String @db.ObjectId name String - words String + words String // words separated by comma createdBy String + actions BlockWordAction[] createdAt DateTime @default(now()) updatedAt DateTime @updatedAt - actions BlockWordAction[] @default([]) - hub Hub @relation(fields: [hubId], references: [id]) - hubId String @db.ObjectId - @@index([id, words]) + hub Hub @relation(fields: [hubId], references: [id]) + + @@index([hubId]) + @@index([words]) } model HubLogConfig { - id String @id @default(auto()) @map("_id") @db.ObjectId - modLogs String? - joinLeaves String? - profanity String? - appeals hubLogChannelAndRole? - reports hubLogChannelAndRole? - networkAlerts hubLogChannelAndRole? - hub Hub @relation(fields: [hubId], references: [id]) - hubId String @unique @db.ObjectId - - @@index([id, hubId]) + id String @id @default(auto()) @map("_id") @db.ObjectId + hubId String @unique @db.ObjectId + modLogs LogChannel? + joinLeaves LogChannel? + profanity LogChannel? + appeals LogChannel? + reports LogChannel? + networkAlerts LogChannel? + hub Hub @relation(fields: [hubId], references: [id]) } model HubInvite { code String @id @default(nanoid(10)) @map("_id") + hubId String @db.ObjectId expires DateTime hub Hub @relation(fields: [hubId], references: [id]) - hubId String @db.ObjectId - @@index([code, hubId]) + @@index([hubId]) } model UserData { - id String @id @map("_id") @db.String - voteCount Int @default(0) + id String @id @map("_id") @db.String username String? locale String? + voteCount Int @default(0) lastVoted DateTime? - banMeta userBan? - mentionOnReply Boolean @default(true) - acceptedRules Boolean @default(false) - infractions UserInfraction[] + banReason String? + mentionOnReply Boolean @default(true) + acceptedRules Boolean @default(false) + infractions Infraction[] + modPositions HubModerator[] + updatedAt DateTime @updatedAt } model LobbyChatHistory { id String @id @default(auto()) @map("_id") @db.ObjectId serverId String channelId String - users String[] lobbyId String - date DateTime @default(now()) + users String[] + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt - @@index([serverId, channelId, lobbyId]) + @@index([serverId, channelId]) + @@index([lobbyId]) } model ServerHistory { diff --git a/src/commands/context-menu/deleteMsg.ts b/src/commands/context-menu/deleteMsg.ts index af5bc5a4..d3f28496 100644 --- a/src/commands/context-menu/deleteMsg.ts +++ b/src/commands/context-menu/deleteMsg.ts @@ -1,17 +1,17 @@ -import Constants, { emojis } from '#utils/Constants.js'; import BaseCommand from '#main/core/BaseCommand.js'; -import db from '#main/utils/Db.js'; +import HubManager from '#main/managers/HubManager.js'; +import { HubService } from '#main/services/HubService.js'; import { findOriginalMessage, getBroadcasts, getOriginalMessage, OriginalMessage, } from '#main/utils/network/messageUtils.js'; -import { isStaffOrHubMod } from '#utils/hub/utils.js'; +import Constants, { emojis } from '#utils/Constants.js'; import { logMsgDelete } from '#utils/hub/logger/ModLogs.js'; +import { isStaffOrHubMod } from '#utils/hub/utils.js'; import { t } from '#utils/Locale.js'; import { deleteMessageFromHub, isDeleteInProgress } from '#utils/moderation/deleteMessage.js'; -import { Hub, HubLogConfig } from '@prisma/client'; import { ApplicationCommandType, InteractionContextType, @@ -51,7 +51,7 @@ export default class DeleteMessage extends BaseCommand { private async processMessageDeletion( interaction: MessageContextMenuCommandInteraction, originalMsg: OriginalMessage, - hub: Hub & { logConfig: HubLogConfig[] }, + hub: HubManager, ): Promise { const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); @@ -77,15 +77,15 @@ export default class DeleteMessage extends BaseCommand { await this.logDeletion(interaction, hub, originalMsg); } - private async fetchHub(hubId?: string) { + private async fetchHub(hubId?: string): Promise { if (!hubId) return null; - return await db.hub.findUnique({ where: { id: hubId }, include: { logConfig: true } }); + return await new HubService().fetchHub(hubId); } private async validateMessage( interaction: MessageContextMenuCommandInteraction, originalMsg: OriginalMessage | null, - hub: (Hub & { logConfig: HubLogConfig[] }) | null, + hub: HubManager | null, ) { const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); @@ -106,7 +106,7 @@ export default class DeleteMessage extends BaseCommand { if ( interaction.user.id !== originalMsg.authorId && - !isStaffOrHubMod(interaction.user.id, hub) + !await isStaffOrHubMod(interaction.user.id, hub) ) { await interaction.editReply(t('errors.notMessageAuthor', locale, { emoji: emojis.no })); return false; @@ -117,10 +117,10 @@ export default class DeleteMessage extends BaseCommand { private async logDeletion( interaction: MessageContextMenuCommandInteraction, - hub: Hub & { logConfig: HubLogConfig[] }, + hub: HubManager, originalMsg: OriginalMessage, ): Promise { - if (!isStaffOrHubMod(interaction.user.id, hub)) return; + if (!await isStaffOrHubMod(interaction.user.id, hub)) return; const { targetMessage } = interaction; const messageContent = @@ -132,11 +132,17 @@ export default class DeleteMessage extends BaseCommand { targetMessage.embeds.at(0)?.image?.url ?? targetMessage.content.match(Constants.Regex.ImageURL)?.[0]; - await logMsgDelete(interaction.client, messageContent, hub, { - userId: originalMsg.authorId, - serverId: originalMsg.guildId, - modName: interaction.user.username, - imageUrl, - }); + await logMsgDelete( + interaction.client, + messageContent, + hub.data.name, + await hub.fetchLogConfig(), + { + userId: originalMsg.authorId, + serverId: originalMsg.guildId, + modName: interaction.user.username, + imageUrl, + }, + ); } } diff --git a/src/commands/context-menu/editMsg.ts b/src/commands/context-menu/editMsg.ts index 6da87ad2..3e4807ae 100644 --- a/src/commands/context-menu/editMsg.ts +++ b/src/commands/context-menu/editMsg.ts @@ -1,7 +1,6 @@ /* eslint-disable complexity */ import BaseCommand from '#main/core/BaseCommand.js'; import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; -import HubSettingsManager from '#main/managers/HubSettingsManager.js'; import { SerializedHubSettings } from '#main/modules/BitFields.js'; import VoteBasedLimiter from '#main/modules/VoteBasedLimiter.js'; import { HubService } from '#main/services/HubService.js'; @@ -82,7 +81,7 @@ export default class EditMessage extends BaseCommand { } const modal = new ModalBuilder() - .setCustomId(new CustomID().setIdentifier('editMsg').addArgs(target.id).toString()) + .setCustomId(new CustomID().setIdentifier('editMsg').setArgs(target.id).toString()) .setTitle('Edit Message') .addComponents( new ActionRowBuilder().addComponents( @@ -146,11 +145,10 @@ export default class EditMessage extends BaseCommand { // Get the new message input from the user const userInput = interaction.fields.getTextInputValue('newMessage'); - const settingsManager = new HubSettingsManager(originalMsgData.hubId, hub.settings); - const messageToEdit = this.sanitizeMessage(userInput, settingsManager.getAllSettings()); + const messageToEdit = this.sanitizeMessage(userInput, hub.settings.getAll()); // Check if the message contains invite links - if (settingsManager.getSetting('BlockInvites') && containsInviteLinks(messageToEdit)) { + if (hub.settings.has('BlockInvites') && containsInviteLinks(messageToEdit)) { await interaction.editReply( t('errors.inviteLinks', await this.getLocale(interaction), { emoji: emojis.no }), ); @@ -177,7 +175,7 @@ export default class EditMessage extends BaseCommand { // Find all the messages that need to be edited const broadcastedMsgs = Object.values(await getBroadcasts(target.id, originalMsgData.hubId)); - const channelSettingsArr = await db.connectedList.findMany({ + const channelSettingsArr = await db.connection.findMany({ where: { channelId: { in: broadcastedMsgs.map((c) => c.channelId) } }, }); diff --git a/src/commands/context-menu/messageInfo.ts b/src/commands/context-menu/messageInfo.ts index 695c981f..29d67d6e 100644 --- a/src/commands/context-menu/messageInfo.ts +++ b/src/commands/context-menu/messageInfo.ts @@ -2,6 +2,7 @@ import BaseCommand from '#main/core/BaseCommand.js'; import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; import { modPanelButton } from '#main/interactions/ShowModPanel.js'; import HubLogManager from '#main/managers/HubLogManager.js'; +import HubManager from '#main/managers/HubManager.js'; import { HubService } from '#main/services/HubService.js'; import { findOriginalMessage, getOriginalMessage } from '#main/utils/network/messageUtils.js'; import type { RemoveMethods } from '#types/CustomClientProps.d.ts'; @@ -14,7 +15,7 @@ import { InfoEmbed } from '#utils/EmbedUtils.js'; import { sendHubReport } from '#utils/hub/logger/Report.js'; import { isStaffOrHubMod } from '#utils/hub/utils.js'; import { supportedLocaleCodes, t } from '#utils/Locale.js'; -import type { connectedList, Hub } from '@prisma/client'; +import { Connection } from '@prisma/client'; import { ActionRow, ActionRowBuilder, @@ -42,13 +43,13 @@ import { type LocaleInfo = { locale: supportedLocaleCodes }; type AuthorInfo = { author: User }; type ServerInfo = { server: RemoveMethods | undefined }; -type HubInfo = { hub: Hub | null }; +type HubInfo = { hub: HubManager | null }; type MsgInfo = { messageId: string }; type UserInfoOpts = LocaleInfo & AuthorInfo; type MsgInfoOpts = AuthorInfo & ServerInfo & LocaleInfo & HubInfo & MsgInfo; type ReportOpts = LocaleInfo & HubInfo & MsgInfo; -type ServerInfoOpts = LocaleInfo & ServerInfo & { connection: connectedList | undefined }; +type ServerInfoOpts = LocaleInfo & ServerInfo & { connection: Connection | undefined }; export default class MessageInfo extends BaseCommand { readonly data: RESTPostAPIApplicationCommandsJSONBody = { @@ -80,7 +81,7 @@ export default class MessageInfo extends BaseCommand { .addFields([ { name: 'Sender', value: codeBlock(author.username), inline: true }, { name: 'From Server', value: codeBlock(`${server?.name}`), inline: true }, - { name: 'Which Hub?', value: codeBlock(hub.name), inline: true }, + { name: 'Which Hub?', value: codeBlock(hub.data.name), inline: true }, { name: 'Message ID', value: codeBlock(originalMsg.messageId), inline: true }, { name: 'Sent At', value: time(new Date(originalMsg.timestamp), 't'), inline: true }, ]) @@ -91,7 +92,7 @@ export default class MessageInfo extends BaseCommand { (c) => c.connected && c.serverId === originalMsg.guildId, ); const components = this.buildButtons(target.id, locale, { - buildModActions: isStaffOrHubMod(interaction.user.id, hub), + buildModActions: await isStaffOrHubMod(interaction.user.id, hub), inviteButtonUrl: connection?.invite, }); @@ -294,7 +295,7 @@ export default class MessageInfo extends BaseCommand { .addFields([ { name: 'Sender', value: codeBlock(author.username), inline: true }, { name: 'From Server', value: codeBlock(`${server?.name}`), inline: true }, - { name: 'Which Hub?', value: codeBlock(hub.name), inline: true }, + { name: 'Which Hub?', value: codeBlock(hub.data.name), inline: true }, { name: 'Message ID', value: codeBlock(messageId), inline: true }, { name: 'Sent At', value: time(message.createdAt, 't'), inline: true }, ]) diff --git a/src/commands/context-menu/modActions.ts b/src/commands/context-menu/modActions.ts index 1c51f65a..968de653 100644 --- a/src/commands/context-menu/modActions.ts +++ b/src/commands/context-menu/modActions.ts @@ -57,7 +57,7 @@ export default class BlacklistCtxMenu extends BaseCommand { ) { const hubService = new HubService(db); const hub = await hubService.fetchHub(originalMsg.hubId); - if (!hub || !isStaffOrHubMod(interaction.user.id, hub)) { + if (!hub || !await isStaffOrHubMod(interaction.user.id, hub)) { await this.replyEmbed(interaction, t('errors.messageNotSentOrExpired', locale), { ephemeral: true, edit: true, diff --git a/src/commands/prefix/deleteMsg.ts b/src/commands/prefix/deleteMsg.ts index 4a9aa326..15597860 100644 --- a/src/commands/prefix/deleteMsg.ts +++ b/src/commands/prefix/deleteMsg.ts @@ -40,7 +40,7 @@ export default class DeleteMsgCommand extends BasePrefixCommand { const hub = await hubService.fetchHub(originalMsg.hubId); if ( !hub || // Check if the hub exists - !isStaffOrHubMod(message.author.id, hub) || // Check if the user is a staff or hub mod + !await isStaffOrHubMod(message.author.id, hub) || // Check if the user is a staff or hub mod originalMsg.authorId !== message.author.id // Only then check if the user is the author of the message ) { const embed = new EmbedBuilder() diff --git a/src/commands/prefix/modpanel.ts b/src/commands/prefix/modpanel.ts index 86d92f98..7ebbd57e 100644 --- a/src/commands/prefix/modpanel.ts +++ b/src/commands/prefix/modpanel.ts @@ -36,7 +36,7 @@ export default class BlacklistPrefixCommand extends BasePrefixCommand { const hubService = new HubService(db); const hub = await hubService.fetchHub(originalMessage.hubId); - if (!hub || !isStaffOrHubMod(message.author.id, hub)) { + if (!hub || !await isStaffOrHubMod(message.author.id, hub)) { const embed = new EmbedBuilder() .setColor('Red') .setDescription(`${emojis.no} You do not have permission to use this command.`); diff --git a/src/commands/slash/Information/about.ts b/src/commands/slash/Information/about.ts index 07b1f070..0a227ee8 100644 --- a/src/commands/slash/Information/about.ts +++ b/src/commands/slash/Information/about.ts @@ -90,20 +90,20 @@ export default class About extends BaseCommand { ${creditsDivider} ✨ **Deserving Mentions:** - ${emojis.dotBlue} @${usernames[6]} (made our cute mascot chipi ${mascotEmojis.flushed}) - ${emojis.dotBlue} @${usernames[7]} (top [voter](${Constants.Links.Vote}) of all time ${emojis.topggSparkles}) + ${emojis.dotBlue} @${usernames[4]} (maker of our cute mascot chipi ${mascotEmojis.smile}) + ${emojis.dotBlue} @${usernames[5]} ([top voter](${Constants.Links.Vote}) of all time ${emojis.topggSparkles}) ${badgeEmojis.Developer} **Developers:** ${emojis.dotBlue} @${usernames[0]} - ${badgeEmojis.Staff} **Staff: ([Recruiting!](${Constants.Links.Website}/apply))** + ${badgeEmojis.Staff} **Staff: ([Check Applications!](${Constants.Links.Website}/apply))** ${emojis.dotBlue} @${usernames[1]} ${emojis.dotBlue} @${usernames[2]} ${emojis.dotBlue} @${usernames[3]} ${emojis.dotBlue} @${usernames[4]} ${emojis.dotBlue} @${usernames[5]} ${creditsDivider} - `, + `, ) .setFooter({ text: ` InterChat v${interaction.client.version} • Made with ❤️ by the InterChat Team`, diff --git a/src/commands/slash/Main/blacklist/index.ts b/src/commands/slash/Main/blacklist/index.ts index 8e4bf186..5ee79a9b 100644 --- a/src/commands/slash/Main/blacklist/index.ts +++ b/src/commands/slash/Main/blacklist/index.ts @@ -1,21 +1,23 @@ +import BaseCommand from '#main/core/BaseCommand.js'; +import HubManager from '#main/managers/HubManager.js'; +import { HubService } from '#main/services/HubService.js'; +import { isStaffOrHubMod } from '#main/utils/hub/utils.js'; import { emojis } from '#utils/Constants.js'; +import db from '#utils/Db.js'; import { supportedLocaleCodes, t } from '#utils/Locale.js'; -import { Hub } from '@prisma/client'; +import { getReplyMethod, handleError } from '#utils/Utils.js'; import { - type AutocompleteInteraction, - type ChatInputCommandInteraction, - type RESTPostAPIApplicationCommandsJSONBody, - type Snowflake, type APIApplicationCommandBasicOption, ApplicationCommandOptionChoiceData, ApplicationCommandOptionType, + type AutocompleteInteraction, + type ChatInputCommandInteraction, Collection, EmbedBuilder, + type RESTPostAPIApplicationCommandsJSONBody, + type Snowflake, time, } from 'discord.js'; -import BaseCommand from '#main/core/BaseCommand.js'; -import db from '#utils/Db.js'; -import { checkIfStaff, escapeRegexChars, getReplyMethod, handleError } from '#utils/Utils.js'; export default class BlacklistCommand extends BaseCommand { static readonly subcommands = new Collection(); @@ -152,6 +154,8 @@ export default class BlacklistCommand extends BaseCommand { ], }; + protected readonly hubService = new HubService(); + async execute(interaction: ChatInputCommandInteraction): Promise { const subCommandName = interaction.options.getSubcommand(); const subcommand = BlacklistCommand.subcommands.get(subCommandName); @@ -167,9 +171,9 @@ export default class BlacklistCommand extends BaseCommand { if (hubOpt?.focused && typeof hubOpt.value === 'string') { choices = (await this.findHubsByName(hubOpt?.value, interaction.user.id))?.map( - ({ name }) => ({ - name, - value: name, + ({ data }) => ({ + name: data.name, + value: data.name, }), ); } @@ -203,6 +207,7 @@ export default class BlacklistCommand extends BaseCommand { choices = await this.searchBlacklistedServers(hub.id, serverOpt.value); break; } + default: break; } @@ -212,13 +217,11 @@ export default class BlacklistCommand extends BaseCommand { } protected async getHub({ name, userId }: { name: string | null; userId: Snowflake }) { - const allHubs = await db.hub.findMany({ - where: { - name: name ?? undefined, - OR: [{ ownerId: userId }, { moderators: { some: { userId } } }], - }, - }); + const allHubs = (await this.hubService.fetchModeratedHubs(userId)).filter((h) => + name ? h.data.name === name : true, + ); + // FIXME: what was I smoking when I wrote this? if (allHubs.length > 1) return 'exceeds max length'; // assign first value of the hub query @@ -250,9 +253,9 @@ export default class BlacklistCommand extends BaseCommand { protected isValidHub( interaction: ChatInputCommandInteraction, - hub: Hub | string | null, + hub: HubManager | string | null, locale: supportedLocaleCodes = 'en', - ): hub is Hub { + ): hub is HubManager { const hiddenOpt = { ephemeral: true }; if (!hub) { this.replyEmbed(interaction, t('hub.notFound_mod', locale), hiddenOpt); @@ -270,60 +273,60 @@ export default class BlacklistCommand extends BaseCommand { return true; } - protected isStaffOrHubMod(userId: string, hub: Hub | null): hub is Hub { - const isHubMod = - hub?.ownerId === userId || hub?.moderators.find((mod) => mod.userId === userId); - const isStaff = checkIfStaff(userId); - - return Boolean(!hub?.private ? isHubMod || isStaff : isHubMod); - } - private async searchBlacklistedServers(hubId: string, nameOrId: string) { - const allServers = await db.serverInfraction.findMany({ + const allServers = await db.infraction.findMany({ where: { hubId, status: 'ACTIVE', type: 'BLACKLIST', OR: [ { serverName: { mode: 'insensitive', contains: nameOrId } }, - { id: { mode: 'insensitive', contains: nameOrId } }, + { serverId: { mode: 'insensitive', contains: nameOrId } }, ], }, take: 25, }); - return allServers.map(({ serverName, serverId }) => ({ name: serverName, value: serverId })); + return allServers + .filter((infraction) => Boolean(infraction.userId)) + .map(({ serverName, serverId }) => ({ + name: serverName, + value: serverId, + })) as ApplicationCommandOptionChoiceData[]; } private async searchBlacklistedUsers(hubId: string, nameOrId: string) { - const filteredUsers = await db.userInfraction.findMany({ + const filteredUsers = await db.infraction.findMany({ where: { hubId, status: 'ACTIVE', type: 'BLACKLIST', OR: [ - { userData: { username: { mode: 'insensitive', contains: nameOrId } } }, - { id: { mode: 'insensitive', contains: nameOrId } }, + { user: { username: { mode: 'insensitive', contains: nameOrId } } }, + { userId: { mode: 'insensitive', contains: nameOrId } }, ], }, - include: { userData: { select: { username: true } } }, + include: { user: { select: { username: true } } }, take: 25, }); - return filteredUsers.map((user) => ({ - name: `${user.userData.username ?? 'Unknown User'} - ${user.userId}`, - value: user.userId, - })); + return filteredUsers + .filter((infraction) => Boolean(infraction.userId)) + .map(({ user, userId }) => ({ + name: `${user?.username ?? 'Unknown User'} - ${userId}`, + value: userId, + })) as ApplicationCommandOptionChoiceData[]; } - private async findHubsByName(name: string, ownerId: string, limit?: number): Promise; - private async findHubsByName(name: string, ownerId: string, limit: 1): Promise; - private async findHubsByName(name: string, ownerId: string, limit?: number) { - const hubs = await db.hub.findMany({ - where: { name: { mode: 'insensitive', contains: escapeRegexChars(name) } }, - take: limit ?? 25, - }); + protected async findHubsByName( + name: string, + modId: string, + limit?: number, + ): Promise; + protected async findHubsByName(name: string, modId: string, limit: 1): Promise; + protected async findHubsByName(name: string, modId: string, limit = 25) { + const hubs = await this.hubService.findHubsByName(name, { insensitive: true, take: limit }); - if (limit === 1 && hubs.length > 0) return hubs[0]; - return hubs.filter((hub) => this.isStaffOrHubMod(ownerId, hub)); + if (limit === 1) return hubs.at(0) ?? null; + return await Promise.all(hubs.filter((h) => isStaffOrHubMod(modId, h))); } } diff --git a/src/commands/slash/Main/blacklist/list.ts b/src/commands/slash/Main/blacklist/list.ts index 186e00eb..cb5b570a 100644 --- a/src/commands/slash/Main/blacklist/list.ts +++ b/src/commands/slash/Main/blacklist/list.ts @@ -1,49 +1,38 @@ +import { Pagination } from '#main/modules/Pagination.js'; import Constants, { emojis } from '#utils/Constants.js'; import db from '#utils/Db.js'; import { type supportedLocaleCodes, t } from '#utils/Locale.js'; -import { Pagination } from '#main/modules/Pagination.js'; import { toTitleCase } from '#utils/Utils.js'; +import { Infraction } from '@prisma/client'; import { type ChatInputCommandInteraction, EmbedBuilder, time, User } from 'discord.js'; import BlacklistCommand from './index.js'; -import type { ServerInfraction, UserInfraction } from '@prisma/client'; // Type guard -const isServerType = (list: ServerInfraction | UserInfraction) => list && 'serverName' in list; +const isServerType = (list: Infraction) => list.serverId && list.serverName; export default class ListBlacklists extends BlacklistCommand { async execute(interaction: ChatInputCommandInteraction) { await interaction.deferReply(); const hubName = interaction.options.getString('hub', true); - const hubInDb = await db.hub.findFirst({ - where: { - name: hubName, - OR: [ - { ownerId: interaction.user.id }, - { moderators: { some: { userId: interaction.user.id } } }, - ], - }, - }); + const hub = await this.findHubsByName(hubName, interaction.user.id, 1); + const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); - if (!hubInDb) { + if (!hub) { await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no })); return; } - const blacklistType = interaction.options.getString('type') as 'server' | 'user'; - const hubId = hubInDb.id; + const hubId = hub.id; const query = { where: { hubId, type: 'BLACKLIST', status: 'ACTIVE' } } as const; - const list = - blacklistType === 'server' - ? await db.serverInfraction.findMany(query) - : await db.userInfraction.findMany({ - where: query.where, - orderBy: { expiresAt: 'desc' }, - include: { userData: { select: { username: true } } }, - }); + const list = await db.infraction.findMany({ + where: query.where, + orderBy: { expiresAt: 'desc' }, + include: { user: { select: { username: true } } }, + }); - const options = { LIMIT: 5, iconUrl: hubInDb.iconUrl }; + const options = { LIMIT: 5, iconUrl: hub.data.iconUrl }; const fields = []; let counter = 0; @@ -80,7 +69,7 @@ export default class ListBlacklists extends BlacklistCommand { } private createFieldData( - data: ServerInfraction | (UserInfraction & { userData: { username: string | null } }), + data: Infraction & { user: { username: string | null } | null }, type: 'user' | 'server', { moderator, @@ -90,10 +79,14 @@ export default class ListBlacklists extends BlacklistCommand { locale: supportedLocaleCodes; }, ) { + const name = isServerType(data) + ? (data.serverName ?? 'Unknown Server.') + : (data.user?.username ?? 'Unknown User.'); + return { - name: (isServerType(data) ? data.serverName : data.userData.username) ?? 'Unknown User.', + name, value: t(`blacklist.list.${type}`, locale, { - id: 'userId' in data ? data.userId : data.serverId, + id: (data.userId ?? data.serverId) as string, moderator: moderator ? `@${moderator.username} (${moderator.id})` : 'Unknown', reason: `${data?.reason}`, expires: !data?.expiresAt diff --git a/src/commands/slash/Main/blacklist/server.ts b/src/commands/slash/Main/blacklist/server.ts index e8da2951..ccd1502f 100644 --- a/src/commands/slash/Main/blacklist/server.ts +++ b/src/commands/slash/Main/blacklist/server.ts @@ -1,6 +1,6 @@ import { emojis } from '#utils/Constants.js'; import BlacklistManager from '#main/managers/BlacklistManager.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; + import { deleteConnections } from '#utils/ConnectedListUtils.js'; import { logServerUnblacklist } from '#utils/hub/logger/ModLogs.js'; import { t } from '#utils/Locale.js'; @@ -24,7 +24,7 @@ export default class extends BlacklistCommand { const subCommandGroup = interaction.options.getSubcommandGroup(); const serverId = interaction.options.getString('server', true); - const blacklistManager = new BlacklistManager(new ServerInfractionManager(serverId)); + const blacklistManager = new BlacklistManager('server', serverId); if (subCommandGroup === 'add') { const reason = interaction.options.getString('reason', true); @@ -85,11 +85,11 @@ export default class extends BlacklistCommand { // Using name from DB since the bot can't access server through API. await this.replyEmbed( interaction, - t('blacklist.removed', locale, { emoji: emojis.delete, name: result.serverName }), + t('blacklist.removed', locale, { emoji: emojis.delete, name: result.serverName ?? 'Unknown Server.' }), ); // send log to hub's log channel - await logServerUnblacklist(interaction.client, hub.id, { + await logServerUnblacklist(interaction.client, hub, { id: serverId, mod: interaction.user, }); @@ -101,7 +101,7 @@ export default class extends BlacklistCommand { serverId: Snowflake, opts: { duration?: number }, ) { - const blacklistManager = new BlacklistManager(new ServerInfractionManager(serverId)); + const blacklistManager = new BlacklistManager('server', serverId); const blacklist = await blacklistManager.fetchBlacklist(hubId); const hiddenOpt = { ephemeral: true }; diff --git a/src/commands/slash/Main/blacklist/user.ts b/src/commands/slash/Main/blacklist/user.ts index bd97fb20..c2601808 100644 --- a/src/commands/slash/Main/blacklist/user.ts +++ b/src/commands/slash/Main/blacklist/user.ts @@ -1,5 +1,5 @@ import BlacklistManager from '#main/managers/BlacklistManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; + import { emojis } from '#utils/Constants.js'; import { logUserUnblacklist } from '#utils/hub/logger/ModLogs.js'; import { t } from '#utils/Locale.js'; @@ -7,6 +7,7 @@ import { sendBlacklistNotif } from '#utils/moderation/blacklistUtils.js'; import type { ChatInputCommandInteraction, User } from 'discord.js'; import BlacklistCommand from './index.js'; import ms from 'ms'; +import { HubService } from '#main/services/HubService.js'; export default class extends BlacklistCommand { async execute(interaction: ChatInputCommandInteraction) { @@ -27,7 +28,7 @@ export default class extends BlacklistCommand { if (subcommandGroup === 'add') { const user = interaction.options.getUser('user', true); - const blacklistManager = new BlacklistManager(new UserInfractionManager(user.id)); + const blacklistManager = new BlacklistManager('user', user.id); const passedChecks = await this.runUserAddChecks(interaction, blacklistManager, { hubId: hub.id, @@ -58,7 +59,7 @@ export default class extends BlacklistCommand { } else if (subcommandGroup === 'remove') { const userId = interaction.options.getString('user', true); - const blacklistManager = new BlacklistManager(new UserInfractionManager(userId)); + const blacklistManager = new BlacklistManager('user', userId); const result = await this.removeUserBlacklist(interaction, blacklistManager, userId, { hubId: hub.id, @@ -109,9 +110,10 @@ export default class extends BlacklistCommand { opts: { hubId: string; reason: string }, ) { const revoked = await blacklistManager.removeBlacklist(opts.hubId); + const hub = await new HubService().fetchHub(opts.hubId); - if (revoked) { - await logUserUnblacklist(interaction.client, opts.hubId, { + if (revoked && hub) { + await logUserUnblacklist(interaction.client, hub, { id: userId, mod: interaction.user, reason: opts.reason, diff --git a/src/commands/slash/Main/connection/edit.ts b/src/commands/slash/Main/connection/edit.ts index e6a7935b..f707d559 100644 --- a/src/commands/slash/Main/connection/edit.ts +++ b/src/commands/slash/Main/connection/edit.ts @@ -34,7 +34,7 @@ export default class ConnectionEditCommand extends Connection { interaction.options.getString('channel')?.replace(Constants.Regex.ChannelMention, '') ?? interaction.channelId; - const isInDb = await db.connectedList.findFirst({ where: { channelId } }); + const isInDb = await db.connection.findFirst({ where: { channelId } }); const locale = await this.getLocale(interaction); if (!isInDb) { @@ -161,7 +161,7 @@ export default class ConnectionEditCommand extends Connection { return; } - const connection = await db.connectedList.findFirst({ where: { channelId } }); + const connection = await db.connection.findFirst({ where: { channelId } }); if (!channelId || !connection) { await interaction.reply({ content: t('connection.channelNotFound', locale, { emoji: emojis.no }), @@ -183,7 +183,7 @@ export default class ConnectionEditCommand extends Connection { const modal = new ModalBuilder() .setTitle('Add Invite Link') .setCustomId( - new CustomID().setIdentifier('connectionModal', 'invite').addArgs(channelId).toString(), + new CustomID().setIdentifier('connectionModal', 'invite').setArgs(channelId).toString(), ) .addComponents( new ActionRowBuilder().addComponents( @@ -205,7 +205,7 @@ export default class ConnectionEditCommand extends Connection { .setCustomId( new CustomID() .setIdentifier('connectionModal', 'embed_color') - .addArgs(channelId) + .setArgs(channelId) .toString(), ) .addComponents( @@ -274,7 +274,7 @@ export default class ConnectionEditCommand extends Connection { return; } - const alreadyConnected = await db.connectedList.findFirst({ + const alreadyConnected = await db.connection.findFirst({ where: { channelId: newChannel.id }, }); diff --git a/src/commands/slash/Main/connection/index.ts b/src/commands/slash/Main/connection/index.ts index f2f65ee7..0b678855 100644 --- a/src/commands/slash/Main/connection/index.ts +++ b/src/commands/slash/Main/connection/index.ts @@ -79,7 +79,7 @@ export default class Connection extends BaseCommand { async autocomplete(interaction: AutocompleteInteraction): Promise { const focusedValue = escapeRegexChars(interaction.options.getFocused()); - const isInDb = await db.connectedList.findMany({ + const isInDb = await db.connection.findMany({ where: { serverId: interaction.guild?.id, OR: [ diff --git a/src/commands/slash/Main/connection/list.ts b/src/commands/slash/Main/connection/list.ts index 50cabf3a..9efc93e1 100644 --- a/src/commands/slash/Main/connection/list.ts +++ b/src/commands/slash/Main/connection/list.ts @@ -2,13 +2,13 @@ import Constants, { emojis } from '#utils/Constants.js'; import { Pagination } from '#main/modules/Pagination.js'; import db from '#utils/Db.js'; import { t } from '#utils/Locale.js'; -import { connectedList, Hub } from '@prisma/client'; +import { Connection, Hub } from '@prisma/client'; import { ChatInputCommandInteraction, EmbedBuilder, EmbedField } from 'discord.js'; import ConnectionCommand from './index.js'; export default class extends ConnectionCommand { async execute(interaction: ChatInputCommandInteraction): Promise { - const connections = await db.connectedList.findMany({ + const connections = await db.connection.findMany({ where: { serverId: interaction.guild?.id }, include: { hub: true }, }); @@ -34,7 +34,7 @@ export default class extends ConnectionCommand { } private createPaginatedEmbeds( - connections: (connectedList & { hub: Hub | null })[], + connections: (Connection & { hub: Hub | null })[], description: string, fieldsPerPage = 25, ) { @@ -50,7 +50,7 @@ export default class extends ConnectionCommand { return pages; } - private getField(connection: connectedList & { hub: Hub | null }) { + private getField(connection: Connection & { hub: Hub | null }) { return { name: `${connection.hub?.name} ${connection.connected ? emojis.connect : emojis.disconnect}`, value: `<#${connection.channelId}>`, diff --git a/src/commands/slash/Main/connection/pause.ts b/src/commands/slash/Main/connection/pause.ts index 215d8eb0..b86a38ce 100644 --- a/src/commands/slash/Main/connection/pause.ts +++ b/src/commands/slash/Main/connection/pause.ts @@ -14,7 +14,7 @@ import Connection from './index.js'; export default class Pause extends Connection { override async execute(interaction: ChatInputCommandInteraction): Promise { const channelId = interaction.options.getString('channel') ?? interaction.channelId; - const connected = await db.connectedList.findFirst({ where: { channelId } }); + const connected = await db.connection.findFirst({ where: { channelId } }); const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); diff --git a/src/commands/slash/Main/connection/unpause.ts b/src/commands/slash/Main/connection/unpause.ts index cf1b6c37..a7a91bd6 100644 --- a/src/commands/slash/Main/connection/unpause.ts +++ b/src/commands/slash/Main/connection/unpause.ts @@ -15,7 +15,7 @@ import Connection from './index.js'; export default class Unpause extends Connection { override async execute(interaction: ChatInputCommandInteraction): Promise { const channelId = interaction.options.getString('channel') ?? interaction.channelId; - const connected = await db.connectedList.findFirst({ where: { channelId } }); + const connected = await db.connection.findFirst({ where: { channelId } }); const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); diff --git a/src/commands/slash/Main/hub/announce.ts b/src/commands/slash/Main/hub/announce.ts index c3b9463e..52a2be6d 100644 --- a/src/commands/slash/Main/hub/announce.ts +++ b/src/commands/slash/Main/hub/announce.ts @@ -1,6 +1,9 @@ -import { emojis } from '#utils/Constants.js'; +import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; +import { HubService } from '#main/services/HubService.js'; +import { CustomID } from '#main/utils/CustomID.js'; import db from '#main/utils/Db.js'; -import { isHubManager, sendToHub } from '#main/utils/hub/utils.js'; +import { sendToHub } from '#main/utils/hub/utils.js'; +import { emojis } from '#utils/Constants.js'; import { ActionRowBuilder, ChatInputCommandInteraction, @@ -11,18 +14,20 @@ import { TextInputStyle, } from 'discord.js'; import HubCommand from './index.js'; -import { CustomID } from '#main/utils/CustomID.js'; -import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; -import { HubService } from '#main/services/HubService.js'; export default class AnnounceCommand extends HubCommand { readonly cooldown = 1 * 60 * 1000; async execute(interaction: ChatInputCommandInteraction) { const hubName = interaction.options.getString('hub', true); - const hub = await db.hub.findFirst({ where: { name: hubName } }); - if (!hub || !isHubManager(interaction.user.id, hub)) { - await this.replyEmbed(interaction, 'hub.notFound_mod', { ephemeral: true, t: { emoji: emojis.no } }); + const hubService = new HubService(); + const hub = (await hubService.findHubsByName(hubName)).at(0); + + if (!hub || !(await hub.isMod(interaction.user.id))) { + await this.replyEmbed(interaction, 'hub.notFound_mod', { + ephemeral: true, + t: { emoji: emojis.no }, + }); return; } @@ -56,7 +61,7 @@ export default class AnnounceCommand extends HubCommand { const hub = await hubService.fetchHub(hubId); await sendToHub(hubId, { - avatarURL: hub?.iconUrl, + avatarURL: hub?.data.iconUrl, embeds: [ new EmbedBuilder() .setTitle('📢 Official Hub Announcement') diff --git a/src/commands/slash/Main/hub/appeal.ts b/src/commands/slash/Main/hub/appeal.ts index 2681901c..f978aa10 100644 --- a/src/commands/slash/Main/hub/appeal.ts +++ b/src/commands/slash/Main/hub/appeal.ts @@ -1,9 +1,7 @@ +import HubManager from '#main/managers/HubManager.js'; import { emojis } from '#utils/Constants.js'; -import db from '#utils/Db.js'; import { ErrorEmbed } from '#utils/EmbedUtils.js'; -import { isHubMod } from '#utils/hub/utils.js'; import { t } from '#utils/Locale.js'; -import { Hub } from '@prisma/client'; import { ChatInputCommandInteraction } from 'discord.js'; import ms from 'ms'; import HubCommand from './index.js'; @@ -20,7 +18,7 @@ export default class AppealCommand extends HubCommand { } } - private async handleAppealCooldown(interaction: ChatInputCommandInteraction, hub: Hub) { + private async handleAppealCooldown(interaction: ChatInputCommandInteraction, hub: HubManager) { const cooldown = interaction.options.getString('cooldown', true); const appealCooldownHours = ms(cooldown) / 1000 / 60 / 60; if (!appealCooldownHours || appealCooldownHours < 1) { @@ -34,7 +32,7 @@ export default class AppealCommand extends HubCommand { return; } - await db.hub.update({ where: { id: hub.id }, data: { appealCooldownHours } }); + await hub.setAppealCooldownHours(appealCooldownHours); await interaction.reply({ content: `${emojis.clock_icon} Appeal cooldown has been set to **${appealCooldownHours}** hour(s).`, @@ -44,9 +42,9 @@ export default class AppealCommand extends HubCommand { private async runHubChecks(interaction: ChatInputCommandInteraction) { const hubName = interaction.options.getString('hub', true); - const hub = await db.hub.findFirst({ where: { name: hubName } }); + const hub = (await this.hubService.findHubsByName(hubName)).at(0); - if (!hub || !isHubMod(interaction.user.id, hub)) { + if (!hub || !await hub.isMod(interaction.user.id)) { await this.replyEmbed( interaction, t( diff --git a/src/commands/slash/Main/hub/blockwords.ts b/src/commands/slash/Main/hub/blockwords.ts index 20883597..d385086f 100644 --- a/src/commands/slash/Main/hub/blockwords.ts +++ b/src/commands/slash/Main/hub/blockwords.ts @@ -1,20 +1,21 @@ import HubCommand from '#main/commands/slash/Main/hub/index.js'; -import { emojis } from '#utils/Constants.js'; import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; -import { ACTION_LABELS, buildBlockWordsListEmbed } from '#main/utils/moderation/blockWords.js'; +import { ACTION_LABELS, buildBlockWordListEmbed } from '#main/utils/moderation/blockWords.js'; +import { emojis } from '#utils/Constants.js'; import { CustomID } from '#utils/CustomID.js'; import db from '#utils/Db.js'; import { isStaffOrHubMod } from '#utils/hub/utils.js'; import { t } from '#utils/Locale.js'; import { - buildBlockWordsActionsSelect, buildBWRuleEmbed, - buildBlockWordsModal, + buildBlockWordActionsSelect, + buildBlockWordModal, buildBlockedWordsBtns, sanitizeWords, } from '#utils/moderation/blockWords.js'; -import { BlockWordAction, Hub, MessageBlockList } from '@prisma/client'; +import { BlockWord, BlockWordAction } from '@prisma/client'; import { + ButtonBuilder, RepliableInteraction, StringSelectMenuInteraction, type ButtonInteraction, @@ -25,9 +26,9 @@ import { export default class BlockWordCommand extends HubCommand { async execute(interaction: ChatInputCommandInteraction) { const hubName = interaction.options.getString('hub', true); - const hub = await this.fetchHub({ name: hubName }); + const hub = (await this.hubService.findHubsByName(hubName)).at(0); - if (!hub || !isStaffOrHubMod(interaction.user.id, hub)) { + if (!hub || !(await isStaffOrHubMod(interaction.user.id, hub))) { const locale = await this.getLocale(interaction); await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no }), { ephemeral: true, @@ -35,10 +36,12 @@ export default class BlockWordCommand extends HubCommand { return; } + const blockWords = await hub.fetchBlockWords(); + const handlers = { - edit: () => this.handleEditSubcommand(interaction, hub), - list: () => this.handleList(interaction, hub), - create: () => this.handleAdd(interaction, hub), + edit: () => this.handleEditSubcommand(interaction, hub.id, blockWords), + list: () => this.handleList(interaction, blockWords), + create: () => this.handleAdd(interaction, hub.id), }; const subcommand = interaction.options.getSubcommand(true) as keyof typeof handlers; @@ -52,7 +55,7 @@ export default class BlockWordCommand extends HubCommand { const hub = await this.fetchHub({ id: hubId }); - if (!hub || !isStaffOrHubMod(interaction.user.id, hub)) { + if (!hub || !(await isStaffOrHubMod(interaction.user.id, hub))) { const locale = await this.getLocale(interaction); await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no }), { ephemeral: true, @@ -60,7 +63,7 @@ export default class BlockWordCommand extends HubCommand { return; } - const blockWords = hub.msgBlockList; + const blockWords = await hub.fetchBlockWords(); const presetRule = blockWords.find((r) => r.id === ruleId); if (!presetRule) { @@ -68,7 +71,7 @@ export default class BlockWordCommand extends HubCommand { return; } - const modal = buildBlockWordsModal(hub.id, { presetRule }); + const modal = buildBlockWordModal(hub.id, { presetRule }); await interaction.showModal(modal); } @@ -90,17 +93,17 @@ export default class BlockWordCommand extends HubCommand { // new rule if (!ruleId) { - if (hub.msgBlockList.length >= 2) { + if ((await hub.fetchBlockWords()).length >= 2) { await interaction.editReply('You can only have 2 block word rules per hub.'); return; } - const rule = await db.messageBlockList.create({ + const rule = await db.blockWord.create({ data: { hubId, name, createdBy: interaction.user.id, words: newWords }, }); const embed = buildBWRuleEmbed(rule); - const buttons = buildBlockedWordsBtns(hub.id, rule.id); + const buttons = buildBlockedWordsBtns(hub.id, rule.id).addComponents(new ButtonBuilder()); await interaction.editReply({ content: `${emojis.yes} Rule added.`, embeds: [embed], @@ -109,13 +112,13 @@ export default class BlockWordCommand extends HubCommand { } // remove rule else if (newWords.length === 0) { - await db.messageBlockList.delete({ where: { id: ruleId } }); + await db.blockWord.delete({ where: { id: ruleId } }); await interaction.editReply(`${emojis.yes} Rule removed.`); } // update rule else { - await db.messageBlockList.update({ where: { id: ruleId }, data: { words: newWords, name } }); + await db.blockWord.update({ where: { id: ruleId }, data: { words: newWords, name } }); await interaction.editReply(`${emojis.yes} Rule updated.`); } } @@ -126,7 +129,7 @@ export default class BlockWordCommand extends HubCommand { const [hubId, ruleId] = customId.args; const hub = await this.fetchHub({ id: hubId }); - if (!hub || !isStaffOrHubMod(interaction.user.id, hub)) { + if (!hub || !(await isStaffOrHubMod(interaction.user.id, hub))) { const locale = await this.getLocale(interaction); await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no }), { ephemeral: true, @@ -134,13 +137,13 @@ export default class BlockWordCommand extends HubCommand { return; } - const rule = hub.msgBlockList.find((r) => r.id === ruleId); + const rule = (await hub.fetchBlockWords()).find((r) => r.id === ruleId); if (!rule) { await interaction.reply({ content: 'Rule not found', ephemeral: true }); return; } - const selectMenu = buildBlockWordsActionsSelect(hubId, ruleId, rule.actions || []); + const selectMenu = buildBlockWordActionsSelect(hubId, ruleId, rule.actions || []); await interaction.reply({ content: `Configure actions for rule: ${rule.name}`, components: [selectMenu], @@ -154,7 +157,7 @@ export default class BlockWordCommand extends HubCommand { const ruleId = customId.args[1]; const selectedActions = interaction.values as BlockWordAction[]; - await db.messageBlockList.update({ + await db.blockWord.update({ where: { id: ruleId }, data: { actions: selectedActions }, }); @@ -168,10 +171,11 @@ export default class BlockWordCommand extends HubCommand { private async handleEditSubcommand( interaction: ChatInputCommandInteraction, - hub: Hub & { msgBlockList: MessageBlockList[] }, + hubId: string, + blockWords: BlockWord[], ) { const ruleName = interaction.options.getString('rule', true); - const rule = hub.msgBlockList.find((r) => r.name === ruleName); + const rule = blockWords.find((r) => r.name === ruleName); if (!rule) { await this.replyWithNotFound(interaction); @@ -179,30 +183,35 @@ export default class BlockWordCommand extends HubCommand { } const embed = buildBWRuleEmbed(rule); - const buttons = buildBlockedWordsBtns(hub.id, rule.id); + const buttons = buildBlockedWordsBtns(hubId, rule.id); await interaction.reply({ embeds: [embed], components: [buttons] }); } private async handleList( interaction: ChatInputCommandInteraction, - hub: Hub & { msgBlockList: MessageBlockList[] }, + blockWords: BlockWord[], ) { - if (!hub.msgBlockList) { + if (!blockWords.length) { await this.replyWithNotFound(interaction); return; } - const embed = buildBlockWordsListEmbed(hub.msgBlockList); + const embed = buildBlockWordListEmbed(blockWords); await interaction.reply({ embeds: [embed] }); } - private async handleAdd(interaction: ChatInputCommandInteraction | ButtonInteraction, hub: Hub) { - const modal = buildBlockWordsModal(hub.id); + private async handleAdd( + interaction: ChatInputCommandInteraction | ButtonInteraction, + hubId: string, + ) { + const modal = buildBlockWordModal(hubId); await interaction.showModal(modal); } private async fetchHub({ id, name }: { id?: string; name?: string }) { - return await db.hub.findFirst({ where: { id, name }, include: { msgBlockList: true } }); + if (id) return await this.hubService.fetchHub(id); + else if (name) return (await this.hubService.findHubsByName(name)).at(0); + return null; } private async replyWithNotFound(interaction: RepliableInteraction) { diff --git a/src/commands/slash/Main/hub/browse.ts b/src/commands/slash/Main/hub/browse.ts index 1d79ae22..13b7dfe6 100644 --- a/src/commands/slash/Main/hub/browse.ts +++ b/src/commands/slash/Main/hub/browse.ts @@ -1,14 +1,13 @@ import HubCommand from '#main/commands/slash/Main/hub/index.js'; -import Constants, { emojis } from '#utils/Constants.js'; import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; -import { HubJoinService } from '#main/services/HubJoinService.js'; import { Pagination } from '#main/modules/Pagination.js'; +import { HubJoinService } from '#main/services/HubJoinService.js'; import { getHubConnections } from '#main/utils/ConnectedListUtils.js'; import { CustomID } from '#main/utils/CustomID.js'; import db from '#main/utils/Db.js'; import { InfoEmbed } from '#main/utils/EmbedUtils.js'; -import { calculateRating, getStars } from '#main/utils/Utils.js'; -import { connectedList, Hub } from '@prisma/client'; +import Constants, { emojis } from '#utils/Constants.js'; +import { Connection, Hub } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { ActionRowBuilder, @@ -20,7 +19,6 @@ import { EmbedField, time, } from 'discord.js'; -import { HubService } from '#main/services/HubService.js'; export default class BrowseCommand extends HubCommand { async execute(interaction: ChatInputCommandInteraction) { @@ -78,24 +76,22 @@ export default class BrowseCommand extends HubCommand { await interaction.deferReply(); - const hubService = new HubService(db); - const hub = await hubService.fetchHub(hubId); + const hub = await this.hubService.fetchHub(hubId); if (!hub) { await interaction.reply({ content: 'Hub not found.', ephemeral: true }); return; } const joinService = new HubJoinService(interaction, await this.getLocale(interaction)); - await joinService.joinHub(interaction.channel, hub.name); + await joinService.joinHub(interaction.channel, hub.data.name); } - private buildField(hub: Hub, connections: connectedList[]) { + private buildField(hub: Hub, connections: Connection[]) { const lastActiveConnection = connections.filter((c) => c.hubId === hub.id).at(0); - const stars = `\`${getStars(calculateRating(hub.rating.map((r) => r.rating)))}\``; return { - name: `${hub.name} (${stars || '`0`'})`, + name: `${hub.name}`, value: `${emojis.user_icon} ${connections.length} ・ ${emojis.chat_icon} ${time(lastActiveConnection?.lastActive ?? new Date(), 'R')}\n\n${hub.description}`.slice( 0, @@ -105,7 +101,7 @@ export default class BrowseCommand extends HubCommand { }; } - private buildButtons(guildId: string, hub: Hub, connections: connectedList[]) { + private buildButtons(guildId: string, hub: Hub, connections: Connection[]) { const disabled = connections.some((c) => c.serverId === guildId); const joinButton = new ButtonBuilder() .setCustomId(new CustomID('hub_browse:join', [hub.id]).toString()) @@ -126,7 +122,7 @@ export default class BrowseCommand extends HubCommand { private getPages( guildId: string, hubs: Hub[], - connections: connectedList[][], + connections: Connection[][], thumbnail: string, ) { const pages: BaseMessageOptions[] = []; diff --git a/src/commands/slash/Main/hub/create.ts b/src/commands/slash/Main/hub/create.ts index e5b99de8..86b58711 100644 --- a/src/commands/slash/Main/hub/create.ts +++ b/src/commands/slash/Main/hub/create.ts @@ -1,10 +1,9 @@ import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; import { HubValidator } from '#main/modules/HubValidator.js'; -import { HubCreationData, HubService } from '#main/services/HubService.js'; +import { HubCreationData } from '#main/services/HubService.js'; import { CustomID } from '#main/utils/CustomID.js'; import { handleError } from '#main/utils/Utils.js'; import Constants from '#utils/Constants.js'; -import db from '#utils/Db.js'; import { supportedLocaleCodes, t } from '#utils/Locale.js'; import { ActionRowBuilder, @@ -19,14 +18,8 @@ import { import HubCommand from './index.js'; export default class Create extends HubCommand { - private readonly hubService: HubService; readonly cooldown = 10 * 60 * 1000; // 10 mins - constructor() { - super(); - this.hubService = new HubService(db); - } - async execute(interaction: ChatInputCommandInteraction) { const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); diff --git a/src/commands/slash/Main/hub/delete.ts b/src/commands/slash/Main/hub/delete.ts index 7b01bd31..bf29e86d 100644 --- a/src/commands/slash/Main/hub/delete.ts +++ b/src/commands/slash/Main/hub/delete.ts @@ -19,20 +19,26 @@ import HubCommand from './index.js'; export default class Delete extends HubCommand { async execute(interaction: ChatInputCommandInteraction): Promise { const hubName = interaction.options.getString('hub', true); - const hubInDb = await db.hub.findFirst({ where: { name: hubName } }); - const { userManager } = interaction.client; - const locale = await userManager.getUserLocale(interaction.user.id); - if (interaction.user.id !== hubInDb?.ownerId) { - await interaction.reply({ - content: t('hub.delete.ownerOnly', locale, { emoji: emojis.no }), - ephemeral: true, - }); + const hub = (await this.hubService.getOwnedHubs(interaction.user.id)).find( + (h) => h.data.name === hubName, + ); + + if (!hub) { + const infoEmbed = new InfoEmbed().setDescription( + t('hub.notOwner', await interaction.client.userManager.getUserLocale(interaction.user.id), { + emoji: emojis.no, + }), + ); + await interaction.reply({ embeds: [infoEmbed], ephemeral: true }); return; } + const { userManager } = interaction.client; + const locale = await userManager.getUserLocale(interaction.user.id); + const confirmEmbed = new EmbedBuilder() - .setDescription(t('hub.delete.confirm', locale, { hub: hubInDb.name })) + .setDescription(t('hub.delete.confirm', locale, { hub: hub.data.name })) .setColor('Red'); const confirmButtons = new ActionRowBuilder().addComponents( new ButtonBuilder() @@ -40,8 +46,8 @@ export default class Delete extends HubCommand { .setCustomId( new CustomID() .setIdentifier('hub_delete', 'confirm') - .addArgs(interaction.user.id) - .addArgs(hubInDb.id) + .setArgs(interaction.user.id) + .setArgs(hub.id) .toString(), ) .setStyle(ButtonStyle.Danger), @@ -50,8 +56,8 @@ export default class Delete extends HubCommand { .setCustomId( new CustomID() .setIdentifier('hub_delete', 'cancel') - .addArgs(interaction.user.id) - .addArgs(hubInDb.id) + .setArgs(interaction.user.id) + .setArgs(hub.id) .toString(), ) .setStyle(ButtonStyle.Secondary), @@ -100,7 +106,7 @@ export default class Delete extends HubCommand { const hubInDb = await hubService.fetchHub(hubId); // only the owner can delete the hub - if (hubInDb?.ownerId !== interaction.user.id) { + if (!hubInDb?.isOwner(interaction.user.id)) { const infoEmbed = new InfoEmbed().setDescription( t('hub.notFound', locale, { emoji: emojis.no }), ); @@ -113,7 +119,7 @@ export default class Delete extends HubCommand { await hubService.deleteHub(hubInDb.id); await interaction.editReply({ - content: t('hub.delete.success', locale, { emoji: emojis.tick, hub: hubInDb.name }), + content: t('hub.delete.success', locale, { emoji: emojis.tick, hub: hubInDb.data.name }), embeds: [], }); } diff --git a/src/commands/slash/Main/hub/edit.ts b/src/commands/slash/Main/hub/edit.ts index 8e4fac7d..a77af08b 100644 --- a/src/commands/slash/Main/hub/edit.ts +++ b/src/commands/slash/Main/hub/edit.ts @@ -1,36 +1,34 @@ -import Constants, { emojis } from '#utils/Constants.js'; import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; import HubLogManager, { LogConfigTypes as HubConfigTypes } from '#main/managers/HubLogManager.js'; +import HubManager from '#main/managers/HubManager.js'; import { setComponentExpiry } from '#utils/ComponentUtils.js'; +import Constants, { emojis } from '#utils/Constants.js'; import { CustomID } from '#utils/CustomID.js'; -import db from '#utils/Db.js'; import { InfoEmbed } from '#utils/EmbedUtils.js'; import { hubEditSelects, hubEmbed } from '#utils/hub/edit.js'; -import { isHubManager, sendToHub } from '#utils/hub/utils.js'; +import { sendToHub } from '#utils/hub/utils.js'; import { type supportedLocaleCodes, t } from '#utils/Locale.js'; -import type { Hub } from '@prisma/client'; import { ActionRowBuilder, type ChatInputCommandInteraction, type MessageComponentInteraction, ModalBuilder, type ModalSubmitInteraction, + RepliableInteraction, TextInputBuilder, TextInputStyle, } from 'discord.js'; import HubCommand from './index.js'; -import { HubService } from '#main/services/HubService.js'; export default class HubEdit extends HubCommand { - private readonly hubService = new HubService(db); - async execute(interaction: ChatInputCommandInteraction) { - const { hubInDb, locale } = await this.getInitialData(interaction); - if (!hubInDb) return; + const { hub, locale } = await this.getInitialData(interaction); + if (!hub) return; + const embed = await this.getRefreshedEmbed(hub); await interaction.reply({ - embeds: [await hubEmbed(hubInDb)], - components: [hubEditSelects(hubInDb.id, interaction.user.id, locale)], + embeds: [embed], + components: [hubEditSelects(hub.id, interaction.user.id, locale)], }); await this.setComponentExpiry(interaction); @@ -40,47 +38,47 @@ export default class HubEdit extends HubCommand { async handleActionsSelect(interaction: MessageComponentInteraction) { if (!interaction.isStringSelectMenu()) return; - const { hubInDb, locale } = await this.componentChecks(interaction); - if (!hubInDb) return; + const { hub, locale } = await this.componentChecks(interaction); + if (!hub) return; const action = interaction.values[0]; - await this.handleAction(interaction, hubInDb, action, locale); + await this.handleAction(interaction, hub, action, locale); } @RegisterInteractionHandler('hub_edit', 'logsChSel') async handleChannelSelects(interaction: MessageComponentInteraction) { if (!interaction.isChannelSelectMenu()) return; - const { hubInDb, customId, locale } = await this.componentChecks(interaction); - if (!hubInDb) return; + const { hub, customId, locale } = await this.componentChecks(interaction); + if (!hub) return; const type = customId.args[2] as HubConfigTypes; const channel = interaction.channels.first(); if (!channel) return; - await this.updateLogChannel(interaction, hubInDb, type, channel.id, locale); + await this.updateLogChannel(interaction, await hub.fetchLogConfig(), type, channel.id, locale); } @RegisterInteractionHandler('hub_edit_modal') async handleModals(interaction: ModalSubmitInteraction) { - const { hubInDb, customId, locale } = await this.modalChecks(interaction); - if (!hubInDb) return; + const { hub, customId, locale } = await this.modalChecks(interaction); + if (!hub) return; switch (customId.suffix) { case 'description': - await this.updateDescription(interaction, hubInDb.id, locale); + await this.updateDescription(interaction, hub.id, locale); break; case 'icon': - await this.updateIcon(interaction, hubInDb.id, locale); + await this.updateIcon(interaction, hub.id, locale); break; case 'banner': - await this.updateBanner(interaction, hubInDb.id, locale); + await this.updateBanner(interaction, hub.id, locale); break; default: break; } - await this.updateOriginalMessage(interaction, hubInDb.id); + await this.updateOriginalMessage(interaction, hub.id); } // Helper methods... @@ -89,24 +87,22 @@ export default class HubEdit extends HubCommand { const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); const chosenHub = interaction.options.getString('hub', true); - const hubInDb = await this.fetchHubFromDb(interaction.user.id, chosenHub); + const hub = await this.fetchHubFromDb(interaction.user.id, chosenHub); - if (!hubInDb) { + if (!hub) { await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no })); - return { hubInDb: null, locale }; + return { hub: null, locale }; } - return { hubInDb, locale }; + return { hub, locale }; } private async fetchHubFromDb(userId: string, hubName: string) { - return await db.hub.findFirst({ - where: { - name: hubName, - OR: [{ ownerId: userId }, { moderators: { some: { userId, position: 'manager' } } }], - }, - include: { connections: true }, - }); + const hubByName = (await this.hubService.findHubsByName(hubName)).at(0); + console.log(hubByName); + if (hubByName) return hubByName; + + return (await this.hubService.fetchModeratedHubs(userId, { take: 1 })).at(0); } private async setComponentExpiry(interaction: ChatInputCommandInteraction) { @@ -116,7 +112,7 @@ export default class HubEdit extends HubCommand { private async handleAction( interaction: MessageComponentInteraction, - hubInDb: Hub, + hub: HubManager, action: string, locale: supportedLocaleCodes, ) { @@ -124,10 +120,10 @@ export default class HubEdit extends HubCommand { case 'icon': case 'description': case 'banner': - await this.showModal(interaction, hubInDb.id, action, locale); + await this.showModal(interaction, hub.id, action, locale); break; case 'toggle_lock': - await this.toggleLock(interaction, hubInDb); + await this.toggleLock(interaction, hub); break; default: break; @@ -165,25 +161,21 @@ export default class HubEdit extends HubCommand { await interaction.showModal(modal); } - private async toggleLock(interaction: MessageComponentInteraction, hubInDb: Hub) { + private async toggleLock(interaction: MessageComponentInteraction, hub: HubManager) { await interaction.deferReply({ ephemeral: true }); - const updatedHub = await db.hub.update({ - where: { id: hubInDb?.id }, - data: { locked: !hubInDb?.locked }, - include: { connections: true }, - }); - - const lockedStatus = updatedHub.locked ? 'locked' : 'unlocked'; + await hub.setLocked(!hub.data.locked); + const lockedStatus = hub.data.locked ? 'locked' : 'unlocked'; await this.replyEmbed( interaction, `${lockedStatus === 'locked' ? '🔒' : '🔓'} Hub chats are now **${lockedStatus}**.`, ); - await interaction.message.edit({ embeds: [await hubEmbed(updatedHub)] }).catch(() => null); + const embed = await this.getRefreshedEmbed(hub); + await interaction.message.edit({ embeds: [embed] }).catch(() => null); - await sendToHub(updatedHub.id, { + await sendToHub(hub.id, { embeds: [ new InfoEmbed() .setTitle(`🛡️ Hub chats are now ${lockedStatus}.`) @@ -196,12 +188,11 @@ export default class HubEdit extends HubCommand { private async updateLogChannel( interaction: MessageComponentInteraction, - hubInDb: Hub, + logManager: HubLogManager, type: HubConfigTypes, channelId: string, locale: supportedLocaleCodes, ) { - const logManager = await HubLogManager.create(hubInDb.id); await logManager.setLogChannel(type, channelId); const embed = interaction.message.embeds[0].toJSON(); @@ -229,10 +220,18 @@ export default class HubEdit extends HubCommand { locale: supportedLocaleCodes, ) { const description = interaction.fields.getTextInputValue('description'); - await db.hub.update({ - where: { id: hubId }, - data: { description }, - }); + const hub = await this.hubService.fetchHub(hubId); + console.log(hub); + + if (!hub) { + await interaction.reply({ + content: t('hub.notFound_mod', locale, { emoji: emojis.no }), + ephemeral: true, + }); + return; + } + + await hub.setDescription(description); await interaction.reply({ content: t('hub.manage.description.changed', locale), @@ -253,7 +252,10 @@ export default class HubEdit extends HubCommand { return; } - await db.hub.update({ where: { id: hubId }, data: { iconUrl } }); + const hub = await this.getHubOrError(interaction, hubId, locale); + if (!hub) return; + + await hub.setIconUrl(iconUrl); await interaction.reply({ content: t('hub.manage.icon.changed', locale), @@ -268,14 +270,12 @@ export default class HubEdit extends HubCommand { ) { await interaction.deferReply({ ephemeral: true }); - const bannerUrl = interaction.fields.getTextInputValue('banner'); + const hub = await this.getHubOrError(interaction, hubId, locale); + if (!hub) return; + const bannerUrl = interaction.fields.getTextInputValue('banner'); if (!bannerUrl) { - await db.hub.update({ - where: { id: hubId }, - data: { bannerUrl: { unset: true } }, - }); - + await hub.setBannerUrl(null); await interaction.editReply(t('hub.manage.banner.removed', locale)); return; } @@ -287,22 +287,17 @@ export default class HubEdit extends HubCommand { return; } - await db.hub.update({ - where: { id: hubId }, - data: { bannerUrl }, - }); + await hub.setBannerUrl(bannerUrl); await interaction.editReply(emojis.yes + t('hub.manage.banner.changed', locale)); } private async updateOriginalMessage(interaction: ModalSubmitInteraction, hubId: string) { - const updatedHub = await db.hub.findFirst({ - where: { id: hubId }, - include: { connections: true }, - }); + const updatedHub = await this.hubService.fetchHub(hubId); if (updatedHub) { - await interaction.message?.edit({ embeds: [await hubEmbed(updatedHub)] }).catch(() => null); + const embed = await this.getRefreshedEmbed(updatedHub); + await interaction.message?.edit({ embeds: [embed] }).catch(() => null); } } @@ -320,14 +315,14 @@ export default class HubEdit extends HubCommand { return {}; } - const hubInDb = await this.hubService.fetchHub(customId.args[1], { connections: true }); - if (!hubInDb) { + const hub = await this.hubService.fetchHub(customId.args[1]); + if (!hub) { const embed = new InfoEmbed().setDescription(t('hub.notFound', locale, { emoji: emojis.no })); await interaction.reply({ embeds: [embed], ephemeral: true }); return {}; } - return { hubInDb, customId, locale }; + return { hub, customId, locale }; } private async modalChecks(interaction: ModalSubmitInteraction) { @@ -336,20 +331,45 @@ export default class HubEdit extends HubCommand { const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); - const hubInDb = await this.hubService.fetchHub(hubId, { connections: true }); - if (!hubInDb || !isHubManager(interaction.user.id, hubInDb)) { + const hub = await this.hubService.fetchHub(hubId); + + if (!(await hub?.isManager(interaction.user.id))) { await interaction.reply({ - content: t('hub.notFound_mod', locale, { emoji: emojis.no }), + content: t('hub.notManager', locale, { emoji: emojis.no }), ephemeral: true, }); return {}; } - return { hubInDb, customId, locale }; + return { hub, customId, locale }; } private channelMention(channelId: string | null | undefined) { if (!channelId) return emojis.no; return `<#${channelId}>`; } + + private async getHubOrError( + interaction: RepliableInteraction, + hubId: string, + locale: supportedLocaleCodes, + ) { + const hub = await this.hubService.fetchHub(hubId); + + if (!hub) { + await interaction.reply({ + content: t('hub.notFound_mod', locale, { emoji: emojis.no }), + ephemeral: true, + }); + return null; + } + + return hub; + } + + private async getRefreshedEmbed(hub: HubManager) { + const connections = await hub.fetchConnections(); + const mods = await hub.moderators.fetchAll(); + return await hubEmbed(hub.data, connections.length, mods.length); + } } diff --git a/src/commands/slash/Main/hub/index.ts b/src/commands/slash/Main/hub/index.ts index 2b572d1e..102891b9 100644 --- a/src/commands/slash/Main/hub/index.ts +++ b/src/commands/slash/Main/hub/index.ts @@ -1,6 +1,8 @@ import BaseCommand from '#main/core/BaseCommand.js'; import { logsWithRoleId } from '#main/managers/HubLogManager.js'; +import HubManager from '#main/managers/HubManager.js'; import { HubSettingsBits } from '#main/modules/BitFields.js'; +import { HubService } from '#main/services/HubService.js'; import db from '#utils/Db.js'; import { escapeRegexChars, handleError, toTitleCase } from '#utils/Utils.js'; import { @@ -455,6 +457,8 @@ export default class HubCommand extends BaseCommand { // subcommand classes are added to this map in their respective files static readonly subcommands = new Collection(); + protected readonly hubService = new HubService(); + async execute(interaction: ChatInputCommandInteraction) { const subcommand = HubCommand.subcommands?.get( interaction.options.getSubcommandGroup() || interaction.options.getSubcommand(), @@ -478,13 +482,13 @@ export default class HubCommand extends BaseCommand { const subcommand = interaction.options.getSubcommand(); const subcommandGroup = interaction.options.getSubcommandGroup(); const focusedValue = escapeRegexChars(interaction.options.getFocused()); - let hubChoices; + let hubChoices: HubManager[] = []; if (subcommand === 'browse' || subcommand === 'join') { hubChoices = await this.getPublicHubs(focusedValue); } - else if (subcommand === 'edit' && subcommandGroup === 'blockwords') { - const choices = await this.getBlockWordsRules(interaction); + else if (subcommandGroup === 'blockwords' && subcommand === 'edit') { + const choices = await this.getBlockWordRules(interaction); await interaction.respond(choices ?? []); return; } @@ -508,18 +512,18 @@ export default class HubCommand extends BaseCommand { return; } - const choices = hubChoices?.map((hub) => ({ name: hub.name, value: hub.name })); + const choices = hubChoices.map((hub) => ({ name: hub.data.name, value: hub.data.name })); await interaction.respond(choices ?? []); } - private async getBlockWordsRules(interaction: AutocompleteInteraction) { + private async getBlockWordRules(interaction: AutocompleteInteraction) { const focused = interaction.options.getFocused(true); const hubName = interaction.options.getString('hub'); if (focused.name === 'rule') { if (!hubName) return [{ name: 'Please select a hub first.', value: '' }]; - const rules = await db.messageBlockList.findMany({ + const rules = await db.blockWord.findMany({ where: { hub: { name: hubName } }, select: { id: true, name: true }, }); @@ -530,51 +534,46 @@ export default class HubCommand extends BaseCommand { } private async getPublicHubs(focusedValue: string) { - return await db.hub.findMany({ + const hubs = await db.hub.findMany({ where: { name: { mode: 'insensitive', contains: focusedValue }, private: false, }, take: 25, }); + + return hubs.map((hub) => new HubManager(hub, this.hubService)); } private async getModeratedHubs(focusedValue: string, modId: Snowflake) { - return await db.hub.findMany({ - where: { - name: { mode: 'insensitive', contains: focusedValue }, - OR: [{ ownerId: modId }, { moderators: { some: { userId: modId } } }], - }, + const hubs = await this.hubService.fetchModeratedHubs(modId, { + filter: { hub: { name: { contains: focusedValue } } }, take: 25, }); + return hubs; } private async getManagedHubs(focusedValue: string, modId: Snowflake) { - return await db.hub.findMany({ - where: { - name: { mode: 'insensitive', contains: focusedValue }, - OR: [{ ownerId: modId }, { moderators: { some: { userId: modId, position: 'manager' } } }], - }, + const hubs = await this.hubService.fetchModeratedHubs(modId, { + roles: ['MANAGER', 'OWNER'], + filter: { hub: { name: { contains: focusedValue } } }, take: 25, }); + + return hubs; } private async getOwnedHubs(focusedValue: string, ownerId: Snowflake) { - return await db.hub.findMany({ - where: { - ownerId, - name: { mode: 'insensitive', contains: focusedValue }, - }, - take: 25, - }); + const hubs = await this.hubService.getOwnedHubs(ownerId); + return hubs.filter((hub) => hub.data.name.toLowerCase().includes(focusedValue.toLowerCase())); } private async getInfractionSubcommandChoices(interaction: AutocompleteInteraction) { const focused = interaction.options.getFocused(true); if (focused.name === 'hub') { return (await this.getModeratedHubs(focused.value, interaction.user.id)).map((hub) => ({ - name: hub.name, - value: hub.name, + name: hub.data.name, + value: hub.data.name, })); } } @@ -582,7 +581,7 @@ export default class HubCommand extends BaseCommand { private async getLeaveSubcommandChoices(focusedValue: string, guild: Guild | null) { if (!guild) return null; - const networks = await db.connectedList.findMany({ + const networks = await db.connection.findMany({ where: { serverId: guild?.id }, select: { channelId: true, hub: true }, take: 25, diff --git a/src/commands/slash/Main/hub/infractions.ts b/src/commands/slash/Main/hub/infractions.ts index 7d10f21d..415a90a7 100644 --- a/src/commands/slash/Main/hub/infractions.ts +++ b/src/commands/slash/Main/hub/infractions.ts @@ -1,16 +1,14 @@ import HubCommand from '#main/commands/slash/Main/hub/index.js'; -import { InfractionManagerFactory } from '#main/managers/InfractionManager/InfractionManagerFactory.js'; +import HubManager from '#main/managers/HubManager.js'; +import InfractionManager from '#main/managers/InfractionManager.js'; import { Pagination } from '#main/modules/Pagination.js'; import { RemoveMethods } from '#main/types/Utils.js'; import { msToReadable } from '#main/utils/Utils.js'; import Constants, { emojis } from '#utils/Constants.js'; import db from '#utils/Db.js'; import { t } from '#utils/Locale.js'; -import { - buildInfractionListEmbeds, - isServerInfraction, -} from '#utils/moderation/infractionUtils.js'; -import { Hub, ServerInfraction, UserInfraction } from '@prisma/client'; +import { buildInfractionListEmbeds } from '#utils/moderation/infractionUtils.js'; +import { Infraction, UserData } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { BaseMessageOptions, @@ -25,7 +23,7 @@ import { // Types for better type safety and documentation type InfractionType = 'server' | 'user'; -type GroupedInfraction = (UserInfraction | ServerInfraction) & { count: number }; +type GroupedInfraction = Infraction & { user: UserData | null; count: number }; interface TargetInfo { name: string; @@ -52,41 +50,45 @@ export default class ViewInfractions extends HubCommand { await this.showTargetInfractions(interaction, hub, type, targetId); } - private async validateAndGetHub(interaction: ChatInputCommandInteraction): Promise { + private async validateAndGetHub( + interaction: ChatInputCommandInteraction, + ): Promise { const hubName = interaction.options.getString('hub', true); - const hub = await db.hub.findFirst({ - where: { - name: hubName, - OR: [ - { ownerId: interaction.user.id }, - { moderators: { some: { userId: interaction.user.id } } }, - ], - }, + + const hub = await this.hubService.fetchModeratedHubs(interaction.user.id, { + filter: { hub: { name: hubName } }, + take: 1, }); - if (!hub) { + if (!hub.length) { const locale = await interaction.client.userManager.getUserLocale(interaction.user.id); await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no })); return null; } - return hub; + return hub[0]; } private async showTargetInfractions( interaction: ChatInputCommandInteraction, - hub: Hub, + hub: HubManager, type: InfractionType, targetId: string, ) { - const targetInfo = await this.getTargetInfo(interaction.client, type, targetId, hub.iconUrl); - const infractionManager = InfractionManagerFactory.create(type, targetId); + const targetInfo = await this.getTargetInfo( + interaction.client, + type, + targetId, + hub.data.iconUrl, + ); + const infractionManager = new InfractionManager(type, targetId); const infractions = await infractionManager.getHubInfractions(hub.id); // Update target name if it's a server infraction - const finalTargetName = isServerInfraction(infractions[0]) - ? infractions[0].serverName - : targetInfo.name; + const finalTargetName = + infractionManager.targetType === 'user' + ? targetInfo.name + : (infractions.at(0)?.serverName ?? 'Unknown Server'); const embeds = await buildInfractionListEmbeds( interaction.client, @@ -120,32 +122,21 @@ export default class ViewInfractions extends HubCommand { private async showAllInfractions( interaction: ChatInputCommandInteraction, - hub: Hub, + hub: HubManager, type: InfractionType, ) { - const groupedInfractions = await this.getGroupedInfractions(hub.id, type); - const embeds = await this.buildAllInfractionsEmbed( - interaction.client, - groupedInfractions, - type, - ); + const Infractions = await this.getInfractions(hub.id); + const embeds = await this.buildAllInfractionsEmbed(interaction.client, Infractions, type); await this.displayPagination(interaction, embeds); } - private async getGroupedInfractions( - hubId: string, - type: InfractionType, - ): Promise> { + private async getInfractions(hubId: string): Promise> { // Fetch all infractions in a single query with included relations - const infractions = await (type === 'server' - ? db.serverInfraction.findMany({ - where: { hubId }, - orderBy: { dateIssued: 'desc' }, - }) - : db.userInfraction.findMany({ - where: { hubId }, - orderBy: { dateIssued: 'desc' }, - })); + const infractions = await db.infraction.findMany({ + where: { hubId }, + orderBy: { createdAt: 'desc' }, + include: { user: true }, + }); // Group infractions by target ID return infractions.reduce((grouped, infraction) => { @@ -166,29 +157,29 @@ export default class ViewInfractions extends HubCommand { private async buildAllInfractionsEmbed( client: Client, - groupedInfractions: Collection, + Infractions: Collection, type: InfractionType, ) { const pages: BaseMessageOptions[] = []; - const targetIds = [...groupedInfractions.keys()]; + const targetIds = [...Infractions.keys()]; // Batch fetch all users/servers at once const [targets, moderators] = await Promise.all([ this.batchFetchTargets(client, targetIds, type), this.batchFetchModerators(client, [ - ...new Set(groupedInfractions.map((i) => i.moderatorId).filter(Boolean) as string[]), + ...new Set(Infractions.map((i) => i.moderatorId).filter(Boolean) as string[]), ]), ]); let currentFields: { name: string; value: string }[] = []; let counter = 0; - for (const [targetId, infraction] of groupedInfractions) { + for (const [targetId, infraction] of Infractions) { const target = targets.get(targetId); const moderator = moderators.get(infraction.moderatorId ?? '') ?? null; const field = { - name: `${this.getTargetName(target, infraction)} (${targetId}) (${time(infraction.dateIssued, 'R')})`, + name: `${this.getTargetName(target, infraction)} (${targetId}) (${time(infraction.createdAt, 'R')})`, value: this.formatInfractionDetails( infraction, moderator, @@ -199,7 +190,7 @@ export default class ViewInfractions extends HubCommand { currentFields.push(field); counter++; - if (this.shouldCreateNewPage(counter, currentFields.length, groupedInfractions.size)) { + if (this.shouldCreateNewPage(counter, currentFields.length, Infractions.size)) { pages.push(this.createPageEmbed(currentFields)); currentFields = []; counter = 0; @@ -251,13 +242,15 @@ export default class ViewInfractions extends HubCommand { infraction: GroupedInfraction, ): string { if (!target) { - return 'userId' in infraction ? 'Unknown User' : (infraction.serverName ?? 'Unknown Server'); + return infraction.userId + ? (infraction.user?.username ?? 'Unknown User') + : (infraction.serverName ?? 'Unknown Server'); } return target instanceof User ? target.username : target.name; } - private getTargetId(infraction: UserInfraction | ServerInfraction): string { - return 'userId' in infraction ? infraction.userId : infraction.serverId; + private getTargetId(infraction: Infraction): string { + return infraction.userId ?? infraction.serverId ?? ''; } private async createInfractionField(client: Client, infraction: GroupedInfraction) { @@ -266,7 +259,7 @@ export default class ViewInfractions extends HubCommand { const targetInfo = await this.getTargetFieldInfo(client, infraction); return { - name: `${targetInfo.name} (${targetInfo.id}) (${time(infraction.dateIssued, 'R')})`, + name: `${targetInfo.name} (${targetInfo.id}) (${time(infraction.createdAt, 'R')})`, value: this.formatInfractionDetails(infraction, moderator, expiresAt), }; } @@ -287,7 +280,7 @@ export default class ViewInfractions extends HubCommand { private async getTargetFieldInfo(client: Client, infraction: GroupedInfraction) { const targetId = this.getTargetId(infraction); - if ('userId' in infraction) { + if (infraction.userId) { const user = await client.users.fetch(targetId).catch(() => null); return { name: user?.username ?? 'Unknown User', id: targetId }; } diff --git a/src/commands/slash/Main/hub/invite.ts b/src/commands/slash/Main/hub/invite.ts index 12447dc6..95a2cbb1 100644 --- a/src/commands/slash/Main/hub/invite.ts +++ b/src/commands/slash/Main/hub/invite.ts @@ -6,7 +6,6 @@ import { CacheType, ChatInputCommandInteraction, EmbedBuilder } from 'discord.js import ms from 'ms'; import HubCommand from './index.js'; import { HubService } from '#main/services/HubService.js'; -import { isHubManager } from '#main/utils/hub/utils.js'; import { InfoEmbed } from '#main/utils/EmbedUtils.js'; export default class Invite extends HubCommand { @@ -35,17 +34,17 @@ export default class Invite extends HubCommand { const duration = expiryStr ? ms(expiryStr) : undefined; const expires = new Date(Date.now() + (duration || 60 * 60 * 4000)); - const hubService = new HubService(db); - const hubInDb = await hubService.getHubByName(hubName); + const hubService = new HubService(); + const hub = await (await hubService.findHubsByName(hubName)).at(0); - if (!hubInDb) { + if (!hub) { await this.replyEmbed(interaction, 'hub.notFound_mod', { t: { emoji: emojis.no }, ephemeral: true, }); return; } - else if (!hubInDb?.private) { + else if (!hub?.data.private) { await this.replyEmbed(interaction, 'hub.notPrivate', { t: { emoji: emojis.no }, ephemeral: true, @@ -53,7 +52,7 @@ export default class Invite extends HubCommand { return; } - if (!isHubManager(interaction.user.id, hubInDb)) { + if (!await hub.isManager(interaction.user.id)) { await this.replyEmbed(interaction, 'hub.notManager', { t: { emoji: emojis.no }, ephemeral: true, @@ -69,12 +68,7 @@ export default class Invite extends HubCommand { return; } - const createdInvite = await db.hubInvite.create({ - data: { - hub: { connect: { name: hubName } }, - expires, - }, - }); + const createdInvite = await hub.createInvite(expires); const embed = new EmbedBuilder() .setDescription( @@ -98,13 +92,14 @@ export default class Invite extends HubCommand { locale: supportedLocaleCodes, ) { const code = interaction.options.getString('code', true); + const inviteInDb = await db.hubInvite.findFirst({ where: { code, hub: { OR: [ { ownerId: interaction.user.id }, - { moderators: { some: { userId: interaction.user.id, position: 'manager' } } }, + { moderators: { some: { userId: interaction.user.id, role: 'MANAGER' } } }, ], }, }, @@ -137,17 +132,19 @@ export default class Invite extends HubCommand { locale: supportedLocaleCodes, ) { const hubName = interaction.options.getString('hub', true); - const hubInDb = await db.hub.findFirst({ - where: { - name: hubName, - OR: [ - { ownerId: interaction.user.id }, - { moderators: { some: { userId: interaction.user.id, position: 'manager' } } }, - ], - }, - }); - if (!hubInDb?.private) { + const hub = (await this.hubService.findHubsByName(hubName)).at(0); + + if (!await hub?.isManager(interaction.user.id)) { + await this.replyEmbed( + interaction, + t('hub.notManager', locale, { emoji: emojis.no }), + { ephemeral: true }, + ); + return; + } + + if (!hub?.data.private) { await this.replyEmbed( interaction, t('hub.invite.list.notPrivate', locale, { emoji: emojis.no }), @@ -156,7 +153,7 @@ export default class Invite extends HubCommand { return; } - const invitesInDb = await db.hubInvite.findMany({ where: { hubId: hubInDb.id } }); + const invitesInDb = await hub.fetchInvites(); if (invitesInDb.length === 0) { await this.replyEmbed( interaction, diff --git a/src/commands/slash/Main/hub/leave.ts b/src/commands/slash/Main/hub/leave.ts index 6c9029b8..839a9075 100644 --- a/src/commands/slash/Main/hub/leave.ts +++ b/src/commands/slash/Main/hub/leave.ts @@ -23,7 +23,7 @@ export default class Leave extends HubCommand { await interaction.deferReply({ ephemeral: true }); const channelId = interaction.options.getString('hub', true); - const isChannelConnected = await db.connectedList.findFirst({ + const isChannelConnected = await db.connection.findFirst({ where: { channelId }, include: { hub: true }, }); @@ -91,7 +91,7 @@ export default class Leave extends HubCommand { const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); - const validConnection = await db.connectedList.findFirst({ where: { channelId } }); + const validConnection = await db.connection.findFirst({ where: { channelId } }); if (!validConnection) { await interaction.update({ content: t('connection.notFound', locale, { emoji: emojis.no }), diff --git a/src/commands/slash/Main/hub/logging.ts b/src/commands/slash/Main/hub/logging.ts index 4fe2a153..08651148 100644 --- a/src/commands/slash/Main/hub/logging.ts +++ b/src/commands/slash/Main/hub/logging.ts @@ -1,9 +1,9 @@ import HubLogManager, { LogConfigTypes, RoleIdLogConfigs } from '#main/managers/HubLogManager.js'; +import HubManager from '#main/managers/HubManager.js'; import { HubService } from '#main/services/HubService.js'; import { isGuildTextBasedChannel } from '#main/utils/ChannelUtls.js'; import { emojis } from '#main/utils/Constants.js'; import db from '#utils/Db.js'; -import { Hub } from '@prisma/client'; import { Channel, ChatInputCommandInteraction, @@ -37,10 +37,12 @@ export default class LoggingCommand extends HubCommand { await handlers[subcommand]?.(); } - private async getHubForUser(interaction: ChatInputCommandInteraction): Promise { + private async getHubForUser( + interaction: ChatInputCommandInteraction, + ): Promise { const hubService = new HubService(db); const hubName = interaction.options.getString('hub'); - const hubs = await hubService.getHubsForUser(interaction.user.id); + const hubs = await hubService.getOwnedHubs(interaction.user.id); if (hubs.length === 0) { await this.replyEmbed(interaction, 'You do not have access to any hubs.', { @@ -50,7 +52,7 @@ export default class LoggingCommand extends HubCommand { } if (hubName) { - const hub = hubs.find((h) => h.name === hubName); + const hub = hubs.find((h) => h.data.name === hubName); if (!hub) { await this.replyEmbed(interaction, 'Hub not found.', { ephemeral: true }); return null; @@ -68,9 +70,9 @@ export default class LoggingCommand extends HubCommand { return null; } - private async handleView(interaction: ChatInputCommandInteraction, hub: Hub) { + private async handleView(interaction: ChatInputCommandInteraction, hub: HubManager) { const hubLogManager = await HubLogManager.create(hub.id); - const embed = hubLogManager.createEmbed(hub.iconUrl); + const embed = hubLogManager.createEmbed(hub.data.iconUrl); await interaction.reply({ embeds: [embed] }); } diff --git a/src/commands/slash/Main/hub/moderator.ts b/src/commands/slash/Main/hub/moderator.ts index 47d81b2c..12413f3a 100644 --- a/src/commands/slash/Main/hub/moderator.ts +++ b/src/commands/slash/Main/hub/moderator.ts @@ -1,36 +1,30 @@ +import HubManager from '#main/managers/HubManager.js'; import { emojis } from '#utils/Constants.js'; -import db from '#utils/Db.js'; import { type supportedLocaleCodes, t } from '#utils/Locale.js'; -import type { HubModeratorPosition, Hub } from '@prisma/client'; +import type { HubModerator } from '@prisma/client'; import { ChatInputCommandInteraction, EmbedBuilder } from 'discord.js'; import HubCommand from './index.js'; export default class Moderator extends HubCommand { async execute(interaction: ChatInputCommandInteraction): Promise { const hubName = interaction.options.getString('hub', true); - const hub = await db.hub.findFirst({ - where: { - name: hubName, - OR: [ - { ownerId: interaction.user.id }, - { moderators: { some: { userId: interaction.user.id, position: 'manager' } } }, - ], - }, - }); + const hub = (await this.hubService.findHubsByName(hubName)).at(0); const locale = await interaction.client.userManager.getUserLocale(interaction.user.id); - if (!hub) { - await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no }), { + if (!hub || !(await hub?.isManager(interaction.user.id))) { + await this.replyEmbed(interaction, t('hub.notManager', locale, { emoji: emojis.no }), { ephemeral: true, }); return; } + const moderators = await hub.moderators.fetchAll(); + const handlers = { - add: () => this.handleAddSubcommand(interaction, hub, locale), - remove: () => this.handleRemoveSubcommand(interaction, hub, locale), - edit: () => this.handleEditSubcommand(interaction, hub, locale), - list: () => this.handleListSubcommand(interaction, hub, locale), + add: () => this.handleAddSubcommand(interaction, hub, moderators, locale), + remove: () => this.handleRemoveSubcommand(interaction, hub, moderators, locale), + edit: () => this.handleEditSubcommand(interaction, hub, moderators, locale), + list: () => this.handleListSubcommand(interaction, moderators, locale), }; const subcommand = interaction.options.getSubcommand(true) as keyof typeof handlers; @@ -39,11 +33,12 @@ export default class Moderator extends HubCommand { private async handleRemoveSubcommand( interaction: ChatInputCommandInteraction, - hub: Hub, + hub: HubManager, + moderators: HubModerator[], locale: supportedLocaleCodes, ) { const user = interaction.options.getUser('user', true); - if (!hub.moderators.find((mod) => mod.userId === user.id)) { + if (!moderators.find((mod) => mod.userId === user.id)) { await this.replyEmbed( interaction, t('hub.moderator.remove.notModerator', locale, { user: user.toString(), emoji: emojis.no }), @@ -52,16 +47,14 @@ export default class Moderator extends HubCommand { return; } - const mod = hub.moderators.find((m) => m.userId === user.id); - - const isRestrictedAction = mod?.position === 'manager' || user.id === interaction.user.id; - const isExecutorOwner = hub.ownerId === interaction.user.id; + const mod = moderators.find((m) => m.userId === user.id); + const isRestrictedAction = mod?.role === 'MANAGER' || user.id === interaction.user.id; /* executor needs to be owner to: - change position of other managers - change their own position */ - if (!isExecutorOwner && isRestrictedAction) { + if (!hub.isOwner(interaction.user.id) && isRestrictedAction) { await this.replyEmbed( interaction, t('hub.moderator.remove.notOwner', locale, { emoji: emojis.no }), @@ -70,12 +63,7 @@ export default class Moderator extends HubCommand { return; } - await db.hub.update({ - where: { id: hub.id }, - data: { - moderators: { deleteMany: { where: { userId: user.id } } }, - }, - }); + await hub.moderators.remove(user.id); await this.replyEmbed( interaction, @@ -85,16 +73,16 @@ export default class Moderator extends HubCommand { private async handleEditSubcommand( interaction: ChatInputCommandInteraction, - hub: Hub, + hub: HubManager, + moderators: HubModerator[], locale: supportedLocaleCodes, ) { const user = interaction.options.getUser('user', true); - const position = interaction.options.getString('position', true) as HubModeratorPosition; - const isUserMod = hub.moderators.find((mod) => mod.userId === user.id); - const isExecutorManager = hub.moderators.find( + const role = interaction.options.getString('position', true) as HubModerator['role']; + const isUserMod = moderators.find((mod) => mod.userId === user.id); + const isExecutorManager = moderators.find( (mod) => - (mod.userId === interaction.user.id && mod.position === 'manager') || - hub.ownerId === interaction.user.id, + mod.userId === interaction.user.id && (mod.role === 'MANAGER' || mod.role === 'OWNER'), ); if (!isExecutorManager) { @@ -113,7 +101,7 @@ export default class Moderator extends HubCommand { ); return; } - else if (isUserMod.position === 'manager' && hub.ownerId !== interaction.user.id) { + else if (isUserMod.role === 'MANAGER' && !hub.isOwner(interaction.user.id)) { await this.replyEmbed( interaction, t('hub.moderator.update.notOwner', locale, { emoji: emojis.no }), @@ -122,18 +110,13 @@ export default class Moderator extends HubCommand { return; } - await db.hub.update({ - where: { id: hub.id }, - data: { - moderators: { updateMany: { where: { userId: user.id }, data: { position } } }, - }, - }); + await hub.moderators.update(user.id, role); await this.replyEmbed( interaction, t('hub.moderator.update.success', locale, { user: user.toString(), - position, + position: role, emoji: emojis.yes, }), ); @@ -141,7 +124,7 @@ export default class Moderator extends HubCommand { private async handleListSubcommand( interaction: ChatInputCommandInteraction, - hub: Hub, + moderators: HubModerator[], locale: supportedLocaleCodes, ) { await interaction.reply({ @@ -149,12 +132,12 @@ export default class Moderator extends HubCommand { new EmbedBuilder() .setTitle('Hub Moderators') .setDescription( - hub.moderators.length > 0 - ? hub.moderators + moderators.length > 0 + ? moderators .map( (mod, index) => `${index + 1}. <@${mod.userId}> - ${ - mod.position === 'network_mod' ? 'Network Moderator' : 'Hub Manager' + mod.role === 'MODERATOR' ? 'Moderator' : 'Hub Manager' }`, ) .join('\n') @@ -169,12 +152,13 @@ export default class Moderator extends HubCommand { private async handleAddSubcommand( interaction: ChatInputCommandInteraction, - hub: Hub, + hub: HubManager, + moderators: HubModerator[], locale: supportedLocaleCodes, ) { const user = interaction.options.getUser('user', true); - if (hub.moderators.find((mod) => mod.userId === user.id)) { + if (moderators.find((mod) => mod.userId === user.id)) { await this.replyEmbed( interaction, t('hub.moderator.add.alreadyModerator', locale, { @@ -186,18 +170,16 @@ export default class Moderator extends HubCommand { return; } - const position = (interaction.options.getString('position') ?? - 'network_mod') as HubModeratorPosition; - await db.hub.update({ - where: { id: hub.id }, - data: { moderators: { push: { userId: user.id, position } } }, - }); + const role = (interaction.options.getString('position') ?? + 'NETWORK_MOD') as HubModerator['role']; + + await hub.moderators.add(user.id, role); await this.replyEmbed( interaction, t('hub.moderator.add.success', locale, { user: user.toString(), - position, + position: role, emoji: emojis.yes, }), ); diff --git a/src/commands/slash/Main/hub/servers.ts b/src/commands/slash/Main/hub/servers.ts index 14e64ad4..f307bef6 100644 --- a/src/commands/slash/Main/hub/servers.ts +++ b/src/commands/slash/Main/hub/servers.ts @@ -1,6 +1,5 @@ import { Pagination } from '#main/modules/Pagination.js'; import Constants, { emojis } from '#utils/Constants.js'; -import db from '#utils/Db.js'; import { t } from '#utils/Locale.js'; import { resolveEval } from '#utils/Utils.js'; import { type ChatInputCommandInteraction, EmbedBuilder } from 'discord.js'; @@ -15,24 +14,18 @@ export default class Servers extends HubCommand { const { userManager } = interaction.client; const locale = await userManager.getUserLocale(interaction.user.id); - const hub = await db.hub.findUnique({ - where: { name: hubOpt }, - include: { connections: true }, - }); - + const hub = (await this.hubService.findHubsByName(hubOpt)).at(0); if (!hub) { await this.replyEmbed(interaction, t('hub.notFound', locale, { emoji: emojis.no })); return; } - else if ( - hub.ownerId !== interaction.user.id && - !hub.moderators.some((mod) => mod.userId === interaction.user.id) - ) { + else if (!(await hub.isMod(interaction.user.id))) { await this.replyEmbed(interaction, t('hub.notFound_mod', locale, { emoji: emojis.no })); return; } - if (hub.connections.length === 0) { + const connections = await hub.fetchConnections(); + if (connections.length === 0) { await this.replyEmbed( interaction, t('hub.servers.noConnections', locale, { emoji: emojis.no }), @@ -41,11 +34,11 @@ export default class Servers extends HubCommand { } if (serverOpt) { - const connection = hub.connections.find((con) => con.serverId === serverOpt); + const connection = connections.find((con) => con.serverId === serverOpt); if (!connection) { await this.replyEmbed( interaction, - t('hub.servers.notConnected', locale, { hub: hub.name, emoji: emojis.no }), + t('hub.servers.notConnected', locale, { hub: hub.data.name, emoji: emojis.no }), ); return; } @@ -58,7 +51,7 @@ export default class Servers extends HubCommand { t('hub.servers.connectionInfo', locale, { channelName: `${channel?.name}`, channelId: connection.channelId, - joinedAt: ``, + joinedAt: ``, invite: connection.invite ? connection.invite : 'Not Set.', connected: connection.connected ? 'Yes' : 'No', }), @@ -71,8 +64,8 @@ export default class Servers extends HubCommand { const paginator = new Pagination(); let itemsPerPage = 5; - for (let index = 0; index < hub.connections.length; index += 5) { - const current = hub.connections?.slice(index, itemsPerPage); + for (let index = 0; index < connections.length; index += 5) { + const current = connections?.slice(index, itemsPerPage); let itemCounter = index; let embedFromIndex = index; @@ -99,7 +92,7 @@ export default class Servers extends HubCommand { const value = t('hub.servers.connectionInfo', locale, { channelName: `${evalRes?.channelName}`, channelId: connection.channelId, - joinedAt: ``, + joinedAt: ``, invite: connection.invite ? connection.invite : 'Not Set.', connected: connection.connected ? 'Yes' : 'No', }); @@ -114,7 +107,7 @@ export default class Servers extends HubCommand { t('hub.servers.total', locale, { from: `${++embedFromIndex}`, to: `${itemCounter}`, - total: `${hub.connections.length}`, + total: `${connections.length}`, }), ) .setColor(0x2f3136) diff --git a/src/commands/slash/Main/hub/settings.ts b/src/commands/slash/Main/hub/settings.ts index c0e733be..0b6aafdb 100644 --- a/src/commands/slash/Main/hub/settings.ts +++ b/src/commands/slash/Main/hub/settings.ts @@ -1,12 +1,11 @@ import HubCommand from '#main/commands/slash/Main/hub/index.js'; -import { emojis } from '#utils/Constants.js'; import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; -import { type HubSettingsString } from '#main/modules/BitFields.js'; +import HubManager from '#main/managers/HubManager.js'; import HubSettingsManager from '#main/managers/HubSettingsManager.js'; +import { type HubSettingsString } from '#main/modules/BitFields.js'; +import { emojis } from '#utils/Constants.js'; import { CustomID } from '#utils/CustomID.js'; -import db from '#utils/Db.js'; import { t } from '#utils/Locale.js'; -import type { Hub } from '@prisma/client'; import { ActionRowBuilder, ButtonBuilder, @@ -30,23 +29,19 @@ export default class Settings extends HubCommand { } } - private async handleList(interaction: ChatInputCommandInteraction, hub: Hub) { - const settingsManager = new HubSettingsManager(hub.id, hub.settings); - - await interaction.reply({ embeds: [settingsManager.settingsEmbed] }); + private async handleList(interaction: ChatInputCommandInteraction, hub: HubManager) { + await interaction.reply({ embeds: [hub.settings.embed] }); } - private async handleToggle(interaction: ChatInputCommandInteraction, hub: Hub) { + private async handleToggle(interaction: ChatInputCommandInteraction, hub: HubManager) { const settingStr = interaction.options.getString('setting', true) as HubSettingsString; - const settingsManager = new HubSettingsManager(hub.id, hub.settings); - - const value = await settingsManager.updateSetting(settingStr); + const value = await hub.settings.updateSetting(settingStr); const viewSettingsButton = new ActionRowBuilder().addComponents( new ButtonBuilder() .setCustomId( new CustomID() .setIdentifier('hubSettings', 'list') - .addArgs(hub.id, interaction.user.id) + .setArgs(hub.id, interaction.user.id) .toString(), ) .setLabel('View Settings') @@ -80,21 +75,13 @@ export default class Settings extends HubCommand { } const settingsManager = await HubSettingsManager.create(hubId); - await interaction.reply({ embeds: [settingsManager.settingsEmbed], ephemeral: true }); + await interaction.reply({ embeds: [settingsManager.embed], ephemeral: true }); } private async runHubCheck(interaction: ChatInputCommandInteraction) { const hubName = interaction.options.getString('hub') as string | undefined; - const hub = await db.hub.findFirst({ - where: { - name: hubName, - OR: [ - { ownerId: interaction.user.id }, - { moderators: { some: { userId: interaction.user.id, position: 'manager' } } }, - ], - }, - }); + const hub = hubName ? (await this.hubService.findHubsByName(hubName)).at(0) : null; - if (!hub) { + if (!await hub?.isManager(interaction.user.id)) { await this.replyEmbed( interaction, 'Hub not found. Provide a valid hub in the `hub` option of the command.', diff --git a/src/commands/slash/Main/hub/visibility.ts b/src/commands/slash/Main/hub/visibility.ts index 3ff74824..384817e4 100644 --- a/src/commands/slash/Main/hub/visibility.ts +++ b/src/commands/slash/Main/hub/visibility.ts @@ -1,13 +1,10 @@ +import HubManager from '#main/managers/HubManager.js'; +import { InfoEmbed } from '#main/utils/EmbedUtils.js'; +import { wait } from '#main/utils/Utils.js'; import { emojis } from '#utils/Constants.js'; -import HubLogManager from '#main/managers/HubLogManager.js'; -import db from '#main/utils/Db.js'; -import { isHubManager } from '#main/utils/hub/utils.js'; -import { Hub } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { ChatInputCommandInteraction, time } from 'discord.js'; import HubCommand from './index.js'; -import { InfoEmbed } from '#main/utils/EmbedUtils.js'; -import { wait } from '#main/utils/Utils.js'; export default class VisibilityCommnd extends HubCommand { async execute(interaction: ChatInputCommandInteraction) { @@ -15,9 +12,9 @@ export default class VisibilityCommnd extends HubCommand { const hubName = interaction.options.getString('hub', true); const visibility = interaction.options.getString('visibility', true) as 'public' | 'private'; - const hub = await db.hub.findFirst({ where: { name: hubName } }); + const hub = (await this.hubService.findHubsByName(hubName)).at(0); - if (!hub || !isHubManager(interaction.user.id, hub)) { + if (!hub || await hub.isManager(interaction.user.id)) { await this.replyEmbed(interaction, 'hub.notFound_mod', { t: { emoji: emojis.no }, ephemeral: true, @@ -31,28 +28,35 @@ export default class VisibilityCommnd extends HubCommand { if (!passedChecks) return; } - const updatedHub = await db.hub.update({ - where: { id: hub.id }, - data: { private: visibility === 'private' }, - }); + await hub.setPrivate(visibility === 'private'); await this.replyEmbed(interaction, 'hub.manage.visibility.success', { content: ' ', ephemeral: true, edit: true, t: { - emoji: updatedHub.private ? '🔒' : '🔓', - visibility: updatedHub.private ? 'private' : 'public', + emoji: hub.data.private ? '🔒' : '🔓', + visibility: hub.data.private ? 'private' : 'public', }, }); } - private async runPublicRequirementChecks(interaction: ChatInputCommandInteraction, hub: Hub) { - const logConfig = await HubLogManager.create(hub.id); + private async runPublicRequirementChecks( + interaction: ChatInputCommandInteraction, + hub: HubManager, + ) { + const logConfig = await hub.fetchLogConfig(); + const mods = await hub.moderators.fetchAll(); const requirements = [ - { name: 'Hub is older than 24 hours', check: hub.createdAt < new Date(Date.now() + 24 * 60 * 60 * 1000) }, - { name: 'Hub has more than 2 moderators', check: hub.moderators.length >= 2 }, - { name: 'Hub has accepts user-reports by setting a log channel for reports', check: logConfig.config.reports !== null }, + { + name: 'Hub is older than 24 hours', + check: hub.data.createdAt < new Date(Date.now() + 24 * 60 * 60 * 1000), + }, + { name: 'Hub atleast than 2 moderators', check: mods.length >= 2 }, + { + name: 'Hub has accepts user-reports by setting a log channel for reports', + check: logConfig.config.reports !== null, + }, ]; const passed = requirements.every((r) => r.check); diff --git a/src/commands/slash/Main/set/reply_mentions.ts b/src/commands/slash/Main/set/reply_mentions.ts index 3b7489ba..3806b6b6 100644 --- a/src/commands/slash/Main/set/reply_mentions.ts +++ b/src/commands/slash/Main/set/reply_mentions.ts @@ -1,7 +1,8 @@ import { emojis } from '#utils/Constants.js'; import { ChatInputCommandInteraction } from 'discord.js'; import Set from './index.js'; -export default class replyMention extends Set { + +export default class ReplyMention extends Set { async execute(interaction: ChatInputCommandInteraction) { const { userManager } = interaction.client; const dbUser = await userManager.getUser(interaction.user.id); diff --git a/src/commands/slash/Staff/find/server.ts b/src/commands/slash/Staff/find/server.ts index 0a6f1342..70fdcbe0 100644 --- a/src/commands/slash/Staff/find/server.ts +++ b/src/commands/slash/Staff/find/server.ts @@ -19,12 +19,12 @@ export default class Server extends Find { const owner = await guild?.fetchOwner(); - const guildInDb = await db.connectedList.findMany({ + const guildInDb = await db.connection.findMany({ where: { serverId: guild.id }, include: { hub: true }, }); - const guildBlacklisted = await db.serverInfraction.count({ + const guildBlacklisted = await db.infraction.count({ where: { expiresAt: { gt: new Date() }, serverId: guild.id }, }); const guildBoostLevel = GuildPremiumTier[guild.premiumTier]; diff --git a/src/commands/slash/Staff/find/user.ts b/src/commands/slash/Staff/find/user.ts index 88fb6cde..59ac9cd4 100644 --- a/src/commands/slash/Staff/find/user.ts +++ b/src/commands/slash/Staff/find/user.ts @@ -4,6 +4,7 @@ import { InfoEmbed } from '#utils/EmbedUtils.js'; import { stripIndents } from 'common-tags'; import { ChatInputCommandInteraction, EmbedBuilder } from 'discord.js'; import Find from './index.js'; +import { HubService } from '#main/services/HubService.js'; export default class Server extends Find { async execute(interaction: ChatInputCommandInteraction): Promise { @@ -19,7 +20,7 @@ export default class Server extends Find { } const userData = await interaction.client.userManager.getUser(user.id); - const blacklistList = await db.userInfraction.findMany({ + const blacklistList = await db.infraction.findMany({ where: { userId: user.id, status: 'ACTIVE', type: 'BLACKLIST' }, select: { hub: { select: { name: true } } }, }); @@ -32,11 +33,10 @@ export default class Server extends Find { const serversOwned = user.client.guilds.cache .filter((guild) => guild.ownerId === user.id) .map((guild) => guild.name); - const hubsOwned = await db.hub.findMany({ - where: { ownerId: user.id }, - }); + + const ownedHubs = await new HubService().getOwnedHubs(user.id); const numServersOwned = serversOwned.length > 0 ? serversOwned.join(', ') : 'None'; - const numHubOwned = hubsOwned.length > 0 ? hubsOwned.map((hub) => hub.name).join(', ') : 'None'; + const numHubOwned = ownedHubs.length > 0 ? ownedHubs.map((hub) => hub.data.name).join(', ') : 'None'; const embed = new EmbedBuilder() .setAuthor({ name: user.username, iconURL: user.avatarURL()?.toString() }) @@ -59,7 +59,7 @@ export default class Server extends Find { value: stripIndents` > ${emojis.chat_icon} **Hubs Owned:** ${numHubOwned} > ${emojis.delete} **Blacklisted From:** ${blacklistedFromStr} - > ${emojis.deleteDanger_icon} **Banned:** ${userData?.banMeta?.reason ? 'Yes' : 'No'} + > ${emojis.deleteDanger_icon} **Banned:** ${userData?.banReason ? 'Yes' : 'No'} `, }, ]); diff --git a/src/commands/slash/Staff/unban.ts b/src/commands/slash/Staff/unban.ts index 24f13166..518306ce 100644 --- a/src/commands/slash/Staff/unban.ts +++ b/src/commands/slash/Staff/unban.ts @@ -23,7 +23,7 @@ export default class Unban extends BaseCommand { const { userManager } = interaction.client; const alreadyBanned = await userManager.getUser(user.id); - if (!alreadyBanned?.banMeta?.reason) { + if (!alreadyBanned?.banReason) { const notBannedEmbed = new InfoEmbed().setDescription( `${emojis.slash} User **${user.username}** is not banned.`, ); diff --git a/src/events/interactionCreate.ts b/src/events/interactionCreate.ts index 1950f15c..92aa9205 100644 --- a/src/events/interactionCreate.ts +++ b/src/events/interactionCreate.ts @@ -1,13 +1,17 @@ +import BaseCommand from '#main/core/BaseCommand.js'; import BaseEventListener from '#main/core/BaseEventListener.js'; import { showRulesScreening } from '#main/interactions/RulesScreening.js'; import Constants, { emojis } from '#utils/Constants.js'; -import { CustomID } from '#utils/CustomID.js'; +import { CustomID, ParsedCustomId } from '#utils/CustomID.js'; import { InfoEmbed } from '#utils/EmbedUtils.js'; import { t } from '#utils/Locale.js'; import { checkIfStaff, handleError } from '#utils/Utils.js'; import { UserData } from '@prisma/client'; import { + AutocompleteInteraction, CacheType, + ChatInputCommandInteraction, + ContextMenuCommandInteraction, Interaction, MessageComponentInteraction, ModalSubmitInteraction, @@ -18,100 +22,164 @@ export default class InteractionCreate extends BaseEventListener<'interactionCre async execute(interaction: Interaction) { try { - if (this.isInMaintenance(interaction)) return; - - const dbUser = (await interaction.client.userManager.getUser(interaction.user.id)) ?? null; - - if (await this.isUserBanned(interaction, dbUser)) return; - if (this.shouldShowRules(interaction, dbUser)) { - return await showRulesScreening(interaction, dbUser); - } - - if (interaction.isMessageComponent() || interaction.isModalSubmit()) { - await this.handleModalsAndComponents(interaction, dbUser); - } - else { - const { commands } = interaction.client; - const command = commands.get(interaction.commandName); - if (command?.staffOnly && !checkIfStaff(interaction.user.id)) return; - - if (interaction.isAutocomplete()) { - if (command?.autocomplete) await command.autocomplete(interaction); - } - else { - await command?.execute(interaction); - } - } + const preCheckResult = await this.performPreChecks(interaction); + if (!preCheckResult.shouldContinue) return; + + await this.handleInteraction(interaction, preCheckResult.dbUser); } catch (e) { handleError(e, interaction); } } - private shouldShowRules(interaction: Interaction, dbUser: UserData | null) { - // don't show rules again if user is clicking on the rules screen buttons - return ( - dbUser?.acceptedRules === false && - (interaction.isButton() && - CustomID.parseCustomId(interaction.customId).prefix === 'rulesScreen') === false - ); + private async performPreChecks(interaction: Interaction) { + if (this.isInMaintenance(interaction)) { + return { shouldContinue: false, dbUser: null }; + } + + const dbUser = (await interaction.client.userManager.getUser(interaction.user.id)) ?? null; + + if (await this.isUserBanned(interaction, dbUser)) { + return { shouldContinue: false, dbUser: null }; + } + + if (this.shouldShowRules(interaction, dbUser)) { + await showRulesScreening(interaction, dbUser); + return { shouldContinue: false, dbUser: null }; + } + + return { shouldContinue: true, dbUser }; + } + + private async handleInteraction(interaction: Interaction, dbUser: UserData | null) { + if (interaction.isMessageComponent() || interaction.isModalSubmit()) { + await this.handleComponentOrModal(interaction, dbUser); + return; + } + + await this.handleCommand(interaction); } - private async handleModalsAndComponents( + private async handleCommand( + interaction: + | ChatInputCommandInteraction + | ContextMenuCommandInteraction + | AutocompleteInteraction, + ) { + const { commands } = interaction.client; + const command = commands.get(interaction.commandName); + + if (!this.validateCommandAccess(command, interaction)) return; + + if (interaction.isAutocomplete()) { + await this.handleAutocomplete(command, interaction); + return; + } + + await command?.execute(interaction); + } + + private validateCommandAccess( + command: BaseCommand | undefined, + interaction: Interaction | ContextMenuCommandInteraction, + ) { + if (command?.staffOnly && !checkIfStaff(interaction.user.id)) { + return false; + } + return true; + } + + private async handleAutocomplete( + command: BaseCommand | undefined, + interaction: AutocompleteInteraction, + ) { + if (command?.autocomplete) { + await command.autocomplete(interaction); + } + } + + private async handleComponentOrModal( interaction: ModalSubmitInteraction | MessageComponentInteraction, dbUser: UserData | null, ) { const customId = CustomID.parseCustomId(interaction.customId); + const handler = this.getInteractionHandler(interaction, customId); + + if (await this.isExpiredInteraction(interaction, customId, dbUser)) { + return; + } + + if (handler) await handler(interaction); + } - // component decorator stuff + private getInteractionHandler( + interaction: MessageComponentInteraction | ModalSubmitInteraction, + customId: ParsedCustomId, + ) { const { interactions } = interaction.client; const customIdSuffix = customId.suffix ? `:${customId.suffix}` : ''; - const interactionHandler = - interactions.get(`${customId.prefix}${customIdSuffix}`) ?? interactions.get(customId.prefix); - const isExpiredInteraction = customId.expiry && customId.expiry < Date.now(); - - if (isExpiredInteraction) { - const { userManager } = interaction.client; - const locale = await userManager.getUserLocale(dbUser); - const embed = new InfoEmbed({ - description: t('errors.notUsable', locale, { emoji: emojis.slash }), - }); + return ( + interactions.get(`${customId.prefix}${customIdSuffix}`) ?? interactions.get(customId.prefix) + ); + } - await interaction.reply({ embeds: [embed], ephemeral: true }); - return; + private async isExpiredInteraction( + interaction: MessageComponentInteraction | ModalSubmitInteraction, + customId: ParsedCustomId, + dbUser: UserData | null, + ) { + if (!customId.expiry || customId.expiry >= Date.now()) { + return false; } - if (interactionHandler) await interactionHandler(interaction); + const { userManager } = interaction.client; + const locale = await userManager.getUserLocale(dbUser); + const embed = new InfoEmbed({ + description: t('errors.notUsable', locale, { emoji: emojis.slash }), + }); + + await interaction.reply({ embeds: [embed], ephemeral: true }); + return true; + } + + private shouldShowRules(interaction: Interaction, dbUser: UserData | null) { + const isRulesScreenButton = + interaction.isButton() && + CustomID.parseCustomId(interaction.customId).prefix === 'rulesScreen'; + + return dbUser?.acceptedRules === false && !isRulesScreenButton; } private isInMaintenance(interaction: Interaction) { - if (interaction.client.cluster.maintenance && interaction.isRepliable()) { - interaction - .reply({ - content: `${emojis.slash} The bot is currently undergoing maintenance. Please try again later.`, - ephemeral: true, - }) - .catch(() => null); - return true; + if (!interaction.client.cluster.maintenance || !interaction.isRepliable()) { + return false; } - return false; + + interaction + .reply({ + content: `${emojis.slash} The bot is currently undergoing maintenance. Please try again later.`, + ephemeral: true, + }) + .catch(() => null); + return true; } private async isUserBanned(interaction: Interaction, dbUser: UserData | undefined | null) { - if (dbUser?.banMeta?.reason) { - if (interaction.isRepliable()) { - const { userManager } = interaction.client; - const locale = await userManager.getUserLocale(dbUser); - await interaction.reply({ - content: t('errors.banned', locale, { - emoji: emojis.no, - support_invite: Constants.Links.SupportInvite, - }), - ephemeral: true, - }); - } - return true; + if (!dbUser?.banReason) { + return false; + } + + if (interaction.isRepliable()) { + const { userManager } = interaction.client; + const locale = await userManager.getUserLocale(dbUser); + await interaction.reply({ + content: t('errors.banned', locale, { + emoji: emojis.no, + support_invite: Constants.Links.SupportInvite, + }), + ephemeral: true, + }); } - return false; + return true; } } diff --git a/src/events/messageReactionAdd.ts b/src/events/messageReactionAdd.ts index 1cee8d87..ddff2c8d 100644 --- a/src/events/messageReactionAdd.ts +++ b/src/events/messageReactionAdd.ts @@ -1,5 +1,4 @@ import BaseEventListener from '#main/core/BaseEventListener.js'; -import { HubSettingsBitField } from '#main/modules/BitFields.js'; import { HubService } from '#main/services/HubService.js'; import db from '#main/utils/Db.js'; import { @@ -32,7 +31,7 @@ export default class ReadctionAdd extends BaseEventListener<'messageReactionAdd' const hubService = new HubService(db); const hub = originalMsg ? await hubService.fetchHub(originalMsg?.hubId) : null; - if (!originalMsg || !hub || !new HubSettingsBitField(hub.settings).has('Reactions')) { + if (!originalMsg || !hub?.settings.has('Reactions')) { return; } diff --git a/src/events/webhooksUpdate.ts b/src/events/webhooksUpdate.ts index d34af582..edbed9d4 100644 --- a/src/events/webhooksUpdate.ts +++ b/src/events/webhooksUpdate.ts @@ -12,7 +12,7 @@ export default class Ready extends BaseEventListener<'webhooksUpdate'> { channel: NewsChannel | TextChannel | VoiceChannel | ForumChannel | MediaChannel, ) { try { - const connection = await db.connectedList.findFirst({ + const connection = await db.connection.findFirst({ where: { OR: [{ channelId: channel.id }, { parentId: channel.id }] }, }); diff --git a/src/interactions/BlacklistAppeal.ts b/src/interactions/BlacklistAppeal.ts index 6b2747bd..4bb71f4f 100644 --- a/src/interactions/BlacklistAppeal.ts +++ b/src/interactions/BlacklistAppeal.ts @@ -1,8 +1,8 @@ import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; import BlacklistManager from '#main/managers/BlacklistManager.js'; import HubLogManager from '#main/managers/HubLogManager.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; +import InfractionManager from '#main/managers/InfractionManager.js'; + import { HubService } from '#main/services/HubService.js'; import db from '#main/utils/Db.js'; import { CustomID } from '#utils/CustomID.js'; @@ -31,7 +31,6 @@ export const buildAppealSubmitButton = (type: 'user' | 'server', hubId: string) .setStyle(ButtonStyle.Primary), ); - export default class AppealInteraction { @RegisterInteractionHandler('appealSubmit', 'button') async appealSubmitButton(interaction: ButtonInteraction): Promise { @@ -80,23 +79,18 @@ export default class AppealInteraction { appealIconUrl = interaction.guild?.iconURL(); appealName = interaction.guild?.name; appealTargetId = interaction.guildId as string; - - new ServerInfractionManager(appealTargetId).updateInfraction( - { type: 'BLACKLIST', hubId, status: 'ACTIVE' }, - { appealerUserId: interaction.user.id, appealedAt: new Date() }, - ); } else { appealIconUrl = interaction.user.displayAvatarURL(); appealName = interaction.user.username; appealTargetId = interaction.user.id; - - new UserInfractionManager(appealTargetId).updateInfraction( - { type: 'BLACKLIST', hubId, status: 'ACTIVE' }, - { appealedAt: new Date() }, - ); } + await new InfractionManager(type, appealTargetId).updateInfraction( + { type: 'BLACKLIST', hubId, status: 'ACTIVE' }, + { appealedBy: interaction.user.id, appealedAt: new Date() }, + ); + await logAppeals(type, hubId, interaction.user, { appealsChannelId, appealsRoleId, @@ -138,8 +132,8 @@ export default class AppealInteraction { const blacklistManager = type === 'user' - ? new BlacklistManager(new UserInfractionManager(targetId)) - : new BlacklistManager(new ServerInfractionManager(targetId)); + ? new BlacklistManager('user', targetId) + : new BlacklistManager('server', targetId); const blacklist = await blacklistManager.fetchBlacklist(hubId); if (!blacklist) return; @@ -162,13 +156,13 @@ export default class AppealInteraction { 'appealerUserId' in blacklist ? await interaction.client.users.fetch(blacklist.appealerUserId as string) : await interaction.client.users.fetch(targetId); - extraServerSteps = `You can re-join the hub by running \`/hub join hub:${hub?.name}\`.`; + extraServerSteps = `You can re-join the hub by running \`/hub join hub:${hub?.data.name}\`.`; } const approvalStatus = customId.suffix === 'approve' ? 'appealed 🎉' : 'rejected'; const message = ` ### Blacklist Appeal Review - Your blacklist appeal for ${appealTarget} in the hub **${hub?.name}** has been ${approvalStatus}. ${extraServerSteps} + Your blacklist appeal for ${appealTarget} in the hub **${hub?.data.name}** has been ${approvalStatus}. ${extraServerSteps} `; const embed = new EmbedBuilder() @@ -198,21 +192,20 @@ export default class AppealInteraction { hubId: string, type: 'user' | 'server', ): Promise<{ passedCheck: boolean }> { - const infractionManager = - type === 'user' - ? new UserInfractionManager(interaction.user.id) - : new ServerInfractionManager(interaction.guildId as string); - - - const blacklistManager = new BlacklistManager(infractionManager); + const blacklistManager = new BlacklistManager( + type, + type === 'user' ? interaction.user.id : (interaction.guildId as string), + ); const hubService = new HubService(db); const hub = await hubService.fetchHub(hubId); - const allInfractions = await infractionManager.getHubInfractions(hubId, { type: 'BLACKLIST' }); + const allInfractions = await blacklistManager.infractions.getHubInfractions(hubId, { + type: 'BLACKLIST', + }); const sevenDays = 60 * 60 * 24 * 7 * 1000; - const appealCooldown = hub?.appealCooldownHours - ? hub.appealCooldownHours * (60 * 60 * 1000) + const appealCooldown = hub?.data.appealCooldownHours + ? hub.data.appealCooldownHours * (60 * 60 * 1000) : sevenDays; const lastAppealed = allInfractions.find( diff --git a/src/interactions/InactiveConnect.ts b/src/interactions/InactiveConnect.ts index e3f81544..b43e63e0 100644 --- a/src/interactions/InactiveConnect.ts +++ b/src/interactions/InactiveConnect.ts @@ -32,8 +32,8 @@ export const buildConnectionButtons = ( .setCustomId( new CustomID() .setIdentifier(opts.customCustomId ?? 'connection', 'toggle') - .addArgs(channelId) - .addArgs(opts?.userId ?? '') + .setArgs(channelId) + .setArgs(opts?.userId ?? '') .toString(), ) .setLabel(connected ? 'Disconnect' : 'Reconnect') diff --git a/src/interactions/ModPanel.ts b/src/interactions/ModPanel.ts index e711a360..a268dbef 100644 --- a/src/interactions/ModPanel.ts +++ b/src/interactions/ModPanel.ts @@ -1,7 +1,7 @@ import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; import BlacklistManager from '#main/managers/BlacklistManager.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; + + import { HubService } from '#main/services/HubService.js'; import { CustomID } from '#main/utils/CustomID.js'; import db from '#main/utils/Db.js'; @@ -106,7 +106,7 @@ export default class ModPanelHandler { ) { const hubService = new HubService(db); const hub = await hubService.fetchHub(originalMsg.hubId); - if (!hub || !isStaffOrHubMod(interaction.user.id, hub)) { + if (!hub || !await isStaffOrHubMod(interaction.user.id, hub)) { const embed = new InfoEmbed().setDescription(t('errors.messageNotSentOrExpired', locale)); await interaction.editReply({ embeds: [embed] }); return false; @@ -125,8 +125,8 @@ export async function buildModPanel( const deleteInProgress = await isDeleteInProgress(originalMsg.messageId); const { userManager } = interaction.client; - const userBlManager = new BlacklistManager(new UserInfractionManager(originalMsg.authorId)); - const serverBlManager = new BlacklistManager(new ServerInfractionManager(originalMsg.guildId)); + const userBlManager = new BlacklistManager('user', originalMsg.authorId); + const serverBlManager = new BlacklistManager('server', originalMsg.guildId); const isUserBlacklisted = Boolean(await userBlManager.fetchBlacklist(originalMsg.hubId)); const isServerBlacklisted = Boolean(await serverBlManager.fetchBlacklist(originalMsg.hubId)); @@ -135,14 +135,14 @@ export async function buildModPanel( const embed = buildInfoEmbed(user.username, server?.name ?? 'Unknown Server', { isUserBlacklisted, isServerBlacklisted, - isBanned: Boolean(dbUserTarget?.banMeta?.reason), + isBanned: Boolean(dbUserTarget?.banReason), isDeleteInProgress: deleteInProgress, }); const buttons = buildButtons(interaction, originalMsg.messageId, { isUserBlacklisted, isServerBlacklisted, - isBanned: Boolean(dbUserTarget?.banMeta?.reason), + isBanned: Boolean(dbUserTarget?.banReason), isDeleteInProgress: deleteInProgress, }); diff --git a/src/interactions/NetworkReaction.ts b/src/interactions/NetworkReaction.ts index 22b1902b..0b988339 100644 --- a/src/interactions/NetworkReaction.ts +++ b/src/interactions/NetworkReaction.ts @@ -1,20 +1,20 @@ -import Constants, { emojis } from '#utils/Constants.js'; import { RegisterInteractionHandler } from '#main/decorators/RegisterInteractionHandler.js'; -import HubSettingsManager from '#main/managers/HubSettingsManager.js'; -import { HubSettingsBitField } from '#main/modules/BitFields.js'; +import HubManager from '#main/managers/HubManager.js'; +import { HubService } from '#main/services/HubService.js'; +import db from '#main/utils/Db.js'; import { findOriginalMessage, getOriginalMessage, OriginalMessage, storeMessage, } from '#main/utils/network/messageUtils.js'; +import Constants, { emojis } from '#utils/Constants.js'; import { CustomID, ParsedCustomId } from '#utils/CustomID.js'; import { t } from '#utils/Locale.js'; import { addReaction, removeReaction, updateReactions } from '#utils/reaction/actions.js'; import { checkBlacklists } from '#utils/reaction/helpers.js'; import sortReactions from '#utils/reaction/sortReactions.js'; import { getEmojiId } from '#utils/Utils.js'; -import { Hub } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { ActionRowBuilder, @@ -25,8 +25,6 @@ import { StringSelectMenuBuilder, time, } from 'discord.js'; -import db from '#main/utils/Db.js'; -import { HubService } from '#main/services/HubService.js'; export default class NetworkReactionInteraction { @RegisterInteractionHandler('reaction_') @@ -43,7 +41,7 @@ export default class NetworkReactionInteraction { const hubService = new HubService(db); const hub = originalMessage ? await hubService.fetchHub(originalMessage?.hubId) : null; - if (!originalMessage || !this.isReactionAllowed(hub)) return; + if (!originalMessage || !hub?.settings.has('Reactions')) return; const { userBlacklisted, serverBlacklisted } = await this.checkUserPermissions( hub, @@ -70,12 +68,8 @@ export default class NetworkReactionInteraction { return { customId, messageId }; } - private isReactionAllowed(hub: Hub | null): hub is Hub { - return Boolean(hub && new HubSettingsBitField(hub.settings).has('Reactions')); - } - private async checkUserPermissions( - hub: Hub, + hub: HubManager, interaction: ButtonInteraction | AnySelectMenuInteraction, ) { return await checkBlacklists(hub.id, interaction.guildId, interaction.user.id); @@ -111,7 +105,7 @@ export default class NetworkReactionInteraction { private async handleViewAllReactions( interaction: ButtonInteraction | AnySelectMenuInteraction, messageId: string, - hub: Hub, + hub: HubManager, ) { const originalMessage = (await getOriginalMessage(messageId)) ?? (await findOriginalMessage(messageId)); @@ -142,7 +136,7 @@ export default class NetworkReactionInteraction { private buildReactionMenu( dbReactions: { [key: string]: Snowflake[] }, interaction: ButtonInteraction | AnySelectMenuInteraction, - hub: Hub, + hub: HubManager, ) { const sortedReactions = sortReactions(dbReactions); let totalReactions = 0; @@ -150,13 +144,12 @@ export default class NetworkReactionInteraction { const reactionMenu = new ActionRowBuilder().addComponents( new StringSelectMenuBuilder() .setCustomId( - new CustomID().setIdentifier('reaction_').addArgs(interaction.message.id).toString(), + new CustomID().setIdentifier('reaction_').setArgs(interaction.message.id).toString(), ) .setPlaceholder('Add a reaction'), ); - const hubSettings = new HubSettingsManager(hub.id, hub.settings); - if (!hubSettings.getSetting('Reactions')) reactionMenu.components[0].setDisabled(true); + if (!hub.settings.has('Reactions')) reactionMenu.components[0].setDisabled(true); sortedReactions.forEach((r, index) => { if (r[1].length === 0 || index >= 10) return; diff --git a/src/interactions/ShowModPanel.ts b/src/interactions/ShowModPanel.ts index 84f30564..306c36cb 100644 --- a/src/interactions/ShowModPanel.ts +++ b/src/interactions/ShowModPanel.ts @@ -11,7 +11,7 @@ import db from '#main/utils/Db.js'; export const modPanelButton = (targetMsgId: string, opts?: { label?: string; emoji?: string }) => new ButtonBuilder() - .setCustomId(new CustomID().setIdentifier('showModPanel').addArgs(targetMsgId).toString()) + .setCustomId(new CustomID().setIdentifier('showModPanel').setArgs(targetMsgId).toString()) .setStyle(ButtonStyle.Danger) .setLabel(opts?.label ?? 'Mod Panel') .setEmoji(emojis.blobFastBan); @@ -30,7 +30,7 @@ export default class ModActionsButton { const hubService = new HubService(db); const hub = originalMessage ? await hubService.fetchHub(originalMessage?.hubId) : null; - if (!originalMessage || !hub || !isStaffOrHubMod(interaction.user.id, hub)) { + if (!originalMessage || !hub || !await isStaffOrHubMod(interaction.user.id, hub)) { await interaction.editReply({ components: [] }); await interaction.followUp({ embeds: [new InfoEmbed({ description: `${emojis.slash} Message was deleted.` })], @@ -39,7 +39,7 @@ export default class ModActionsButton { return; } - if (!isStaffOrHubMod(interaction.user.id, hub)) return; + if (!await isStaffOrHubMod(interaction.user.id, hub)) return; const panel = await buildModPanel(interaction, originalMessage); await interaction.followUp({ diff --git a/src/managers/BlacklistManager.ts b/src/managers/BlacklistManager.ts index c557bb87..cebc0db9 100644 --- a/src/managers/BlacklistManager.ts +++ b/src/managers/BlacklistManager.ts @@ -1,49 +1,39 @@ -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; +import InfractionManager from '#main/managers/InfractionManager.js'; +import UserDbManager from '#main/managers/UserDbManager.js'; +import { HubService } from '#main/services/HubService.js'; import Constants, { emojis } from '#main/utils/Constants.js'; -import db from '#main/utils/Db.js'; import { sendLog } from '#main/utils/hub/logger/Default.js'; import { resolveEval } from '#main/utils/Utils.js'; -import { InfractionStatus, Prisma, ServerInfraction, UserInfraction } from '@prisma/client'; +import { Infraction, InfractionStatus, Prisma } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { Client, EmbedBuilder, User, type Snowflake } from 'discord.js'; export default class BlacklistManager { - readonly targetId: Snowflake; - readonly infracManager; - - constructor(infracManager: UserInfractionManager | ServerInfractionManager) { - this.targetId = infracManager.targetId; - this.infracManager = infracManager; + public readonly targetId: Snowflake; + public readonly infractions; + private readonly type: 'user' | 'server'; + private readonly userManager = new UserDbManager(); + + constructor(type: 'user' | 'server', targetId: Snowflake) { + this.type = type; + this.targetId = targetId; + this.infractions = new InfractionManager(type, targetId); } public async addBlacklist(opts: { hubId: string; reason: string; moderatorId: string; - serverName: string; - expiresAt: Date | null; - }): Promise; - public async addBlacklist(opts: { - hubId: string; - reason: string; - moderatorId: string; - expiresAt: Date | null; - }): Promise; - public async addBlacklist(opts: { - hubId: string; - reason: string; - moderatorId: string; - serverName: string; expiresAt: Date | null; - }): Promise { + serverName?: string; + }): Promise { const blacklisted = await this.fetchBlacklist(opts.hubId); if (blacklisted) { - return await this.infracManager.updateInfraction( + return await this.infractions.updateInfraction( { hubId: opts.hubId, type: 'BLACKLIST', status: 'ACTIVE' }, { - dateIssued: new Date(), + updatedAt: new Date(), expiresAt: opts.expiresAt, reason: opts.reason, moderatorId: opts.moderatorId, @@ -51,7 +41,11 @@ export default class BlacklistManager { ); } - return await this.infracManager.addInfraction('BLACKLIST', opts); + if (this.type === 'user' && !(await this.userManager.getUser(this.targetId))) { + await this.userManager.createUser({ id: this.targetId }); // Create user if not found + } + + return await this.infractions.addInfraction('BLACKLIST', opts); } public async removeBlacklist( @@ -61,24 +55,21 @@ export default class BlacklistManager { const exists = await this.fetchBlacklist(hubId); if (!exists) return null; - return await this.infracManager.revokeInfraction('BLACKLIST', hubId, status); + return await this.infractions.revokeInfraction('BLACKLIST', hubId, status); } - public async updateBlacklist( - hubId: string, - data: Prisma.UserInfractionUpdateInput | Prisma.ServerInfractionUpdateInput, - ) { + public async updateBlacklist(hubId: string, data: Prisma.InfractionUpdateInput) { const blacklisted = await this.fetchBlacklist(hubId); if (!blacklisted) return null; - return await this.infracManager.updateInfraction( + return await this.infractions.updateInfraction( { hubId, type: 'BLACKLIST', status: 'ACTIVE' }, data, ); } public async fetchBlacklist(hubId: string) { - const blacklist = await this.infracManager.fetchInfraction('BLACKLIST', hubId, 'ACTIVE'); + const blacklist = await this.infractions.fetchInfraction('BLACKLIST', hubId, 'ACTIVE'); return blacklist; } /** @@ -95,16 +86,17 @@ export default class BlacklistManager { ) { const { mod, reason, expiresAt } = opts; - const hub = await db.hub.findFirst({ where: { id: hubId }, include: { logConfig: true } }); - const { modLogs } = hub?.logConfig.at(0) ?? {}; - if (!modLogs) return; + const hub = await new HubService().fetchHub(hubId); + const logConfig = await hub?.fetchLogConfig(); + + if (!logConfig?.config.modLogs) return; let name; let iconURL; let type; let target; - if (this.infracManager instanceof ServerInfractionManager) { + if (this.infractions.targetType === 'server') { target = resolveEval( await client.cluster.broadcastEval( (c, guildId) => { @@ -135,7 +127,7 @@ export default class BlacklistManager { stripIndents` ${emojis.dotBlue} **${type}:** ${name} (${target.id}) ${emojis.dotBlue} **Moderator:** ${mod.username} (${mod.id}) - ${emojis.dotBlue} **Hub:** ${hub?.name} + ${emojis.dotBlue} **Hub:** ${hub?.data.name} `, ) .addFields( @@ -149,12 +141,10 @@ export default class BlacklistManager { .setColor(Constants.Colors.interchatBlue) .setFooter({ text: `Blacklisted by: ${mod.username}`, iconURL: mod.displayAvatarURL() }); - await sendLog(opts.mod.client.cluster, modLogs, embed); + await sendLog(opts.mod.client.cluster, logConfig?.config.modLogs.channelId, embed); } - public static isServerBlacklist( - data: UserInfraction | ServerInfraction | null, - ): data is ServerInfraction { - return Boolean(data && 'serverId' in data); + public static isServerBlacklist(data: Infraction | null) { + return data?.serverId !== null && data?.serverName === null; } } diff --git a/src/managers/HubLogManager.ts b/src/managers/HubLogManager.ts index 706707c5..426d1818 100644 --- a/src/managers/HubLogManager.ts +++ b/src/managers/HubLogManager.ts @@ -60,14 +60,9 @@ export default class HubLogManager { async setLogChannel(type: LogConfigTypes, channelId: string) { - if (this.logsWithRoleId.includes(type)) { - await this.updateLogConfig({ - [type]: { upsert: { set: { channelId }, update: { channelId } } }, - }); - return; - } - - await this.updateLogConfig({ [type]: channelId }); + await this.updateLogConfig({ + [type]: { upsert: { set: { channelId }, update: { channelId } } }, + }); } async resetLog(...type: LogConfigTypes[]) { @@ -130,8 +125,8 @@ export default class HubLogManager { .setCustomId( new CustomID() .setIdentifier('hub_edit', 'logsSelect') - .addArgs(userId) - .addArgs(hubId) + .setArgs(userId) + .setArgs(hubId) .toString(), ) .setPlaceholder('Choose a log type to set a channel.') diff --git a/src/managers/HubManager.ts b/src/managers/HubManager.ts new file mode 100644 index 00000000..81cf2431 --- /dev/null +++ b/src/managers/HubManager.ts @@ -0,0 +1,164 @@ +import HubLogManager from '#main/managers/HubLogManager.js'; +import HubModeratorManager from '#main/managers/HubModeratorManager.js'; +import HubSettingsManager from '#main/managers/HubSettingsManager.js'; +import { HubService } from '#main/services/HubService.js'; +import { getHubConnections } from '#main/utils/ConnectedListUtils.js'; +import { RedisKeys } from '#main/utils/Constants.js'; +import db from '#main/utils/Db.js'; +import Logger from '#main/utils/Logger.js'; +import getRedis from '#main/utils/Redis.js'; +import { BlockWord, Hub, HubModerator } from '@prisma/client'; +import { Redis } from 'ioredis'; + +export default class HubManager { + public readonly id: string; + + private readonly cache: Redis; + private readonly hubService: HubService; + private readonly settingsManager: HubSettingsManager; + private readonly modManager: HubModeratorManager; + + private readonly blockWordsKey: `${RedisKeys.Hub}:${string}:blockWords`; + private readonly expirationSeconds = 10 * 60 * 1000; // 10 mins + + private hub: Hub; + private logManager: HubLogManager | null = null; + + constructor( + hub: Hub, + hubService = new HubService(), + modManager = new HubModeratorManager(this), + cache: Redis = getRedis(), + ) { + this.hub = hub; + this.id = hub.id; + this.settingsManager = new HubSettingsManager(this); + + this.blockWordsKey = `${RedisKeys.Hub}:${hub.id}:blockWords`; + + this.cache = cache; + this.hubService = hubService; + this.modManager = modManager; + + this.cacheHub().catch(Logger.error); + } + + private async cacheHub() { + await this.cache.set( + `${this.hubService.hubKey}${this.hub.id}`, + JSON.stringify(this.hub), + 'EX', + this.expirationSeconds, + ); + } + + public get data() { + return this.hub; + } + + public get moderators() { + return this.modManager; + } + + async delete() { + await this.hubService.deleteHub(this.hub.id); + } + async setDescription(description: string) { + this.hub = await db.hub.update({ where: { id: this.hub.id }, data: { description } }); + this.cacheHub(); + } + + async setIconUrl(iconUrl: string) { + this.hub = await db.hub.update({ where: { id: this.hub.id }, data: { iconUrl } }); + this.cacheHub(); + } + + async setBannerUrl(bannerUrl: string | null) { + this.hub = await db.hub.update({ where: { id: this.hub.id }, data: { bannerUrl } }); + this.cacheHub(); + } + + async setPrivate(isPrivate: boolean) { + this.hub = await db.hub.update({ where: { id: this.hub.id }, data: { private: isPrivate } }); + this.cacheHub(); + } + + async setLocked(locked: boolean) { + this.hub = await db.hub.update({ where: { id: this.hub.id }, data: { locked } }); + this.cacheHub(); + } + async setAppealCooldownHours(appealCooldownHours: number) { + this.hub = await db.hub.update({ where: { id: this.hub.id }, data: { appealCooldownHours } }); + this.cacheHub(); + } + + async createInvite(expires: Date) { + const createdInvite = await db.hubInvite.create({ + data: { + hub: { connect: { id: this.hub.id } }, + expires, + }, + }); + + return createdInvite; + } + + /** + * This method is made specifically for the HubSettingsManager to update settings + * @param settings - Bitfield of settings + */ + async setSettings(settings: number) { + this.hub = await db.hub.update({ where: { id: this.hub.id }, data: { settings } }); + this.cacheHub(); + } + + get settings() { + return this.settingsManager; + } + + async fetchBlockWords() { + const fromCache = await this.cache.smembers(this.blockWordsKey); + if (fromCache.length > 0) { + return fromCache.map((c) => JSON.parse(c)) as BlockWord[]; + } + + const blockWords = await db.blockWord.findMany({ where: { hubId: this.hub.id } }); + await this.storeInCache(this.blockWordsKey, blockWords); + + return blockWords; + } + + async fetchInvites() { + const invites = await db.hubInvite.findMany({ where: { hubId: this.hub.id } }); + return invites; + } + + async fetchLogConfig() { + if (!this.logManager) this.logManager = await HubLogManager.create(this.hub.id); + return this.logManager; + } + + async fetchConnections() { + return await getHubConnections(this.hub.id); + } + + isOwner(userId: string) { + return this.data.ownerId === userId; + } + + private async storeInCache(key: string, data: BlockWord[] | HubModerator[]) { + const multi = this.cache.multi(); + multi.del(key); + data.forEach((bw) => multi.sadd(key, JSON.stringify(bw))); + multi.expire(key, 60 * 60 * 24); // + await multi.exec(); + } + + async isManager(userId: string) { + return await this.modManager.checkStatus(userId, ['MANAGER', 'OWNER']); + } + + async isMod(userId: string) { + return await this.modManager.checkStatus(userId); + } +} diff --git a/src/managers/HubModeratorManager.ts b/src/managers/HubModeratorManager.ts new file mode 100644 index 00000000..e9fb6bc6 --- /dev/null +++ b/src/managers/HubModeratorManager.ts @@ -0,0 +1,101 @@ +import HubManager from '#main/managers/HubManager.js'; +import { RedisKeys } from '#main/utils/Constants.js'; +import db from '#main/utils/Db.js'; +import getRedis from '#main/utils/Redis.js'; +import { handleError } from '#main/utils/Utils.js'; +import { HubModerator, Role } from '@prisma/client'; +import { Redis } from 'ioredis'; + +export default class HubModeratorManager { + private readonly hub: HubManager; + private readonly modsKey: string; + private readonly cache: Redis; + // 10 minutes + private readonly expirationSeconds = 10 * 60 * 1000; + + constructor(hub: HubManager, cache: Redis = getRedis()) { + this.hub = hub; + this.cache = cache; + this.modsKey = `${RedisKeys.Hub}:${hub.id}:moderators`; + } + + private async storeInCache(key: string, mods: HubModerator[]) { + await this.cache.hset( + this.modsKey, + mods.map((mod) => [mod.userId, JSON.stringify(mod)]).flat(), + ); + await this.cache.expire(this.modsKey, this.expirationSeconds); + } + + private async syncModeratorsCache(data: HubModerator) { + try { + if ((await this.cache.hlen(this.modsKey)) === 0) { + await this.fetchAll(); + } + else { + await this.cache.hset(this.modsKey, data.userId, JSON.stringify(data)); + await this.cache.expire(this.modsKey, this.expirationSeconds); + } + } + catch (e) { + handleError(e); + } + } + + async add(userId: string, role: Role) { + const data = await db.hubModerator.create({ data: { hubId: this.hub.id, userId, role } }); + this.syncModeratorsCache(data); + } + + async remove(userId: string) { + await db.hubModerator.delete({ where: { hubId_userId: { hubId: this.hub.id, userId } } }); + await this.cache.hdel(this.modsKey, userId); + await this.cache.expire(this.modsKey, this.expirationSeconds); + } + + async update(userId: string, role: Role) { + const data = await db.hubModerator.update({ + where: { hubId_userId: { hubId: this.hub.id, userId } }, + data: { role }, + }); + + this.syncModeratorsCache(data); + } + + async fetchAll() { + const fromCache = await this.cache.hgetall(this.modsKey); + if (fromCache) { + return Object.values(fromCache).map((c) => JSON.parse(c)) as HubModerator[]; + } + + const mods = await db.hubModerator.findMany({ where: { hubId: this.hub.id } }); + await this.storeInCache(this.modsKey, mods); + + return mods; + } + + async fetch(userId: string) { + const fromCache = await this.cache.hget(this.modsKey, userId); + if (fromCache) return JSON.parse(fromCache) as HubModerator; + + const mod = await db.hubModerator.findFirst({ where: { hubId: this.hub.id, userId } }); + if (mod) { + this.cache.hlen(this.modsKey).then(async (len) => { + if (len === 0) this.fetchAll(); + else await this.cache.hset(this.modsKey, userId, JSON.stringify(mod)); + }); + } + + return mod; + } + + async checkStatus(userId: string, checkRoles?: Role[]) { + const mods = await this.fetchAll(); + return mods.some((mod) => { + if (mod.userId !== userId) return false; + if (!checkRoles) return true; + + return checkRoles.includes(mod.role) || this.hub.data.ownerId === userId; + }); + } +} diff --git a/src/managers/HubSettingsManager.ts b/src/managers/HubSettingsManager.ts index 48d87cea..93fa9cea 100644 --- a/src/managers/HubSettingsManager.ts +++ b/src/managers/HubSettingsManager.ts @@ -1,27 +1,27 @@ -import { emojis } from '#utils/Constants.js'; +import HubManager from '#main/managers/HubManager.js'; import { HubSettingsBitField, HubSettingsBits, type HubSettingsString, } from '#main/modules/BitFields.js'; -import db from '#utils/Db.js'; -import { Hub } from '@prisma/client'; -import { EmbedBuilder } from 'discord.js'; +import { HubService } from '#main/services/HubService.js'; import { InfoEmbed } from '#main/utils/EmbedUtils.js'; +import { emojis } from '#utils/Constants.js'; +import { EmbedBuilder } from 'discord.js'; export default class HubSettingsManager { - private readonly hubId: string; + private readonly hub: HubManager; private settings: HubSettingsBitField; - constructor(hubId: string, initialSettings?: number) { - this.hubId = hubId; - this.settings = new HubSettingsBitField(initialSettings ?? 0); + constructor(hub: HubManager) { + this.hub = hub; + this.settings = new HubSettingsBitField(hub.data.settings ?? 0); } static async create(hubId: string): Promise { - const hub = await db.hub.findUnique({ where: { id: hubId } }); + const hub = await new HubService().fetchHub(hubId); if (!hub) throw new Error('Hub not found'); - return new HubSettingsManager(hubId, hub.settings); + return new HubSettingsManager(hub); } async updateSetting(setting: HubSettingsString, value?: boolean): Promise { @@ -30,7 +30,7 @@ export default class HubSettingsManager { else this.settings.remove(setting); await this.saveSettings(); - return this.settings.has(setting); + return this.has(setting); } async updateMultipleSettings( @@ -44,21 +44,21 @@ export default class HubSettingsManager { await this.saveSettings(); } - getSetting(setting: HubSettingsString): boolean { + has(setting: HubSettingsString): boolean { return this.settings.has(setting); } - getAllSettings(): Record { + getAll(): Record { return this.settings.serialize(); } - get settingsEmbed(): EmbedBuilder { + get embed(): EmbedBuilder { const embed = new InfoEmbed() .setTitle('Hub Settings') .setColor('#0099ff') .setDescription('Current settings for this hub:'); - for (const [key, value] of Object.entries(this.getAllSettings())) { + for (const [key, value] of Object.entries(this.getAll())) { embed.addFields({ name: key, value: value ? `${emojis.yes} Enabled` : `${emojis.no} Disabled`, @@ -69,11 +69,8 @@ export default class HubSettingsManager { return embed; } - private async saveSettings(): Promise { - return await db.hub.update({ - where: { id: this.hubId }, - data: { settings: this.settings.bitfield }, - }); + private async saveSettings(): Promise { + return await this.hub.setSettings(this.settings.bitfield); } // Helper method to reset all settings to default diff --git a/src/managers/InfractionManager.ts b/src/managers/InfractionManager.ts new file mode 100644 index 00000000..b64b0f91 --- /dev/null +++ b/src/managers/InfractionManager.ts @@ -0,0 +1,190 @@ +import { HubService } from '#main/services/HubService.js'; +import db from '#main/utils/Db.js'; +import { logUserUnblacklist, logServerUnblacklist } from '#main/utils/hub/logger/ModLogs.js'; +import type { ConvertDatesToString } from '#types/Utils.d.ts'; +import { cacheData, getCachedData } from '#utils/CacheUtils.js'; +import { Infraction, InfractionStatus, InfractionType, Prisma } from '@prisma/client'; +import { type Client, type Snowflake, type User } from 'discord.js'; +import { isDate } from 'util/types'; + +export default class InfractionManager { + public readonly targetId: Snowflake; + public readonly targetType: 'user' | 'server'; + + private readonly modelName = 'Infraction'; + private readonly cacheExpirySecs = 5 * 60; + + constructor(targetType: 'user' | 'server', targetId: Snowflake) { + this.targetId = targetId; + this.targetType = targetType; + } + + + private getKey(entityId: Snowflake, hubId: string) { + return `${this.modelName}:${entityId}:${hubId}`; + } + + public async addInfraction( + type: InfractionType, + opts: { + serverName?: string; + hubId: string; + reason: string; + moderatorId: Snowflake; + expiresAt: Date | null; + }, + ) { + const infraction = await db.infraction.create({ + data: { + ...opts, + userId: this.targetType === 'user' ? this.targetId : undefined, + serverId: this.targetType === 'server' ? this.targetId : undefined, + serverName: opts.serverName, + type, + }, + }); + + await this.cacheEntity(infraction); + + return infraction; + } + + public async removeInfraction(type: InfractionType, hubId: string) { + const infraction = await this.fetchInfraction(type, hubId); + if (!infraction) return null; + + const entity = await db.infraction.delete({ where: { id: infraction.id } }); + + this.removeCachedEntity(infraction); + return entity; + } + + public async updateInfraction( + filter: { type: InfractionType; hubId: string; status?: InfractionStatus }, + data: Prisma.InfractionUpdateInput, + ) { + const infraction = await this.fetchInfraction(filter.type, filter.hubId, filter.status); + if (!infraction) return null; + + const updated = await db.infraction.update({ where: { id: infraction.id }, data }); + this.cacheEntity(updated); + return updated; + } + + private async queryEntityInfractions(hubId: string) { + if (this.targetType === 'user') { + return await db.infraction.findMany({ + where: { userId: this.targetId, hubId }, + orderBy: { createdAt: 'desc' }, + }); + } + else { + return await db.infraction.findMany({ + where: { serverId: this.targetId, hubId }, + orderBy: { createdAt: 'desc' }, + }); + } + } + + public async getHubInfractions(hubId: string, opts?: { type?: InfractionType; count?: number }) { + const fetched = await getCachedData( + `${this.modelName}:${this.targetId}:${hubId}`, + async () => await this.queryEntityInfractions(hubId), + this.cacheExpirySecs, + ); + + let infractionsArr = fetched.data ?? []; + if (opts?.type) infractionsArr = infractionsArr.filter((i) => i.type === opts.type); + if (opts?.count) infractionsArr = infractionsArr.slice(0, opts.count); + + return this.updateInfractionDates(infractionsArr); + } + + public async fetchInfraction(type: InfractionType, hubId: string, status?: InfractionStatus) { + const infractions = await this.getHubInfractions(hubId, { type }); + const infraction = infractions.find( + (i) => (status ? i.status === status : true) && i.type === type, + ); + + return infraction ?? null; + } + + public async revokeInfraction( + type: InfractionType, + hubId: string, + status: Exclude = 'REVOKED', + ) { + const revoked = await this.updateInfraction({ type, hubId, status: 'ACTIVE' }, { status }); + return revoked; + } + + public async logUnblacklist( + client: Client, + hubId: string, + id: string, + opts: { mod: User; reason?: string }, + ) { + const hub = await new HubService().fetchHub(hubId); + if (!hub) return; + + if (this.targetType === 'user') { + await logUserUnblacklist(client, hub, { id, mod: opts.mod, reason: opts.reason }); + } + else { + await logServerUnblacklist(client, hub, { id, mod: opts.mod, reason: opts.reason }); + } + } + + protected async refreshCache(hubId: string) { + const key = this.getKey(this.targetId, hubId); + const infractions = await this.queryEntityInfractions(hubId); + await cacheData(key, JSON.stringify(infractions), this.cacheExpirySecs); + } + + protected async cacheEntity(entity: Infraction) { + const entitySnowflake = entity.userId ?? entity.serverId; + const key = this.getKey(entitySnowflake as string, entity.hubId); + const existing = (await this.getHubInfractions(entity.hubId, { type: entity.type })).filter( + (i) => i.id !== entity.id, + ); + + return cacheData(key, JSON.stringify([...existing, entity]), this.cacheExpirySecs); + } + + protected async removeCachedEntity(entity: Infraction) { + const existingInfractions = await this.getHubInfractions(entity.hubId, { type: entity.type }); + const entitySnowflake = entity.userId ?? entity.serverId; + return cacheData( + this.getKey(entitySnowflake as string, entity.hubId), + JSON.stringify(existingInfractions.filter((i) => i.id !== entity.id)), + this.cacheExpirySecs, + ); + } + + protected updateInfractionDates(infractions: ConvertDatesToString[]) { + if (infractions.length === 0) { + return []; + } + else if (infractions.every((i) => isDate(i.createdAt))) { + return infractions as unknown as Infraction[]; + } + + const fixedInfractions: Infraction[] = infractions.map((infrac) => ({ + ...infrac, + createdAt: new Date(infrac.createdAt), + updatedAt: new Date(infrac.updatedAt), + appealedAt: infrac.appealedAt ? new Date(infrac.appealedAt) : null, + expiresAt: infrac.expiresAt ? new Date(infrac.expiresAt) : null, + })); + + return fixedInfractions; + } + + public filterValidInfractions(infractions: Infraction[]): Infraction[] { + return infractions.filter(({ expiresAt }) => !expiresAt || expiresAt > new Date()) ?? []; + } + + public isExpiredInfraction(infraction: Infraction | null) { + return !infraction?.expiresAt || infraction.expiresAt <= new Date(); + } +} diff --git a/src/managers/InfractionManager/BaseInfractionManager.ts b/src/managers/InfractionManager/BaseInfractionManager.ts deleted file mode 100644 index 077e0b6a..00000000 --- a/src/managers/InfractionManager/BaseInfractionManager.ts +++ /dev/null @@ -1,125 +0,0 @@ -import type { ConvertDatesToString } from '#types/Utils.d.ts'; -import { cacheData, getCachedData } from '#utils/CacheUtils.js'; -import { - InfractionStatus, - InfractionType, - Prisma, - ServerInfraction, - UserInfraction, -} from '@prisma/client'; -import { type Client, type Snowflake, type User } from 'discord.js'; -import { isDate } from 'util/types'; - -export default abstract class BaseInfractionManager { - protected abstract modelName: 'UserInfraction' | 'ServerInfraction'; - public readonly targetId: Snowflake; - private readonly cacheExpirySecs = 5 * 60; - - constructor(targetId: Snowflake) { - this.targetId = targetId; - } - - public abstract addInfraction( - type: InfractionType, - opts: { - hubId: string; - reason: string; - moderatorId: Snowflake; - expiresAt: Date | null; - }, - ): Promise; - - public abstract removeInfraction(type: InfractionType, hubId: string): Promise; - - public abstract updateInfraction( - filter: { type: InfractionType; hubId: string; status?: InfractionStatus }, - data: Prisma.UserInfractionUpdateInput | Prisma.ServerInfractionUpdateInput, - ): Promise; - - protected abstract queryEntityInfractions(hubId: string): Promise; - - public async getHubInfractions(hubId: string, opts?: { type?: InfractionType; count?: number }) { - const fetched = await getCachedData( - `${this.modelName}:${this.targetId}:${hubId}`, - async () => await this.queryEntityInfractions(hubId), - this.cacheExpirySecs, - ); - - let infractionsArr = fetched.data ?? []; - if (opts?.type) infractionsArr = infractionsArr.filter((i) => i.type === opts.type); - if (opts?.count) infractionsArr = infractionsArr.slice(0, opts.count); - - return this.updateInfractionDates(infractionsArr); - } - - public async fetchInfraction(type: InfractionType, hubId: string, status?: InfractionStatus) { - const infractions = await this.getHubInfractions(hubId, { type }); - const infraction = infractions.find( - (i) => (status ? i.status === status : true) && i.type === type, - ); - - return infraction ?? null; - } - - public async revokeInfraction( - type: InfractionType, - hubId: string, - status: Exclude = 'REVOKED', - ) { - const revoked = await this.updateInfraction({ type, hubId, status: 'ACTIVE' }, { status }); - return revoked; - } - - public abstract logUnblacklist( - client: Client, - hubId: string, - id: string, - opts: { mod: User; reason?: string }, - ): Promise; - - protected async refreshCache(hubId: string) { - const key = `${this.modelName}:${this.targetId}:${hubId}`; - const infractions = await this.queryEntityInfractions(hubId); - await cacheData(key, JSON.stringify(infractions), this.cacheExpirySecs); - } - - protected async cacheEntity(entity: T) { - const entitySnowflake = 'userId' in entity ? entity.userId : entity.serverId; - const key = `${this.modelName}:${entitySnowflake}:${entity.hubId}`; - const existing = (await this.getHubInfractions(entity.hubId, { type: entity.type })).filter( - (i) => i.id !== entity.id, - ); - - return cacheData(key, JSON.stringify([...existing, entity]), this.cacheExpirySecs); - } - - protected async removeCachedEntity(entity: T) { - const existingInfractions = await this.getHubInfractions(entity.hubId, { type: entity.type }); - const entitySnowflake = 'userId' in entity ? entity.userId : entity.serverId; - return cacheData( - `${this.modelName}:${entitySnowflake}:${entity.hubId}`, - JSON.stringify(existingInfractions.filter((i) => i.id !== entity.id)), - this.cacheExpirySecs, - ); - } - - protected updateInfractionDates(infractions: ConvertDatesToString[]) { - if (infractions.length === 0) return []; - else if (isDate(infractions[0].dateIssued)) return infractions as T[]; - - return infractions.map((infrac) => ({ - ...infrac, - dateIssued: new Date(infrac.dateIssued), - appealedAt: infrac.appealedAt ? new Date(infrac.appealedAt) : null, - expiresAt: infrac.expiresAt ? new Date(infrac.expiresAt) : null, - })); - } - - public filterValidInfractions(infractions: UserInfraction[]): UserInfraction[] { - return infractions.filter(({ expiresAt }) => !expiresAt || expiresAt > new Date()) ?? []; - } - - public isExpiredInfraction(infraction: T | null) { - return !infraction || (!!infraction.expiresAt && infraction.expiresAt <= new Date()); - } -} diff --git a/src/managers/InfractionManager/InfractionManagerFactory.ts b/src/managers/InfractionManager/InfractionManagerFactory.ts deleted file mode 100644 index 60d22253..00000000 --- a/src/managers/InfractionManager/InfractionManagerFactory.ts +++ /dev/null @@ -1,10 +0,0 @@ -import ServerInfractionManager from './ServerInfractionManager.js'; -import UserInfractionManager from './UserInfractionManager.js'; - -export class InfractionManagerFactory { - static create(type: 'user' | 'server', targetId: string) { - return type === 'server' - ? new ServerInfractionManager(targetId) - : new UserInfractionManager(targetId); - } -} diff --git a/src/managers/InfractionManager/ServerInfractionManager.ts b/src/managers/InfractionManager/ServerInfractionManager.ts deleted file mode 100644 index d0984246..00000000 --- a/src/managers/InfractionManager/ServerInfractionManager.ts +++ /dev/null @@ -1,89 +0,0 @@ -import BaseInfractionManager from './BaseInfractionManager.js'; -import db from '#utils/Db.js'; -import { logServerUnblacklist } from '#utils/hub/logger/ModLogs.js'; -import type { InfractionStatus, InfractionType, Prisma, ServerInfraction } from '@prisma/client'; -import { type Client, type Snowflake, type User } from 'discord.js'; - -interface AddInfractionOpts { - hubId: string; - serverName: string; - reason: string; - moderatorId: Snowflake; - expiresAt: Date | null; -} - -export default class ServerInfractionManager extends BaseInfractionManager { - protected readonly modelName = 'ServerInfraction'; - - protected async queryEntityInfractions(hubId: string) { - return await db.serverInfraction.findMany({ - where: { serverId: this.targetId, hubId }, - orderBy: { dateIssued: 'desc' }, - }); - } - - public async revokeInfraction(type: InfractionType, hubId: string) { - const infraction = await this.fetchInfraction(type, hubId); - if (!infraction) return null; - - const revoked = await db.serverInfraction.update({ - where: { id: infraction.id }, - data: { status: 'REVOKED' }, - }); - - this.cacheEntity(revoked); - - return revoked; - } - - public override async logUnblacklist( - client: Client, - id: string, - hubId: string, - { mod, reason }: { mod: User; reason?: string }, - ) { - await logServerUnblacklist(client, hubId, { id, mod, reason }); - } - - /** - * Add a server to the blacklist. - * @param server The ID or instance of the server to blacklist. - * @param hubId The ID of the hub to add the blacklist to. - * @param reason The reason for the blacklist. - * @param expires The date after which the blacklist will expire. - * @returns The created blacklist. - */ - public override async addInfraction( - type: InfractionType, - { hubId, serverName, reason, moderatorId, expiresAt }: AddInfractionOpts, - ) { - const blacklist = await db.serverInfraction.create({ - data: { serverId: this.targetId, serverName, type, expiresAt, reason, moderatorId, hubId }, - }); - - this.cacheEntity(blacklist); - return blacklist; - } - - public override async updateInfraction( - filter: { type: InfractionType; hubId: string; status?: InfractionStatus }, - data: Prisma.ServerInfractionUpdateInput, - ) { - const infraction = await this.fetchInfraction(filter.type, filter.hubId, filter.status); - if (!infraction) return null; - - const updated = await db.serverInfraction.update({ where: { id: infraction.id }, data }); - this.cacheEntity(updated); - return updated; - } - - public override async removeInfraction(type: InfractionType, hubId: string) { - const infraction = await this.fetchInfraction(type, hubId); - if (!infraction) return null; - - const server = await db.serverInfraction.delete({ where: { id: infraction.id } }); - - this.removeCachedEntity(infraction); - return server; - } -} diff --git a/src/managers/InfractionManager/UserInfractionManager.ts b/src/managers/InfractionManager/UserInfractionManager.ts deleted file mode 100644 index 6b0f66a2..00000000 --- a/src/managers/InfractionManager/UserInfractionManager.ts +++ /dev/null @@ -1,77 +0,0 @@ -import db from '#utils/Db.js'; -import { logUserUnblacklist } from '#utils/hub/logger/ModLogs.js'; -import type { InfractionStatus, InfractionType, Prisma, UserInfraction } from '@prisma/client'; -import { type Client, type Snowflake, type User } from 'discord.js'; -import BaseInfractionManager from './BaseInfractionManager.js'; - -interface AddInfractionOpts { - hubId: string; - reason: string; - moderatorId: Snowflake; - expiresAt: Date | null; -} - -export default class UserInfractionManager extends BaseInfractionManager { - protected readonly modelName = 'UserInfraction'; - - protected async queryEntityInfractions(hubId: string) { - return await db.userInfraction.findMany({ - where: { userId: this.targetId, hubId }, - orderBy: { dateIssued: 'desc' }, - }); - } - - public override async logUnblacklist( - client: Client, - hubId: string, - id: string, - { mod, reason }: { mod: User; reason?: string }, - ) { - await logUserUnblacklist(client, hubId, { id, mod, reason }); - } - - async addInfraction( - type: InfractionType, - { hubId, reason, moderatorId, expiresAt }: AddInfractionOpts, - ) { - // if already blacklisted, override it, otherwise add a new one - const infraction = await db.userInfraction.create({ - data: { - userData: { - connectOrCreate: { where: { id: this.targetId }, create: { id: this.targetId } }, - }, - hub: { connect: { id: hubId } }, - type, - expiresAt, - reason, - moderatorId, - }, - }); - - this.refreshCache(hubId); - - return infraction; - } - - async removeInfraction(type: InfractionType, hubId: string) { - const infraction = await this.fetchInfraction(type, hubId); - if (!infraction) return null; - - const user = await db.userInfraction.delete({ where: { id: infraction.id } }); - - this.removeCachedEntity(infraction); - return user; - } - - public async updateInfraction( - filter: { type: InfractionType; hubId: string; status?: InfractionStatus }, - data: Prisma.UserInfractionUpdateInput, - ) { - const infraction = await this.fetchInfraction(filter.type, filter.hubId, filter.status); - if (!infraction) return null; - - const updated = await db.userInfraction.update({ where: { id: infraction.id }, data }); - this.cacheEntity(updated); - return updated; - } -} diff --git a/src/managers/UserDbManager.ts b/src/managers/UserDbManager.ts index 1f0a69d8..932521a9 100644 --- a/src/managers/UserDbManager.ts +++ b/src/managers/UserDbManager.ts @@ -14,6 +14,7 @@ export default class UserDbManager { private serializeUserDates(user: ConvertDatesToString): UserData { return { ...user, + updatedAt: new Date(user.updatedAt), lastVoted: user.lastVoted ? new Date(user.lastVoted) : null, }; } @@ -67,7 +68,7 @@ export default class UserDbManager { const user = await this.upsertUser(id, { username, voteCount: 0, - banMeta: { reason }, + banReason: reason, }); await this.addToCache(user); @@ -77,7 +78,7 @@ export default class UserDbManager { const user = await this.upsertUser(id, { username, voteCount: 0, - banMeta: { set: null }, + banReason: null, }); await this.addToCache(user); diff --git a/src/modules/HubValidator.ts b/src/modules/HubValidator.ts index d6f91f98..dc4a4799 100644 --- a/src/modules/HubValidator.ts +++ b/src/modules/HubValidator.ts @@ -1,8 +1,7 @@ -import type { HubCreationData } from '#main/services/HubService.js'; +import HubManager from '#main/managers/HubManager.js'; +import { HubService, type HubCreationData } from '#main/services/HubService.js'; import Constants, { emojis } from '#main/utils/Constants.js'; -import db from '#main/utils/Db.js'; import { supportedLocaleCodes, t } from '#main/utils/Locale.js'; -import { Hub } from '@prisma/client'; export interface ValidationResult { isValid: boolean; @@ -11,6 +10,7 @@ export interface ValidationResult { export class HubValidator { private readonly locale: supportedLocaleCodes; + private readonly hubService = new HubService(); constructor(locale: supportedLocaleCodes) { this.locale = locale; @@ -18,7 +18,10 @@ export class HubValidator { private static readonly MAX_HUBS_PER_USER = 3; - async validateNewHub(data: HubCreationData, existingHubs: Hub[]): Promise { + async validateNewHub( + data: HubCreationData, + existingHubs: HubManager[], + ): Promise { const nameValidation = this.validateHubName(data.name); if (!nameValidation.isValid) return nameValidation; @@ -45,7 +48,7 @@ export class HubValidator { } private async validateUniqueName(name: string): Promise { - const existingHub = await db.hub.findFirst({ where: { name } }); + const existingHub = await this.hubService.fetchHub({ name }); if (existingHub) { return { isValid: false, @@ -55,9 +58,9 @@ export class HubValidator { return { isValid: true }; } - private validateHubLimit(ownerId: string, existingHubs: Hub[]): ValidationResult { + private validateHubLimit(ownerId: string, existingHubs: HubManager[]): ValidationResult { const userHubCount = existingHubs.reduce( - (acc, hub) => (hub.ownerId === ownerId ? acc + 1 : acc), + (acc, hub) => (hub.isOwner(ownerId) ? acc + 1 : acc), 0, ); diff --git a/src/modules/Pagination.ts b/src/modules/Pagination.ts index c541b7ec..b04c0ec2 100644 --- a/src/modules/Pagination.ts +++ b/src/modules/Pagination.ts @@ -301,8 +301,12 @@ export class Pagination { ackd = true; } - if (options?.deleteOnEnd) await interaction.deleteReply(); - else if (ackd === false) await interaction.editReply({ components: [] }); + if (options?.deleteOnEnd) { + await interaction.deleteReply(); + } + else if (ackd === false) { + await interaction.message.edit({ components: [] }).catch(() => null); + } }); } diff --git a/src/scheduled/startTasks.ts b/src/scheduled/startTasks.ts index 7d245e1e..5b99cf7b 100644 --- a/src/scheduled/startTasks.ts +++ b/src/scheduled/startTasks.ts @@ -16,7 +16,7 @@ export default function startTasks(clusterManager: ClusterManager) { const scheduler = new Scheduler(); - // store network message timestamps to connectedList every minute + // store network message timestamps to Connection every minute scheduler.addRecurringTask('storeMsgTimestamps', 10 * 60 * 1000, storeMsgTimestamps); scheduler.addRecurringTask('cleanupTasks', 60 * 60 * 1000, () => { deleteExpiredInvites().catch(Logger.error); diff --git a/src/scheduled/tasks/pauseIdleConnections.ts b/src/scheduled/tasks/pauseIdleConnections.ts index 27a1001f..4a7ef0a5 100644 --- a/src/scheduled/tasks/pauseIdleConnections.ts +++ b/src/scheduled/tasks/pauseIdleConnections.ts @@ -4,7 +4,7 @@ import { emojis } from '#utils/Constants.js'; import db from '#utils/Db.js'; import { InfoEmbed } from '#utils/EmbedUtils.js'; import Logger from '#utils/Logger.js'; -import { connectedList } from '@prisma/client'; +import { Connection } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { WebhookClient } from 'discord.js'; import 'dotenv/config'; @@ -43,7 +43,7 @@ export default async () => { }); }; -async function findInactiveConnections(): Promise { +async function findInactiveConnections(): Promise { const twentyFourHoursAgo = new Date(Date.now() - 24 * 60 * 60 * 1000); // Find all hubs with at least 50 connections diff --git a/src/scheduled/tasks/updateBlacklists.ts b/src/scheduled/tasks/updateBlacklists.ts index cd7003d8..3e441e4f 100644 --- a/src/scheduled/tasks/updateBlacklists.ts +++ b/src/scheduled/tasks/updateBlacklists.ts @@ -1,69 +1,40 @@ -import db from '#utils/Db.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; -import { type ServerInfraction, type UserInfraction } from '@prisma/client'; -import type { Client } from 'discord.js'; import BlacklistManager from '#main/managers/BlacklistManager.js'; +import HubManager from '#main/managers/HubManager.js'; +import db from '#utils/Db.js'; import { logServerUnblacklist, logUserUnblacklist } from '#utils/hub/logger/ModLogs.js'; - -type ExtractedEntityInfo = { - id: string; - hubId: string; - moderatorId: string | null; -}; - -const unblacklistEntity = async ( - client: Client, - infrac: ExtractedEntityInfo, - type: 'user' | 'server', -) => { - if (client.user) { - if (type === 'user') { - await logUserUnblacklist(client, infrac.hubId, { - id: infrac.id, - mod: client.user, - reason: 'Blacklist duration expired.', - }); - } - else if (type === 'server') { - await logServerUnblacklist(client, infrac.hubId, { - id: infrac.id, - mod: client.user, - reason: 'Blacklist duration expired.', - }); - } - } - - const blacklistManager = - type === 'user' - ? new BlacklistManager(new UserInfractionManager(infrac.id)) - : new BlacklistManager(new ServerInfractionManager(infrac.id)); - - await blacklistManager.removeBlacklist(infrac.hubId); -}; - -const extractEntityInfo = ( - entities: (UserInfraction | ServerInfraction)[] | null, -): ExtractedEntityInfo[] | undefined => - entities?.map((infrac) => ({ - id: 'userId' in infrac ? infrac.userId : infrac.serverId, - hubId: infrac.hubId, - moderatorId: infrac.moderatorId, - })); +import type { Client } from 'discord.js'; export default async (client: Client) => { - const query = { + const allInfractions = await db.infraction.findMany({ where: { status: 'ACTIVE', expiresAt: { not: null, lte: new Date() } }, - } as const; - - // find blacklists that expired in the past 1.5 minutes - const allUsers = await db.userInfraction.findMany(query); - const allServers = await db.serverInfraction.findMany(query); - - extractEntityInfo(allUsers)?.forEach( - async (infrac) => await unblacklistEntity(client, infrac, 'user'), - ); - extractEntityInfo(allServers)?.forEach( - async (infrac) => await unblacklistEntity(client, infrac, 'server'), - ); + include: { hub: true }, + }); + + allInfractions?.forEach(async (infrac) => { + const type = infrac.userId ? 'user' : 'server'; + + const blacklistManager = + type === 'user' + ? new BlacklistManager('user', infrac.id) + : new BlacklistManager('server', infrac.id); + + await blacklistManager.removeBlacklist(infrac.hubId); + + if (client.user) { + if (type === 'user') { + await logUserUnblacklist(client, new HubManager(infrac.hub), { + id: infrac.id, + mod: client.user, + reason: 'Blacklist duration expired.', + }); + } + else if (type === 'server') { + await logServerUnblacklist(client, new HubManager(infrac.hub), { + id: infrac.id, + mod: client.user, + reason: 'Blacklist duration expired.', + }); + } + } + }); }; diff --git a/src/services/BroadcastService.ts b/src/services/BroadcastService.ts index 32e3d606..d5d27ed2 100644 --- a/src/services/BroadcastService.ts +++ b/src/services/BroadcastService.ts @@ -1,16 +1,17 @@ -import { Message, WebhookClient, WebhookMessageCreateOptions, HexColorString } from 'discord.js'; -import { Hub, connectedList } from '@prisma/client'; +import HubManager from '#main/managers/HubManager.js'; import HubSettingsManager from '#main/managers/HubSettingsManager.js'; -import { getAttachmentURL } from '#utils/ImageUtils.js'; -import { getReferredContent, getReferredMsgData } from '#utils/network/utils.js'; -import storeMessageData, { NetworkWebhookSendResult } from '#utils/network/storeMessageData.js'; import MessageFormattingService from '#main/services/MessageFormattingService.js'; import Logger from '#main/utils/Logger.js'; +import { BroadcastOpts, ReferredMsgData } from '#main/utils/network/Types.js'; import { generateJumpButton as getJumpButton } from '#utils/ComponentUtils.js'; import { ConnectionMode } from '#utils/Constants.js'; +import { getAttachmentURL } from '#utils/ImageUtils.js'; +import storeMessageData, { NetworkWebhookSendResult } from '#utils/network/storeMessageData.js'; +import { getReferredContent, getReferredMsgData } from '#utils/network/utils.js'; import { censor } from '#utils/ProfanityUtils.js'; import { trimAndCensorBannedWebhookWords } from '#utils/Utils.js'; -import { ReferredMsgData, BroadcastOpts } from '#main/utils/network/Types.js'; +import { Connection } from '@prisma/client'; +import { HexColorString, Message, WebhookClient, WebhookMessageCreateOptions } from 'discord.js'; const BATCH_SIZE = 15; const CONCURRENCY_LIMIT = 10; @@ -40,13 +41,12 @@ export class BroadcastService { async broadcastMessage( message: Message, - hub: Hub, - hubConnections: connectedList[], - settings: HubSettingsManager, - connection: connectedList, + hub: HubManager, + hubConnections: Connection[], + connection: Connection, ) { const attachmentURL = await this.resolveAttachmentURL(message); - const username = this.getUsername(settings, message); + const username = this.getUsername(hub.settings, message); const censoredContent = censor(message.content); const referredMessage = await this.fetchReferredMessage(message); const referredMsgData = await getReferredMsgData(referredMessage); @@ -145,7 +145,7 @@ export class BroadcastService { private getUsername(settings: HubSettingsManager, message: Message): string { return trimAndCensorBannedWebhookWords( - settings.getSetting('UseNicknames') + settings.has('UseNicknames') ? (message.member?.displayName ?? message.author.displayName) : message.author.username, ); @@ -153,8 +153,8 @@ export class BroadcastService { private async sendToConnection( message: Message, - hub: Hub, - connection: connectedList, + hub: HubManager, + connection: Connection, opts: BroadcastOpts & { username: string; censoredContent: string; @@ -180,8 +180,8 @@ export class BroadcastService { private getMessageFormat( message: Message, - connection: connectedList, - hub: Hub, + connection: Connection, + hub: HubManager, opts: BroadcastOpts & { username: string; censoredContent: string; @@ -201,7 +201,7 @@ export class BroadcastService { const messageFormatter = new MessageFormattingService(connection); return messageFormatter.format(message, { ...opts, - hub, + hub: hub.data, author, servername, jumpButton, @@ -210,7 +210,7 @@ export class BroadcastService { private getJumpButton( username: string, - { channelId, serverId }: connectedList, + { channelId, serverId }: Connection, dbReferrence: ReferredMsgData['dbReferrence'], ) { const reply = dbReferrence?.broadcastMsgs.get(channelId) ?? dbReferrence; diff --git a/src/services/ConnectionService.ts b/src/services/ConnectionService.ts index 5766c8b2..0d89d3a8 100644 --- a/src/services/ConnectionService.ts +++ b/src/services/ConnectionService.ts @@ -1,10 +1,12 @@ +import { HubService } from '#main/services/HubService.js'; import type { ConnectionData } from '#types/ConnectionTypes.d.ts'; import { getConnectionHubId, getHubConnections } from '#utils/ConnectedListUtils.js'; -import db from '#utils/Db.js'; -import { connectedList } from '@prisma/client'; +import { Connection } from '@prisma/client'; import { Message } from 'discord.js'; export class ConnectionService { + private readonly hubService = new HubService(); + async getConnectionData(message: Message): Promise { const connectionHubId = await getConnectionHubId(message.channelId); if (!connectionHubId) return null; @@ -16,25 +18,18 @@ export class ConnectionService { if (!connection?.connected || !hubConnections) return null; - const hub = await this.getHub(connection.hubId); + const hub = await this.hubService.fetchHub(connection.hubId); if (!hub) return null; return { connection, hubConnections, hub }; } - private async getHub(hubId: string) { - return await db.hub.findFirst({ - where: { id: hubId }, - include: { msgBlockList: true }, - }); - } - private async getConnectionAndHubConnections( channelId: string, connectionHubId: string, - ): Promise<{ connection: connectedList | null; hubConnections: connectedList[] | null }> { - let connection: connectedList | null = null; - const filteredHubConnections: connectedList[] = []; + ): Promise<{ connection: Connection | null; hubConnections: Connection[] | null }> { + let connection: Connection | null = null; + const filteredHubConnections: Connection[] = []; const hubConnections = await getHubConnections(connectionHubId); for (const conn of hubConnections) { diff --git a/src/services/HubJoinService.ts b/src/services/HubJoinService.ts index a4d4ff42..58802476 100644 --- a/src/services/HubJoinService.ts +++ b/src/services/HubJoinService.ts @@ -1,6 +1,7 @@ import BlacklistManager from '#main/managers/BlacklistManager.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; +import HubManager from '#main/managers/HubManager.js'; +import { HubService } from '#main/services/HubService.js'; + import { TranslationKeys } from '#types/TranslationKeys.d.ts'; import { createConnection, getHubConnections } from '#utils/ConnectedListUtils.js'; import { emojis } from '#utils/Constants.js'; @@ -10,7 +11,6 @@ import { sendToHub } from '#utils/hub/utils.js'; import { supportedLocaleCodes, t } from '#utils/Locale.js'; import { check } from '#utils/ProfanityUtils.js'; import { getOrCreateWebhook, getReplyMethod } from '#utils/Utils.js'; -import { Hub } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { ChatInputCommandInteraction, @@ -23,13 +23,16 @@ export class HubJoinService { | ChatInputCommandInteraction<'cached'> | MessageComponentInteraction<'cached'>; private readonly locale: supportedLocaleCodes; + private readonly hubService: HubService; constructor( interaction: ChatInputCommandInteraction<'cached'> | MessageComponentInteraction<'cached'>, locale: supportedLocaleCodes, + hubService: HubService = new HubService(), ) { this.interaction = interaction; this.locale = locale; + this.hubService = hubService; } async joinRandomHub(channel: GuildTextBasedChannel) { @@ -109,17 +112,15 @@ export class HubJoinService { include: { hub: true }, }); - if (fetchedInvite) return fetchedInvite.hub; + if (fetchedInvite) return new HubManager(fetchedInvite.hub); } // Otherwise search by name - return await db.hub.findFirst({ - where: { name: hubName, private: false }, - }); + return await this.hubService.fetchHub({ name: hubName }); } private async isAlreadyInHub(channel: GuildTextBasedChannel, hubId: string) { - const channelInHub = await db.connectedList.findFirst({ + const channelInHub = await db.connection.findFirst({ where: { OR: [{ channelId: channel.id }, { serverId: channel.guildId, hubId }] }, include: { hub: { select: { name: true } } }, }); @@ -135,17 +136,15 @@ export class HubJoinService { return false; } - private async isBlacklisted(hub: Hub) { - const userBlManager = new BlacklistManager(new UserInfractionManager(this.interaction.user.id)); - const serverBlManager = new BlacklistManager( - new ServerInfractionManager(this.interaction.guildId), - ); + private async isBlacklisted(hub: HubManager) { + const userBlManager = new BlacklistManager('user', this.interaction.user.id); + const serverBlManager = new BlacklistManager('server', this.interaction.guildId); const userBlacklist = await userBlManager.fetchBlacklist(hub.id); const serverBlacklist = await serverBlManager.fetchBlacklist(hub.id); if (userBlacklist || serverBlacklist) { - await this.replyError('errors.blacklisted', { emoji: emojis.no, hub: hub.name }); + await this.replyError('errors.blacklisted', { emoji: emojis.no, hub: hub.data.name }); return true; } @@ -164,38 +163,45 @@ export class HubJoinService { return webhook; } - private async sendSuccessMessages(hub: Hub, channel: GuildTextBasedChannel) { + private async sendSuccessMessages(hub: HubManager, channel: GuildTextBasedChannel) { const replyMethod = getReplyMethod(this.interaction); await this.interaction[replyMethod]({ content: t('hub.join.success', this.locale, { channel: `${channel}`, - hub: hub.name, + hub: hub.data.name, }), embeds: [], components: [], }); const totalConnections = - (await getHubConnections(hub.id))?.reduce((total, c) => total + (c.connected ? 1 : 0), 0) ?? - 0; + (await getHubConnections(hub.id))?.reduce( + (total, c) => total + (c.connected && c.channelId !== channel.id ? 1 : 0), + 0, + ) ?? 0; + + const serverCountMessage = + totalConnections === 0 + ? 'There are no other servers connected to this hub. *cricket noises* 🦗' + : `We now have ${totalConnections} servers in this hub! 🎉`; // Announce to hub await sendToHub(hub.id, { - username: `InterChat | ${hub.name}`, + username: `InterChat | ${hub.data.name}`, content: stripIndents` A new server has joined the hub! ${emojis.clipart} **Server Name:** __${this.interaction.guild.name}__ **Member Count:** __${this.interaction.guild.memberCount}__ - We now have **${totalConnections}** servers with us! + ${serverCountMessage} `, }); // Send log await logJoinToHub(hub.id, this.interaction.guild, { totalConnections, - hubName: hub.name, + hubName: hub.data.name, }); } diff --git a/src/services/HubService.ts b/src/services/HubService.ts index 8767d56f..0ed14a88 100644 --- a/src/services/HubService.ts +++ b/src/services/HubService.ts @@ -1,7 +1,12 @@ +import HubManager from '#main/managers/HubManager.js'; import { HubSettingsBits } from '#main/modules/BitFields.js'; +import { ConvertDatesToString } from '#main/types/Utils.js'; import { deleteConnections } from '#main/utils/ConnectedListUtils.js'; -import Constants from '#main/utils/Constants.js'; -import { Prisma, PrismaClient } from '@prisma/client'; +import Constants, { RedisKeys } from '#main/utils/Constants.js'; +import db from '#main/utils/Db.js'; +import getRedis from '#main/utils/Redis.js'; +import { Hub, Prisma, PrismaClient, Role } from '@prisma/client'; +import { Redis } from 'ioredis'; export interface HubCreationData { name: string; @@ -13,18 +18,63 @@ export interface HubCreationData { export class HubService { private readonly db: PrismaClient; - constructor(db: PrismaClient) { - this.db = db; + private readonly cache: Redis; + public readonly hubKey = `${RedisKeys.Hub}:`; + + constructor(_db: PrismaClient = db, cache = getRedis()) { + this.db = _db; + this.cache = cache; + } + + protected parseHubStringToObject(hub: string): Hub { + const parsedHub = JSON.parse(hub) as ConvertDatesToString; + + return { + ...parsedHub, + createdAt: new Date(parsedHub.createdAt), + updatedAt: new Date(parsedHub.updatedAt), + }; } - async fetchHub(id: string, include: Prisma.HubInclude = {}) { - return await this.db.hub.findFirst({ where: { id }, include }); + + private createHubManager(hub: Hub | string): HubManager { + if (typeof hub === 'string') return new HubManager(this.parseHubStringToObject(hub), this); + return new HubManager(hub); + } + + async fetchHub(whereInput: string | { id?: string; name?: string }): Promise { + const where: { id?: string; name?: string } = typeof whereInput === 'string' + ? { id: whereInput } + : whereInput; + + if (!where.id && !where.name) { + return null; + } + + // Check cache if we have an ID + if (where.id) { + const fromCache = await this.cache.get(`${this.hubKey}${where.id}`); + if (fromCache) { + return this.createHubManager(fromCache); + } + } + + const hub = await this.db.hub.findFirst({ where }); + + // Cache result if we found something + if (hub) { + await this.cache.set(`${this.hubKey}${hub.id}`, JSON.stringify(hub)); + return this.createHubManager(hub); + } + + return null; } - async createHub(data: HubCreationData): Promise { - await this.db.hub.create({ + async createHub(data: HubCreationData): Promise { + const hub = await this.db.hub.create({ data: { ...data, + moderators: { create: { userId: data.ownerId, role: 'OWNER' } }, private: true, iconUrl: data.iconUrl ?? Constants.Links.EasterAvatar, bannerUrl: data.bannerUrl ?? null, @@ -32,6 +82,8 @@ export class HubService { HubSettingsBits.SpamFilter | HubSettingsBits.Reactions | HubSettingsBits.BlockNSFW, }, }); + + return this.createHubManager(hub); } async deleteHub(hubId: string): Promise { @@ -40,28 +92,63 @@ export class HubService { await this.db.$transaction([ this.db.hubInvite.deleteMany({ where: { hubId } }), this.db.hubLogConfig.deleteMany({ where: { hubId } }), - this.db.messageBlockList.deleteMany({ where: { hubId } }), - this.db.userInfraction.deleteMany({ where: { hubId } }), - this.db.serverInfraction.deleteMany({ where: { hubId } }), + this.db.blockWord.deleteMany({ where: { hubId } }), + this.db.infraction.deleteMany({ where: { hubId } }), ]); // finally, delete the hub - await this.db.hub.deleteMany({ where: { id: hubId } }); + await this.db.hub.delete({ where: { id: hubId } }); } - async getHubsForUser(userId: string) { - return await this.db.hub.findMany({ where: { ownerId: userId } }); + async getOwnedHubs(userId: string) { + const hubs = await this.db.hub.findMany({ where: { ownerId: userId } }); + return hubs.map((hub) => this.createHubManager(hub)); } - async getHubByName(name: string, ownerId?: string, include: Prisma.HubInclude = {}) { - return await this.db.hub.findFirst({ where: { name, ownerId }, include }); + async findHubsByName( + name: string, + opts?: { insensitive?: boolean; ownerId?: string; take?: number }, + ): Promise { + const hubs = await this.db.hub.findMany({ + where: { + name: { + mode: opts?.insensitive ? 'insensitive' : 'default', + contains: name, + }, + ownerId: opts?.ownerId, + }, + take: opts?.take, + }); + + return hubs.map((hub) => this.createHubManager(hub)); } async getExistingHubs(ownerId: string, hubName: string) { - return await this.db.hub.findMany({ + const hubs = await this.db.hub.findMany({ + where: { OR: [{ ownerId }, { name: hubName }] }, + }); + + return hubs.map((hub) => this.createHubManager(hub)); + } + + async fetchModeratedHubs( + userId: string, + opts?: { + roles?: Role[]; + filter?: Prisma.HubModeratorWhereInput; + take?: number; + }, + ) { + const hubs = await this.db.hubModerator.findMany({ where: { - OR: [{ ownerId }, { name: hubName }], + role: opts?.roles ? { in: [...opts.roles, 'OWNER'] } : undefined, + ...opts?.filter, + userId, }, + include: { hub: true }, + take: opts?.take, }); + + return hubs.map(({ hub }) => this.createHubManager(hub)); } } diff --git a/src/services/MessageFormattingService.ts b/src/services/MessageFormattingService.ts index cc212cfd..637af003 100644 --- a/src/services/MessageFormattingService.ts +++ b/src/services/MessageFormattingService.ts @@ -1,5 +1,5 @@ import { BroadcastOpts, ReferredMsgData } from '#main/utils/network/Types.js'; -import { connectedList, Hub } from '@prisma/client'; +import { Connection, Hub } from '@prisma/client'; import { ActionRowBuilder, ButtonBuilder, Message, userMention, WebhookMessageCreateOptions } from 'discord.js'; import { CompactMessageFormatter } from './formatters/CompactMsgFormatter.js'; import { EmbedMessageFormatter } from './formatters/EmbedMsgFormatter.js'; @@ -7,7 +7,7 @@ import { EmbedMessageFormatter } from './formatters/EmbedMsgFormatter.js'; export interface MessageFormatterStrategy { format( message: Message, - connection: connectedList, + connection: Connection, opts: DefaultFormaterOpts ): WebhookMessageCreateOptions; } @@ -27,9 +27,9 @@ export type DefaultFormaterOpts = BroadcastOpts & { export default class MessageFormattingService { private readonly strategy: MessageFormatterStrategy; - private readonly connection: connectedList; + private readonly connection: Connection; - constructor(connection: connectedList) { + constructor(connection: Connection) { this.strategy = connection.compact ? new CompactMessageFormatter() : new EmbedMessageFormatter(); @@ -45,7 +45,7 @@ export default class MessageFormattingService { } private addReplyMention( messageFormat: WebhookMessageCreateOptions, - connection: connectedList, + connection: Connection, referredMsgData?: ReferredMsgData, ): WebhookMessageCreateOptions { if (referredMsgData && connection.serverId === referredMsgData.dbReferrence?.guildId) { diff --git a/src/services/MessageProcessor.ts b/src/services/MessageProcessor.ts index 5d27fca4..5c35b1ff 100644 --- a/src/services/MessageProcessor.ts +++ b/src/services/MessageProcessor.ts @@ -1,5 +1,4 @@ import { showRulesScreening } from '#main/interactions/RulesScreening.js'; -import HubSettingsManager from '#main/managers/HubSettingsManager.js'; import { LobbyManager } from '#main/managers/LobbyManager.js'; import Constants, { emojis } from '#main/utils/Constants.js'; import { checkBlockedWords } from '#main/utils/network/blockwordsRunner.js'; @@ -57,13 +56,12 @@ export class MessageProcessor { const userData = await userManager.getUser(message.author.id); if (!userData?.acceptedRules) return await showRulesScreening(message, userData); - const settings = new HubSettingsManager(hub.id, hub.settings); const attachmentURL = await this.broadcastService.resolveAttachmentURL(message); if ( !(await runChecks(message, hub, { userData, - settings, + settings: hub.settings, attachmentURL, totalHubConnections: hubConnections.length, })) @@ -73,16 +71,10 @@ export class MessageProcessor { message.channel.sendTyping().catch(() => null); - const { passed } = await checkBlockedWords(message, hub.msgBlockList); + const { passed } = await checkBlockedWords(message, await hub.fetchBlockWords()); if (!passed) return; - await this.broadcastService.broadcastMessage( - message, - hub, - hubConnections, - settings, - connection, - ); + await this.broadcastService.broadcastMessage(message, hub, hubConnections, connection); } private async updateLobbyActivity(message: Message, lobby: LobbyData) { diff --git a/src/services/formatters/CompactMsgFormatter.ts b/src/services/formatters/CompactMsgFormatter.ts index 71fced92..b7f1d14d 100644 --- a/src/services/formatters/CompactMsgFormatter.ts +++ b/src/services/formatters/CompactMsgFormatter.ts @@ -1,4 +1,4 @@ -import { connectedList } from '@prisma/client'; +import { Connection } from '@prisma/client'; import { WebhookMessageCreateOptions, EmbedBuilder, Message } from 'discord.js'; import { DefaultFormaterOpts, MessageFormatterStrategy } from '../MessageFormattingService.js'; import { censor } from '#main/utils/ProfanityUtils.js'; @@ -8,7 +8,7 @@ import Constants from '#main/utils/Constants.js'; export class CompactMessageFormatter implements MessageFormatterStrategy { format( message: Message, - connection: connectedList, + connection: Connection, opts: DefaultFormaterOpts, ): WebhookMessageCreateOptions { const contents = { diff --git a/src/services/formatters/EmbedMsgFormatter.ts b/src/services/formatters/EmbedMsgFormatter.ts index e5941738..a051bf1c 100644 --- a/src/services/formatters/EmbedMsgFormatter.ts +++ b/src/services/formatters/EmbedMsgFormatter.ts @@ -1,4 +1,4 @@ -import { connectedList } from '@prisma/client'; +import { Connection } from '@prisma/client'; import { Message, WebhookMessageCreateOptions } from 'discord.js'; import { DefaultFormaterOpts, MessageFormatterStrategy } from '../MessageFormattingService.js'; import { buildNetworkEmbed } from '#main/utils/network/utils.js'; @@ -6,7 +6,7 @@ import { buildNetworkEmbed } from '#main/utils/network/utils.js'; export class EmbedMessageFormatter implements MessageFormatterStrategy { format( message: Message, - connection: connectedList, + connection: Connection, opts: DefaultFormaterOpts, ): WebhookMessageCreateOptions { const embeds = buildNetworkEmbed(message, opts.username, opts.censoredContent, { diff --git a/src/types/ConnectionTypes.d.ts b/src/types/ConnectionTypes.d.ts index 06ab7b56..4cab694f 100644 --- a/src/types/ConnectionTypes.d.ts +++ b/src/types/ConnectionTypes.d.ts @@ -1,7 +1,8 @@ -import { Hub, connectedList } from '@prisma/client'; +import HubManager from '#main/managers/HubManager.js'; +import { Connection } from '@prisma/client'; export interface ConnectionData { - connection: connectedList; - hubConnections: connectedList[]; - hub: Hub & { msgBlockList: MessageBlockList[] }; + connection: Connection; + hubConnections: Connection[]; + hub: HubManager; } diff --git a/src/utils/BanUtils.ts b/src/utils/BanUtils.ts index 4c8007fe..496f8929 100644 --- a/src/utils/BanUtils.ts +++ b/src/utils/BanUtils.ts @@ -16,7 +16,7 @@ export const handleBan = async ( const { userManager } = interaction.client; const dbUser = await userManager.getUser(targetId); - if (dbUser?.banMeta) { + if (dbUser?.banReason) { await interaction.reply({ content: `${emojis.slash} This user is already banned.`, ephemeral: true, diff --git a/src/utils/ConnectedListUtils.ts b/src/utils/ConnectedListUtils.ts index 5ec0e814..b6eedb0b 100644 --- a/src/utils/ConnectedListUtils.ts +++ b/src/utils/ConnectedListUtils.ts @@ -4,24 +4,24 @@ import { cacheData, getCachedData } from '#utils/CacheUtils.js'; import { RedisKeys } from '#utils/Constants.js'; import db from '#utils/Db.js'; import getRedis from '#utils/Redis.js'; -import type { connectedList, Prisma } from '@prisma/client'; +import type { Connection, Prisma } from '@prisma/client'; import isEmpty from 'lodash/isEmpty.js'; -type whereUniuqeInput = Prisma.connectedListWhereUniqueInput; -type whereInput = Prisma.connectedListWhereInput; -type dataInput = Prisma.connectedListUpdateInput; -type CachedConnection = ConvertDatesToString; +type whereUniuqeInput = Prisma.ConnectionWhereUniqueInput; +type whereInput = Prisma.ConnectionWhereInput; +type dataInput = Prisma.ConnectionUpdateInput; +type CachedConnection = ConvertDatesToString; -const convertToConnectedList = (connection: CachedConnection): connectedList => ({ +const convertToConnectedList = (connection: CachedConnection): Connection => ({ ...connection, - date: new Date(connection.date), + createdAt: new Date(connection.createdAt), lastActive: new Date(connection.lastActive), }); /** * This includes both connected and disconnected connections */ -export const getHubConnections = async (hubId: string): Promise => { +export const getHubConnections = async (hubId: string): Promise => { const redis = getRedis(); const key = `${RedisKeys.hubConnections}:${hubId}`; const cached = await redis.hgetall(key); @@ -31,7 +31,7 @@ export const getHubConnections = async (hubId: string): Promise return cachedData; } - const fromDb = await db.connectedList.findMany({ where: { hubId } }); + const fromDb = await db.connection.findMany({ where: { hubId } }); const keyValuePairs = fromDb.flatMap((c) => [c.id, JSON.stringify(c)]); if (keyValuePairs.length === 0) return []; @@ -46,7 +46,7 @@ export const getHubConnections = async (hubId: string): Promise return fromDb; }; -export const cacheHubConnection = async (connection: connectedList) => { +export const cacheHubConnection = async (connection: Connection) => { const redis = getRedis(); const cached = await redis.hlen(`${RedisKeys.hubConnections}:${connection.hubId}`); @@ -76,7 +76,7 @@ const purgeConnectionCache = async (channelId: string) => { await getRedis().del(`${RedisKeys.connectionHubId}:${channelId}`); }; -const cacheConnectionHubId = async (...connections: connectedList[]) => { +const cacheConnectionHubId = async (...connections: Connection[]) => { const keysToDelete: string[] = []; const cachePromises: Promise[] = []; @@ -99,7 +99,7 @@ const cacheConnectionHubId = async (...connections: connectedList[]) => { }; export const fetchConnection = async (channelId: string) => { - const connection = await db.connectedList.findFirst({ where: { channelId } }); + const connection = await db.connection.findFirst({ where: { channelId } }); if (!connection) return null; await cacheConnectionHubId(connection); @@ -118,17 +118,17 @@ export const getConnectionHubId = async (channelId: string) => { }; export const deleteConnection = async (where: whereUniuqeInput) => { - const connection = await db.connectedList.findFirst({ where }); + const connection = await db.connection.findFirst({ where }); if (!connection) return null; - const deleted = await db.connectedList.delete({ where }); + const deleted = await db.connection.delete({ where }); await removeFromHubConnections(deleted.id, deleted.hubId); await purgeConnectionCache(deleted.channelId); return deleted; }; -export const createConnection = async (data: Prisma.connectedListCreateInput) => { - const connection = await db.connectedList.create({ data }); +export const createConnection = async (data: Prisma.ConnectionCreateInput) => { + const connection = await db.connection.create({ data }); await cacheConnectionHubId(connection); await cacheHubConnection(connection); @@ -136,11 +136,11 @@ export const createConnection = async (data: Prisma.connectedListCreateInput) => }; export const deleteConnections = async (where: whereInput) => { - const connections = await db.connectedList.findMany({ where }); + const connections = await db.connection.findMany({ where }); if (connections.length === 0) return []; else if (connections.length === 1) return [await deleteConnection({ id: connections[0].id })]; - await db.connectedList.deleteMany({ + await db.connection.deleteMany({ where: { id: { in: connections.map((i) => i.id) } }, }); @@ -154,11 +154,11 @@ export const deleteConnections = async (where: whereInput) => { }; export const updateConnection = async (where: whereUniuqeInput, data: dataInput) => { - const conn = await db.connectedList.findFirst({ where }); + const conn = await db.connection.findFirst({ where }); if (!conn) return null; // Update in database - const connection = await db.connectedList.update({ where, data }); + const connection = await db.connection.update({ where, data }); // Update cache await cacheConnectionHubId(connection); @@ -169,9 +169,9 @@ export const updateConnection = async (where: whereUniuqeInput, data: dataInput) export const updateConnections = async (where: whereInput, data: dataInput) => { // Update in database - const updated = await db.connectedList.updateMany({ where, data }); + const updated = await db.connection.updateMany({ where, data }); - db.connectedList.findMany({ where }).then(async (connections) => { + db.connection.findMany({ where }).then(async (connections) => { await cacheConnectionHubId(...connections); connections.forEach(cacheHubConnection); }); diff --git a/src/utils/Constants.ts b/src/utils/Constants.ts index 41f19e3d..6b8c3faa 100644 --- a/src/utils/Constants.ts +++ b/src/utils/Constants.ts @@ -1,16 +1,15 @@ import type { Colors, HexColorString, Snowflake } from 'discord.js'; -import { createRequire } from 'module'; -import type jsonEmotes from './JSON/emojis.json'; -import type badwordsType from './JSON/profanity.json'; +import jsonEmotes from './JSON/emojis.json' with { 'type': 'json' }; +import badwordsType from './JSON/profanity.json' with { 'type': 'json' }; +import packageJson from '../../package.json' with { 'type': 'json' }; -// create a require as ESM doesn't support importing JSON -const require = createRequire(import.meta.url); -export const { slurs, profanity } = require('./JSON/profanity.json') as typeof badwordsType; + +export const { slurs, profanity } = badwordsType; export const { normal: emojis, mascot: mascotEmojis, badge: badgeEmojis, -} = require('./JSON/emojis.json') as typeof jsonEmotes; +} = jsonEmotes; export const enum RedisKeys { msgTimestamp = 'msgTimestamp', @@ -23,8 +22,7 @@ export const enum RedisKeys { channelQueue = 'channelQueue', commandUsesLeft = 'commandUsesLeft', msgDeleteInProgress = 'msgDeleteInProgress', - userInfraction = 'UserInfraction', - serverInfraction = 'ServerInfraction', + Infraction = 'Infraction', hubLogConfig = 'hubLogConfig', message = 'message', broadcasts = 'broadcasts', @@ -34,6 +32,7 @@ export const enum RedisKeys { ChannelPrefs = 'channelPrefs', MatchingPool = 'matchingPool', LobbyMessages = 'lobbyMessages', + Hub = 'hub', } export const enum ConnectionMode { @@ -63,7 +62,7 @@ export default { DeveloperIds: ['701727675311587358'] as Snowflake[], SupporterIds: ['880978672037802014', '786348225341947986'] as Snowflake[], - ProjectVersion: require('../../package.json').version ?? 'Unknown', + ProjectVersion: packageJson.version ?? 'Unknown', SupportServerId: '770256165300338709', VoterRoleId: '985153241727770655', diff --git a/src/utils/CustomID.ts b/src/utils/CustomID.ts index 74d12046..4b6c7aeb 100644 --- a/src/utils/CustomID.ts +++ b/src/utils/CustomID.ts @@ -33,8 +33,7 @@ export class CustomID { * @returns CustomID - The CustomID instance for method chaining. */ - // TODO: Rename this to set args and add a new method for adding args - addArgs(...values: string[]): CustomID { + setArgs(...values: string[]): this { if (!values) return this; const invalidChars = ['&']; @@ -52,8 +51,8 @@ export class CustomID { * @param date - The expiry date. * @returns CustomID - The CustomID instance for method chaining. */ - setExpiry(date: Date): CustomID { - this.addArgs(`ex=${date.getTime()}`); + setExpiry(date: Date): this { + this.setArgs(`ex=${date.getTime()}`); return this; } diff --git a/src/utils/hub/edit.ts b/src/utils/hub/edit.ts index bba2c028..161ec47a 100644 --- a/src/utils/hub/edit.ts +++ b/src/utils/hub/edit.ts @@ -2,18 +2,22 @@ import Constants, { emojis } from '#utils/Constants.js'; import { CustomID } from '#utils/CustomID.js'; import db from '#utils/Db.js'; import { supportedLocaleCodes, t } from '#utils/Locale.js'; -import { connectedList, Hub } from '@prisma/client'; +import { Hub } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { ActionRowBuilder, EmbedBuilder, StringSelectMenuBuilder } from 'discord.js'; -export const hubEditSelects = (hubId: string, userId: string, locale: supportedLocaleCodes = 'en') => +export const hubEditSelects = ( + hubId: string, + userId: string, + locale: supportedLocaleCodes = 'en', +) => new ActionRowBuilder().addComponents( new StringSelectMenuBuilder() .setCustomId( new CustomID() .setIdentifier('hub_edit', 'actions') - .addArgs(userId) - .addArgs(hubId) + .setArgs(userId) + .setArgs(hubId) .toString(), ) .addOptions([ @@ -44,11 +48,8 @@ export const hubEditSelects = (hubId: string, userId: string, locale: supportedL ]), ); -export const hubEmbed = async (hub: Hub & { connections: connectedList[] }) => { - const hubBlacklistedUsers = await db.userInfraction.count({ - where: { hubId: hub.id, status: 'ACTIVE' }, - }); - const hubBlacklistedServers = await db.serverInfraction.count({ +export const hubEmbed = async (hub: Hub, totalConnections: number, totalMods: number) => { + const hubBlacklists = await db.infraction.findMany({ where: { hubId: hub.id, status: 'ACTIVE' }, }); @@ -60,7 +61,7 @@ export const hubEmbed = async (hub: Hub & { connections: connectedList[] }) => { ${hub.description} ${emojis.dotBlue} __**Visibility:**__ ${hub.private ? 'Private' : 'Public'} - ${emojis.dotBlue} __**Connections**__: ${hub.connections.length} + ${emojis.dotBlue} __**Connections**__: ${totalConnections} ${emojis.dotBlue} __**Chats Locked:**__ ${hub.locked ? 'Yes' : 'No'} `, @@ -71,17 +72,17 @@ export const hubEmbed = async (hub: Hub & { connections: connectedList[] }) => { { name: 'Blacklists', value: stripIndents` - Total: ${hubBlacklistedUsers + hubBlacklistedServers} - Users: ${hubBlacklistedUsers} - Servers: ${hubBlacklistedServers} - `, + Total: ${hubBlacklists.length} + Users: ${hubBlacklists.filter((i) => Boolean(i.userId)).length} + Servers: ${hubBlacklists.filter((i) => Boolean(i.serverId)).length} + `, inline: true, }, { name: 'Hub Stats', value: stripIndents` - Moderators: ${hub.moderators.length.toString()} + Moderators: ${totalMods} Owner: <@${hub.ownerId}> `, inline: true, diff --git a/src/utils/hub/logger/BlockWordAlert.ts b/src/utils/hub/logger/BlockWordAlert.ts index ed75b894..82a2eee5 100644 --- a/src/utils/hub/logger/BlockWordAlert.ts +++ b/src/utils/hub/logger/BlockWordAlert.ts @@ -2,7 +2,7 @@ import { emojis } from '#utils/Constants.js'; import HubLogManager from '#main/managers/HubLogManager.js'; import { sendLog } from '#main/utils/hub/logger/Default.js'; import { ACTION_LABELS, createRegexFromWords } from '#main/utils/moderation/blockWords.js'; -import { MessageBlockList } from '@prisma/client'; +import { BlockWord } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { EmbedBuilder, Message } from 'discord.js'; @@ -10,7 +10,7 @@ const boldANSIText = (text: string) => `\u001b[1;2m${text}\u001b[0m`; export const logBlockwordAlert = async ( message: Message, - rule: MessageBlockList, + rule: BlockWord, matches: string[], ) => { const logManager = await HubLogManager.create(rule.hubId); diff --git a/src/utils/hub/logger/JoinLeave.ts b/src/utils/hub/logger/JoinLeave.ts index 4098a54d..e9980b5c 100644 --- a/src/utils/hub/logger/JoinLeave.ts +++ b/src/utils/hub/logger/JoinLeave.ts @@ -1,8 +1,8 @@ import HubLogManager from '#main/managers/HubLogManager.js'; +import { getHubConnections } from '#utils/ConnectedListUtils.js'; +import Constants, { emojis } from '#utils/Constants.js'; import { stripIndents } from 'common-tags'; import { EmbedBuilder, Guild } from 'discord.js'; -import Constants, { emojis } from '#utils/Constants.js'; -import { getHubConnections } from '#utils/ConnectedListUtils.js'; import { sendLog } from './Default.js'; export const logJoinToHub = async ( @@ -29,7 +29,7 @@ export const logJoinToHub = async ( text: `We have ${opt?.totalConnections} server(s) connected to ${opt?.hubName} now!`, }); - await sendLog(server.client.cluster, logManager.config.joinLeaves, embed); + await sendLog(server.client.cluster, logManager.config.joinLeaves.channelId, embed); }; export const logGuildLeaveToHub = async (hubId: string, server: Guild) => { @@ -57,5 +57,5 @@ export const logGuildLeaveToHub = async (hubId: string, server: Guild) => { text: `We now have ${totalConnections} server(s) connected to the hub now!`, }); - await sendLog(server.client.cluster, logManager.config.joinLeaves, embed); + await sendLog(server.client.cluster, logManager.config.joinLeaves.channelId, embed); }; diff --git a/src/utils/hub/logger/ModLogs.ts b/src/utils/hub/logger/ModLogs.ts index 135ef5c7..4db5d31c 100644 --- a/src/utils/hub/logger/ModLogs.ts +++ b/src/utils/hub/logger/ModLogs.ts @@ -1,11 +1,11 @@ import BlacklistManager from '#main/managers/BlacklistManager.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; -import db from '#utils/Db.js'; -import type { Hub, HubLogConfig } from '@prisma/client'; +import HubLogManager from '#main/managers/HubLogManager.js'; +import HubManager from '#main/managers/HubManager.js'; + + +import Constants, { emojis } from '#utils/Constants.js'; import { stripIndents } from 'common-tags'; import { type Client, codeBlock, EmbedBuilder, type Snowflake, User } from 'discord.js'; -import Constants, { emojis } from '#utils/Constants.js'; import { sendLog } from './Default.js'; const getUnblacklistEmbed = ( @@ -50,32 +50,38 @@ type UnblacklistOpts = { export const logServerUnblacklist = async ( client: Client, - hubId: string, + hub: HubManager, opts: UnblacklistOpts, ) => { - const hub = await db.hub.findFirst({ where: { id: hubId }, include: { logConfig: true } }); - const blacklistManager = new BlacklistManager(new ServerInfractionManager(opts.id)); - const blacklist = await blacklistManager.fetchBlacklist(hubId); - const modLogs = hub?.logConfig.at(0)?.modLogs; - if (!BlacklistManager.isServerBlacklist(blacklist) || !modLogs) return; + const blacklistManager = new BlacklistManager('server', opts.id); + const blacklist = await blacklistManager.fetchBlacklist(hub.id); + + const logConfig = await hub.fetchLogConfig(); + const modLogs = logConfig.config.modLogs; + if (!blacklist?.serverName || !modLogs) return; const embed = getUnblacklistEmbed('Server', { id: opts.id, name: blacklist.serverName, mod: opts.mod, - hubName: hub.name, + hubName: hub.data.name, reason: opts.reason, originalReason: blacklist.reason, }); - await sendLog(client.cluster, modLogs, embed); + await sendLog(client.cluster, modLogs.channelId, embed); }; -export const logUserUnblacklist = async (client: Client, hubId: string, opts: UnblacklistOpts) => { - const hub = await db.hub.findFirst({ where: { id: hubId }, include: { logConfig: true } }); - const blacklistManager = new BlacklistManager(new UserInfractionManager(opts.id)); - const blacklist = await blacklistManager.fetchBlacklist(hubId); - const modLogs = hub?.logConfig.at(0)?.modLogs; +export const logUserUnblacklist = async ( + client: Client, + hub: HubManager, + opts: UnblacklistOpts, +) => { + const blacklistManager = new BlacklistManager('user', opts.id); + const blacklist = await blacklistManager.fetchBlacklist(hub.id); + + const logConfig = await hub.fetchLogConfig(); + const modLogs = logConfig.config.modLogs; if (!blacklist || !modLogs) return; const user = await client.users.fetch(opts.id).catch(() => null); @@ -86,21 +92,22 @@ export const logUserUnblacklist = async (client: Client, hubId: string, opts: Un id: opts.id, mod: opts.mod, reason: opts.reason, - hubName: hub.name, + hubName: hub.data.name, originalReason: blacklist.reason, }); - await sendLog(client.cluster, modLogs, embed); + await sendLog(client.cluster, modLogs.channelId, embed); }; export const logMsgDelete = async ( client: Client, content: string, - hub: Hub & { logConfig: HubLogConfig[] }, + hubName: string, + logConfig: HubLogManager, opts: { userId: string; serverId: string; modName: string; imageUrl?: string }, ) => { - const modLogs = hub?.logConfig.at(0)?.modLogs; - if (!modLogs) return; + const modLogs = logConfig.config.modLogs; + if (!modLogs?.channelId) return; const { userId, serverId } = opts; const user = await client.users.fetch(userId).catch(() => null); @@ -119,9 +126,9 @@ export const logMsgDelete = async ( .addFields([ { name: `${emojis.connect_icon} User`, value: `${user?.username} (\`${userId}\`)` }, { name: `${emojis.rules_icon} Server`, value: `${server?.name} (\`${serverId}\`)` }, - { name: `${emojis.globe_icon} Hub`, value: hub.name }, + { name: `${emojis.globe_icon} Hub`, value: hubName }, ]) .setFooter({ text: `Deleted by: ${opts.modName}` }); - await sendLog(client.cluster, modLogs, embed); + await sendLog(client.cluster, modLogs.channelId, embed); }; diff --git a/src/utils/hub/logger/Profanity.ts b/src/utils/hub/logger/Profanity.ts index 398abda8..1cd7a25a 100644 --- a/src/utils/hub/logger/Profanity.ts +++ b/src/utils/hub/logger/Profanity.ts @@ -1,5 +1,5 @@ +import { HubService } from '#main/services/HubService.js'; import Constants, { emojis } from '#utils/Constants.js'; -import db from '#utils/Db.js'; import { stripIndents } from 'common-tags'; import { EmbedBuilder, Guild, User } from 'discord.js'; import { sendLog } from './Default.js'; @@ -11,8 +11,10 @@ import { sendLog } from './Default.js'; * @param server - The server where the content was posted. */ export default async (hubId: string, rawContent: string, author: User, server: Guild) => { - const hub = await db.hub.findFirst({ where: { id: hubId }, include: { logConfig: true } }); - if (!hub?.logConfig[0]?.profanity) return; + const hub = await new HubService().fetchHub(hubId); + const logConfig = await hub?.fetchLogConfig(); + + if (!hub || !logConfig?.config?.profanity) return; const embed = new EmbedBuilder() .setTitle('Profanity Detected') @@ -23,9 +25,9 @@ export default async (hubId: string, rawContent: string, author: User, server: G value: stripIndents` ${emojis.dotBlue} **Author:** @${author.username} (${author.id}) ${emojis.dotBlue} **Server:** ${server.name} (${server.id}}) - ${emojis.dotBlue} **Hub:** ${hub.name} + ${emojis.dotBlue} **Hub:** ${hub.data.name} `, }); - await sendLog(author.client.cluster, hub?.logConfig[0]?.profanity, embed); + await sendLog(author.client.cluster, logConfig.config.profanity.channelId, embed); }; diff --git a/src/utils/hub/logger/Report.ts b/src/utils/hub/logger/Report.ts index 649c3245..2808e330 100644 --- a/src/utils/hub/logger/Report.ts +++ b/src/utils/hub/logger/Report.ts @@ -20,6 +20,7 @@ import { } from 'discord.js'; import { sendLog } from './Default.js'; import { markResolvedButton } from '#main/interactions/MarkResolvedButton.js'; +import { HubService } from '#main/services/HubService.js'; export type ReportEvidenceOpts = { // the message content @@ -68,7 +69,7 @@ const genJumpLink = async ( ), ); - const networkChannel = await db.connectedList.findFirst({ + const networkChannel = await db.connection.findFirst({ where: { serverId: reportsServerId, hubId }, }); @@ -95,12 +96,12 @@ export const sendHubReport = async ( client: Client, { userId, serverId, reason, reportedBy, evidence }: LogReportOpts, ) => { - const hub = await db.hub.findFirst({ where: { id: hubId }, include: { logConfig: true } }); - if (!hub?.logConfig[0]?.reports?.channelId) return; + const hub = await new HubService().fetchHub(hubId); + const logConfig = await hub?.fetchLogConfig(); - if (!evidence?.messageId) return; + if (!logConfig?.config.reports?.channelId || !evidence?.messageId) return; - const { channelId: reportsChannelId, roleId: reportsRoleId } = hub.logConfig[0].reports; + const { channelId: reportsChannelId, roleId: reportsRoleId } = logConfig.config.reports; const user = await client.users.fetch(userId).catch(() => null); const server = await client.fetchGuild(serverId); const jumpLink = await genJumpLink(hubId, client, evidence?.messageId, reportsChannelId); diff --git a/src/utils/hub/settings.ts b/src/utils/hub/settings.ts index a10b3b8f..14c0b746 100644 --- a/src/utils/hub/settings.ts +++ b/src/utils/hub/settings.ts @@ -13,8 +13,8 @@ export const buildSettingsMenu = ( .setCustomId( new CustomID() .setIdentifier('hub_edit', 'settingsSelect') - .addArgs(userId) - .addArgs(hubId) + .setArgs(userId) + .setArgs(hubId) .toString(), ) .setPlaceholder('Select an option') diff --git a/src/utils/hub/utils.ts b/src/utils/hub/utils.ts index 722a1de2..3be1af79 100644 --- a/src/utils/hub/utils.ts +++ b/src/utils/hub/utils.ts @@ -1,11 +1,9 @@ +import HubManager from '#main/managers/HubManager.js'; import Constants from '#main/utils/Constants.js'; -import { - deleteConnection, - getHubConnections, -} from '#utils/ConnectedListUtils.js'; +import { deleteConnection, getHubConnections } from '#utils/ConnectedListUtils.js'; import Logger from '#utils/Logger.js'; import { checkIfStaff } from '#utils/Utils.js'; -import type { Hub } from '@prisma/client'; +import type { HubModerator, Role } from '@prisma/client'; import { type WebhookMessageCreateOptions, WebhookClient } from 'discord.js'; /** @@ -48,12 +46,13 @@ export const sendToHub = async ( } }; -export const isHubMod = (userId: string, hub: Hub) => - Boolean(hub.ownerId === userId || hub.moderators.find((mod) => mod.userId === userId)); +export const isHubMod = (userId: string, mods: HubModerator[], checkRoles?: Role[]) => + mods.some((mod) => { + if (mod.userId !== userId) return false; + if (!checkRoles) return true; -export const isStaffOrHubMod = (userId: string, hub: Hub) => - checkIfStaff(userId) || isHubMod(userId, hub); + return checkRoles.includes(mod.role); + }); -export const isHubManager = (userId: string, hub: Hub) => - hub.ownerId === userId || - hub.moderators.some((mod) => mod.userId === userId && mod.position === 'manager'); +export const isStaffOrHubMod = async (userId: string, hub: HubManager) => + checkIfStaff(userId) || (await hub.isMod(userId)); diff --git a/src/utils/moderation/blacklistUtils.ts b/src/utils/moderation/blacklistUtils.ts index 0a6fb7ce..e7202758 100644 --- a/src/utils/moderation/blacklistUtils.ts +++ b/src/utils/moderation/blacklistUtils.ts @@ -3,7 +3,7 @@ import { getHubConnections } from '#utils/ConnectedListUtils.js'; import { CustomID } from '#utils/CustomID.js'; import db from '#utils/Db.js'; import Logger from '#utils/Logger.js'; -import { ServerInfraction, UserInfraction } from '@prisma/client'; +import { Infraction } from '@prisma/client'; import { ActionRowBuilder, APIActionRowComponent, @@ -18,10 +18,9 @@ import { User, } from 'discord.js'; import { buildAppealSubmitButton } from '#main/interactions/BlacklistAppeal.js'; +import { HubService } from '#main/services/HubService.js'; -export const isBlacklisted = ( - infraction: T | null, -): infraction is T => +export const isBlacklisted = (infraction: Infraction | null): infraction is Infraction => Boolean( infraction?.type === 'BLACKLIST' && infraction.status === 'ACTIVE' && @@ -66,9 +65,9 @@ export const sendBlacklistNotif = async ( opts: BlacklistOpts, ) => { try { - const hub = await db.hub.findUnique({ where: { id: opts.hubId } }); + const hub = await new HubService().fetchHub(opts.hubId); const embed = buildBlacklistNotifEmbed(type, { - hubName: `${hub?.name}`, + hubName: `${hub?.data.name}`, expiresAt: opts.expiresAt, reason: opts.reason, }); @@ -84,7 +83,7 @@ export const sendBlacklistNotif = async ( else { const serverInHub = (await getHubConnections(opts.hubId))?.find((con) => con.serverId === opts.target.id) ?? - (await db.connectedList.findFirst({ + (await db.connection.findFirst({ where: { serverId: opts.target.id, hubId: opts.hubId }, })); diff --git a/src/utils/moderation/blockWords.ts b/src/utils/moderation/blockWords.ts index ffdc391d..e2bdbf38 100644 --- a/src/utils/moderation/blockWords.ts +++ b/src/utils/moderation/blockWords.ts @@ -2,7 +2,7 @@ import { emojis, numberEmojis } from '#utils/Constants.js'; import { CustomID } from '#utils/CustomID.js'; import { InfoEmbed } from '#utils/EmbedUtils.js'; -import { BlockWordAction, MessageBlockList } from '@prisma/client'; +import { BlockWord, BlockWordAction } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { codeBlock, @@ -38,7 +38,7 @@ export const sanitizeWords = (words: string) => .map((word) => word.trim()) .join(','); -export const buildBlockWordsListEmbed = (rules: MessageBlockList[]) => +export const buildBlockWordListEmbed = (rules: BlockWord[]) => new InfoEmbed() .removeTitle() .setDescription( @@ -54,7 +54,7 @@ export const buildBlockWordsListEmbed = (rules: MessageBlockList[]) => })), ); -export const buildBWRuleEmbed = (rule: MessageBlockList) => { +export const buildBWRuleEmbed = (rule: BlockWord) => { const actions = rule.actions.map((a) => ACTION_LABELS[a]).join(', '); return new InfoEmbed() .removeTitle() @@ -79,7 +79,7 @@ export const buildBlockedWordsBtns = (hubId: string, ruleId: string) => .setStyle(ButtonStyle.Secondary), ); -export const buildBlockWordsModal = (hubId: string, opts?: { presetRule: MessageBlockList }) => { +export const buildBlockWordModal = (hubId: string, opts?: { presetRule: BlockWord }) => { const customId = new CustomID('blockwordsModal', [hubId]); const modal = new ModalBuilder() .setTitle(opts?.presetRule ? `Edit Block Rule ${opts.presetRule.name}` : 'Add Block Word Rule') @@ -110,7 +110,7 @@ export const buildBlockWordsModal = (hubId: string, opts?: { presetRule: Message ); if (opts?.presetRule) { - modal.setCustomId(customId.addArgs(hubId, opts.presetRule.id).toString()); + modal.setCustomId(customId.setArgs(hubId, opts.presetRule.id).toString()); modal.components[0].components[0].setValue(opts.presetRule.name); modal.components[1].components[0].setValue(opts.presetRule.words.replace(/\.\*/g, '*')); } @@ -118,7 +118,7 @@ export const buildBlockWordsModal = (hubId: string, opts?: { presetRule: Message return modal; }; -export const buildBlockWordsActionsSelect = ( +export const buildBlockWordActionsSelect = ( hubId: string, ruleId: string, currentActions: BlockWordAction[], diff --git a/src/utils/moderation/infractionUtils.ts b/src/utils/moderation/infractionUtils.ts index 52c81e37..a9e43d50 100644 --- a/src/utils/moderation/infractionUtils.ts +++ b/src/utils/moderation/infractionUtils.ts @@ -1,18 +1,10 @@ import Constants from '#utils/Constants.js'; import { msToReadable, toTitleCase } from '#utils/Utils.js'; -import { ServerInfraction, UserInfraction } from '@prisma/client'; +import { Infraction } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { EmbedBuilder, User, Client, time } from 'discord.js'; -// Type guard -export const isServerInfraction = ( - list: ServerInfraction | UserInfraction | undefined, -): list is ServerInfraction => Boolean(list && 'serverName' in list); - -const createFieldData = ( - data: ServerInfraction | UserInfraction, - { moderator }: { moderator: User | null }, -) => { +const createFieldData = (data: Infraction, { moderator }: { moderator: User | null }) => { let expiresAt = 'Never'; if (data.expiresAt) { expiresAt = @@ -22,7 +14,7 @@ const createFieldData = ( } return { - name: `${data.id} (${time(data.dateIssued, 'R')})`, + name: `${data.id} (${time(data.createdAt, 'R')})`, value: stripIndents` > \`\`\`yaml > Type: ${data.type} @@ -38,7 +30,7 @@ const createFieldData = ( export const buildInfractionListEmbeds = async ( client: Client, targetName: string, - infractions: (ServerInfraction | UserInfraction)[], + infractions: Infraction[], type: 'server' | 'user', iconURL: string, ) => { @@ -47,9 +39,7 @@ export const buildInfractionListEmbeds = async ( let counter = 0; const firstInfraction = infractions.at(0); - const targetId = isServerInfraction(firstInfraction) - ? firstInfraction.serverId - : firstInfraction?.userId; + const targetId = firstInfraction?.serverId ?? firstInfraction?.userId; const pages = []; for (const infraction of infractions) { diff --git a/src/utils/moderation/modPanel/handlers/blacklistHandler.ts b/src/utils/moderation/modPanel/handlers/blacklistHandler.ts index 83846351..889b0bf9 100644 --- a/src/utils/moderation/modPanel/handlers/blacklistHandler.ts +++ b/src/utils/moderation/modPanel/handlers/blacklistHandler.ts @@ -1,7 +1,7 @@ import { emojis } from '#utils/Constants.js'; import BlacklistManager from '#main/managers/BlacklistManager.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; + + import { OriginalMessage } from '#main/utils/network/messageUtils.js'; import { deleteConnections } from '#utils/ConnectedListUtils.js'; import { CustomID } from '#utils/CustomID.js'; @@ -45,7 +45,7 @@ abstract class BaseBlacklistHandler implements ModAction { return new ModalBuilder() .setTitle(title) .setCustomId( - new CustomID().setIdentifier('blacklist_modal', type).addArgs(originalMsgId).toString(), + new CustomID().setIdentifier('blacklist_modal', type).setArgs(originalMsgId).toString(), ) .addComponents( new ActionRowBuilder().addComponents( @@ -142,7 +142,7 @@ export class BlacklistUserHandler extends BaseBlacklistHandler { } const { reason, expiresAt } = this.getModalData(interaction); - const blacklistManager = new BlacklistManager(new UserInfractionManager(user.id)); + const blacklistManager = new BlacklistManager('user', user.id); await blacklistManager.addBlacklist({ hubId: originalMsg.hubId, @@ -212,7 +212,7 @@ export class BlacklistServerHandler extends BaseBlacklistHandler { } const { reason, expiresAt } = this.getModalData(interaction); - const blacklistManager = new BlacklistManager(new ServerInfractionManager(originalMsg.guildId)); + const blacklistManager = new BlacklistManager('server', originalMsg.guildId); await blacklistManager.addBlacklist({ reason, diff --git a/src/utils/moderation/modPanel/handlers/userBanHandler.ts b/src/utils/moderation/modPanel/handlers/userBanHandler.ts index eb32316a..aa7c300b 100644 --- a/src/utils/moderation/modPanel/handlers/userBanHandler.ts +++ b/src/utils/moderation/modPanel/handlers/userBanHandler.ts @@ -33,7 +33,7 @@ export default class UserBanHandler implements ModAction { const modal = new ModalBuilder() .setTitle('Ban User') .setCustomId( - new CustomID().setIdentifier('userBanModal').addArgs(originalMsg.authorId).toString(), + new CustomID().setIdentifier('userBanModal').setArgs(originalMsg.authorId).toString(), ) .addComponents( new ActionRowBuilder().addComponents( diff --git a/src/utils/moderation/modPanel/handlers/viewInfractions.ts b/src/utils/moderation/modPanel/handlers/viewInfractions.ts index fe5be7e3..2cc7b721 100644 --- a/src/utils/moderation/modPanel/handlers/viewInfractions.ts +++ b/src/utils/moderation/modPanel/handlers/viewInfractions.ts @@ -1,4 +1,3 @@ -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; import { Pagination } from '#main/modules/Pagination.js'; import { getOriginalMessage } from '#main/utils/network/messageUtils.js'; import type { supportedLocaleCodes } from '#utils/Locale.js'; @@ -8,6 +7,7 @@ import { replyWithUnknownMessage, } from '#main/utils/moderation/modPanel/utils.js'; import { type ButtonInteraction, type Snowflake } from 'discord.js'; +import InfractionManager from '#main/managers/InfractionManager.js'; export default class ViewInfractionsHandler implements ModAction { async handle( @@ -30,7 +30,7 @@ export default class ViewInfractionsHandler implements ModAction { return; } - const infractionManager = new UserInfractionManager(originalMsg.authorId); + const infractionManager = new InfractionManager('user', originalMsg.authorId); const infractions = await infractionManager.getHubInfractions(originalMsg.hubId); const targetName = user.username ?? 'Unknown User.'; const iconURL = user.displayAvatarURL(); diff --git a/src/utils/network/blockwordsRunner.ts b/src/utils/network/blockwordsRunner.ts index f416424a..86a72d70 100644 --- a/src/utils/network/blockwordsRunner.ts +++ b/src/utils/network/blockwordsRunner.ts @@ -1,10 +1,11 @@ import BlacklistManager from '#main/managers/BlacklistManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; + import { logBlockwordAlert } from '#main/utils/hub/logger/BlockWordAlert.js'; import Logger from '#main/utils/Logger.js'; import { sendBlacklistNotif } from '#main/utils/moderation/blacklistUtils.js'; import { createRegexFromWords } from '#main/utils/moderation/blockWords.js'; -import { BlockWordAction, MessageBlockList } from '@prisma/client'; +import { CheckResult } from '#main/utils/network/runChecks.js'; +import { BlockWordAction, BlockWord } from '@prisma/client'; import { ActionRowBuilder, Awaitable, ButtonBuilder, Message } from 'discord.js'; // Interface for action handler results @@ -18,7 +19,7 @@ interface ActionResult { // Action handler type type ActionHandler = ( message: Message, - rule: MessageBlockList, + rule: BlockWord, matches: string[], ) => Awaitable; @@ -42,7 +43,7 @@ const actionHandlers: Record = { const target = message.author; const mod = message.client.user; - const blacklistManager = new BlacklistManager(new UserInfractionManager(target.id)); + const blacklistManager = new BlacklistManager('user', target.id); await blacklistManager.addBlacklist({ hubId: rule.hubId, reason, @@ -66,49 +67,79 @@ const actionHandlers: Record = { }, }; -export async function checkBlockedWords(message: Message, msgBlockList: MessageBlockList[]) { - if (msgBlockList.length === 0) return Promise.resolve({ passed: true }); +interface ActionResult { + success: boolean; + shouldBlock: boolean; + message?: string; +} + +interface BlockResult { + shouldBlock: boolean; + reason?: string; +} + +export async function checkBlockedWords( + message: Message, + msgBlockList: BlockWord[], +): Promise { + if (msgBlockList.length === 0) return { passed: true }; for (const rule of msgBlockList) { - const regex = createRegexFromWords(rule.words); - const matches = message.content.match(regex); - - if (matches) { - let shouldBlock = false; - let blockReason: string | undefined; - - // Execute all configured actions for this rule - for (const action of rule.actions || []) { - const handler = actionHandlers[action]; - if (handler) { - try { - const result = await handler(message, rule, matches); - if (result.success && result.shouldBlock) { - shouldBlock = true; - blockReason = result.message; - } - } - catch (error) { - Logger.error(`Failed to execute action ${action}:`, error); - } - } - } - - // If no specific blocking actions were taken but actions were configured, - // still block the message by default - if (rule.actions?.length && !shouldBlock) { - shouldBlock = true; - blockReason = `Your message contains blocked words from the rule: ${rule.name}`; - } - - if (shouldBlock) { - return { - passed: false, - reason: blockReason, - }; - } + const { shouldBlock, reason } = await checkRule(message, rule); + if (shouldBlock) { + return { + passed: false, + reason, + }; } } return { passed: true }; } + +async function executeAction( + action: keyof typeof actionHandlers, + message: Message, + rule: BlockWord, + matches: RegExpMatchArray, +): Promise { + const handler = actionHandlers[action]; + if (!handler) return { success: false, shouldBlock: false }; + + try { + return await handler(message, rule, matches); + } + catch (error) { + Logger.error(`Failed to execute action ${action}:`, error); + return { success: false, shouldBlock: false }; + } +} + +async function processActions( + message: Message, + triggeredRule: BlockWord, + matches: RegExpMatchArray, +): Promise { + if (!triggeredRule.actions.length) return { shouldBlock: false }; + + for (const actionToTake of triggeredRule.actions) { + const result = await executeAction(actionToTake, message, triggeredRule, matches); + if (result.success && result.shouldBlock) { + return { + shouldBlock: true, + reason: result.message, + }; + } + } + + return { shouldBlock: false }; +} + +async function checkRule(message: Message, rule: BlockWord): Promise { + const regex = createRegexFromWords(rule.words); + const matches = message.content.match(regex); + + if (!matches) return { shouldBlock: false }; + + return await processActions(message, rule, matches); +} diff --git a/src/utils/network/buildConnectionAssets.ts b/src/utils/network/buildConnectionAssets.ts index 59cd93d0..2e66217b 100644 --- a/src/utils/network/buildConnectionAssets.ts +++ b/src/utils/network/buildConnectionAssets.ts @@ -20,7 +20,7 @@ export const buildEditEmbed = async ( iconURL: string | undefined, locale: supportedLocaleCodes = 'en', ) => { - const networkData = await db.connectedList.findFirst({ + const networkData = await db.connection.findFirst({ where: { channelId }, include: { hub: true }, }); @@ -78,8 +78,8 @@ export const buildEditSelect = ( .setCustomId( new CustomID() .setIdentifier('connection', 'settings') - .addArgs(channelId) - .addArgs(userIdFilter) + .setArgs(channelId) + .setArgs(userIdFilter) .toString(), ) .setPlaceholder(t('connection.selects.placeholder', locale)) @@ -113,8 +113,8 @@ export const buildChannelSelect = (channelId: Snowflake, userIdFilter: Snowflake .setCustomId( new CustomID() .setIdentifier('connection', 'change_channel') - .addArgs(channelId) - .addArgs(userIdFilter) + .setArgs(channelId) + .setArgs(userIdFilter) .toString(), ) .setChannelTypes(ChannelType.GuildText, ChannelType.PublicThread, ChannelType.PrivateThread) diff --git a/src/utils/network/runChecks.ts b/src/utils/network/runChecks.ts index e6257472..52336c6e 100644 --- a/src/utils/network/runChecks.ts +++ b/src/utils/network/runChecks.ts @@ -1,19 +1,19 @@ import BlacklistManager from '#main/managers/BlacklistManager.js'; +import HubManager from '#main/managers/HubManager.js'; import HubSettingsManager from '#main/managers/HubSettingsManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; + import NSFWDetector from '#main/modules/NSFWDetection.js'; import { sendBlacklistNotif } from '#main/utils/moderation/blacklistUtils.js'; import Constants, { emojis } from '#utils/Constants.js'; import logProfanity from '#utils/hub/logger/Profanity.js'; -import { isHubMod } from '#utils/hub/utils.js'; import { t } from '#utils/Locale.js'; import { check as checkProfanity } from '#utils/ProfanityUtils.js'; import { containsInviteLinks, replaceLinks } from '#utils/Utils.js'; -import { Hub, MessageBlockList, UserData } from '@prisma/client'; +import { UserData } from '@prisma/client'; import { stripIndents } from 'common-tags'; import { Awaitable, EmbedBuilder, Message } from 'discord.js'; -interface CheckResult { +export interface CheckResult { passed: boolean; reason?: string; } @@ -22,7 +22,7 @@ interface CheckFunctionOpts { userData: UserData; settings: HubSettingsManager; totalHubConnections: number; - hub: Hub & { msgBlockList: MessageBlockList[] }; + hub: HubManager; attachmentURL?: string | null; } @@ -59,7 +59,7 @@ const replyToMsg = async ( export const runChecks = async ( message: Message, - hub: Hub & { msgBlockList: MessageBlockList[] }, + hub: HubManager, opts: { userData: UserData; settings: HubSettingsManager; @@ -84,24 +84,27 @@ async function checkBanAndBlacklist( ): Promise { const { userManager } = message.client; const userData = await userManager.getUser(message.author.id); - const blacklistManager = new BlacklistManager(new UserInfractionManager(message.author.id)); + const blacklistManager = new BlacklistManager('user', message.author.id); const blacklisted = await blacklistManager.fetchBlacklist(opts.hub.id); - if (userData?.banMeta?.reason || blacklisted) { + if (userData?.banReason || blacklisted) { return { passed: false }; } return { passed: true }; } -function checkHubLock(message: Message, { hub }: CheckFunctionOpts): CheckResult { - if (hub.locked && !isHubMod(message.author.id, hub)) { +async function checkHubLock( + message: Message, + { hub }: CheckFunctionOpts, +): Promise { + if (hub.data.locked && !(await hub.isMod(message.author.id))) { return { passed: false, reason: 'This hub is currently locked.' }; } return { passed: true }; } const containsLinks = (message: Message, settings: HubSettingsManager) => - settings.getSetting('HideLinks') && + settings.has('HideLinks') && !Constants.Regex.StaticImageUrl.test(message.content) && Constants.Regex.Links.test(message.content); @@ -116,14 +119,14 @@ function checkLinks(message: Message, opts: CheckFunctionOpts): CheckResul async function checkSpam(message: Message, opts: CheckFunctionOpts): Promise { const { settings, hub } = opts; const result = await message.client.antiSpamManager.handleMessage(message); - if (settings.getSetting('SpamFilter') && result) { + if (settings.has('SpamFilter') && result) { if (result.messageCount >= 6) { const expiresAt = new Date(Date.now() + 60 * 5000); const reason = 'Auto-blacklisted for spamming.'; const target = message.author; const mod = message.client.user; - const blacklistManager = new BlacklistManager(new UserInfractionManager(target.id)); + const blacklistManager = new BlacklistManager('user', target.id); await blacklistManager.addBlacklist({ hubId: hub.id, reason, @@ -199,7 +202,7 @@ async function checkInviteLinks( ): Promise { const { settings, userData } = opts; - if (settings.getSetting('BlockInvites') && containsInviteLinks(message.content)) { + if (settings.has('BlockInvites') && containsInviteLinks(message.content)) { const locale = await message.client.userManager.getUserLocale(userData); return { passed: false, reason: t('errors.inviteLinks', locale, { emoji: emojis.no }) }; } diff --git a/src/utils/network/storeMessageData.ts b/src/utils/network/storeMessageData.ts index d43a0aa6..59f4829d 100644 --- a/src/utils/network/storeMessageData.ts +++ b/src/utils/network/storeMessageData.ts @@ -23,7 +23,7 @@ interface SendResult { export type NetworkWebhookSendResult = ErrorResult | SendResult; /** - * Stores message data in the database and updates the connectedList based on the webhook status. + * Stores message data in the database and updates the Connection based on the webhook status. * @param channelAndMessageIds The result of sending the message to multiple channels. * @param hubId The ID of the hub to connect the message data to. */ diff --git a/src/utils/reaction/actions.ts b/src/utils/reaction/actions.ts index ec7c6596..7581bad9 100644 --- a/src/utils/reaction/actions.ts +++ b/src/utils/reaction/actions.ts @@ -100,7 +100,7 @@ export const updateReactions = async ( const broadcastedMessages = Object.values( await getBroadcasts(originalMessage.messageId, originalMessage.hubId), ); - const connections = await db.connectedList.findMany({ + const connections = await db.connection.findMany({ where: { channelId: { in: broadcastedMessages.map((c) => c.channelId) }, connected: true, diff --git a/src/utils/reaction/helpers.ts b/src/utils/reaction/helpers.ts index f6613dae..323d70cd 100644 --- a/src/utils/reaction/helpers.ts +++ b/src/utils/reaction/helpers.ts @@ -1,6 +1,6 @@ import BlacklistManager from '#main/managers/BlacklistManager.js'; -import ServerInfractionManager from '#main/managers/InfractionManager/ServerInfractionManager.js'; -import UserInfractionManager from '#main/managers/InfractionManager/UserInfractionManager.js'; + + import { isBlacklisted } from '#utils/moderation/blacklistUtils.js'; /** @@ -16,10 +16,10 @@ export const checkBlacklists = async ( userId: string | null, ) => { const userBlacklistManager = userId - ? new BlacklistManager(new UserInfractionManager(userId)) + ? new BlacklistManager('user', userId) : undefined; const guildBlacklistManager = guildId - ? new BlacklistManager(new ServerInfractionManager(guildId)) + ? new BlacklistManager('server', guildId) : undefined; const userBlacklist = await userBlacklistManager?.fetchBlacklist(hubId);