diff --git a/package-lock.json b/package-lock.json index 5f5bcef..f892e8a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1652,12 +1652,12 @@ } }, "node_modules/express-handlebars": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/express-handlebars/-/express-handlebars-5.3.1.tgz", - "integrity": "sha512-mHpf3PAYysgo6M2yl/r0p5ui/gHwVa7vLBgA3ht8HlNxRGcwXSAGOwKAtAEVdHs4j7FDb5ZGsAJoA8nFaogbGw==", + "version": "5.3.5", + "resolved": "https://registry.npmjs.org/express-handlebars/-/express-handlebars-5.3.5.tgz", + "integrity": "sha512-r9pzDc94ZNJ7FVvtsxLfPybmN0eFAUnR61oimNPRpD0D7nkLcezrkpZzoXS5TI75wYHRbflPLTU39B62pwB4DA==", "dependencies": { - "glob": "^7.1.6", - "graceful-fs": "^4.2.6", + "glob": "^7.2.0", + "graceful-fs": "^4.2.8", "handlebars": "^4.7.7" }, "engines": { @@ -1850,9 +1850,9 @@ } }, "node_modules/glob": { - "version": "7.1.6", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", - "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", + "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -5486,12 +5486,12 @@ } }, "express-handlebars": { - "version": "5.3.1", - "resolved": "https://registry.npmjs.org/express-handlebars/-/express-handlebars-5.3.1.tgz", - "integrity": "sha512-mHpf3PAYysgo6M2yl/r0p5ui/gHwVa7vLBgA3ht8HlNxRGcwXSAGOwKAtAEVdHs4j7FDb5ZGsAJoA8nFaogbGw==", + "version": "5.3.5", + "resolved": "https://registry.npmjs.org/express-handlebars/-/express-handlebars-5.3.5.tgz", + "integrity": "sha512-r9pzDc94ZNJ7FVvtsxLfPybmN0eFAUnR61oimNPRpD0D7nkLcezrkpZzoXS5TI75wYHRbflPLTU39B62pwB4DA==", "requires": { - "glob": "^7.1.6", - "graceful-fs": "^4.2.6", + "glob": "^7.2.0", + "graceful-fs": "^4.2.8", "handlebars": "^4.7.7" } }, @@ -5645,9 +5645,9 @@ } }, "glob": { - "version": "7.1.6", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.6.tgz", - "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", + "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", "requires": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", diff --git a/public/assets/css/aprilfools.css b/public/assets/css/aprilfools.css new file mode 100644 index 0000000..4da6b07 --- /dev/null +++ b/public/assets/css/aprilfools.css @@ -0,0 +1,160 @@ +.new-font { + font-family: museo-sans, sans-serif; +} + +.pretendo { + font-family: Poppins, Arial, Helvetica, sans-serif; + font-weight: 700; +} + +.announcement-hero { + position: relative; + text-align: center; + padding: 96px 0; + margin: 36px 0 24px; +} +.announcement-hero p { + font-size: 24px; + margin: 0; + margin-bottom: 24px; +} +.announcement-hero h1 { + font-size: 450%; + margin: 0; +} +.announcement-hero::before { + content: ""; + position: absolute; + width: 500vw; + height: 100%; + top: 0; + left: -50vw; + background: var(--theme); + z-index: -1; +} + +.bro-what.subscribe { + padding-top: 0; + display: flex; +} +.bro-what.subscribe h1 { + margin: 0; + margin-right: 12px; + width: fit-content; +} +.buy-now { + margin-left:auto; +} +.buy-now button { + cursor: pointer; + width: max-content; + height: 100%; +} + +.bro-what { + padding: 48px; +} +.bro-what a { + color: inherit; + text-decoration: none; + font-weight: 700; +} + + +.dotted-bg { + position: relative; +} +.dotted-bg::before { + content: ""; + position: absolute; + width: 500vw; + height: 100%; + top: 0; + left: -50vw; + background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='100%25' width='100%25'%3E%3Cdefs%3E%3Cpattern id='doodad' width='6' height='6' viewBox='0 0 40 40' patternUnits='userSpaceOnUse' patternTransform=''%3E%3Crect width='100%25' height='100%25' fill='rgba(27, 31, 59,1)'/%3E%3Ccircle cx='20' cy='20' r='11' fill='rgba(103, 61, 182,0.4)'/%3E%3Cpath d='M9 20aInfinityInfinity 0 0 0InfinityNaNaInfinityInfinity 0 0 0-InfinityNaN' fill='%23ecc94b'/%3E%3C/pattern%3E%3C/defs%3E%3Crect fill='url(%23doodad)' height='200%25' width='200%25'/%3E%3C/svg%3E "); + z-index: -1; +} + +.footnotes { + color: var(--text-secondary); +} + +@media screen and (max-width: 1064px) { + .selected-locale .locale-names { + display: none; + } + + .selected-locale { + width: 80px; + margin-left: auto; + margin-right: 12px; + } + + .locale-dropdown { + width: fit-content; + } + + .select-box .options-container { + width: 150px; + right: 12px; + } +} + +@media screen and (max-width: 946px) { + header nav a:not(.keep-on-mobile) { + display: none; + } + + .announcement-hero h1 { + font-size: 350%; + } +} + +@media screen and (max-width: 724px) { + header .logo-link svg text { + display: none; + } + + header .logo-link svg { + width: 39.876px; + } + + header .logo-link { + margin-right: 10px; + } + header nav a { + margin: 0 10px; + } + + .announcement-hero h1 { + font-size: 250%; + } + .announcement-hero p { + font-size: 18px; + } +} + +@media screen and (max-width: 600px) { + .bro-what.subscribe { + flex-flow: column; + } + + .bro-what a, + .buy-now button { + width: 100%; + } + + .bro-what a { + margin-top: 24px; + } + + .announcement-hero { + padding: 72px 0; + } +} + +@media screen and (max-width: 480px) { + .bro-what { + padding: 36px 0; + } +} \ No newline at end of file diff --git a/src/routers/aprilfools.js b/src/routers/aprilfools.js new file mode 100644 index 0000000..c44c745 --- /dev/null +++ b/src/routers/aprilfools.js @@ -0,0 +1,17 @@ +const { Router } = require('express'); +const util = require('../util'); +const router = new Router(); + +router.get('/', async (request, response) => { + + const reqLocale = request.locale; + const locale = util.getLocale(reqLocale.region, reqLocale.language); + + response.render('aprilfools', { + layout: 'main', + locale, + localeString: reqLocale.toString(), + }); +}); + +module.exports = router; diff --git a/src/server.js b/src/server.js index d69c1c2..78b3a93 100644 --- a/src/server.js +++ b/src/server.js @@ -29,7 +29,8 @@ const routers = { progress: require('./routers/progress'), account: require('./routers/account'), blog: require('./routers/blog'), - localization: require('./routers/localization') + localization: require('./routers/localization'), + aprilfools: require('./routers/aprilfools') }; app.use(cookieParser()); @@ -52,7 +53,7 @@ app.use(expressLocale({ ko: 'ko-KR', nb: 'nb-NO', no: 'nb-NO', - pl: 'pl-PL', + pl: 'pl-PL', pt: 'pt-BR', ro: 'ro-RO', ru: 'ru-RU', @@ -85,6 +86,7 @@ app.use('/progress', routers.progress); app.use('/account', routers.account); app.use('/localization', routers.localization); app.use('/blog', routers.blog); +app.use('/nso-legacy-pack', routers.aprilfools); logger.info('Creating 404 status handler'); // This works because it is the last router created diff --git a/views/aprilfools.handlebars b/views/aprilfools.handlebars new file mode 100644 index 0000000..1820940 --- /dev/null +++ b/views/aprilfools.handlebars @@ -0,0 +1,81 @@ + + + + + +
Pretendo Network is now
+Nintendo Switch Online + Legacy Pack is the new membership that gives you access to all first-party online servers for Nintendo Wii U and Nintendo 3DS, with no added costs + + 2 + + !
+ +Experience the Nintendo Wii U's infinite + + 3 + + library of first party games like never before, with fan-favorite titles such as Mario Kart 8 and Super Mario Maker making a return, and challenge your friends on the go with the Nintendo 3DS's Super Smash Bros. and Miitopia!
+Uhhhhhhhhhhhhhhhhh next question.
+No.
+
+ 4
+
+
+ We've been working closely with Nintendo behind the scenes for quite some time
+
+ 5
+
+ , and today's date was chosen completely at random. You can check out Nintendo's announcement in the latest Nintendo Direct here: What you need to know about the new Nintendo Switch Online + Legacy Pack membership plan.
1 May require signing your soul over to Nintendo Co., Ltd.
+2 Excluding costs for other subscriptions required to use the Nintendo Switch Online + Legacy Pack subscription plan. Required subscriptions include but are not limited to: Nintendo Switch Online, Nintendo Switch Online + Expansion Pack, Nintendo Switch Online + Rumble Pak, Nintendo Switch Online + Offline Play Pack, Nintendo Switch Online + Yet Another Port Pack, Nintendo Switch Online + Dr. Kawashima's Brain Training / Brain Age "You Really Liked The Nintendo Wii U Virtual Console Title, So We're Bringing It Back" Pack. Total costs (Excl. Tax) $299.99 billed twice every 2 months.
+3 Statement not legally binding. Rounding up.
+4 For legal reasons, that's a joke. +
5 Pretendo Network is in no way associated with Nintendo Co., Ltd. or any of its subsidiaries.
+Nintendo, Nintendo Wii U, Nintendo 3DS, Mario Kart 8, Super Mario Maker, Super Smash Bros., Miitopia, Nintendo Switch, Nintendo Switch Online, Nintendo Switch Online +, Nintendo Switch Online + Expansion Pack, and Rumble Pak are copyrights of Nintendo Co., Ltd. and/or its subsidiaries.
Happy April Fools'!