-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Manage discord spoilers #3
Conversation
Markdown on all clients will eventually be consistent as features are developed, so callback handling is not needed. Also, the library should not have custom html tags, so please revert it to the original output with altered regex. |
I am confused what you mean by this. the |
It should return like this All elements use a span with a class for styling and support for css modules |
it that case it won't be usable in systems that use a limited subset of html, as mentioned in #4, output customizability for such non-standard things are kinda needed there |
I don't understand what you mean by that. The Pr must maintain consistency with the rest of the library. It is not my intention to support clients that have rare use-cases such as not being able to use classes. If you want to patch the spoiler regex and test, that's fine. This PR introduces a breaking change by changing how we output tags and breaking CSS module support. It also includes and undocumented change to run eslint, which should at least be mentioned. |
while i adapted it now we will have to fork it, sadly |
Due to the number of issues with this PR I've decided to just implement it myself |
The existing code for
some {{spoiler}}
doesn't seem to be what discords markdown for this is.As of the point of writing this they introduced
some ||spoiler||
with all kind of cases. Currently webbrowser discord just gobbles up the|
, but android discord makes it a spoiler correctly.This makes spoilers have the ability to have a custom callback, as, well, each environment may want to treat spoilers differently