Skip to content

Commit

Permalink
improve button styles
Browse files Browse the repository at this point in the history
  • Loading branch information
samlhuillier committed Nov 29, 2023
1 parent ff4de30 commit 970d696
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
},
"dependencies": {
"@huggingface/hub": "^0.12.0",
"@material-tailwind/react": "^2.1.5",
"@mdxeditor/editor": "1.11.4",
"@tailwindcss/typography": "^0.5.10",
"@xenova/transformers": "^2.8.0",
Expand Down
1 change: 0 additions & 1 deletion src/components/File/FileEditor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ export const FileEditor: React.FC<FileEditorProps> = ({
}, [content]); // Dependency on content ensures saveFile has the latest content

useEffect(() => {
console.log("setting content in child: ", content);
setContentInParent(content);
}, [content]);

Expand Down
8 changes: 5 additions & 3 deletions src/components/File/NewNote.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React, { useState } from "react";
import Modal from "../Generic/Modal";
// import Modal from './Modal'; // Adjust the import path as necessary
import { Button } from "@material-tailwind/react";

interface NewNoteComponentProps {
isOpen: boolean;
Expand Down Expand Up @@ -45,12 +46,13 @@ const NewNoteComponent: React.FC<NewNoteComponentProps> = ({
onKeyDown={handleKeyPress}
placeholder="Note Name"
/>
<button
<Button
className="mt-2 border-none h-10 hover:bg-slate-800 cursor-pointer"
onClick={sendNewNoteMsg}
className="mt-4 bg-blue-500 hover:bg-blue-600 text-white font-bold py-2 px-4 rounded"
>
Create
</button>
</Button>
{/* </button> */}
</div>
</Modal>
);
Expand Down
9 changes: 5 additions & 4 deletions src/components/Settings/SettingsModal.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useEffect, useState } from "react";
import Modal from "../Generic/Modal";

import { Button } from "@material-tailwind/react";
interface ModalProps {
isOpen: boolean;
onClose: () => void;
Expand Down Expand Up @@ -32,12 +32,13 @@ const SettingsModal: React.FC<ModalProps> = ({ isOpen, onClose }) => {
value={openAIKey}
onChange={(e) => setOpenAIKey(e.target.value)}
/>
<button
className="mt-4 bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded"

<Button
className="mt-2 border-none h-10 hover:bg-slate-800 cursor-pointer"
onClick={handleSave}
>
Save Key
</button>
</Button>
</div>
</Modal>
);
Expand Down

0 comments on commit 970d696

Please sign in to comment.