4.0.0 • Published 5 years ago

primer-markdown v4.0.0

Weekly downloads
1,551
License
MIT
Repository
github
Last release
5 years ago

Primer Markdown

npm version Build Status

Stylesheets for rendering GitHub Flavored Markdown and syntax highlighted code snippets.

This repository is a module of the full primer repository.

Install

This repository is distributed with npm. After installing npm, you can install primer-markdown with this command.

$ npm install --save primer-markdown

Usage

The source files included are written in Sass (scss) You can simply point your sass include-path at your node_modules directory and import it like this.

@import "primer-markdown/index.scss";

You can also import specific portions of the module by importing those partials from the /lib/ folder. Make sure you import any requirements along with the modules.

Build

For a compiled css version of this module, a npm script is included that will output a css version to build/build.css The built css file is also included in the npm package.

$ npm run build

Documentation

Text can be bold, italic, or strikethrough. Links should be blue with no underlines (unless hovered over).

There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs.

There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs. There should be whitespace between paragraphs.

There should be no margin above this first sentence.

Blockquotes should be a lighter gray with a gray border along the left side.

There should be no margin below this final sentence.

Header 1

This is a normal paragraph following a header. Bacon ipsum dolor sit amet t-bone doner shank drumstick, pork belly porchetta chuck sausage brisket ham hock rump pig. Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.

Header 2

This is a blockquote following a header. Bacon ipsum dolor sit amet t-bone doner shank drumstick, pork belly porchetta chuck sausage brisket ham hock rump pig. Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.

Header 3

This is a code block following a header.

Header 4

  • This is an unordered list following a header.
  • This is an unordered list following a header.
  • This is an unordered list following a header.
Header 5
  1. This is an ordered list following a header.
  2. This is an ordered list following a header.
  3. This is an ordered list following a header.
Header 6
WhatFollows
A tableA header
A tableA header
A tableA header

There's a horizontal rule above and below this.


Here is an unordered list:

  • Salt-n-Pepa
  • Bel Biv DeVoe
  • Kid 'N Play

And an ordered list:

  1. Michael Jackson
  2. Michael Bolton
  3. Michael Bublé

And an unordered task list:

  • Create a sample markdown document
  • Add task lists to it
  • Take a vacation

And a "mixed" task list:

  • Steal underpants
  • ?
  • Profit!

And a nested list:

  • Jackson 5
    • Michael
    • Tito
    • Jackie
    • Marlon
    • Jermaine
  • TMNT
    • Leonardo
    • Michelangelo
    • Donatello
    • Raphael

Definition lists can be used with HTML syntax. Definition terms are bold and italic.


Tables should have bold headings and alternating shaded rows.

ArtistAlbumYear
Michael JacksonThriller1982
PrincePurple Rain1984
Beastie BoysLicense to Ill1986

If a table is too wide, it should condense down and/or scroll horizontally.

ArtistAlbumYearLabelAwardsSongs
Michael JacksonThriller1982Epic RecordsGrammy Award for Album of the Year, American Music Award for Favorite Pop/Rock Album, American Music Award for Favorite Soul/R&B Album, Brit Award for Best Selling Album, Grammy Award for Best Engineered Album, Non-ClassicalWanna Be Startin' Somethin', Baby Be Mine, The Girl Is Mine, Thriller, Beat It, Billie Jean, Human Nature, P.Y.T. (Pretty Young Thing), The Lady in My Life
PrincePurple Rain1984Warner Brothers RecordsGrammy Award for Best Score Soundtrack for Visual Media, American Music Award for Favorite Pop/Rock Album, American Music Award for Favorite Soul/R&B Album, Brit Award for Best Soundtrack/Cast Recording, Grammy Award for Best Rock Performance by a Duo or Group with VocalLet's Go Crazy, Take Me With U, The Beautiful Ones, Computer Blue, Darling Nikki, When Doves Cry, I Would Die 4 U, Baby I'm a Star, Purple Rain
Beastie BoysLicense to Ill1986Mercury RecordsnoawardsbutthistablecelliswideRhymin & Stealin, The New Style, She's Crafty, Posse in Effect, Slow Ride, Girls, (You Gotta) Fight for Your Right, No Sleep Till Brooklyn, Paul Revere, Hold It Now, Hit It, Brass Monkey, Slow and Low, Time to Get Ill

Code snippets like var foo = "bar"; can be shown inline.

Also, this should vertically align with this and this.

Code can also be shown in a block element.

var foo = "bar";

Code can also use syntax highlighting.

var foo = "bar";
Long, single-line code blocks should not wrap. They should horizontally scroll if they are too long. This line should be long enough to demonstrate this.
var foo = "The same thing is true for code with syntax highlighting. A single line of code should horizontally scroll if it is really long.";

Inline code inside table cells should still be distinguishable.

LanguageCode
Javascriptvar foo = "bar";
Rubyfoo = "bar"

Small images should be shown at their actual size.

npm.io

Large images should always scale down and fit in the content container.

npm.io

This is the final element on the page and there should be no margin below this.

License

MIT © GitHub

4.0.0

5 years ago

3.7.13

5 years ago

3.7.12

5 years ago

3.7.12-rc.1

5 years ago

3.7.12-rc.0

5 years ago

3.7.11-rc.6

5 years ago

3.7.11-rc.5

5 years ago

3.7.11

5 years ago

3.7.11-rc.4

5 years ago

3.7.11-rc.3

5 years ago

3.7.11-rc.2

5 years ago

3.7.11-rc.1

5 years ago

3.7.11-rc.0

5 years ago

3.7.10-rc.5

5 years ago

3.7.10-rc.4

5 years ago

3.7.10-rc.3

5 years ago

3.7.10-rc.2

5 years ago

3.7.10-rc.1

5 years ago

3.7.10

5 years ago

3.7.10-rc.0

5 years ago

3.7.9-rc.12

5 years ago

3.7.9-rc.11

5 years ago

3.7.9-rc.10

5 years ago

3.7.9-rc.9

5 years ago

3.7.9-rc.8

5 years ago

3.7.9-rc.7

5 years ago

3.7.9-rc.6

5 years ago

3.7.9-rc.5

5 years ago

3.7.9-rc.4

5 years ago

3.7.9-rc.3

5 years ago

3.7.9

6 years ago

3.7.9-rc.2

6 years ago

3.7.9-rc.1

6 years ago

3.7.9-rc.0

6 years ago

3.7.8-rc.2

6 years ago

3.7.8-rc.1

6 years ago

3.7.8

6 years ago

3.7.8-rc.0

6 years ago

3.7.7-rc.10

6 years ago

3.7.7-rc.9

6 years ago

3.7.7-rc.8

6 years ago

3.7.7-rc.7

6 years ago

3.7.7-rc.6

6 years ago

3.7.7-rc.5

6 years ago

3.7.7-rc.4

6 years ago

3.7.7-rc.3

6 years ago

3.7.7-rc.2

6 years ago

3.7.7

6 years ago

3.7.7-rc.1

6 years ago

3.7.7-rc.0

6 years ago

3.7.6-rc.2

6 years ago

3.7.6-rc.1

6 years ago

3.7.6

6 years ago

3.7.6-rc.0

6 years ago

3.7.5-rc.7

6 years ago

3.7.5-rc.6

6 years ago

3.7.5-rc.5

6 years ago

3.7.5-rc.4

6 years ago

3.7.5-rc.3

6 years ago

3.7.5-rc.2

6 years ago

3.7.5-rc.1

6 years ago

3.7.5

6 years ago

3.7.5-rc.0

6 years ago

3.7.4-rc.14

6 years ago

3.7.4-rc.13

6 years ago

3.7.4-rc.12

6 years ago

3.7.4-rc.11

6 years ago

3.7.4-rc.10

6 years ago

3.7.4-rc.9

6 years ago

3.7.4-rc.8

6 years ago

3.7.4-rc.7

6 years ago

3.7.4-rc.6

6 years ago

3.7.4-rc.5

6 years ago

3.7.4-rc.4

6 years ago

3.7.4-rc.3

6 years ago

3.7.4

6 years ago

3.7.4-rc.2

6 years ago

3.7.4-rc.1

6 years ago

3.7.4-rc.0

6 years ago

3.7.3-rc.7

6 years ago

3.7.3-rc.6

6 years ago

3.7.3-rc.5

6 years ago

3.7.3-rc.4

6 years ago

3.7.3-rc.3

6 years ago

3.7.3-rc.2

6 years ago

3.7.3

6 years ago

3.7.3-rc.1

6 years ago

3.7.3-rc.0

6 years ago

3.7.2-rc.6

6 years ago

3.7.2-rc.5

6 years ago

3.7.2-rc.4

6 years ago

3.7.2-rc.3

6 years ago

3.7.2-rc.2

6 years ago

3.7.2-rc.1

6 years ago

3.7.2

6 years ago

3.7.2-rc.0

6 years ago

3.7.1-rc.17

6 years ago

3.7.1-rc.16

6 years ago

3.7.1-rc.15

6 years ago

3.7.1-rc.14

6 years ago

3.7.1-rc.13

6 years ago

3.7.1-rc.12

6 years ago

3.7.1-rc.11

6 years ago

3.7.1-rc.10

6 years ago

3.7.1-rc.9

6 years ago

3.7.1-rc.8

6 years ago

3.7.1-rc.7

6 years ago

3.7.1-rc.6

6 years ago

3.7.1-rc.5

6 years ago

3.7.1-rc.4

6 years ago

3.7.1-rc.3

6 years ago

3.7.1-rc.2

6 years ago

3.7.1-rc.1

6 years ago

3.7.1-rc.0

6 years ago

3.7.1

6 years ago

3.7.0-rc.18

6 years ago

3.7.0-rc.17

6 years ago

3.7.0-rc.16

6 years ago

3.7.0-rc.15

6 years ago

3.7.0-rc.14

6 years ago

3.7.0-rc.13

6 years ago

3.7.0-rc.12

6 years ago

3.7.0-rc.11

6 years ago

3.7.0-rc.10

6 years ago

3.7.0-rc.9

6 years ago

3.7.0-rc.8

6 years ago

3.7.0-rc.7

6 years ago

3.7.0-rc.6

6 years ago

3.7.0

6 years ago

3.7.0-rc.5

6 years ago

3.6.0-rc.10

7 years ago

3.7.0-rc.4

7 years ago

3.6.0-rc.9

7 years ago

3.7.0-rc.3

7 years ago

3.7.0-rc.2

7 years ago

3.6.0-rc.8

7 years ago

3.7.0-rc.1

7 years ago

3.7.0-rc.0

7 years ago

3.6.0-rc.7

7 years ago

3.6.0-rc.6

7 years ago

3.6.0-rc.5

7 years ago

3.6.0-rc.4

7 years ago

3.6.0-rc.3

7 years ago

3.6.0

7 years ago

3.6.0-rc.2

7 years ago

3.6.0-rc.1

7 years ago

3.6.0-rc.0

7 years ago

3.5.0

7 years ago

3.5.0-rc.1

7 years ago

3.5.0-rc.0

7 years ago

3.4.1-rc.15

7 years ago

3.4.1-rc.14

7 years ago

3.4.1

7 years ago

3.4.1-rc.13

7 years ago

3.4.1-rc.12

7 years ago

3.4.1-rc.11

7 years ago

3.4.1-rc.10

7 years ago

3.4.1-rc.9

7 years ago

3.4.1-rc.8

7 years ago

3.4.0

7 years ago

3.4.0-rc.7

7 years ago

3.4.0-rc.6

7 years ago

3.4.0-rc.5

7 years ago

3.4.0-rc.4

7 years ago

3.3.13-4

7 years ago

3.3.13-3

7 years ago

3.3.13-2

7 years ago

3.3.13-1

7 years ago

3.3.13

7 years ago

3.3.13-0

7 years ago

3.3.12

7 years ago

3.3.11

7 years ago

3.3.10

7 years ago

3.3.9

7 years ago

3.3.8

7 years ago

3.3.8-alpha.1

7 years ago

3.3.8-alpha.0

7 years ago

3.3.8-monobeta.0

7 years ago

3.3.8-monotest.0

7 years ago

3.3.8-mono.0

7 years ago

3.3.7

7 years ago

3.3.6

7 years ago

3.3.5

7 years ago

3.3.3

7 years ago

3.3.2

7 years ago

3.3.1

7 years ago

3.3.0

8 years ago

3.2.0

8 years ago

3.1.3

8 years ago

3.1.2

8 years ago

3.1.1

8 years ago

3.1.0

8 years ago

3.0.0

8 years ago

2.5.1

8 years ago

2.5.0

8 years ago

2.4.0

8 years ago

2.3.0

8 years ago

2.2.3

8 years ago

2.2.2

8 years ago

2.2.1

8 years ago

2.1.7

8 years ago