Skip to content

Commit 79ff4e7

Browse files
committed
Change button name
1 parent 0acf677 commit 79ff4e7

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

client/src/components/UploadRecipe.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ const UploadRecipe: React.FC = () => {
5050
{status === "idle" && (
5151
<form>
5252
<label className="flex flex-col items-center justify-center px-4 py-2 text-sm font-medium text-white bg-green-600 rounded-md cursor-pointer hover:bg-green-700 transition-colors">
53-
Upload Recipe PDF
53+
Upload Recipe Book
5454
<input type="file" accept=".pdf" hidden onChange={handleUpload} />
5555
</label>
5656
</form>

client/src/components/__tests__/UploadRecipe.test.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ describe("UploadRecipe Component", () => {
2323
it("renders upload button in idle state", () => {
2424
render(<UploadRecipe />);
2525

26-
expect(screen.getByText("Upload Recipe PDF")).toBeInTheDocument();
27-
expect(screen.getByLabelText("Upload Recipe PDF")).toBeInTheDocument();
26+
expect(screen.getByText("Upload Recipe Book")).toBeInTheDocument();
27+
expect(screen.getByLabelText("Upload Recipe Book")).toBeInTheDocument();
2828
});
2929

3030
it("shows uploading state when file is selected", async () => {
@@ -36,7 +36,7 @@ describe("UploadRecipe Component", () => {
3636
render(<UploadRecipe />);
3737

3838
const fileInput = screen.getByLabelText(
39-
"Upload Recipe PDF",
39+
"Upload Recipe Book",
4040
) as HTMLInputElement;
4141
const file = new File(["test content"], "recipe.pdf", {
4242
type: "application/pdf",
@@ -60,12 +60,12 @@ describe("UploadRecipe Component", () => {
6060
render(<UploadRecipe />);
6161

6262
const fileInput = screen.getByLabelText(
63-
"Upload Recipe PDF",
63+
"Upload Recipe Book",
6464
) as HTMLInputElement;
6565

6666
fireEvent.change(fileInput!, { target: { files: [] } });
6767

6868
expect(mockFetch).not.toHaveBeenCalled();
69-
expect(screen.getByText("Upload Recipe PDF")).toBeInTheDocument();
69+
expect(screen.getByText("Upload Recipe Book")).toBeInTheDocument();
7070
});
7171
});

0 commit comments

Comments
 (0)