Skip to content

Commit

Permalink
#118 - set the possition of setting and github icon
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Giek committed Jan 15, 2025
1 parent 698cc0c commit a98b578
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 17 deletions.
8 changes: 2 additions & 6 deletions src/renderer/components/shared/settings/SettingsModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,14 @@ import { useVariableStore } from '@/state/variableStore';
import { Button } from '@/components/ui/button';
import * as React from 'react';

interface Props {
className: string;
}
export const SettingsModal = (props: Props) => {
const { className } = props;
export const SettingsModal = () => {
const { save, cancel, openModal } = useVariableStore.getState();
const isOpen = useVariableStore((state) => state.isOpen);
const allDoubleKeys = useVariableStore((state) => state.allDoubleKeys);

return (
<Dialog open={isOpen} onOpenChange={cancel}>
<DialogTrigger className={className} onClick={openModal}>
<DialogTrigger onClick={openModal}>
<FiSettings className="text-xl ml-2" />
</DialogTrigger>
<DialogContent style={{ minWidth: '100vh' }}>
Expand Down
19 changes: 8 additions & 11 deletions src/renderer/components/sidebar/FooterBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,14 @@ export function FooterBar() {
{/* Version text on the left */}
<span className="text-xs text-gray-500">{appVersion ?? null}</span>

{/* Icons on the right */}
{/* GitHub Icon */}
<a
className="flex items-center space-x-4"
href="https://github.com/EXXETA/trufos"
target="_blank"
rel="noopener noreferrer"
>
<GithubIcon /> {/* Adjust the size as needed */}
</a>
<SettingsModal className="flex items-center space-x-4" />
<div className="flex items-center gap-1">
{/* Icons on the right */}
{/* GitHub Icon */}
<a href="https://github.com/EXXETA/trufos" target="_blank" rel="noopener noreferrer">
<GithubIcon /> {/* Adjust the size as needed */}
</a>
<SettingsModal />
</div>
</div>
);
}

0 comments on commit a98b578

Please sign in to comment.