0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-27 02:52:43 +00:00

improve simple styling on theme selector. nest inside toggle.

This commit is contained in:
Gazook89
2023-12-22 22:58:13 -06:00
parent 985a9843f2
commit 7b8e398891
2 changed files with 18 additions and 13 deletions

View File

@@ -176,8 +176,9 @@ const Snippetbar = createClass({
<div className={`editorTool editorTheme ${this.state.themeSelector ? 'active' : ''}`}
onClick={this.toggleThemeSelector} >
<i className='fas fa-palette' />
{this.state.themeSelector && this.renderThemeSelector()}
</div>
{this.state.themeSelector && this.renderThemeSelector()}
<div className='divider'></div>
<div className={cx('text', { selected: this.props.view === 'text' })}
onClick={()=>this.props.onViewChange('text')}>

View File

@@ -61,13 +61,14 @@
color : black;
}
}
&.editorTheme{
&.editorTheme {
.tooltipLeft('Editor Themes');
font-size : 0.75em;
color : black;
&.active{
color : white;
background-color: black;
&.active {
position : relative;
color : white;
background-color : black;
}
}
&.divider {
@@ -78,14 +79,17 @@
}
}
}
.themeSelector{
position: absolute;
left: -65px;
top: 30px;
z-index: 999;
width: 170px;
background-color: black;
border-radius: 5px;
.themeSelector {
position : absolute;
top : 25px;
right : 0;
z-index : 1;
display : flex;
align-items : center;
justify-content : center;
width : 170px;
height : inherit;
background-color : inherit;
}
}
.snippetBarButton{