Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: git commit push feature from workbench #818

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/commit.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{ "commit": "282beb96e2ee92ba8b1174aaaf9f270e03a288e8", "version": "0.0.2" }
{ "commit": "a2330084eb9c960dff0a58b7e45f501266fc12a1" }
40 changes: 25 additions & 15 deletions app/components/workbench/EditorPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import { FileBreadcrumb } from './FileBreadcrumb';
import { FileTree } from './FileTree';
import { DEFAULT_TERMINAL_SIZE, TerminalTabs } from './terminal/TerminalTabs';
import { workbenchStore } from '~/lib/stores/workbench';
import WithTooltip from '~/components/ui/Tooltip';

interface EditorPanelProps {
files?: FileMap;
Expand Down Expand Up @@ -53,6 +54,8 @@ export const EditorPanel = memo(
}: EditorPanelProps) => {
renderLogger.trace('EditorPanel');

// const activeTab = useState<'files' | 'git'>('files');

const theme = useStore(themeStore);
const showTerminal = useStore(workbenchStore.showTerminal);

Expand All @@ -72,21 +75,28 @@ export const EditorPanel = memo(
<PanelGroup direction="vertical">
<Panel defaultSize={showTerminal ? DEFAULT_EDITOR_SIZE : 100} minSize={20}>
<PanelGroup direction="horizontal">
<Panel defaultSize={20} minSize={10} collapsible>
<div className="flex flex-col border-r border-bolt-elements-borderColor h-full">
<PanelHeader>
<div className="i-ph:tree-structure-duotone shrink-0" />
Files
</PanelHeader>
<FileTree
className="h-full"
files={files}
hideRoot
unsavedFiles={unsavedFiles}
rootFolder={WORK_DIR}
selectedFile={selectedFile}
onFileSelect={onFileSelect}
/>
<Panel defaultSize={25} minSize={15} collapsible>
<div className="flex h-full">
<div className="flex flex-col w-8 min-w-8 border-r border-bolt-elements-borderColor h-full">
<WithTooltip tooltip="Files">
<div className="i-ph:files-fill mx-auto m-4 text-lg text-bolt-elements-textSecondary hover:text-bolt-elements-item-contentAccent" />
</WithTooltip>
</div>
<div className="flex flex-col flex-1 border-r border-bolt-elements-borderColor h-full">
<PanelHeader>
<div className="i-ph:tree-structure-duotone shrink-0" />
Files
</PanelHeader>
<FileTree
className="h-full"
files={files}
hideRoot
unsavedFiles={unsavedFiles}
rootFolder={WORK_DIR}
selectedFile={selectedFile}
onFileSelect={onFileSelect}
/>
</div>
</div>
</Panel>
<PanelResizeHandle />
Expand Down
Loading