A Discord utility app that can convert messages into colorful ANSI-formatted text blocks, translates messages between languages, and more! Perfect for making your important messages stand out, adding some flair to your Discord server, or communicating with users who speak different languages.
-
Text Formatting
- Slash Command: Use
/chromato create custom colored text - Context Menu: Right-click any message and select "Colorize Text" to transform it
- Formatting Options: Choose from normal, bold, or underlined text
- Color Choices: 8 text colors and 8 background colors to mix and match
- Mobile-Friendly Mode: Optional streamlined output for easier copy-pasting on mobile devices
- Slash Command: Use
-
Translation
- Slash Command: Use
/translateto translate text to another language - Context Menu: Right-click any message and select "Translate" to translate it
- Language Options: Choose from 10 popular languages including English, Spanish, French, and more
- Auto-Detection: Automatically detects the source language of the message
- Slash Command: Use
You can easily add Chroma to your apps or server by clicking here. However, if you're interested in contributing, or maybe creating your own version of Chroma, then you can do so by following the guide below.
- Python 3.8+
- Discord.py v2.0+
- python-dotenv
- googletrans==4.0.2
-
Clone the repository
git clone https://github.com/lsalik2/chroma.git cd chroma -
Install dependencies
pip install -r requirements.txt
-
Create a Discord bot
- Go to Discord Developer Portal
- Create a new application
- Add a bot to your application
- Copy your bot token under the "Bot" tab
-
Configure environment variables
-
Create a
.envfile in the project directory -
Add your Discord bot token:
DISCORD_TOKEN=your_token_here
-
-
Invite the bot to your server
- Go to OAuth2 > URL Generator in the Discord Developer Portal
- Select scopes:
bot,applications.commands - Select permissions:
Send Messages,Use Slash Commands - Use the generated URL to invite the bot to your server
-
Run the bot
python bot.py
Use the /chroma command with the following parameters:
message: The text you want to colorizeformat: Choose text formatting (Normal, Bold, Underline)background_color: Select a background colortext_color: Select a text colormobile_friendly: (Optional) Simplified output for mobile users
- Right-click on any message
- Select Apps > Colorize Text
- Choose your formatting options from the dropdown menus
- Click "Submit"
Use the /translate command with the following parameters:
text: The text you want to translatelanguage: The target language to translate to
- Right-click on any message
- Select Apps > Translate
- Choose your target language from the dropdown menu
- Click "Submit"
| Formats | Text Colors | Background Colors |
|---|---|---|
| Normal (0) | Grey (30) | Dark Blue (40) |
| Bold (1) | Red (31) | Orange (41) |
| Underline (4) | Green (32) | Dark Grey (42) |
| Yellow (33) | Grey (43) | |
| Blue (34) | Light Grey (44) | |
| Pink (35) | Indigo (45) | |
| Cyan (36) | Silver (46) | |
| White (37) | White (47) |
| Language | Code |
|---|---|
| English | en |
| Spanish | es |
| French | fr |
| German | de |
| Italian | it |
| Portuguese | pt |
| Russian | ru |
| Japanese | ja |
| Chinese (Simplified) | zh-cn |
| Arabic | ar |
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- A guide to ANSI on Discord by kkrypt0nn
- The Discord.py team for their excellent library
- The googletrans library for translation functionality
- All contributors who help improve Chroma
If you need help with setup or have questions, please open an issue on GitHub or message slk on Discord.
