Skip to content
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

notifications in markup: info, success, warning, error #887

Closed
McFoggy opened this issue Apr 30, 2016 · 10 comments
Closed

notifications in markup: info, success, warning, error #887

McFoggy opened this issue Apr 30, 2016 · 10 comments

Comments

@McFoggy
Copy link

McFoggy commented Apr 30, 2016

Would be great to have some support both at markup and renderer level (CSS) for notifications panel. Something like (taken from Isabel Castillo blog)
image

Of course underlying markups libraries would have to support such a feature.

In mardown it could be for example:

! This is an info message.
!v This is a success message.
!! Consider this a warning.
!x This is an error message.

It would ease a lot to have good rendered README when explaining how to use your project/library or whatever else.

@PuZZleDucK
Copy link

A simple hack (sans color) might be to use icons:
ℹ️ :information_source:
☑️ :ballot_box_with_check:
⚠️ :warning:
:x:

or
:exclamation:
✖️ :heavy_multiplication_x:

good list of more here: https://gist.github.com/rxaviers/7360908

@jhermann
Copy link

rST has these kind of blocks officially (admonitions), but the HTML whitelist is way too aggressive and filters them out, in the worst case leading to misunderstandings because of the missing visual cue how to interpret the text.

See also #905 (comment), namespacing could be a viable alternative to just kicking CSS out.

@kivikakk
Copy link
Contributor

kivikakk commented Sep 5, 2018

The emoji hack is a good idea — we won't be expanding Markdown with new syntax, so we won't be adding it as a GitHub-specific feature.

@kivikakk kivikakk closed this as completed Sep 5, 2018
@McFoggy
Copy link
Author

McFoggy commented Sep 5, 2018

The emoji hack is a good idea

Except that it does not provide paragraph highlighting.

One would have to use blockquote to mark a paragraph and an emoji to type it.

ℹ️ this is an information

✔️ this is a success

⚠️ this is a warning

❌ this is an error

Honestly such a hacking is IMO not exactly what was expected.

@jhermann
Copy link

jhermann commented Sep 5, 2018

Still a hack, but IMHO better…

Some text.

@berakoc
Copy link

berakoc commented Aug 6, 2020

Still a hack, but IMHO better…

❗ Some text.

How can I do that?

@berakoc
Copy link

berakoc commented Aug 6, 2020

Would be great to have some support both at markup and renderer level (CSS) for notifications panel. Something like (taken from Isabel Castillo blog)
image

Of course underlying markups libraries would have to support such a feature.

In mardown it could be for example:

! This is an info message.
!v This is a success message.
!! Consider this a warning.
!x This is an error message.

It would ease a lot to have good rendered README when explaining how to use your project/library or whatever else.

I know it has been 4 years but anyways. I guess you wanted something like that: https://github.com/MuhammedBeraKoc/github-notification-markups.

@jhermann
Copy link

jhermann commented Aug 7, 2020

How can I do that?

It is just a table...

:bangbang: | This is important
:---: | :---
‼️ This is important

@McFoggy
Copy link
Author

McFoggy commented Aug 7, 2020

@MuhammedBeraKoc thanks for the trick but it still looks quite hacky. I would really prefer an official inclusion in the markup.

FYI my implementation of this in commonmark-java : commonmark-ext-notifications is now an official commonmark-java extension.

@laserhybiz
Copy link

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants