feat(fs.dev): moved theme picker to header
This commit is contained in:
parent
bb901c4d8a
commit
43a89a85ad
1 changed files with 4 additions and 3 deletions
|
@ -4,16 +4,17 @@ import ThemeIcon from 'shared/components/icons/theme.js'
|
|||
const ThemePicker = ({ app, className='' }) => {
|
||||
return (
|
||||
<div className="dropdown">
|
||||
<div tabIndex="0" className="m-0 btn flex flex-row gap-2">
|
||||
<div tabIndex="0" className="m-0 btn flex flex-row gap-2 hover:bg-neutral hover:border-neutral-content">
|
||||
<ThemeIcon />
|
||||
<span>Theme:</span>
|
||||
<span>{app.theme}</span>
|
||||
<span>Theme</span>
|
||||
</div>
|
||||
<ul tabIndex="0" className="p-2 shadow menu dropdown-content bg-base-100 rounded-box w-52">
|
||||
{Object.keys(themes).map(theme => (
|
||||
<li key={theme}>
|
||||
<button onClick={() => app.setTheme(theme)} className="btn btn-link">
|
||||
<button onClick={() => app.setTheme(theme)} className="btn btn-ghost text-base-content hover:bg-base-200">
|
||||
{theme}
|
||||
<span> Theme</span>
|
||||
</button>
|
||||
</li>
|
||||
))}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue