├── .eslintrc.json ├── .github └── workflows │ └── terraform.yml ├── .gitignore ├── .idea ├── .gitignore ├── inspectionProfiles │ └── Project_Default.xml ├── misc.xml ├── modules.xml ├── prettier.xml ├── vcs.xml └── vote.iml ├── LICENSE ├── README.md ├── next-env.d.ts ├── next.config.mjs ├── package.json ├── postcss.config.cjs ├── prettier.config.js ├── prisma └── schema.prisma ├── public └── favicon.ico ├── src ├── components │ ├── PageHeader.tsx │ ├── auth │ │ └── LogInButton.tsx │ ├── buttons │ │ ├── Button.tsx │ │ ├── CreateNewPollButton.tsx │ │ └── UpvoteDownvote.tsx │ ├── containers │ │ └── Container.tsx │ ├── io │ │ └── useLocalStorage.ts │ ├── loading │ │ └── Skeleton.tsx │ ├── navigation │ │ ├── NavProfile.tsx │ │ ├── NavTitle.tsx │ │ └── Navbar.tsx │ ├── posts │ │ ├── PostCard.tsx │ │ ├── PostPoll.tsx │ │ ├── PostPollOptions.tsx │ │ └── PostsList.tsx │ ├── select │ │ └── Select.tsx │ ├── tooltip │ │ └── Tooltip.tsx │ └── topics │ │ └── useTopicId.ts ├── env │ ├── client.mjs │ ├── schema.mjs │ └── server.mjs ├── pages │ ├── [topicId].tsx │ ├── [topicId] │ │ ├── [postId].tsx │ │ └── create.tsx │ ├── _ │ │ └── twitter.tsx │ ├── _app.tsx │ ├── api │ │ ├── auth │ │ │ └── [...nextauth].ts │ │ ├── examples.ts │ │ ├── restricted.ts │ │ └── trpc │ │ │ └── [trpc].ts │ └── index.tsx ├── server │ ├── common │ │ └── get-server-auth-session.ts │ ├── db │ │ └── client.ts │ ├── router │ │ ├── context.ts │ │ ├── index.ts │ │ ├── models │ │ │ ├── comment.ts │ │ │ ├── post.ts │ │ │ └── topic.ts │ │ ├── protected-example-router.ts │ │ └── protected-router.ts │ └── trpc.ts ├── styles │ └── globals.css ├── types │ └── next-auth.d.ts ├── utils │ ├── DateUtils.ts │ └── trpc.ts └── validation │ └── post.ts ├── tailwind.config.cjs └── tsconfig.json /.eslintrc.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.eslintrc.json -------------------------------------------------------------------------------- /.github/workflows/terraform.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.github/workflows/terraform.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.gitignore -------------------------------------------------------------------------------- /.idea/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.idea/.gitignore -------------------------------------------------------------------------------- /.idea/inspectionProfiles/Project_Default.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.idea/inspectionProfiles/Project_Default.xml -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.idea/misc.xml -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.idea/modules.xml -------------------------------------------------------------------------------- /.idea/prettier.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.idea/prettier.xml -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.idea/vcs.xml -------------------------------------------------------------------------------- /.idea/vote.iml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/.idea/vote.iml -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/README.md -------------------------------------------------------------------------------- /next-env.d.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/next-env.d.ts -------------------------------------------------------------------------------- /next.config.mjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/next.config.mjs -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/package.json -------------------------------------------------------------------------------- /postcss.config.cjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/postcss.config.cjs -------------------------------------------------------------------------------- /prettier.config.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/prettier.config.js -------------------------------------------------------------------------------- /prisma/schema.prisma: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/prisma/schema.prisma -------------------------------------------------------------------------------- /public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/public/favicon.ico -------------------------------------------------------------------------------- /src/components/PageHeader.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/PageHeader.tsx -------------------------------------------------------------------------------- /src/components/auth/LogInButton.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/auth/LogInButton.tsx -------------------------------------------------------------------------------- /src/components/buttons/Button.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/buttons/Button.tsx -------------------------------------------------------------------------------- /src/components/buttons/CreateNewPollButton.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/buttons/CreateNewPollButton.tsx -------------------------------------------------------------------------------- /src/components/buttons/UpvoteDownvote.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/buttons/UpvoteDownvote.tsx -------------------------------------------------------------------------------- /src/components/containers/Container.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/containers/Container.tsx -------------------------------------------------------------------------------- /src/components/io/useLocalStorage.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/io/useLocalStorage.ts -------------------------------------------------------------------------------- /src/components/loading/Skeleton.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/loading/Skeleton.tsx -------------------------------------------------------------------------------- /src/components/navigation/NavProfile.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/navigation/NavProfile.tsx -------------------------------------------------------------------------------- /src/components/navigation/NavTitle.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/navigation/NavTitle.tsx -------------------------------------------------------------------------------- /src/components/navigation/Navbar.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/navigation/Navbar.tsx -------------------------------------------------------------------------------- /src/components/posts/PostCard.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/posts/PostCard.tsx -------------------------------------------------------------------------------- /src/components/posts/PostPoll.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/posts/PostPoll.tsx -------------------------------------------------------------------------------- /src/components/posts/PostPollOptions.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/posts/PostPollOptions.tsx -------------------------------------------------------------------------------- /src/components/posts/PostsList.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/posts/PostsList.tsx -------------------------------------------------------------------------------- /src/components/select/Select.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/select/Select.tsx -------------------------------------------------------------------------------- /src/components/tooltip/Tooltip.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/tooltip/Tooltip.tsx -------------------------------------------------------------------------------- /src/components/topics/useTopicId.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/components/topics/useTopicId.ts -------------------------------------------------------------------------------- /src/env/client.mjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/env/client.mjs -------------------------------------------------------------------------------- /src/env/schema.mjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/env/schema.mjs -------------------------------------------------------------------------------- /src/env/server.mjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/env/server.mjs -------------------------------------------------------------------------------- /src/pages/[topicId].tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/[topicId].tsx -------------------------------------------------------------------------------- /src/pages/[topicId]/[postId].tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/[topicId]/[postId].tsx -------------------------------------------------------------------------------- /src/pages/[topicId]/create.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/[topicId]/create.tsx -------------------------------------------------------------------------------- /src/pages/_/twitter.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/_/twitter.tsx -------------------------------------------------------------------------------- /src/pages/_app.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/_app.tsx -------------------------------------------------------------------------------- /src/pages/api/auth/[...nextauth].ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/api/auth/[...nextauth].ts -------------------------------------------------------------------------------- /src/pages/api/examples.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/api/examples.ts -------------------------------------------------------------------------------- /src/pages/api/restricted.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/api/restricted.ts -------------------------------------------------------------------------------- /src/pages/api/trpc/[trpc].ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/api/trpc/[trpc].ts -------------------------------------------------------------------------------- /src/pages/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/pages/index.tsx -------------------------------------------------------------------------------- /src/server/common/get-server-auth-session.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/common/get-server-auth-session.ts -------------------------------------------------------------------------------- /src/server/db/client.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/db/client.ts -------------------------------------------------------------------------------- /src/server/router/context.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/router/context.ts -------------------------------------------------------------------------------- /src/server/router/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/router/index.ts -------------------------------------------------------------------------------- /src/server/router/models/comment.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/router/models/comment.ts -------------------------------------------------------------------------------- /src/server/router/models/post.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/router/models/post.ts -------------------------------------------------------------------------------- /src/server/router/models/topic.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/router/models/topic.ts -------------------------------------------------------------------------------- /src/server/router/protected-example-router.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/router/protected-example-router.ts -------------------------------------------------------------------------------- /src/server/router/protected-router.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/router/protected-router.ts -------------------------------------------------------------------------------- /src/server/trpc.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/server/trpc.ts -------------------------------------------------------------------------------- /src/styles/globals.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/styles/globals.css -------------------------------------------------------------------------------- /src/types/next-auth.d.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/types/next-auth.d.ts -------------------------------------------------------------------------------- /src/utils/DateUtils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/utils/DateUtils.ts -------------------------------------------------------------------------------- /src/utils/trpc.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/utils/trpc.ts -------------------------------------------------------------------------------- /src/validation/post.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/src/validation/post.ts -------------------------------------------------------------------------------- /tailwind.config.cjs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/tailwind.config.cjs -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/acorn1010/vote/HEAD/tsconfig.json --------------------------------------------------------------------------------