Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commit abf2b80

Browse files
committed
UnverisalPanel colors in each theme
1 parent 5f481d3 commit abf2b80

File tree

10 files changed

+109
-49
lines changed

10 files changed

+109
-49
lines changed

containers/UniversePanel/index.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,6 @@ import {
3636

3737
const debug = makeDebugger('C:UniversePanel')
3838

39-
// R.isEmpty(repos.toJSON()) && !isSearching && !R.isEmpty(inputValue)
40-
41-
// const repoNotFound = R.and()
42-
4339
const SearchEditor = ({ value, searching }) => (
4440
<EditorBar>
4541
<AddOn>{searching ? <LoadingIcon /> : <SearchIcon />}</AddOn>
@@ -79,7 +75,6 @@ class UniversePanelContainer extends React.Component {
7975
<SearchEditor value={inputValue} searching={searching} />
8076

8177
{logic.repoNotFound(store) && <AlertBar>Repo not found</AlertBar>}
82-
8378
<Wraper>
8479
{reposData.map(repo => (
8580
<InfoBar key={repo.id}>

containers/UniversePanel/styles/index.js

Lines changed: 16 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@ const rotate360 = keyframes`
1616
`
1717

1818
export const SearchIcon = styled(searchIcon)`
19-
fill: #014354;
19+
fill: ${props => props.theme.u_panel.search_icon};
2020
width: 30px;
2121
height: 30px;
2222
margin-top: 20px;
2323
`
2424

2525
export const LoadingIcon = styled(loadingIcon)`
26-
fill: #014354;
26+
fill: ${props => props.theme.u_panel.search_icon};
2727
width: 30px;
2828
height: 30px;
2929
margin-top: 20px;
@@ -32,7 +32,6 @@ export const LoadingIcon = styled(loadingIcon)`
3232

3333
export const AddOn = styled.div`
3434
margin-left: 15px;
35-
color: white;
3635
width: 25px;
3736
`
3837

@@ -53,14 +52,14 @@ export const Wraper = styled.div`
5352
overflow: scroll;
5453
`
5554

55+
// #001b21;
5656
export const BaseBar = styled.div`
57-
border: 1px solid white;
5857
box-shadow: 0 12px 48px 0 rgba(0, 0, 0, 0.4);
59-
border: 1px solid #014354;
58+
border: 1px solid ${props => props.theme.u_panel.border};
6059
width: 50vw;
6160
max-width: 600px;
6261
height: 70px;
63-
background: #001b21;
62+
background: ${props => props.theme.u_panel.bar_bg};
6463
color: white;
6564
display: flex;
6665
flex-direction: row;
@@ -86,15 +85,15 @@ export const InfoBar = styled(BaseBar)`
8685
min-height: 100px;
8786
`
8887
export const InputBar = styled.input`
89-
caret-color: #365760; /*cursor color*/
88+
caret-color: ${props => props.theme.u_panel.search_input};
9089
flex-grow: 1;
9190
font-family: '.SFNSText-Light', 'SF UI Text', 'Helvetica Neue', 'Arial',
9291
'Lucida Grande', 'Segoe UI', Noto Sans, sans-serif;
9392
height: 100%;
9493
width: auto;
9594
outline: none;
9695
font-weight: 200;
97-
color: #365760;
96+
color: ${props => props.theme.u_panel.search_input};
9897
font-size: 24px;
9998
line-height: 70px;
10099
max-height: none;
@@ -119,9 +118,14 @@ export const ContentWraper = styled.div`
119118
text-align: left;
120119
flex-grow: 1;
121120
`
122-
export const Title = styled.div`color: white;`
121+
export const Title = styled.div`
122+
display: block;
123+
> a {
124+
color: ${props => props.theme.u_panel.link};
125+
}
126+
`
123127
export const Desc = styled.div`
124-
color: #4c7c8a;
128+
color: ${props => props.theme.u_panel.text};
125129
text-overflow: ellipsis;
126130
width: 400px;
127131
white-space: nowrap;
@@ -135,19 +139,12 @@ export const SubInfoWraper = styled.div`
135139
`
136140

137141
export const RepoLang = styled.div`
138-
color: #4c7c8a;
142+
color: ${props => props.theme.u_panel.text};
139143
font-style: italic;
140144
`
141145

142146
export const RepoStar = styled.div`
143-
color: #4c7c8a;
147+
color: ${props => props.theme.u_panel.text};
144148
font-style: italic;
145149
margin-right: 10px;
146150
`
147-
148-
/*
149-
text-overflow: ellipsis;
150-
width: 400px;
151-
white-space: nowrap;
152-
overflow: hidden;
153-
*/

utils/themes/Brown.js

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,16 @@
22
* a theme inspired by stackedit: https://stackedit.io/editor
33
*/
44

5-
import { darken } from 'polished'
5+
import { lighten, darken } from 'polished'
66

7-
const fronColor = '#787561'
7+
const fontColor = '#787561'
88
const sidebarBg = '#272422'
9+
const mainBg = '#7DC0C5'
910

1011
const Slack = {
11-
font: fronColor,
12+
font: fontColor,
1213
link: '#D57041',
13-
main: '#7DC0C5',
14+
main: mainBg,
1415
body_bg: '#322D28',
1516
selection_bg: '#463f37', // not working
1617
sidebar: {
@@ -19,6 +20,14 @@ const Slack = {
1920
menu_link: '#B1A89D',
2021
border_color: darken(0.1, sidebarBg),
2122
},
23+
u_panel: {
24+
link: lighten(0.2, fontColor),
25+
search_input: lighten(0.1, fontColor),
26+
search_icon: lighten(0.1, fontColor),
27+
bar_bg: darken(0.03, sidebarBg),
28+
border: lighten(0.08, sidebarBg),
29+
text: darken(0.1, fontColor),
30+
},
2231
}
2332

2433
export default Slack

utils/themes/Cyan.js

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,31 @@
22
* a theme inspired by rethinkdb: https://rethinkdb.com/
33
*/
44

5-
const fronColor = '#69a7ad'
5+
import { lighten, darken } from 'polished'
6+
7+
const fontColor = '#69a7ad'
8+
const mainBg = '#E4EEED'
69

710
const Cyan = {
8-
font: fronColor,
11+
font: fontColor,
912
link: 'orange',
1013
main: '#7DC0C5',
11-
body_bg: '#E4EEED',
14+
body_bg: mainBg,
1215
selection_bg: 'tomato',
1316
sidebar: {
1417
bg: '#1C4752',
15-
pin_active: fronColor,
18+
pin_active: fontColor,
1619
menu_link: '#D9E6E5',
1720
border_color: '#14363E',
1821
},
22+
u_panel: {
23+
link: lighten(0.3, fontColor),
24+
search_input: lighten(0.3, fontColor),
25+
search_icon: lighten(0.3, fontColor),
26+
bar_bg: darken(0.03, fontColor),
27+
border: darken(0.05, fontColor),
28+
text: lighten(0.2, fontColor),
29+
},
1930
}
2031

2132
export default Cyan

utils/themes/CyanGreen.js

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,30 @@
44

55
import { darken } from 'polished'
66

7-
const fronColor = '#FBF9FC'
7+
const fontColor = '#dcd9cf'
88
const sidebarBg = '#53B5B0'
9+
const mainBg = '#60848B'
910

1011
const CyanGreen = {
11-
font: fronColor,
12+
font: fontColor,
1213
link: '#99CFAF',
1314
main: '#7DC0C5',
14-
body_bg: '#60848B',
15+
body_bg: mainBg,
1516
selection_bg: '#FDDBA8',
1617
sidebar: {
1718
bg: sidebarBg,
1819
pin_active: '#B1EFBD',
1920
menu_link: '#CAE5E5',
2021
border_color: darken(0.1, sidebarBg),
2122
},
23+
u_panel: {
24+
link: darken(0.25, sidebarBg),
25+
search_input: darken(0.2, sidebarBg),
26+
search_icon: darken(0.2, sidebarBg),
27+
bar_bg: darken(0.01, sidebarBg),
28+
border: darken(0.1, sidebarBg),
29+
text: darken(0.15, sidebarBg),
30+
},
2231
}
2332

2433
export default CyanGreen

utils/themes/Muzli.js

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,31 @@
11
/*
22
* a theme inspired by Muzli && unbuntu
33
*/
4+
import { lighten, darken } from 'polished'
5+
6+
const fontColor = '#BDBDBF'
7+
const mainBg = '#222029'
48

59
const Muzli = {
6-
font: '#BDBDBF',
10+
font: fontColor,
711
link: '#B762B7',
812
main: '#B0AEB3',
9-
body_bg: '#222029',
13+
body_bg: mainBg,
1014
selection_bg: 'tomato',
1115
sidebar: {
1216
bg: '#222029',
1317
pin_active: 'tomato',
1418
menu_link: 'lightgrey',
1519
border_color: '#100F13',
1620
},
21+
u_panel: {
22+
link: lighten(0.25, mainBg),
23+
search_input: lighten(0.1, mainBg),
24+
search_icon: lighten(0.1, mainBg),
25+
bar_bg: darken(0.03, mainBg),
26+
border: lighten(0.05, mainBg),
27+
text: lighten(0.1, mainBg),
28+
},
1729
}
1830

1931
export default Muzli

utils/themes/Slack.js

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,32 @@
22
* a theme inspired by stackedit: https://stackedit.io/editor
33
*/
44

5-
import { darken } from 'polished'
5+
import { lighten, darken } from 'polished'
66

7-
const fronColor = '#657b83'
7+
const fontColor = '#657b83'
88
const sidebarBg = '#4B3A4C'
9+
const mainBg = '#F9F9F9'
910

1011
const Slack = {
11-
font: fronColor,
12+
font: fontColor,
1213
link: '#36AEE5',
1314
main: '#7DC0C5',
14-
body_bg: '#F9F9F9',
15+
body_bg: mainBg,
1516
selection_bg: '#FDDBA8',
1617
sidebar: {
1718
bg: sidebarBg,
1819
pin_active: '#4B968C',
1920
menu_link: '#A99BA9',
2021
border_color: darken(0.1, sidebarBg),
2122
},
23+
u_panel: {
24+
link: lighten(0.3, sidebarBg),
25+
search_input: lighten(0.3, fontColor),
26+
search_icon: lighten(0.3, fontColor),
27+
bar_bg: lighten(0.03, sidebarBg),
28+
border: darken(0.05, fontColor),
29+
text: lighten(0.15, sidebarBg),
30+
},
2231
}
2332

2433
export default Slack

utils/themes/SolarizedDark.js

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,31 @@
33
*/
44

55
// some selection color not supported
6+
import { lighten, darken } from 'polished'
7+
8+
const fontColor = '#839491'
9+
const mainBg = '#002A35'
610

711
const SolarizedDark = {
8-
font: '#839491',
12+
font: fontColor,
913
link: '#269A95',
1014
main: '#7DC0C5',
11-
body_bg: '#002A35',
15+
body_bg: mainBg,
1216
selection_bg: '#839496', // '#657b83',
1317
sidebar: {
1418
bg: '#053542',
1519
pin_active: '#849804',
1620
menu_link: '#93A1A1',
1721
border_color: '#14363E',
1822
},
23+
u_panel: {
24+
link: lighten(0.2, mainBg),
25+
search_input: lighten(0.1, mainBg),
26+
search_icon: lighten(0.1, mainBg),
27+
bar_bg: darken(0.03, mainBg),
28+
border: lighten(0.05, mainBg),
29+
text: lighten(0.1, mainBg),
30+
},
1931
}
2032

2133
export default SolarizedDark

utils/themes/Yellow.js

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,30 @@
44

55
import { darken } from 'polished'
66

7-
const fronColor = '#657b83'
7+
const fontColor = '#657b83'
88
const sidebarBg = '#EEE8D5'
9+
const mainBg = '#FDF6E3'
910

1011
const Yellow = {
11-
font: fronColor,
12+
font: fontColor,
1213
link: '#4E9ED3',
1314
main: '#7DC0C5',
14-
body_bg: '#FDF6E3',
15+
body_bg: mainBg,
1516
selection_bg: '#FDDBA8',
1617
sidebar: {
1718
bg: sidebarBg,
1819
pin_active: '#2AA198',
1920
menu_link: '#000',
2021
border_color: darken(0.1, sidebarBg),
2122
},
23+
u_panel: {
24+
link: darken(0.45, sidebarBg),
25+
search_input: darken(0.5, sidebarBg),
26+
search_icon: darken(0.4, sidebarBg),
27+
bar_bg: darken(0.15, sidebarBg),
28+
border: darken(0.3, sidebarBg),
29+
text: darken(0.35, sidebarBg),
30+
},
2231
}
2332

2433
export default Yellow

utils/themes/index.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,6 @@ export const globalThemes = {
2828
// solarizedDark: { ...SolarizedDark },
2929
muzli: { ...Muzli },
3030
yellow: { ...Yellow },
31-
// purpleDark: {...PurpleDark},
32-
// solarizedDark: {...SolarizedDark},
33-
// solarizedLight: {...SolarizedLight},
3431
slack: { ...Slack },
3532
brown: { ...Brown },
3633
cyanGreen: { ...CyanGreen },

0 commit comments

Comments
 (0)