forked from facebook/react-native-website
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add additional languages and customize prism theme (#16)
* add additional languages for prism * set up custom theme for prism * customize according to solarized dark theme * add custom syntax highlighting from react-native * rename theme file, add Kotlin, fix one ObjC block Co-authored-by: Bartosz Kaszubowski <gosimek@gmail.com>
- Loading branch information
Showing
7 changed files
with
138 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,128 @@ | ||
var theme = { | ||
plain: { | ||
color: '#FFFFFF', | ||
background: '#282C34', | ||
}, | ||
styles: [ | ||
// other modifications | ||
{ | ||
types: ['property'], | ||
style: { | ||
color: '#2aa198', | ||
}, | ||
}, | ||
// solarized-dark theme | ||
{ | ||
types: ['attr-name', 'comment', 'prolog', 'doctype', 'cdata'], | ||
style: { | ||
color: '#93a1a1', | ||
}, | ||
}, | ||
|
||
{ | ||
types: ['punctuation'], | ||
style: { | ||
color: '#657b83' /* base00 */, | ||
}, | ||
}, | ||
{ | ||
types: ['namespace'], | ||
style: { | ||
opacity: 0.7, | ||
}, | ||
}, | ||
{ | ||
types: ['deleted'], | ||
style: { | ||
color: '#d33682' /* magenta */, | ||
}, | ||
}, | ||
{ | ||
types: ['selector', 'char', 'builtin', 'url', 'inserted'], | ||
style: { | ||
color: '#2aa198' /* cyan */, | ||
}, | ||
}, | ||
{ | ||
types: ['entity'], | ||
style: { | ||
color: '#2aa198' /* cyan */, | ||
}, | ||
}, | ||
{ | ||
types: ['atrule'], | ||
style: { | ||
color: '#859900' /* yellow */, | ||
}, | ||
}, | ||
{ | ||
types: ['important', 'variable'], | ||
style: { | ||
color: '#cb4b16' /* orange */, | ||
}, | ||
}, | ||
{ | ||
types: ['important', 'bold'], | ||
style: { | ||
fontWeight: 'bold', | ||
}, | ||
}, | ||
{ | ||
types: ['italic'], | ||
style: { | ||
fontStyle: 'italic', | ||
}, | ||
}, | ||
{ | ||
types: ['entity'], | ||
style: { | ||
cursor: 'help', | ||
}, | ||
}, | ||
// react-native theme | ||
{ | ||
types: ['attr-name', 'keyword'], | ||
style: { | ||
color: '#c5a5c5', | ||
}, | ||
}, | ||
{ | ||
types: ['string', 'regex', 'attr-value'], | ||
style: { | ||
color: '#8dc891', | ||
}, | ||
}, | ||
{ | ||
types: ['number', 'constant', 'symbol'], | ||
style: { | ||
color: '#5a9bcf', | ||
}, | ||
}, | ||
{ | ||
types: ['boolean'], | ||
style: { | ||
color: '#ff8b50', | ||
}, | ||
}, | ||
{ | ||
types: ['class-name'], | ||
style: { | ||
color: '#fac863', | ||
}, | ||
}, | ||
{ | ||
types: ['function'], | ||
style: { | ||
color: '#79b6f2', | ||
}, | ||
}, | ||
{ | ||
types: ['operator', 'tag'], | ||
style: { | ||
color: '#fc929e', | ||
}, | ||
}, | ||
], | ||
}; | ||
|
||
module.exports = theme; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters