refactor: moved "Add track" button from bottom TrackControl to top-left-spacer for better discoverability
This commit is contained in:
@@ -242,7 +242,7 @@ Feature priorities might change.
|
|||||||
- [ ] Support WAV audio tracks
|
- [ ] Support WAV audio tracks
|
||||||
- [ ] Filters and effects
|
- [ ] Filters and effects
|
||||||
- [ ] MCP Support
|
- [ ] MCP Support
|
||||||
- [ ] Add support for OpenAI's open source models (`gpt-oss-20b` and `gpt-oss-120b`)
|
- [X] Add support for OpenAI's open source models (`gpt-oss-20b` and `gpt-oss-120b`)
|
||||||
- [ ] Automatically compact conversations when the context window runs low on space
|
- [ ] Automatically compact conversations when the context window runs low on space
|
||||||
|
|
||||||
## Help Needed
|
## Help Needed
|
||||||
|
|||||||
+14
-11
@@ -325,24 +325,27 @@ body {
|
|||||||
cursor: crosshair;
|
cursor: crosshair;
|
||||||
}
|
}
|
||||||
|
|
||||||
.track-control {
|
.add-track-btn {
|
||||||
padding: 5px;
|
|
||||||
background-color: #2d2d2d;
|
|
||||||
border-top: 1px solid #3a3a3a;
|
|
||||||
}
|
|
||||||
|
|
||||||
.track-control button {
|
|
||||||
background: transparent;
|
background: transparent;
|
||||||
border: none;
|
border: none;
|
||||||
|
outline: none;
|
||||||
color: #999;
|
color: #999;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
padding: 5px;
|
|
||||||
width: 100%;
|
|
||||||
text-align: left;
|
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
|
padding: 0;
|
||||||
|
height: 100%;
|
||||||
|
width: 100%;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.track-control button:hover {
|
.add-track-btn:focus,
|
||||||
|
.add-track-btn:focus-visible {
|
||||||
|
outline: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.add-track-btn:hover {
|
||||||
color: #e0e0e0;
|
color: #e0e0e0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,6 @@ import { useProjectStore } from './stores/projectStore';
|
|||||||
import { useGlobalKeyboardHandler } from './hooks/useGlobalKeyboardHandler';
|
import { useGlobalKeyboardHandler } from './hooks/useGlobalKeyboardHandler';
|
||||||
import Toolbar from './components/Toolbar';
|
import Toolbar from './components/Toolbar';
|
||||||
import StatusBar from './components/StatusBar';
|
import StatusBar from './components/StatusBar';
|
||||||
import TrackControl from './components/TrackControl';
|
|
||||||
import MainContent from './components/MainContent';
|
import MainContent from './components/MainContent';
|
||||||
import InstrumentSelection from './components/InstrumentSelection';
|
import InstrumentSelection from './components/InstrumentSelection';
|
||||||
import ChatBox from './components/ChatBox';
|
import ChatBox from './components/ChatBox';
|
||||||
@@ -135,8 +134,6 @@ function App() {
|
|||||||
<ChatBox isVisible={showChatBox && !showSettings} />
|
<ChatBox isVisible={showChatBox && !showSettings} />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Track Control */}
|
|
||||||
<TrackControl />
|
|
||||||
|
|
||||||
{/* Status Bar */}
|
{/* Status Bar */}
|
||||||
<StatusBar />
|
<StatusBar />
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ interface MainContentProps {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const MainContent: React.FC<MainContentProps> = ({
|
const MainContent: React.FC<MainContentProps> = ({
|
||||||
onTrackClick = () => {} // Default to empty function if not provided
|
onTrackClick = () => { } // Default to empty function if not provided
|
||||||
}) => {
|
}) => {
|
||||||
const {
|
const {
|
||||||
tracks,
|
tracks,
|
||||||
@@ -33,7 +33,8 @@ const MainContent: React.FC<MainContentProps> = ({
|
|||||||
showPianoRoll,
|
showPianoRoll,
|
||||||
activeRegionId,
|
activeRegionId,
|
||||||
setShowPianoRoll,
|
setShowPianoRoll,
|
||||||
setActiveRegionId
|
setActiveRegionId,
|
||||||
|
addTrack
|
||||||
} = useProjectStore();
|
} = useProjectStore();
|
||||||
|
|
||||||
// State to store regions
|
// State to store regions
|
||||||
@@ -688,7 +689,9 @@ const MainContent: React.FC<MainContentProps> = ({
|
|||||||
<div className={`main-content${showInstrumentSelection ? ' has-left-instrument' : ''}`}>
|
<div className={`main-content${showInstrumentSelection ? ' has-left-instrument' : ''}`}>
|
||||||
<div className="main-content-wrapper">
|
<div className="main-content-wrapper">
|
||||||
{/* Top-left spacer */}
|
{/* Top-left spacer */}
|
||||||
<div className="top-left-spacer"></div>
|
<div className="top-left-spacer">
|
||||||
|
<button className="add-track-btn" onClick={() => addTrack()}>+ Add track</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
{/* Bar numbers at the top */}
|
{/* Bar numbers at the top */}
|
||||||
<div
|
<div
|
||||||
|
|||||||
@@ -1,18 +0,0 @@
|
|||||||
import React from 'react';
|
|
||||||
import { useProjectStore } from '../stores/projectStore';
|
|
||||||
|
|
||||||
const TrackControl: React.FC = () => {
|
|
||||||
const { addTrack } = useProjectStore();
|
|
||||||
|
|
||||||
const handleAddTrack = () => {
|
|
||||||
addTrack();
|
|
||||||
};
|
|
||||||
|
|
||||||
return (
|
|
||||||
<div className="track-control">
|
|
||||||
<button onClick={handleAddTrack}>+ Add track</button>
|
|
||||||
</div>
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
export default TrackControl;
|
|
||||||
Reference in New Issue
Block a user