Use tRPC and react-hook-form

This commit is contained in:
Timothy Armes
2023-09-11 10:28:02 +02:00
parent 7111f000e5
commit ac633670ab
42 changed files with 5490 additions and 587 deletions
+3 -3
View File
@@ -10,7 +10,7 @@ import { TimeControlColours } from "@/app/constants";
import { TimeControl } from "@/types";
const Legend = () => {
const t = useTranslations("Tournaments");
const at = useTranslations("App");
const map = useMap();
const tournaments = useAtomValue(filteredTournamentsByTimeControlAtom);
@@ -45,7 +45,7 @@ const Legend = () => {
<li>
<span class="block h-4 w-7 border border-[#999] float-left mr-1" style="background: ${
TimeControlColours[tc]
}"></span>${t("timeControlEnum", { tc })}
}"></span>${at("timeControlEnum", { tc })}
</li>
`,
)
@@ -56,7 +56,7 @@ const Legend = () => {
legend.addTo(map);
}
}, [map, t]); // eslint-disable-line react-hooks/exhaustive-deps
}, [map, at]); // eslint-disable-line react-hooks/exhaustive-deps
return null;
};