Skip to content

Commit cc0c187

Browse files
committed
Add a default theme
1 parent a5c3039 commit cc0c187

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed

Diff for: src/index.js

+5
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import React from 'react';
77
import objectType from './obj-type';
88
import JSONObjectNode from './JSONObjectNode';
99
import JSONArrayNode from './JSONArrayNode';
10+
import solarized from './themes/solarized';
1011

1112
const styles = {
1213
tree: {
@@ -31,6 +32,10 @@ export default class JSONTree extends React.Component {
3132
]).isRequired
3233
};
3334

35+
static defaultProps = {
36+
theme: solarized
37+
};
38+
3439
constructor(props) {
3540
super(props);
3641
}

Diff for: src/themes/solarized.js

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
export default {
2+
scheme: 'solarized',
3+
author: 'ethan schoonover (http://ethanschoonover.com/solarized)',
4+
base00: '#002b36',
5+
base01: '#073642',
6+
base02: '#586e75',
7+
base03: '#657b83',
8+
base04: '#839496',
9+
base05: '#93a1a1',
10+
base06: '#eee8d5',
11+
base07: '#fdf6e3',
12+
base08: '#dc322f',
13+
base09: '#cb4b16',
14+
base0A: '#b58900',
15+
base0B: '#859900',
16+
base0C: '#2aa198',
17+
base0D: '#268bd2',
18+
base0E: '#6c71c4',
19+
base0F: '#d33682'
20+
};

0 commit comments

Comments
 (0)