You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
List of few features that I want to add to this bot if possible. Some of the following may seem unnecessary and I'll re-think about it when I'm working on it. (Warning! This list might include some items that may seem stupid or can never be done)
Highlight only if the code block contains more than x number of characters. It would be a mess if someone use three backticks instead of one backtick, even for a single monospace word.
Make send as document mode the default mode for images.
Allow users to toggle code wrapping for a chat.
Disable code wrapping by default.
Quick inline mode. Write the code after the bot username and the bot should return two inline results: 1) Highlighted image and 2) Highlighted image with code as caption (incase someone wants to copy and edit it).
Show a preview of the theme set: When a theme is set for a chat send a highlighted dummy code image using the chat settings. That'll help user to see what's their configuration looks like.
There Is More Mode for private chats, which allows users to make highlighted images for snippets with more than 4096 (Telegram limit) characters.
Allow formatting supported languages using dprint. "fmt" parameter probably. (Not quite sure about this, might be an overkill).
Allow users to specify language with an argument in the /hl (/highlight) command. For accurate highlighting.
Show chat settings (theme, font) in /stats (or introduce a /settings command).
Switch to a better highlighter library such as Shiki or Prisma. They would require language of the code. So: language guessing using yoeo/guesslang model or its modified microsoft/vscode-languagedetection one.
Allow users to make line numbers optional and introduce a toggle-using-argument for that as well.
Emoji support: Currently emoji aren't rendered due to some limitations with the library we're using. But there is a way using images or SVG. Couldn't hurt to try even though I'm pretty sure it will make the image generation slower.
Re-rendering for edits: Re-render the image when the source is edited. This feature MUST have the ability to toggle.
Recovery mode argument: r. When people forgot to format the code, and have used `, or * symbols which caused their code to get formatted by their client, recover mode comes to the rescue. It goes through the message entities that are in the code snippet and applies them back. Probably, only support Markdown v2.
Finished
No puppeteer. Highlighting without using puppeteer. (The most wanted feature). This was done in v0.5.0 by using an implementation which creates a SVG and transform it into PNG.
Forced /highlighting by replying to a message - if the message contains pre code blocks, highlight them in the usual way. If not, highlight the whole message.
Miscellaneous
Design a more simple bot profile picture. (Maybe not)
Help message for private and a brief one for groups (not for admins).
Improve locales and messages.
Improve README instructions and guide.
The text was updated successfully, but these errors were encountered:
Features
List of few features that I want to add to this bot if possible. Some of the following may seem unnecessary and I'll re-think about it when I'm working on it. (Warning! This list might include some items that may seem stupid or can never be done)
r
. When people forgot to format the code, and have used `, or * symbols which caused their code to get formatted by their client, recover mode comes to the rescue. It goes through the message entities that are in the code snippet and applies them back. Probably, only support Markdown v2.Finished
Miscellaneous
The text was updated successfully, but these errors were encountered: