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

Add admonition type "question" #3295

Closed
arcturus140 opened this issue Oct 21, 2019 · 2 comments
Closed

Add admonition type "question" #3295

arcturus140 opened this issue Oct 21, 2019 · 2 comments
Labels
feature request 🌟 Issue is a new feature request.

Comments

@arcturus140
Copy link
Contributor

Current behavior

https://github.com/docarys/markdown-it-admonition has an admonition type for questions.

Expected behavior

An admonition to highlight questions would be very useful. I miss that a lot.

!!! question

!!!

Other types provided by markdown-it-admonition and currently not supported in Boostnote are:

  • abstract
  • tip
  • success
  • warning
  • failure
  • example
  • quote

However, I think adding all of them would be confusing as caution, danger and warning can be used exchangeable.

Steps to Replicate

!!! question

!!!

Environment

  • Version : 0.11.12
  • OS Version and name : 16.04 Ubuntu
@Flexo013 Flexo013 added the feature request 🌟 Issue is a new feature request. label Oct 21, 2019
@Flexo013 Flexo013 changed the title add admonition type "question" Add admonition type "question" Oct 21, 2019
@ibraude ibraude mentioned this issue Oct 21, 2019
@ibraude
Copy link
Contributor

ibraude commented Oct 21, 2019

Hey,
See #3297 for the added question, quote, and abstract types.

You can add as many as you'd like by adding styles to markdown.styl:

admonition_types = {
    note: {color: #0288D1, icon: "note"},
    hint: {color: #009688, icon: "info_outline"},
    danger: {color: #c2185b, icon: "block"},
    caution: {color: #ffa726, icon: "warning"},
    error: {color: #d32f2f, icon: "error_outline"},
    question: {color: #64dd17, icon: "help_outline"},
    quote: {color: #9e9e9e, icon: "format_quote"},
    abstract: {color: #00b0ff, icon: "subject"},
    attention: {color: #455a64, icon: "priority_high"},
}

and adding the name of the admonition at markdown.js

   this.md.use(require('markdown-it-admonition'), {types: ['note', 'hint', 'attention', 'caution', 'danger', 'error', 'quote', 'abstract', 'question']})

@LuaGeo
Copy link

LuaGeo commented May 1, 2023

Hello, how could i access the file markdown.js in the application?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request 🌟 Issue is a new feature request.
Projects
None yet
Development

No branches or pull requests

4 participants