Skip to content

Commit

Permalink
Button highlighting
Browse files Browse the repository at this point in the history
  • Loading branch information
gsagag committed Aug 1, 2024
1 parent a890c3a commit 4479add
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions oeds_explorer/src/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ function Header({ activeTab, setActiveTab, showPopup, setShowPopup }) {
}

const getButtonStyle = (tab) => {
return tab === activeTab ? { backgroundColor: '#f0f0f0' } : {};
return tab === activeTab ? { backgroundColor: '#AED0FF' } : {};
}
const getPopupButtonStyle = () => {
return showPopup ? { backgroundColor: '#AED0FF', marginLeft: '5px' } : { marginLeft: '5px'};
}

const togglePopup = () => setShowPopup(!showPopup);
Expand All @@ -30,7 +33,7 @@ function Header({ activeTab, setActiveTab, showPopup, setShowPopup }) {
{activeTab === 'rest' &&

<div className="select-container" style={{ display: 'flex', alignItems: 'center' }}>
<button className="popup-button" onClick={togglePopup} style={{ marginLeft: '10px' }}></button>
<button className="popup-button" onClick={togglePopup} style={getPopupButtonStyle()}></button>
<select
value={selectedProfile}
onChange={e => setSelectedProfile(e.target.value)}
Expand Down

0 comments on commit 4479add

Please sign in to comment.