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

Commit

Permalink
Fixed some settings colors
Browse files Browse the repository at this point in the history
  • Loading branch information
tahnik committed Jan 3, 2018
1 parent d0fcd96 commit 7d29761
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 14 deletions.
5 changes: 5 additions & 0 deletions app/src/js/components/settings/button.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ const Button = props => (
<button
onClick={() => props.handleChange()}
disabled={!props.setting.value}
style={{
backgroundColor: props.theme.backgroundColor,
color: props.theme.item_card.color,
}}
>{props.setting.buttonText}
</button>
</div>
Expand All @@ -16,6 +20,7 @@ const Button = props => (

Button.propTypes = {
setting: PropTypes.object.isRequired,
theme: PropTypes.object.isRequired,
handleChange: PropTypes.func.isRequired,
};

Expand Down
3 changes: 3 additions & 0 deletions app/src/js/components/settings/general.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class General extends Component {
handleChange={(value) => {
this.handleChange(primaryKey, secondaryKey, value);
}}
theme={this.props.theme}
/>
);
}
Expand All @@ -33,6 +34,7 @@ class General extends Component {
handleChange={() => {
this.handleChange(primaryKey, secondaryKey, !setting.value);
}}
theme={this.props.theme}
/>
);
}
Expand All @@ -56,6 +58,7 @@ class General extends Component {
handleChange={() => {
this.handleChange(primaryKey, secondaryKey);
}}
theme={this.props.theme}
/>
);
}
Expand Down
2 changes: 2 additions & 0 deletions app/src/js/components/settings/slider.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class Slider extends Component {
value={this.state.value}
onChange={(e) => { this.setState({ value: e.target.value }); }}
onMouseUp={() => this.props.handleChange(this.state.value)}
style={{ backgroundColor: this.props.theme.backgroundColor }}
/>
</div>
</div>
Expand All @@ -31,6 +32,7 @@ class Slider extends Component {

Slider.propTypes = {
setting: PropTypes.object.isRequired,
theme: PropTypes.object.isRequired,
handleChange: PropTypes.func.isRequired,
};

Expand Down
2 changes: 2 additions & 0 deletions app/src/js/components/settings/toggle.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ const Toggle = props => (
/>
<span
className="slider"
style={{ backgroundColor: props.theme.backgroundColor }}
/>
</label>
</div>
Expand All @@ -22,6 +23,7 @@ const Toggle = props => (

Toggle.propTypes = {
setting: PropTypes.object.isRequired,
theme: PropTypes.object.isRequired,
handleChange: PropTypes.func.isRequired,
};

Expand Down
29 changes: 15 additions & 14 deletions app/src/res/sass/modules/common.sass
Original file line number Diff line number Diff line change
Expand Up @@ -132,36 +132,37 @@ $post_comment_height: 13rem
.range_input
-webkit-appearance: none
width: 100%
height: 21px
margin: 7px 0
border: none
position: relative
border-radius: 12px
&:focus
outline: none
&::-webkit-slider-runnable-track
width: 100%
padding: 0px 5px
height: 24px
cursor: pointer
box-shadow: 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px rgba(13, 13, 13, 0)
background: #c14857
border-radius: 12px
border: 0px solid rgba(0, 0, 0, 0)
// &::-webkit-slider-runnable-track
// width: 100%
// padding: 0px 5px
// height: 24px
// cursor: pointer
// box-shadow: 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px rgba(13, 13, 13, 0)
// background: #c14857
// border-radius: 12px
// border: 0px solid rgba(0, 0, 0, 0)
&::-webkit-slider-thumb
position: relative
top: 10px
top: 1px
box-shadow: 0px 0px 0px rgba(0, 0, 0, 0), 0px 0px 0px rgba(13, 13, 13, 0)
border: 0px solid rgba(0, 0, 0, 0)
height: 18.2px
width: 18.2px
border-radius: 18px
border-radius: 18.2px
background: #ffffff
cursor: pointer
-webkit-appearance: none
margin-top: -7px

&:focus::-webkit-slider-runnable-track
background: #c14857
// &:focus::-webkit-slider-runnable-track
// background: #c14857
body
padding: 0
Expand Down

0 comments on commit 7d29761

Please sign in to comment.