From 34af3cceac6b49c80d246018782500bcb59d4f23 Mon Sep 17 00:00:00 2001 From: Xevion Date: Sun, 18 Dec 2022 18:17:20 -0600 Subject: [PATCH] Add analytics, adjust lightmode instructional text --- .env.example | 11 ----------- package.json | 1 + src/pages/index.tsx | 11 ++++++++--- yarn.lock | 9 ++++++++- 4 files changed, 17 insertions(+), 15 deletions(-) delete mode 100644 .env.example diff --git a/.env.example b/.env.example deleted file mode 100644 index 38b70c1..0000000 --- a/.env.example +++ /dev/null @@ -1,11 +0,0 @@ -# Since .env is gitignored, you can use .env.example to build a new `.env` file when you clone the repo. -# Keep this file up-to-date when you add new variables to `.env`. - -# This file will be committed to version control, so make sure not to have any secrets in it. -# If you are cloning this repo, create a copy of this file named `.env` and populate it with your secrets. - -# When adding additional env variables, the schema in /env/schema.mjs should be updated accordingly - -# Example: -# SERVERVAR=foo -# NEXT_PUBLIC_CLIENTVAR=bar diff --git a/package.json b/package.json index 2393c7e..b77cb6f 100644 --- a/package.json +++ b/package.json @@ -20,6 +20,7 @@ "@types/react-no-ssr": "^1.1.3", "chance": "^1.1.9", "next": "13.0.2", + "nextjs-google-analytics": "^2.2.2", "react": "18.2.0", "react-dom": "18.2.0", "react-no-ssr": "^1.1.0", diff --git a/src/pages/index.tsx b/src/pages/index.tsx index cc64dcf..9d437fc 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx @@ -4,11 +4,16 @@ import BoxTable from "@/components/BoxTable"; import NoSSR from "react-no-ssr"; import Page from "@/components/Page"; import BoxLoop from "@/components/BoxLoop"; +import {useBreakpointValue} from "@/utils/helpers"; +import {GoogleAnalytics} from "nextjs-google-analytics"; const Home: NextPage = () => { + const boxCount = useBreakpointValue("md", 5, 3); + return ( <> + 100prisoners.com @@ -20,7 +25,7 @@ const Home: NextPage = () => { raise the chances one hundred octillion.

-
+

Hover to see part of the loop.
Click to hide boxes outside the loop and see more of the loop. @@ -71,9 +76,9 @@ const Home: NextPage = () => { Due to an interesting mathematical quirk of some (assumed) properties of the game, the boxes have an interesting structure to their existence.

-
+
- +

diff --git a/yarn.lock b/yarn.lock index 3a8381d..d31d1d2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1110,7 +1110,7 @@ fs.realpath@^1.0.0: resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== -fsevents@~2.3.2: +fsevents@^2.3.2, fsevents@~2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== @@ -1612,6 +1612,13 @@ next@13.0.2: "@next/swc-win32-ia32-msvc" "13.0.2" "@next/swc-win32-x64-msvc" "13.0.2" +nextjs-google-analytics@^2.2.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/nextjs-google-analytics/-/nextjs-google-analytics-2.2.2.tgz#5f634960c19933c8515f1da310d170418710b83f" + integrity sha512-PfA5QZCV+tsCEHG6AE3UXHY8fpHguN+l8t81GztdVW1EtX6UCfu8/rb/X/E+D3oFMY0P3YFQzouSgdm1OhWFiA== + optionalDependencies: + fsevents "^2.3.2" + node-releases@^2.0.6: version "2.0.8" resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.8.tgz#0f349cdc8fcfa39a92ac0be9bc48b7706292b9ae"