diff --git a/README.md b/README.md index e0f6672f..2bf319a6 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,11 @@ First, fork the repository and clone it. git clone https://github.com//conference-website.git ``` +Change Directory +```bash +cd conference-website +``` + Install Dependencies ```bash npm install diff --git a/config/city-lists.json b/config/city-lists.json index 01393c12..1d8c7b38 100644 --- a/config/city-lists.json +++ b/config/city-lists.json @@ -7,10 +7,25 @@ "description": "Join us for the AsyncAPI Online Conference Edition as the community unites across the globe to share experiences, collaborate, and foster meaningful connections.", "img": "/img/testMic.webp", "address": "AsyncAPI YouTube Channel", - "map": "https://www.youtube.com/playlist?list=PLbi1gRlP7pijItMBmw9SeeyWxuEa3jLR2", - "sponsors": [ - "/img/apidays.png" - ], + "map": "https://www.youtube.com/live/F9wHxd-v2f0?si=PT8BuAUKNmoLHRiM", + "sponsors": { + "eventSponsors" : [{ + "image":"/img/apidays.png", + "websiteUrl":"https://www.apidays.global/" + }], + "financialSponsors" : [ + { + "image":"/img/graviteeio.svg" , + "websiteUrl": "https://www.gravitee.io/", + "className":"w-[250px] h-[50px]" + }, + { + "image":"/img/postman.png" , + "websiteUrl":"https://www.postman.com/", + "className":"w-[240px] h-[70px]" + } + ] + }, "ticket": false, "isFree": true, "ended": true, @@ -27,9 +42,24 @@ "img": "/img/finland.webp", "address": "Pikku-Finlandia, Helsinki, Karamzininranta 4, 00100 Helsinki, Finland", "map": "https://maps.app.goo.gl/UpdEp188m5YNEAEo9", - "sponsors": [ - "/img/apidays.png" - ], + "sponsors": { + "eventSponsors" : [{ + "image":"/img/apidays.png", + "websiteUrl":"https://www.apidays.global/" + }], + "financialSponsors" : [ + { + "image":"/img/graviteeio.svg" , + "websiteUrl": "https://www.gravitee.io/", + "className":"w-[250px] h-[50px]" + }, + { + "image":"/img/postman.png" , + "websiteUrl":"https://www.postman.com/", + "className":"w-[240px] h-[70px]" + } + ] + }, "ticket": false, "isFree": false, "ended": true @@ -43,9 +73,24 @@ "img": "/img/london.gif", "address": "155 Bishopsgate, London EC2M 3YD", "map": "https://maps.app.goo.gl/b2Vb5H2mM41F9nQA6", - "sponsors": [ - "/img/apidays.png" - ], + "sponsors": { + "eventSponsors" : [{ + "image":"/img/apidays.png", + "websiteUrl":"https://www.apidays.global/" + }], + "financialSponsors" : [ + { + "image":"/img/graviteeio.svg" , + "websiteUrl": "https://www.gravitee.io/", + "className":"w-[250px] h-[50px]" + }, + { + "image":"/img/postman.png" , + "websiteUrl":"https://www.postman.com/", + "className":"w-[240px] h-[70px]" + } + ] + }, "ticket": "https://ticket.apidays.global/event/apidays-london-2024/869eca20-bfb6-4103-b8bb-d0348932e940/", "isFree": true, "ended": true, @@ -61,9 +106,24 @@ "img": "https://media1.giphy.com/media/v1.Y2lkPTc5MGI3NjExd24yenR4djEyZzRoeDA0ZmEyb3Y1c2F4NWVmbG13NmZwYWNhZzdnNiZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/Tuy3QxNZF1cxG/giphy.gif", "address": "CNIT (Centre des Nouvelles Industries et Technologies), Paris 2 Place de la Défense, 92092 Puteaux", "map": "https://maps.app.goo.gl/5te8WRM9Rb8B6vNd9", - "sponsors": [ - "/img/apidays.png" - ], + "sponsors": { + "eventSponsors" : [{ + "image":"/img/apidays.png", + "websiteUrl":"https://www.apidays.global/" + }], + "financialSponsors" : [ + { + "image":"/img/graviteeio.svg" , + "websiteUrl": "https://www.gravitee.io/", + "className":"w-[250px] h-[50px]" + }, + { + "image":"/img/postman.png" , + "websiteUrl":"https://www.postman.com/", + "className":"w-[240px] h-[70px]" + } + ] + }, "ticket": "https://ticket.apidays.global/event/apidays-paris-2024/f8f61349-4f78-4bba-a162-68d598833116/cart?coupon=ASYNCAPICONF", "isFree": true, "cfp": false, diff --git a/cypress/e2e/Landing.cy.js b/cypress/e2e/Landing.cy.js index 60c650f0..58d01462 100644 --- a/cypress/e2e/Landing.cy.js +++ b/cypress/e2e/Landing.cy.js @@ -1,11 +1,14 @@ import path from "path"; +import cities from "../../config/city-lists.json"; + describe("Landing Page Tests", () => { beforeEach(() => { cy.visit("/"); }); + it("Contains correct heading", () => { const Year = new Date().getFullYear(); - cy.getTestData("landing-heading").contains(`AsyncAPI Conf On Tour ${Year}`); + cy.getTestData("landing-heading").contains(new RegExp(`AsyncAPI Conf On Tour (${Year}|${Year-1})`)); }); it("Should contain About Section", () => { @@ -13,12 +16,12 @@ describe("Landing Page Tests", () => { }); it("Verify the downloaded file", () => { + const Year = new Date().getFullYear(); cy.getTestData("prospectus-download").should("be.visible"); cy.getTestData("prospectus-download").click(); - const Year = new Date().getFullYear(); const downloadsFolder = Cypress.config("downloadsFolder"); - cy.readFile(path.join(downloadsFolder, `conf ${Year}.pdf`)); + cy.readFile(path.join(downloadsFolder, `conf ${Year}.pdf`)).should("exist"); }); it("Should contain Speakers section", () => { @@ -33,6 +36,25 @@ describe("Landing Page Tests", () => { cy.getTestData("sponsor-section").should("be.visible"); }); + it("Should contain logos in Sponsor component", () => { + const eventSponsors = cities[0].sponsors.eventSponsors; + const financialSponsors = cities[0].sponsors.financialSponsors; + + eventSponsors.forEach((sponsor) => { + cy.getTestData("sponsor-section") + .find(`img[src="${sponsor.image}"]`) + .should("be.visible"); + cy.get(`a[href="${sponsor.websiteUrl}"]`).should("exist"); + }); + + financialSponsors.forEach((sponsor) => { + cy.getTestData("sponsor-section") + .find(`img[src="${sponsor.image}"]`) + .should("be.visible"); + cy.get(`a[href="${sponsor.websiteUrl}"]`).should("exist"); + }); + }); + it("Subscribe Button is functional", () => { cy.getTestData("subscribe-button").invoke("removeAttr", "target").click(); diff --git a/cypress/e2e/Venue.cy.js b/cypress/e2e/Venue.cy.js index cc14bb20..5ee24e6d 100644 --- a/cypress/e2e/Venue.cy.js +++ b/cypress/e2e/Venue.cy.js @@ -6,7 +6,7 @@ it("should render guideline for not ended cities and agenda otherwise",()=>{ cy.getTestData(`venue-${city.name}`).then(val=>{ - if(!city.ended){ + if(Date.now()>Date(city.date) && !city.ended){ cy.getTestData("guideline-com").should("be.visible"); } else{ @@ -18,7 +18,33 @@ it("should render guideline for not ended cities and agenda otherwise",()=>{ }); -it.only("Form should work",()=>{ +it("Should contain logos in Sponsor component", () => { + const eventSponsors = cities[0].sponsors.eventSponsors; + + const financialSponsor = cities[0].sponsors.financialSponsors; + + cy.wrap(cities).each((city) => { + cy.visit(`http://localhost:3000/venue/${city.name}`); + + cy.getTestData("sponsor-section").should("exist"); + + eventSponsors.forEach((sponsor) => { + cy.getTestData('sponsor-section') + .find(`img[src="${sponsor.image}"]`) + .should('be.visible'); + cy.get(`a[href="${sponsor.websiteUrl}"]`).should('exist'); + }); + + financialSponsor.forEach((sponsor) => { + cy.getTestData('sponsor-section') + .find(`img[src="${sponsor.image}"]`) + .should('be.visible'); + cy.get(`a[href="${sponsor.websiteUrl}"]`).should('exist'); + }); + }) +}); + +it("Form should work",()=>{ cy.visit('http://localhost:3000/venue/online/register'); cy.getTestData("cfp-form").should('be.visible'); diff --git a/package-lock.json b/package-lock.json index ec36abc8..cafa67a6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,7 +13,7 @@ "d3": "^7.8.5", "lucide-react": "^0.350.0", "net": "^1.0.2", - "next": "^14.2.10", + "next": "^14.2.21", "next-on-netlify": "^3.0.1", "nodemailer": "^6.9.13", "react": "^18.2.1", @@ -929,9 +929,9 @@ } }, "node_modules/@next/env": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/env/-/env-14.2.15.tgz", - "integrity": "sha512-S1qaj25Wru2dUpcIZMjxeMVSwkt8BK4dmWHHiBuRstcIyOsMapqT4A4jSB6onvqeygkSSmOkyny9VVx8JIGamQ==" + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/env/-/env-14.2.21.tgz", + "integrity": "sha512-lXcwcJd5oR01tggjWJ6SrNNYFGuOOMB9c251wUNkjCpkoXOPkDeF/15c3mnVlBqrW4JJXb2kVxDFhC4GduJt2A==" }, "node_modules/@next/eslint-plugin-next": { "version": "13.1.1", @@ -942,9 +942,9 @@ } }, "node_modules/@next/swc-darwin-arm64": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-14.2.15.tgz", - "integrity": "sha512-Rvh7KU9hOUBnZ9TJ28n2Oa7dD9cvDBKua9IKx7cfQQ0GoYUwg9ig31O2oMwH3wm+pE3IkAQ67ZobPfEgurPZIA==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-14.2.21.tgz", + "integrity": "sha512-HwEjcKsXtvszXz5q5Z7wCtrHeTTDSTgAbocz45PHMUjU3fBYInfvhR+ZhavDRUYLonm53aHZbB09QtJVJj8T7g==", "cpu": [ "arm64" ], @@ -957,9 +957,9 @@ } }, "node_modules/@next/swc-darwin-x64": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-14.2.15.tgz", - "integrity": "sha512-5TGyjFcf8ampZP3e+FyCax5zFVHi+Oe7sZyaKOngsqyaNEpOgkKB3sqmymkZfowy3ufGA/tUgDPPxpQx931lHg==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-14.2.21.tgz", + "integrity": "sha512-TSAA2ROgNzm4FhKbTbyJOBrsREOMVdDIltZ6aZiKvCi/v0UwFmwigBGeqXDA97TFMpR3LNNpw52CbVelkoQBxA==", "cpu": [ "x64" ], @@ -972,9 +972,9 @@ } }, "node_modules/@next/swc-linux-arm64-gnu": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-14.2.15.tgz", - "integrity": "sha512-3Bwv4oc08ONiQ3FiOLKT72Q+ndEMyLNsc/D3qnLMbtUYTQAmkx9E/JRu0DBpHxNddBmNT5hxz1mYBphJ3mfrrw==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-14.2.21.tgz", + "integrity": "sha512-0Dqjn0pEUz3JG+AImpnMMW/m8hRtl1GQCNbO66V1yp6RswSTiKmnHf3pTX6xMdJYSemf3O4Q9ykiL0jymu0TuA==", "cpu": [ "arm64" ], @@ -987,9 +987,9 @@ } }, "node_modules/@next/swc-linux-arm64-musl": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-14.2.15.tgz", - "integrity": "sha512-k5xf/tg1FBv/M4CMd8S+JL3uV9BnnRmoe7F+GWC3DxkTCD9aewFRH1s5rJ1zkzDa+Do4zyN8qD0N8c84Hu96FQ==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-14.2.21.tgz", + "integrity": "sha512-Ggfw5qnMXldscVntwnjfaQs5GbBbjioV4B4loP+bjqNEb42fzZlAaK+ldL0jm2CTJga9LynBMhekNfV8W4+HBw==", "cpu": [ "arm64" ], @@ -1002,9 +1002,9 @@ } }, "node_modules/@next/swc-linux-x64-gnu": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.2.15.tgz", - "integrity": "sha512-kE6q38hbrRbKEkkVn62reLXhThLRh6/TvgSP56GkFNhU22TbIrQDEMrO7j0IcQHcew2wfykq8lZyHFabz0oBrA==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.2.21.tgz", + "integrity": "sha512-uokj0lubN1WoSa5KKdThVPRffGyiWlm/vCc/cMkWOQHw69Qt0X1o3b2PyLLx8ANqlefILZh1EdfLRz9gVpG6tg==", "cpu": [ "x64" ], @@ -1017,9 +1017,9 @@ } }, "node_modules/@next/swc-linux-x64-musl": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-14.2.15.tgz", - "integrity": "sha512-PZ5YE9ouy/IdO7QVJeIcyLn/Rc4ml9M2G4y3kCM9MNf1YKvFY4heg3pVa/jQbMro+tP6yc4G2o9LjAz1zxD7tQ==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-14.2.21.tgz", + "integrity": "sha512-iAEBPzWNbciah4+0yI4s7Pce6BIoxTQ0AGCkxn/UBuzJFkYyJt71MadYQkjPqCQCJAFQ26sYh7MOKdU+VQFgPg==", "cpu": [ "x64" ], @@ -1032,9 +1032,9 @@ } }, "node_modules/@next/swc-win32-arm64-msvc": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-14.2.15.tgz", - "integrity": "sha512-2raR16703kBvYEQD9HNLyb0/394yfqzmIeyp2nDzcPV4yPjqNUG3ohX6jX00WryXz6s1FXpVhsCo3i+g4RUX+g==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-14.2.21.tgz", + "integrity": "sha512-plykgB3vL2hB4Z32W3ktsfqyuyGAPxqwiyrAi2Mr8LlEUhNn9VgkiAl5hODSBpzIfWweX3er1f5uNpGDygfQVQ==", "cpu": [ "arm64" ], @@ -1047,9 +1047,9 @@ } }, "node_modules/@next/swc-win32-ia32-msvc": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.2.15.tgz", - "integrity": "sha512-fyTE8cklgkyR1p03kJa5zXEaZ9El+kDNM5A+66+8evQS5e/6v0Gk28LqA0Jet8gKSOyP+OTm/tJHzMlGdQerdQ==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.2.21.tgz", + "integrity": "sha512-w5bacz4Vxqrh06BjWgua3Yf7EMDb8iMcVhNrNx8KnJXt8t+Uu0Zg4JHLDL/T7DkTCEEfKXO/Er1fcfWxn2xfPA==", "cpu": [ "ia32" ], @@ -1062,9 +1062,9 @@ } }, "node_modules/@next/swc-win32-x64-msvc": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-14.2.15.tgz", - "integrity": "sha512-SzqGbsLsP9OwKNUG9nekShTwhj6JSB9ZLMWQ8g1gG6hdE5gQLncbnbymrwy2yVmH9nikSLYRYxYMFu78Ggp7/g==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-14.2.21.tgz", + "integrity": "sha512-sT6+llIkzpsexGYZq8cjjthRyRGe5cJVhqh12FmlbxHqna6zsDDK8UNaV7g41T6atFHCJUPeLb3uyAwrBwy0NA==", "cpu": [ "x64" ], @@ -5296,11 +5296,11 @@ "license": "MIT" }, "node_modules/next": { - "version": "14.2.15", - "resolved": "https://registry.npmjs.org/next/-/next-14.2.15.tgz", - "integrity": "sha512-h9ctmOokpoDphRvMGnwOJAedT6zKhwqyZML9mDtspgf4Rh3Pn7UTYKqePNoDvhsWBAO5GoPNYshnAUGIazVGmw==", + "version": "14.2.21", + "resolved": "https://registry.npmjs.org/next/-/next-14.2.21.tgz", + "integrity": "sha512-rZmLwucLHr3/zfDMYbJXbw0ZeoBpirxkXuvsJbk7UPorvPYZhP7vq7aHbKnU7dQNCYIimRrbB2pp3xmf+wsYUg==", "dependencies": { - "@next/env": "14.2.15", + "@next/env": "14.2.21", "@swc/helpers": "0.5.5", "busboy": "1.6.0", "caniuse-lite": "^1.0.30001579", @@ -5315,15 +5315,15 @@ "node": ">=18.17.0" }, "optionalDependencies": { - "@next/swc-darwin-arm64": "14.2.15", - "@next/swc-darwin-x64": "14.2.15", - "@next/swc-linux-arm64-gnu": "14.2.15", - "@next/swc-linux-arm64-musl": "14.2.15", - "@next/swc-linux-x64-gnu": "14.2.15", - "@next/swc-linux-x64-musl": "14.2.15", - "@next/swc-win32-arm64-msvc": "14.2.15", - "@next/swc-win32-ia32-msvc": "14.2.15", - "@next/swc-win32-x64-msvc": "14.2.15" + "@next/swc-darwin-arm64": "14.2.21", + "@next/swc-darwin-x64": "14.2.21", + "@next/swc-linux-arm64-gnu": "14.2.21", + "@next/swc-linux-arm64-musl": "14.2.21", + "@next/swc-linux-x64-gnu": "14.2.21", + "@next/swc-linux-x64-musl": "14.2.21", + "@next/swc-win32-arm64-msvc": "14.2.21", + "@next/swc-win32-ia32-msvc": "14.2.21", + "@next/swc-win32-x64-msvc": "14.2.21" }, "peerDependencies": { "@opentelemetry/api": "^1.1.0", diff --git a/package.json b/package.json index 153155e4..6f01eae2 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,7 @@ "d3": "^7.8.5", "lucide-react": "^0.350.0", "net": "^1.0.2", - "next": "^14.2.10", + "next": "^14.2.21", "next-on-netlify": "^3.0.1", "nodemailer": "^6.9.13", "react": "^18.2.1", diff --git a/pages/index.js b/pages/index.js index 9a94f90a..78c8de64 100644 --- a/pages/index.js +++ b/pages/index.js @@ -185,6 +185,7 @@ export default function Home() { +
@@ -192,6 +193,5 @@ export default function Home() { - ); } diff --git a/pages/venue/[id].js b/pages/venue/[id].js index 8ed0a255..385725c0 100644 --- a/pages/venue/[id].js +++ b/pages/venue/[id].js @@ -43,7 +43,7 @@ function Venue({ city }) {
-
+
{city.name == 'Online' ? {city.name} {city.country} : @@ -93,7 +93,7 @@ function Venue({ city }) {
- +
); diff --git a/pages/venue/online/register/index.js b/pages/venue/online/register/index.js index fbb6966d..62ce4060 100644 --- a/pages/venue/online/register/index.js +++ b/pages/venue/online/register/index.js @@ -7,7 +7,7 @@ export default function SpeakersForm(){
- +
) }