i18n(hem+nav) + fix(samtycke-layout): hem-fliken, nav-titlar, samtyckesrad bryter inte
- profile.tsx: samtyckesraden fick flex:1 på texten så längre språk (t.ex. spanska) inte trycker på/av-knappen ur läge (låg till vänster förut) - home.tsx: Dina sparade recept, Skicka in eget recept, matlager-underrubrik, Allt/Öppna, platsnamn (Kyl/Frys/Skafferi...) -> t() (via typ, ej svenskt DB-namn) - _layout.tsx: nav-titlar (Bläddra recept, Sparade recept, Matlager, Streckkod, Byt ut) -> t() - 15 nya nycklar (home.*/nav.*) i alla 12 språk Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -127,28 +127,28 @@ export default function HomeScreen() {
|
||||
</Row>
|
||||
|
||||
<Card onPress={() => router.push("/saved-recipes")}>
|
||||
<Body>⭐ Dina sparade recept</Body>
|
||||
<Body>⭐ {t("home.savedRecipes")}</Body>
|
||||
</Card>
|
||||
|
||||
<Card onPress={() => router.push("/submit-recipe")}>
|
||||
<Body>✍️ Skicka in eget recept</Body>
|
||||
<Body>✍️ {t("home.submitRecipe")}</Body>
|
||||
</Card>
|
||||
|
||||
{/* Matlager – städat, öppnas per plats eller som helhet (spec §8). */}
|
||||
<Card>
|
||||
<Heading>🧺 {t("home.inventory")}</Heading>
|
||||
<Small>Allt du har hemma – öppna en plats eller sök i hela lagret.</Small>
|
||||
<Small>{t("home.inventorySubtitle")}</Small>
|
||||
<Row style={{ marginTop: spacing.xs }}>
|
||||
{locations.map((loc) => (
|
||||
<Button
|
||||
key={loc.type}
|
||||
label={loc.name}
|
||||
label={LOCATION_ORDER.includes(loc.type) ? t(`home.location.${loc.type}`) : loc.name}
|
||||
variant="ghost"
|
||||
onPress={() => router.push(`/kitchen?loc=${loc.type}`)}
|
||||
/>
|
||||
))}
|
||||
<Button
|
||||
label={locations.length ? "Allt" : "Öppna"}
|
||||
label={locations.length ? t("home.openAll") : t("home.open")}
|
||||
variant="primary"
|
||||
onPress={() => router.push("/kitchen")}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user