@@ -585,7 +585,7 @@ export default function StreakTracker() {
{confirmCancel ? (
- Remove freeze?
+ Remove ?
)}
)}
- {!freezeLoading && !freeze?.hasFreeze && (
+ {!Loading && !?.hasFreeze && (
Streak Freeze
@@ -623,12 +623,12 @@ export default function StreakTracker() {
?
- A streak freeze protects your streak for one missed day. You can only use one freeze at a time.
+ A streak protects your streak for one missed day. You can only use one at a time.
@@ -636,9 +636,10 @@ export default function StreakTracker() {
)}
@@ -647,17 +648,17 @@ export default function StreakTracker() {
{contributionData ? (
<>
{/*
- Freeze dates are managed via the streak freeze API (/api/streak/freeze).
- Users can activate a freeze from the freeze button in this component.
- The calendar displays existing freeze dates from the API response.
+ Freeze dates are managed via the streak API (/api/streak/).
+ Users can activate a from the button in this component.
+ The calendar displays existing dates from the API response.
Future: add UI to manually mark/unmark past dates as frozen.
*/}
;
- freezeDates: string[];
+ Dates: string[];
currentMonth: Date;
onMonthChange: (date: Date) => void;
}
@@ -683,7 +684,7 @@ function toLocalDateStr(d: Date): string {
function StreakCalendar({
contributions,
- freezeDates,
+ Dates,
currentMonth,
onMonthChange,
}: StreakCalendarProps) {
@@ -715,7 +716,7 @@ function StreakCalendar({
const handlePrevMonth = () => onMonthChange(new Date(year, month - 1));
const handleNextMonth = () => onMonthChange(new Date(year, month + 1));
- const freezeSet = new Set(freezeDates);
+ const Set = new Set(Dates);
return (
@@ -765,7 +766,7 @@ function StreakCalendar({
const commitCount = contributions[dateStr] ?? 0;
const isFuture = dayData.date > today;
const isToday = dayData.date.toDateString() === today.toDateString();
- const isFrozen = freezeSet.has(dateStr) && commitCount === 0;
+ const isFrozen = Set.has(dateStr) && commitCount === 0;
let bgColor = "bg-transparent";
let borderColor = "border border-[var(--border)]";
@@ -846,7 +847,7 @@ function StreakCalendar({
- Frozen days are set via the streak freeze feature above.
+ Frozen days are set via the streak feature above.