Skip to content
Merged
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"@mui/icons-material": "^6.0.0",
"@mui/material": "^6.4.4",
"@next/third-parties": "^16.0.0",
"@posthog/nextjs-config": "1.8.23",
"@posthog/nextjs-config": "1.8.24",
"@radix-ui/react-avatar": "^1.1.10",
"@radix-ui/react-checkbox": "^1.3.2",
"@radix-ui/react-dialog": "^1.1.14",
Expand Down
10 changes: 10 additions & 0 deletions src/app/(protected)/register/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -397,10 +397,19 @@ export default function RegistrationPage() {

const handleSubmit = async (e: React.FormEvent<HTMLFormElement>) => {
e.preventDefault();
const PSU_Main = "The Pennsylvania State University - Main Campus";

if (!user) {
toast.error("You must be logged in to register.");
return;
}
if (
psuRegisterFlagData?.isEnabled && !isLoadingPSURegisterFlag &&
formData.university !== PSU_Main
) {
toast.error("Only Penn State Main Campus students are eligible to register currently")
return;
}
if (formData.age < 18) {
toast.error("You must be 18 years or older to participate.");
return;
Expand Down Expand Up @@ -1383,6 +1392,7 @@ export default function RegistrationPage() {
<DialogHeader>
<DialogTitle>Penn State Email Verification</DialogTitle>
<DialogDescription>
<strong>We are currently only accepting students from Penn State Main Campus</strong> <br/>
Please enter your valid Penn State email to continue.
</DialogDescription>
</DialogHeader>
Expand Down
17 changes: 14 additions & 3 deletions src/components/PrizesChallenges/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ const TerminalModal: React.FC<{
{award.prizes.map((prize, index) => (
<div key={index} className="flex justify-between">
<span>{prize.place}:</span>
<span className="text-[#ff00ff]">{prize.amount}</span>
<span className="text-[#ff30f8]">{prize.amount}</span>
</div>
))}
</div>
Expand Down Expand Up @@ -249,8 +249,19 @@ const PrizesChallenges: React.FC = () => {
"Build the future with Open Claw at this HackPSU challenge. Create innovative AI-powered tools, applications, and experiments using the OpenClaw platform. Explore bold ideas, collaborate with fellow hackers, and turn prototypes into real projects. Whether you're learning or pushing boundaries, this is your chance to shape what comes next with OpenClaw.",
prizes: [
{
place: "Prize",
amount: "TBD",
place: "1st Place",
amount:
"1 shared 3 month Claude Pro subscription for the team",
},
{
place: "2nd Place",
amount:
"1 shared 2 month Claude Pro subscription for the team",
},
{
place: "3rd Place",
amount:
"1 shared 1 month Claude Pro subscription for the team",
},
],
closedBoxImage: "/sp26/ist_challenge.png",
Expand Down
10 changes: 6 additions & 4 deletions src/components/common/Autocomplete/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,12 @@ const Autocomplete: React.FC<Props> = ({
setQuery(value ?? "");
};

const handleSelectionChange = (selection: string) => {
onSelectionChange(data, selection);
setSelected(selection);
setQuery(selection ?? "");
const handleSelectionChange = (selection: string | null) => {
if (selection !== null) {
onSelectionChange(data, selection);
setSelected(selection);
setQuery(selection);
}
};

return (
Expand Down
Loading
Loading