mirror of
https://github.com/lukevella/rallly.git
synced 2025-06-05 04:02:21 +02:00
Bug fixes (#191)
This commit is contained in:
parent
9fdbe46d19
commit
900fac5735
2 changed files with 6 additions and 4 deletions
|
@ -160,7 +160,8 @@ const MonthCalendar: React.VoidFunctionComponent<DateTimePickerProps> = ({
|
||||||
"relative flex h-12 items-center justify-center text-sm hover:bg-slate-50 focus:ring-0 focus:ring-offset-0 active:bg-slate-100",
|
"relative flex h-12 items-center justify-center text-sm hover:bg-slate-50 focus:ring-0 focus:ring-offset-0 active:bg-slate-100",
|
||||||
{
|
{
|
||||||
"bg-slate-50 text-slate-400": day.outOfMonth,
|
"bg-slate-50 text-slate-400": day.outOfMonth,
|
||||||
"font-bold text-indigo-500": day.today,
|
"font-bold": day.today,
|
||||||
|
"text-indigo-500": day.today && !day.selected,
|
||||||
"border-r": (i + 1) % 7 !== 0,
|
"border-r": (i + 1) % 7 !== 0,
|
||||||
"border-b": i < datepicker.days.length - 7,
|
"border-b": i < datepicker.days.length - 7,
|
||||||
"font-normal text-white after:absolute after:-z-0 after:h-8 after:w-8 after:animate-popIn after:rounded-full after:bg-green-500 after:content-['']":
|
"font-normal text-white after:absolute after:-z-0 after:h-8 after:w-8 after:animate-popIn after:rounded-full after:bg-green-500 after:content-['']":
|
||||||
|
|
|
@ -9,9 +9,10 @@ export const normalizeVotes = (
|
||||||
optionIds: string[],
|
optionIds: string[],
|
||||||
votes: ParticipantForm["votes"],
|
votes: ParticipantForm["votes"],
|
||||||
) => {
|
) => {
|
||||||
return optionIds.map(
|
return optionIds.map((optionId, i) => ({
|
||||||
(optionId, i) => votes[i] ?? { optionId, type: "no" as const },
|
optionId,
|
||||||
);
|
type: votes[i]?.type ?? ("no" as const),
|
||||||
|
}));
|
||||||
};
|
};
|
||||||
|
|
||||||
export const useAddParticipantMutation = () => {
|
export const useAddParticipantMutation = () => {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue