Browse Source

Added emojies to demo

pull/14/head
Vitaly Puzrin 10 years ago
parent
commit
cdf0e2b1f5
  1. 2
      Makefile
  2. 1
      package.json
  3. 1
      support/demo_template/index.jade
  4. 6
      support/demo_template/index.js
  5. 17
      support/demo_template/sample.md

2
Makefile

@ -26,6 +26,8 @@ demo: lint browserify
cp ./dist/markdown-it.js ./demo/
cp ./support/demo_template/index.js ./demo/
cp ./support/demo_template/README.md ./demo/
mkdir ./demo/plugins
cp ./node_modules/markdown-it-emoji/dist/* ./demo/plugins
gh-pages: demo
touch ./demo/.nojekyll

1
package.json

@ -36,6 +36,7 @@
"eslint-plugin-nodeca": "^1.0.0",
"istanbul": "*",
"jade": "^1.6.0",
"markdown-it-emoji": "~ 0.1.0",
"markdown-it-testgen": "~ 0.1.0",
"marked": "0.3.2",
"stylus": "^0.49.1",

1
support/demo_template/index.jade

@ -18,6 +18,7 @@ html
link(rel='stylesheet' href='https://cdn.jsdelivr.net/highlight.js/8.4.0/styles/solarized_light.min.css')
script(src='markdown-it.js')
script(src='plugins/markdown-it-emoji.js')
link(rel='stylesheet' href='index.css')
script(src='index.js')

6
support/demo_template/index.js

@ -58,8 +58,10 @@
mdHtml = window.markdownit('commonmark');
mdSrc = window.markdownit('commonmark');
} else {
mdHtml = window.markdownit('full', defaults);
mdSrc = window.markdownit('full', defaults);
mdHtml = window.markdownit('full', defaults)
.use(window.markdownitEmoji);
mdSrc = window.markdownit('full', defaults)
.use(window.markdownitEmoji);
}
// Beautify output of parser for html content

17
support/demo_template/sample.md

@ -35,13 +35,9 @@ Enable typographer option to see result.
test.. test... test..... test?..... test!....
!!!!!! ???? ,,
!!!!!! ???? ,, -- ---
markdown-it -- awesome
"Smartypants, double quotes"
'Smartypants, single quotes'
"Smartypants, double quotes" and 'single quotes'
## Emphasis
@ -169,6 +165,15 @@ With a reference later in the document defining the URL location:
[id]: https://octodex.github.com/images/dojocat.jpg "The Dojocat"
# Emojies (via [plugin](https://github.com/markdown-it/markdown-it-emoji))
> Classic markup: :wink: :crush: :cry: :tear: :laughing: :yum:
>
> Shortcuts (emoticons): :-) :-( 8-) ;)
see [how to change output](https://github.com/markdown-it/markdown-it-emoji#change-output) with twemoji.
## Footnotes
Footnote 1 link[^first].

Loading…
Cancel
Save