feat(recipes): image upload, fix save 500, HelloFresh seed data #53
@@ -20,7 +20,7 @@
|
||||
<div class="rounded-[var(--radius-lg)] border border-[var(--yellow-light)] bg-[var(--yellow-tint)] p-4">
|
||||
<div class="flex items-baseline gap-1">
|
||||
<span class="font-[var(--font-display)] text-[28px] font-[300] text-[var(--color-text)] md:text-[40px]">
|
||||
{score}
|
||||
{score.toFixed(1)}
|
||||
</span>
|
||||
<span class="font-[var(--font-sans)] text-[13px] text-[var(--color-text-muted)]">/10</span>
|
||||
<span class="ml-1 font-[var(--font-sans)] text-[12px] text-[var(--color-text-muted)]">Abwechslungs-Score</span>
|
||||
|
||||
@@ -51,7 +51,13 @@ describe('VarietyScoreCard', () => {
|
||||
|
||||
it('renders with score 0', () => {
|
||||
render(VarietyScoreCard, { props: { ...baseProps, score: 0 } });
|
||||
expect(screen.getByText('0')).toBeTruthy();
|
||||
expect(screen.getByText('0.0')).toBeTruthy();
|
||||
});
|
||||
|
||||
it('rounds floating-point scores to one decimal place', () => {
|
||||
render(VarietyScoreCard, { props: { ...baseProps, score: 6.199999999999999 } });
|
||||
expect(screen.getByText('6.2')).toBeTruthy();
|
||||
expect(screen.queryByText('6.199999999999999')).toBeNull();
|
||||
});
|
||||
|
||||
it('renders multiple ingredient overlap warnings', () => {
|
||||
|
||||
Reference in New Issue
Block a user