Skip to content
This repository has been archived by the owner on Sep 7, 2020. It is now read-only.

Commit

Permalink
Added: highlight.js theme in the default Phenomic theme
Browse files Browse the repository at this point in the history
Closes #702
  • Loading branch information
MoOx committed Sep 17, 2016
1 parent 0522b18 commit d6330fa
Show file tree
Hide file tree
Showing 3 changed files with 128 additions and 0 deletions.
21 changes: 21 additions & 0 deletions themes/phenomic-theme-base/content/posts/first-post.md
Expand Up @@ -5,3 +5,24 @@ layout: Post
---

This is the first post!

Code works is highlighted by default.

```js
const StatelessComponent = (props) => {
return (
<div>
I'am a stateless component that accept children
{ props.children }
</div>
)
}
// ...
return (
<StatelessComponent>
Example of child
</StatelessComponent>
)
```
1 change: 1 addition & 0 deletions themes/phenomic-theme-base/src/AppContainer.js
@@ -1,6 +1,7 @@
import React, { PropTypes } from "react"

import "./index.global.css"
import "./highlight.global.css"

import Container from "./components/Container"
import DefaultHeadMeta from "./components/DefaultHeadMeta"
Expand Down
106 changes: 106 additions & 0 deletions themes/phenomic-theme-base/src/highlight.global.css
@@ -0,0 +1,106 @@
/**
* You can try all official Highlight.js theme here
*
* https://highlightjs.org/static/demo/
*
* More themes here
*
* https://github.com/isagalaev/highlight.js/tree/master/src/styles
*/

/*
Atom One Dark by Daniel Gamage
Original One Dark Syntax theme from https://github.com/atom/one-dark-syntax
base: #282c34
mono-1: #abb2bf
mono-2: #818896
mono-3: #5c6370
hue-1: #56b6c2
hue-2: #61aeee
hue-3: #c678dd
hue-4: #98c379
hue-5: #e06c75
hue-5-2: #be5046
hue-6: #d19a66
hue-6-2: #e6c07b
*/

.hljs {
display: block;
overflow-x: auto;
padding: 0.5em;
color: #abb2bf;
background: #282c34;
}

.hljs-comment,
.hljs-quote {
color: #5c6370;
font-style: italic;
}

.hljs-doctag,
.hljs-keyword,
.hljs-formula {
color: #c678dd;
}

.hljs-section,
.hljs-name,
.hljs-selector-tag,
.hljs-deletion,
.hljs-subst {
color: #e06c75;
}

.hljs-literal {
color: #56b6c2;
}

.hljs-string,
.hljs-regexp,
.hljs-addition,
.hljs-attribute,
.hljs-meta-string {
color: #98c379;
}

.hljs-built_in,
.hljs-class .hljs-title {
color: #e6c07b;
}

.hljs-attr,
.hljs-variable,
.hljs-template-variable,
.hljs-type,
.hljs-selector-class,
.hljs-selector-attr,
.hljs-selector-pseudo,
.hljs-number {
color: #d19a66;
}

.hljs-symbol,
.hljs-bullet,
.hljs-link,
.hljs-meta,
.hljs-selector-id,
.hljs-title {
color: #61aeee;
}

.hljs-emphasis {
font-style: italic;
}

.hljs-strong {
font-weight: bold;
}

.hljs-link {
text-decoration: underline;
}

0 comments on commit d6330fa

Please sign in to comment.