Faraaz Biyabani

Results 15 comments of Faraaz Biyabani

I can get it to work by editing [this](https://github.com/notion-enhancer/desktop/blob/8e9442336d49cc74bbe46d4b4949fb7a7c1e7515/pkg/apply.mjs#L78) line to fix the inserted `require` statement as ```js `\n\n//notion-enhancer\nrequire('notion-enhancer')('${target.replace(/\\/g, "/")}', exports, (js) => eval(js))` // target.replace(/\\/g, "\\\\")} would also work...

This is a great idea! Rebuilding the left sidebar on each run and iframing it into every page looks straightforward. We can also assume that per_page will not be changed...

Basically, all formatting such as bold, italic, inline links, etc. is removed (because `message.raw_text` is being used [here](https://github.com/knadh/tg-archive/blob/e9de88b07a19f6377d4d44cac0bb5550bfbecd27/tgarchive/sync.py#L163)). `message.text` contains the message content as sanitized HTML (with `client.parse_mode = 'html'`)...

I agree, starting over with large channels seems impractical. I could be missing something but what I understand is raw text should not be rendered without escaping and HTML cannot...

Thanks for the feedback! Have made the change.

Thanks @farzat, but with the option you suggest we need to determine whether a message is raw text or HTML. Consider these example messages, > 1. msg.raw_text - `` (requires...

I guess Telegram returns [`MessageEntity`](https://core.telegram.org/type/MessageEntity) objects which is left for the client (Telethon) to handle and Telethon can give us raw text, HTML and Markdown using those objects. The `raw_text`...

Yes, as expected, `html_messages: True` leads to `message.text` [being stored](https://github.com/faraazb/tg-archive/blob/24abc2bf5c10fb905629d7e40c8a12eebe59df04/tgarchive/sync.py#L128), which is already sanitized by Telethon. However, with `html_messages: False` or in the absence of the config., unescaped raw text...

I agree. Some information has to be stored somewhere which is ultimately due to the Telethon `raw_text` behaviour that was discussed above. If we store version number for future purposes...

To summarize the options and their impact, we can have 1. A config. option (`html_messages: True`), enforces a format on site level. New messages are in HTML if config. is...