diff --git a/public/assets/new_homepage_image.png b/public/assets/new_homepage_image.png new file mode 100644 index 0000000000..737de683df Binary files /dev/null and b/public/assets/new_homepage_image.png differ diff --git a/src/app/components/pages/EventManager.tsx b/src/app/components/pages/EventManager.tsx index e9b7e4e99b..a67db2a337 100644 --- a/src/app/components/pages/EventManager.tsx +++ b/src/app/components/pages/EventManager.tsx @@ -7,20 +7,7 @@ import { SelectedEventDetails } from "../elements/panels/SelectedEventDetails"; import { ManageExistingBookings } from "../elements/panels/ManageExistingBookings"; import { AddUsersToBooking } from "../elements/panels/AddUsersToBooking"; import { EventAttendance } from "../elements/panels/EventAttendance"; -import { Button, Container } from "reactstrap"; - -const EventButton = ({ link, text, className }: { link: string; text: string; className?: string }) => ( - -); +import { Container } from "reactstrap"; export const EventManager = ({ user }: { user: PotentialUser }) => { const [selectedEventId, setSelectedEventId] = useState(null); @@ -35,13 +22,6 @@ export const EventManager = ({ user }: { user: PotentialUser }) => { return ( -
- - -
{selectedEventId !== null && ( diff --git a/src/app/components/pages/IsaacCompetition/EntryForm/EntryFormHandler.tsx b/src/app/components/pages/IsaacCompetition/EntryForm/EntryFormHandler.tsx index 5fde048832..6893e1d737 100644 --- a/src/app/components/pages/IsaacCompetition/EntryForm/EntryFormHandler.tsx +++ b/src/app/components/pages/IsaacCompetition/EntryForm/EntryFormHandler.tsx @@ -6,11 +6,12 @@ import { selectors, useAppSelector } from "../../../../state"; import { isStudent, isAdmin, isTeacher } from "../../../../services"; import CompetitionWrapper from "../CompetitionWrapper"; import { CLOSED_MESSAGE, STUDENT_MESSAGE, TEACHER_MESSAGE } from "../constants"; +import { isBeforeCompetitionOpenDate } from "../dateUtils"; // EOI button configuration - same as HomepageHighlight export const eoiButton = { to: "https://forms.cloud.microsoft/e/K4GmaA3QEF", - label: "Express your interest", + label: isBeforeCompetitionOpenDate(new Date()) ? "Express your interest" : "Submit your project", }; const StudentMessage = () => ( diff --git a/src/app/components/pages/IsaacCompetition/IsaacCompetition.tsx b/src/app/components/pages/IsaacCompetition/IsaacCompetition.tsx index ca7191a4aa..dc5775a9fa 100644 --- a/src/app/components/pages/IsaacCompetition/IsaacCompetition.tsx +++ b/src/app/components/pages/IsaacCompetition/IsaacCompetition.tsx @@ -10,7 +10,7 @@ import CompetitionTimeline from "./CompetitionInformation/CompetitionTimeline"; import EntryFormHandler, { eoiButton } from "./EntryForm/EntryFormHandler"; import CompetitionButton from "./Buttons/CompetitionButton"; import CompetitionWrapper from "./CompetitionWrapper"; -import { liveQandASessionDate } from "./dateUtils"; +import { isBeforeCompetitionOpenDate, liveQandASessionDate } from "./dateUtils"; const { section1, section3, accordion } = content; @@ -71,45 +71,53 @@ export const IsaacCompetition = () => {

National Computer Science Competition

- +

{section1.header.section1}

{section1.header.section2}

- {section1.note.entryDetails} - - Facebook - - {` and `} - - Instagram - - {` ${section1.note.callToAction}`} + {isBeforeCompetitionOpenDate(new Date()) ? ( + <> + {section1.note.beforeOpen.entryDetails} + + Facebook + + {` and `} + + Instagram + + {` ${section1.note.beforeOpen.callToAction}`} + + ) : ( + section1.note.afterOpen.entryDetails + )}

- + - }> - {null} + + - - Competition + +
+ The 2025/2026 competition winners +
+

{section1.imageCaption}

diff --git a/src/app/components/pages/IsaacCompetition/content.ts b/src/app/components/pages/IsaacCompetition/content.ts index b2f1a62e02..51d459a016 100644 --- a/src/app/components/pages/IsaacCompetition/content.ts +++ b/src/app/components/pages/IsaacCompetition/content.ts @@ -2,18 +2,25 @@ export default { section1: { header: { section1: [ - "Calling all computer science fans! We are hosting a national competition to challenge students to imagine, design, and pitch a groundbreaking new product for the Internet of Everything (IOE).", + "Calling all computer science fans! We are hosting a national competition to challenge students to imagine, design, and pitch a groundbreaking new product for the Internet of Everything.", ], section2: [ "The competition is a fantastic opportunity for students to apply their knowledge to real-world ideas.", ], }, note: { - entryDetails: "Follow our", - callToAction: "accounts for updates.", - facebookLink: "https://www.facebook.com/IsaacComputerScience", - instagramLink: "https://www.instagram.com/isaaccomputerscience", + beforeOpen: { + entryDetails: "Follow our", + callToAction: "accounts for updates.", + facebookLink: "https://www.facebook.com/IsaacComputerScience", + instagramLink: "https://www.instagram.com/isaaccomputerscience", + }, + afterOpen: { + entryDetails: "Are you a teacher? Log in to submit a project on behalf of your students.", + }, }, + imageCaption: + "The 2025/2026 competition winners: the 'Binary Sorter' project from Newstead Wood School (four students on the left) and 'Smart Port Locker' from Stroud High School (a student on the right)", }, section3: { diff --git a/src/scss/cs/competition.scss b/src/scss/cs/competition.scss index 2b9b25d788..1f8715e04e 100644 --- a/src/scss/cs/competition.scss +++ b/src/scss/cs/competition.scss @@ -37,6 +37,12 @@ background-color: #ffffff; } +.competition-hero-caption { + font-size: 14px; + line-height: 1.4; + background-color: transparent; +} + .manage-group-link { color: #1d70b8; text-decoration: underline; diff --git a/src/test/pages/EventManager.test.tsx b/src/test/pages/EventManager.test.tsx index 3fd1620b3a..43b2273f0b 100644 --- a/src/test/pages/EventManager.test.tsx +++ b/src/test/pages/EventManager.test.tsx @@ -33,17 +33,6 @@ describe("Event Manager", () => { ); }); - it("shows event listing form and events toolkit buttons with correct links", () => { - renderEventManager(); - const eventListingForm = screen.getByRole("link", { name: /event listing form/i }); - const eventsToolkit = screen.getByRole("link", { name: /events toolkit/i }); - expect(eventListingForm).toHaveAttribute("href", "https://forms.office.com/e/ZrijWx8gcw"); - expect(eventsToolkit).toHaveAttribute( - "href", - "https://myscience.atlassian.net/wiki/spaces/NN/pages/4119658517/Events+toolkit", - ); - }); - it("if logged in as an Event Leader, a message appears to warn that they can only view events they manage", () => { renderEventManager({ role: "EVENT_LEADER" }); checkPageTitle("Event booking admin");