replace all html buttons with button component

This commit is contained in:
Anika Raemer 2025-09-21 10:45:24 +02:00
parent f1f6f5f438
commit 9cb5b52ac9
7 changed files with 58 additions and 54 deletions

View file

@ -2,6 +2,7 @@ import { useState } from "react"
import type { Recipe } from "../../types/recipe"
import type { IngredientGroup } from "../../types/ingredientGroup"
import { IngredientGroupListEditor } from "./IngredientGroupListEditor"
import Button, { ButtonType } from "../basics/Button"
type RecipeEditorProps = {
recipe: Recipe
@ -129,18 +130,15 @@ export default function RecipeEditor({ recipe, onSave, onCancel }: RecipeEditorP
<div className="button-group">
{/* Save Button */}
<button
className="primary-button"
<Button
onClick={() => handleSave(draft)}
>
Save
</button>
<button
className="default-button"
text={"Save"}
buttonType={ButtonType.PrimaryButton}
/>
<Button
onClick={() => onCancel()}
>
Cancel
</button>
text={"Cancel"}
/>
</div>
</div>
)