diff --git a/.env.example b/.env.example index 9213618e..55b094a6 100644 --- a/.env.example +++ b/.env.example @@ -1,3 +1,6 @@ -# Put your environment variable keys here. - -NEXT_PUBLIC_SITE_URL="" \ No newline at end of file +NEXT_PUBLIC_SITE_URL=http://localhost:3000 +BASEHUB_TOKEN="" +REPLAY_API_KEY="" +BASEHUB_DRAFT=true +DRAFT_MODE=true +REPLAY_PLAYWRIGHT_FIXTURE=true \ No newline at end of file diff --git a/.eslintignore b/.eslintignore deleted file mode 100644 index e69de29b..00000000 diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 00000000..f8a16dac --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,7 @@ +{ + "extends": ["next/core-web-vitals", "prettier"], + "plugins": ["prettier"], + "rules": { + "prettier/prettier": "error" + } +} diff --git a/.github/.kodiak.toml b/.github/.kodiak.toml deleted file mode 100644 index 2ebc2a05..00000000 --- a/.github/.kodiak.toml +++ /dev/null @@ -1 +0,0 @@ -version = 1 \ No newline at end of file diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md deleted file mode 100644 index 9b5e06d6..00000000 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ /dev/null @@ -1,10 +0,0 @@ -> include a short description for this PR, and/or link any related issues that this PR addresses **← and then delete me.** - -## Checklist - -- [ ] Related issues linked. -- [ ] My code follows the style guidelines of this project. -- [ ] I have performed a self-review of my own code and it's looking great. -- [ ] I have tested my changes in desktop. -- [ ] I have tested my changes in a mobile device. -- [ ] I have tested my changes in dark and light mode (if applicable). diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 00000000..c725d8ee --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,42 @@ +name: Lint + +on: + pull_request: + workflow_dispatch: + push: + branches: [main] + +jobs: + trunk_check_runner: + name: Trunk Check runner + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: volta-cli/action@v1 + with: + node-version: 20.12.0 + - name: Get yarn cache directory path + id: yarn-cache-dir-path + run: echo "{dir}={$(yarn config get cacheFolder)}" >> $GITHUB_OUTPUT + - name: Restore yarn cache + uses: useblacksmith/cache@v5 + id: yarn-cache + with: + path: | + ${{ steps.yarn-cache-dir-path.outputs.dir }} + **/node_modules + key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }} + restore-keys: "yarn-cache-folder-" + # Actually install packages with Yarn + - name: Install packages + run: yarn install + env: + YARN_CHECKSUM_BEHAVIOR: "update" + - name: Lint + run: yarn lint + - name: Next Build (because it's more strict) + run: yarn build + env: + NEXT_PUBLIC_SITE_URL: "https://replay.io" + BASEHUB_TOKEN: ${{ secrets.BASEHUB_TOKEN }} + BASEHUB_DRAFT: true diff --git a/.github/workflows/playwright.yml b/.github/workflows/playwright.yml new file mode 100644 index 00000000..c9114cf1 --- /dev/null +++ b/.github/workflows/playwright.yml @@ -0,0 +1,43 @@ +name: Playwright Tests +on: + push: + branches: [main] + pull_request: +jobs: + test: + timeout-minutes: 60 + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: volta-cli/action@v1 + with: + node-version: 20.12.0 + - name: Get yarn cache directory path + id: yarn-cache-dir-path + run: echo "{dir}={$(yarn config get cacheFolder)}" >> $GITHUB_OUTPUT + - name: Restore yarn cache + uses: useblacksmith/cache@v5 + id: yarn-cache + with: + path: | + ${{ steps.yarn-cache-dir-path.outputs.dir }} + **/node_modules + key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }} + restore-keys: "yarn-cache-folder-" + - run: yarn install --frozen-lockfile + - run: yarn build + env: + BASEHUB_TOKEN: ${{ secrets.BASEHUB_TOKEN }} + BASEHUB_DRAFT: true + NEXT_PUBLIC_SITE_URL: "https://replay.io" + - run: yarn playwright:replay + env: + NEXT_PUBLIC_SITE_URL: "https://replay.io" + BASEHUB_TOKEN: ${{ secrets.BASEHUB_TOKEN }} + REPLAY_API_KEY: ${{ secrets.REPLAY_API_KEY }} + - uses: actions/upload-artifact@v4 + if: always() + with: + name: playwright-report + path: playwright-report/ + retention-days: 30 diff --git a/.gitignore b/.gitignore index 08637f53..744a4a9c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,40 +1,136 @@ -# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. +.DS_Store +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +lerna-debug.log* +.pnpm-debug.log* -# dependencies -/node_modules -/.pnp -.pnp.js +# Diagnostic reports (https://nodejs.org/api/report.html) +report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json -# testing -/coverage +# Runtime data +pids +*.pid +*.seed +*.pid.lock -# next.js -/.next/ -/out/ +# Directory for instrumented libs generated by jscoverage/JSCover +lib-cov -# production -/build +# Coverage directory used by tools like istanbul +coverage +*.lcov -# misc -*/robots.txt -*/sitemap.xml -*/sitemap-0.xml -.DS_Store -*.pem +# nyc test coverage +.nyc_output -# debug -npm-debug.log* -yarn-debug.log* -yarn-error.log* +# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) +.grunt + +# Bower dependency directory (https://bower.io/) +bower_components + +# node-waf configuration +.lock-wscript + +# Compiled binary addons (https://nodejs.org/api/addons.html) +build/Release + +# Dependency directories +node_modules/ +jspm_packages/ + +# Snowpack dependency directory (https://snowpack.dev/) +web_modules/ + +# TypeScript cache +*.tsbuildinfo + +# Optional npm cache directory +.npm + +# Optional eslint cache +.eslintcache + +# Optional stylelint cache +.stylelintcache + +# Microbundle cache +.rpt2_cache/ +.rts2_cache_cjs/ +.rts2_cache_es/ +.rts2_cache_umd/ -# local env files +# Optional REPL history +.node_repl_history + +# Yarn Integrity file +.yarn-integrity + +# dotenv environment variable files .env -.env.local .env.development.local .env.test.local .env.production.local +.env.local + +# parcel-bundler cache (https://parceljs.org/) +.cache +.parcel-cache + +# basehub build output +.basehub + +# Next.js build output +.next +out + +# Nuxt.js build / generate output +.nuxt +dist + +# Gatsby files +.cache/ +# Comment in the public line in if your project uses Gatsby and not Next.js +# https://nextjs.org/blog/next-9-1#public-directory-support +# public + +# vuepress build output +.vuepress/dist + +# vuepress v2.x temp and cache directory +.temp +.cache + +# Docusaurus cache and generated files +.docusaurus + +# Serverless directories +.serverless/ + +# FuseBox cache +.fusebox/ + +# DynamoDB Local files +.dynamodb/ + +# TernJS port file +.tern-port + +# Stores VSCode versions used for testing VSCode extensions +.vscode-test -# vercel +# yarn v2 +.yarn/cache +.yarn/unplugged +.yarn/build-state.yml +.yarn/install-state.gz +.pnp.* .vercel -tsconfig.tsbuildinfo -.env*.local +/test-results/ +/playwright-report/ +/blob-report/ +/playwright/.cache/ diff --git a/.husky/.gitignore b/.husky/.gitignore deleted file mode 100644 index 31354ec1..00000000 --- a/.husky/.gitignore +++ /dev/null @@ -1 +0,0 @@ -_ diff --git a/.husky/pre-commit b/.husky/pre-commit deleted file mode 100755 index d2ae35e8..00000000 --- a/.husky/pre-commit +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -. "$(dirname "$0")/_/husky.sh" - -yarn lint-staged diff --git a/.nvmrc b/.nvmrc index 3c032078..a75d90a0 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -18 +v20.12.0 diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 4b285176..7befee48 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -1,9 +1,7 @@ { "recommendations": [ "bradlc.vscode-tailwindcss", - "heybourn.headwind", "dbaeumer.vscode-eslint", - "esbenp.prettier-vscode", - "stylelint.vscode-stylelint" + "esbenp.prettier-vscode" ] } diff --git a/.vscode/settings.json b/.vscode/settings.json index 0106d454..11dba55a 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,23 +1,31 @@ { - "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.defaultFormatter": "dbaeumer.vscode-eslint", "editor.codeActionsOnSave": { - "source.fixAll.eslint": "explicit", - "source.fixAll.stylelint": "explicit" + "source.fixAll.eslint": "explicit" }, - "stylelint.validate": ["css", "scss"], "css.validate": false, "less.validate": false, "scss.validate": false, - "[css]": { - "editor.formatOnSave": false - }, "[scss]": { - "editor.formatOnSave": false + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "typescript.tsdk": "node_modules/typescript/lib", + "[jsonc]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "[postcss]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "[markdown]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "[yaml]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" }, - "[less]": { - "editor.formatOnSave": false + "[json]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[typescriptreact]": { - "editor.defaultFormatter": "vscode.typescript-language-features" + "editor.defaultFormatter": "esbenp.prettier-vscode" } } diff --git a/.yarnrc.yml b/.yarnrc.yml new file mode 100644 index 00000000..91b1101f --- /dev/null +++ b/.yarnrc.yml @@ -0,0 +1,5 @@ +compressionLevel: mixed + +enableGlobalCache: false + +nodeLinker: node-modules diff --git a/LICENSE.md b/LICENSE.md new file mode 100644 index 00000000..3a28c7d3 --- /dev/null +++ b/LICENSE.md @@ -0,0 +1,129 @@ +# Tailwind UI License + +## Personal License + +Tailwind Labs Inc. grants you an on-going, non-exclusive license to use the Components and Templates. + +The license grants permission to **one individual** (the Licensee) to access and use the Components and Templates. + +You **can**: + +- Use the Components and Templates to create unlimited End Products. +- Modify the Components and Templates to create derivative components and templates. Those components and templates are subject to this license. +- Use the Components and Templates to create unlimited End Products for unlimited Clients. +- Use the Components and Templates to create End Products where the End Product is sold to End Users. +- Use the Components and Templates to create End Products that are open source and freely available to End Users. + +You **cannot**: + +- Use the Components and Templates to create End Products that are designed to allow an End User to build their own End Products using the Components and Templates or derivatives of the Components and Templates. +- Re-distribute the Components and Templates or derivatives of the Components and Templates separately from an End Product, neither in code or as design assets. +- Share your access to the Components and Templates with any other individuals. +- Use the Components and Templates to produce anything that may be deemed by Tailwind Labs Inc, in their sole and absolute discretion, to be competitive or in conflict with the business of Tailwind Labs Inc. + +### Example usage + +Examples of usage **allowed** by the license: + +- Creating a personal website by yourself. +- Creating a website or web application for a client that will be owned by that client. +- Creating a commercial SaaS application (like an invoicing app for example) where end users have to pay a fee to use the application. +- Creating a commercial self-hosted web application that is sold to end users for a one-time fee. +- Creating a web application where the primary purpose is clearly not to simply re-distribute the components (like a conference organization app that uses the components for its UI for example) that is free and open source, where the source code is publicly available. + +Examples of usage **not allowed** by the license: + +- Creating a repository of your favorite Tailwind UI components or templates (or derivatives based on Tailwind UI components or templates) and publishing it publicly. +- Creating a React or Vue version of Tailwind UI and making it available either for sale or for free. +- Create a Figma or Sketch UI kit based on the Tailwind UI component designs. +- Creating a "website builder" project where end users can build their own websites using components or templates included with or derived from Tailwind UI. +- Creating a theme, template, or project starter kit using the components or templates and making it available either for sale or for free. +- Creating an admin panel tool (like [Laravel Nova](https://nova.laravel.com/) or [ActiveAdmin](https://activeadmin.info/)) that is made available either for sale or for free. + +In simple terms, use Tailwind UI for anything you like as long as it doesn't compete with Tailwind UI. + +### Personal License Definitions + +Licensee is the individual who has purchased a Personal License. + +Components and Templates are the source code and design assets made available to the Licensee after purchasing a Tailwind UI license. + +End Product is any artifact produced that incorporates the Components or Templates or derivatives of the Components or Templates. + +End User is a user of an End Product. + +Client is an individual or entity receiving custom professional services directly from the Licensee, produced specifically for that individual or entity. Customers of software-as-a-service products are not considered clients for the purpose of this document. + +## Team License + +Tailwind Labs Inc. grants you an on-going, non-exclusive license to use the Components and Templates. + +The license grants permission for **up to 25 Employees and Contractors of the Licensee** to access and use the Components and Templates. + +You **can**: + +- Use the Components and Templates to create unlimited End Products. +- Modify the Components and Templates to create derivative components and templates. Those components and templates are subject to this license. +- Use the Components and Templates to create unlimited End Products for unlimited Clients. +- Use the Components and Templates to create End Products where the End Product is sold to End Users. +- Use the Components and Templates to create End Products that are open source and freely available to End Users. + +You **cannot**: + +- Use the Components or Templates to create End Products that are designed to allow an End User to build their own End Products using the Components or Templates or derivatives of the Components or Templates. +- Re-distribute the Components or Templates or derivatives of the Components or Templates separately from an End Product. +- Use the Components or Templates to create End Products that are the property of any individual or entity other than the Licensee or Clients of the Licensee. +- Use the Components or Templates to produce anything that may be deemed by Tailwind Labs Inc, in their sole and absolute discretion, to be competitive or in conflict with the business of Tailwind Labs Inc. + +### Example usage + +Examples of usage **allowed** by the license: + +- Creating a website for your company. +- Creating a website or web application for a client that will be owned by that client. +- Creating a commercial SaaS application (like an invoicing app for example) where end users have to pay a fee to use the application. +- Creating a commercial self-hosted web application that is sold to end users for a one-time fee. +- Creating a web application where the primary purpose is clearly not to simply re-distribute the components or templates (like a conference organization app that uses the components or a template for its UI for example) that is free and open source, where the source code is publicly available. + +Examples of use **not allowed** by the license: + +- Creating a repository of your favorite Tailwind UI components or template (or derivatives based on Tailwind UI components or templates) and publishing it publicly. +- Creating a React or Vue version of Tailwind UI and making it available either for sale or for free. +- Creating a "website builder" project where end users can build their own websites using components or templates included with or derived from Tailwind UI. +- Creating a theme or template using the components or templates and making it available either for sale or for free. +- Creating an admin panel tool (like [Laravel Nova](https://nova.laravel.com/) or [ActiveAdmin](https://activeadmin.info/)) that is made available either for sale or for free. +- Creating any End Product that is not the sole property of either your company or a client of your company. For example your employees/contractors can't use your company Tailwind UI license to build their own websites or side projects. + +### Team License Definitions + +Licensee is the business entity who has purchased a Team License. + +Components and Templates are the source code and design assets made available to the Licensee after purchasing a Tailwind UI license. + +End Product is any artifact produced that incorporates the Components or Templates or derivatives of the Components or Templates. + +End User is a user of an End Product. + +Employee is a full-time or part-time employee of the Licensee. + +Contractor is an individual or business entity contracted to perform services for the Licensee. + +Client is an individual or entity receiving custom professional services directly from the Licensee, produced specifically for that individual or entity. Customers of software-as-a-service products are not considered clients for the purpose of this document. + +## Enforcement + +If you are found to be in violation of the license, access to your Tailwind UI account will be terminated, and a refund may be issued at our discretion. When license violation is blatant and malicious (such as intentionally redistributing the Components or Templates through private warez channels), no refund will be issued. + +The copyright of the Components and Templates is owned by Tailwind Labs Inc. You are granted only the permissions described in this license; all other rights are reserved. Tailwind Labs Inc. reserves the right to pursue legal remedies for any unauthorized use of the Components or Templates outside the scope of this license. + +## Liability + +Tailwind Labs Inc.’s liability to you for costs, damages, or other losses arising from your use of the Components or Templates — including third-party claims against you — is limited to a refund of your license fee. Tailwind Labs Inc. may not be held liable for any consequential damages related to your use of the Components or Templates. + +This Agreement is governed by the laws of the Province of Ontario and the applicable laws of Canada. Legal proceedings related to this Agreement may only be brought in the courts of Ontario. You agree to service of process at the e-mail address on your original order. + +## Questions? + +Unsure which license you need, or unsure if your use case is covered by our licenses? + +Email us at [support@tailwindui.com](mailto:support@tailwindui.com) with your questions. diff --git a/README.example.md b/README.example.md deleted file mode 100644 index defe46e9..00000000 --- a/README.example.md +++ /dev/null @@ -1,36 +0,0 @@ -# `your-project` - -Repository for `your-project`'s website. - -## Featured Aspects of the Stack - -- [TypeScript](https://www.typescriptlang.org/) -- [Next.js](https://nextjs.org/) - -## Get Started - -1. Install yarn: - - ``` - npm install -g yarn - ``` - -2. Install the dependencies with: - - ``` - yarn - ``` - -3. Start developing and watch for code changes: - - ``` - yarn dev - ``` - -## Things to Note - -- Make sure you read `.env.example` to see which environment variables you need to run the project. - ---- - -If you find you need to make extra config to make this work more seamlessly, feel free to submit a PR suggesting your changes. The goal is to get you up and running with the least steps and burden as possible. diff --git a/README.md b/README.md index 7504e269..0458925d 100644 --- a/README.md +++ b/README.md @@ -1,42 +1,35 @@ -# Replay Landing Page +# Salient -![cover](https://replay.io/images/bugslayer.jpeg) +Salient is a [Tailwind UI](https://tailwindui.com) site template built using [Tailwind CSS](https://tailwindcss.com) and [Next.js](https://nextjs.org). -Welcome to BugSlayer -- Replay's official landing page. We teamed up with our friends from Basement to create the craziest GSAP based scrolly-telling hero we've ever seen. +## Getting started -Here's a [replay](https://app.replay.io/recording/cannot-purchase-bugslayer--76c9f375-ccc9-4af9-a431-6e69e5f6e053) of the experience. We hope you enjoy! +To get started with this template, first install the npm dependencies: -## Get Started +```bash +npm install +``` -1. Install yarn: +Next, run the development server: - ``` - npm install -g yarn - ``` +```bash +npm run dev +``` -2. Install the dependencies with: +Finally, open [http://localhost:3000](http://localhost:3000) in your browser to view the website. - ``` - yarn - ``` +## Customizing -3. Start developing and watch for code changes: +You can start editing this template by modifying the files in the `/src` folder. The site will auto-update as you edit these files. - ``` - yarn dev - ``` +## License -## Important Things to Do +This site template is a commercial product and is licensed under the [Tailwind UI license](https://tailwindui.com/license). -- [ ] Check out `.env.example` for required environment variables to run the project. -- [ ] Add favicons. (Re)Place in `./public`: _32x32_ `favicon.ico`, _perfect square_ `favicon.svg` and `favicon-dark.svg` (_dark theme_), _512x512_ `icon-512.png`, _192x192_ `icon-192.png`, _180x180_ `apple-touch-icon.png`. You can use something [like this](https://realfavicongenerator.net/) for some (better to use Gimp, Photoshop, or any graphics editor; read more about it [here](https://evilmartians.com/chronicles/how-to-favicon-in-2021-six-files-that-fit-most-needs)). -- [ ] Delete `console.log(basementLog)` if not wanted — it's under `_app.tsx`. -- [ ] Replace the contents of this file (`README.md`) with the contents of the `README.example.md` file — make sure to adapt it to your project's specific needs. Finally, delete the old `README.example.md` file. +## Learn more ---- +To learn more about the technologies used in this site template, see the following resources: -If you find you need to make extra config to make this work more seamlessly, feel free to submit a PR suggesting your changes. Our focus is to get you up and running with the least steps and burden as possible. - ---- - -![cover image](https://github.com/basementstudio/next-typescript/raw/main/public/og-image.png 'We Make Cool Sh*t That Performs') +- [Tailwind CSS](https://tailwindcss.com/docs) - the official Tailwind CSS documentation +- [Next.js](https://nextjs.org/docs) - the official Next.js documentation +- [Headless UI](https://headlessui.dev) - the official Headless UI documentation diff --git a/bun.lockb b/bun.lockb deleted file mode 100755 index a3454140..00000000 Binary files a/bun.lockb and /dev/null differ diff --git a/components.json b/components.json new file mode 100644 index 00000000..49f0cb5c --- /dev/null +++ b/components.json @@ -0,0 +1,16 @@ +{ + "$schema": "https://ui.shadcn.com/schema.json", + "style": "default", + "rsc": true, + "tsx": true, + "tailwind": { + "config": "tailwind.config.ts", + "css": "src/app/globals.css", + "baseColor": "gray", + "cssVariables": false + }, + "aliases": { + "utils": "~/lib/utils", + "components": "~/components" + } +} diff --git a/index.d.ts b/index.d.ts deleted file mode 100644 index e69de29b..00000000 diff --git a/next-sitemap.js b/next-sitemap.js deleted file mode 100644 index 96137dd9..00000000 --- a/next-sitemap.js +++ /dev/null @@ -1,7 +0,0 @@ -const siteURL = new URL(process.env.NEXT_PUBLIC_SITE_URL) - -module.exports = { - siteUrl: siteURL.href, - generateRobotsTxt: true, - exclude: [] -} diff --git a/next.config.js b/next.config.js index 8fdbda30..fd46afa7 100644 --- a/next.config.js +++ b/next.config.js @@ -1,16 +1,12 @@ -const withBundleAnalyzer = require('@next/bundle-analyzer') -const withTM = require('next-transpile-modules') +const path = require('path') -/** - * @type {import('next').NextConfig} - */ -const config = { - reactStrictMode: false, - productionBrowserSourceMaps: true, - swcMinify: true, +/** @type {import('next').NextConfig} */ +const nextConfig = { images: { - formats: ['image/avif', 'image/webp'], - domains: ['dummyimage.com', 'image.mux.com'] + remotePatterns: [{ hostname: 'basehub.earth' }, { hostname: '"image-forwarder.notaku.so"' }] + }, + sassOptions: { + includePaths: [path.join(__dirname, 'src')] }, redirects() { return [ @@ -82,8 +78,7 @@ const config = { }, { source: '/oss', - destination: - 'https://docs.replay.io/docs/replay-oss-751fc053a0a14c32812c4766d7c65e4d', + destination: 'https://docs.replay.io/docs/replay-oss-751fc053a0a14c32812c4766d7c65e4d', permanent: true }, { @@ -142,8 +137,7 @@ const config = { }, { source: '/billing', - destination: - 'https://docs.replay.io/docs/billing-e01f0740cd9548f1b8725c9773b217f6', + destination: 'https://docs.replay.io/docs/billing-e01f0740cd9548f1b8725c9773b217f6', permanent: true }, { @@ -163,19 +157,7 @@ const config = { permanent: true } ] - }, - experimental: { images: { allowFutureImage: true } }, - webpack: (config) => { - /** Fix yarn linked dependencies that use react */ - config.resolve.alias.react = require('path').resolve('./node_modules/react') - return config } } -module.exports = (_phase, { defaultConfig: _ }) => { - const plugins = [ - withBundleAnalyzer({ enabled: process.env.ANALYZE === 'true' }), - withTM([]) // add modules you want to transpile here - ] - return plugins.reduce((acc, plugin) => plugin(acc), { ...config }) -} +module.exports = nextConfig diff --git a/package.json b/package.json index d4fb618a..1baa13bf 100644 --- a/package.json +++ b/package.json @@ -1,41 +1,56 @@ { - "name": "next-typescript", - "version": "1.0.0", - "description": "A minimalist boilerplate — Next.js with TypeScript.", - "repository": "https://github.com/basementstudio/next-typescript", - "author": "basement.studio", + "name": "replay-landing-page", + "version": "7.0.0", "private": true, "scripts": { - "prepare": "husky install", - "dev": "next", - "build": "next build", - "build:analyze": "cross-env ANALYZE=true yarn build", - "postbuild": "next-sitemap", - "start": "next start", - "lint": "next lint && stylelint '**/*.{css,scss}'", - "tsc": "tsc --pretty --noEmit" + "basehub-gen": "basehub --output .basehub", + "dev": "yarn basehub dev --output .basehub & next dev", + "build": "yarn basehub-gen && next build", + "start": "yarn basehub-gen && next start", + "lint": "next lint", + "playwright": "playwright test --project chromium", + "playwright:replay": "playwright test --project replay-chromium" }, + "browserslist": "defaults, not ie <= 11", "dependencies": { + "@calcom/embed-react": "^1.3.2", + "@headlessui/react": "^1.7.18", + "@headlessui/tailwindcss": "^0.2.0", + "@heroicons/react": "^2.1.3", "@juggle/resize-observer": "^3.4.0", "@mux/mux-player-react": "^2.2.0", + "@radix-ui/react-collapsible": "^1.0.3", "@radix-ui/react-dialog": "^0.1.7", + "@radix-ui/react-icons": "^1.3.0", "@radix-ui/react-navigation-menu": "^1.1.2", "@radix-ui/react-polymorphic": "^0.0.14", "@radix-ui/react-radio-group": "^1.1.2", + "@radix-ui/react-select": "^2.0.0", + "@radix-ui/react-slot": "^1.0.2", "@radix-ui/react-switch": "^0.1.5", "@radix-ui/react-tabs": "^1.0.0", + "@radix-ui/react-tooltip": "^1.0.7", "@replayio/overboard": "^0.4.1", + "@tailwindcss/forms": "^0.5.7", + "@tailwindcss/typography": "github:tailwindcss/typography", "@typeform/embed-react": "^2.22.0", - "@vercel/analytics": "^1.0.1", - "clsx": "1.1.1", + "@types/node": "^20.10.8", + "@types/react": "^18.2.47", + "@types/react-dom": "^18.2.18", + "@vercel/analytics": "^1.2.2", + "autoprefixer": "^10.4.12", + "basehub": "^4.0.3", + "class-variance-authority": "^0.7.0", + "clsx": "^2.1.0", "embla-carousel-react": "8.0.0-rc05", "global": "^4.4.0", "gsap": "./src/lib/gsap/gsap-bonus.tgz", "hls.js": "1.1.5", "lodash": "^4.17.21", "logrocket": "^4.0.3", + "lucide-react": "^0.363.0", "mousetrap": "1.6.5", - "next": "13.4", + "next": "^14.1.4", "prismjs": "^1.28.0", "react": "^18.2.0", "react-device-detect": "2.1.2", @@ -45,232 +60,30 @@ "react-merge-refs": "1.1.0", "react-use-intercom": "^5.1.4", "react-use-measure": "^2.1.1", + "tailwind-merge": "^2.2.2", + "tailwindcss": "^3.4.1", + "tailwindcss-animate": "^1.0.7", + "typescript": "^5.3.3", "zustand": "^4.3.8" }, "devDependencies": { - "@next/bundle-analyzer": "^12.1.2", - "@types/css-font-loading-module": "0.0.7", - "@types/lodash": "^4.14.182", - "@types/mousetrap": "1.6.9", - "@types/node": "17.0.21", - "@types/prismjs": "^1.26.0", - "@types/react": "^17.0.43", - "@types/react-dom": "^17.0.14", - "@typescript-eslint/eslint-plugin": "^4.33.0", - "@typescript-eslint/parser": "^4.33.0", - "babel-plugin-optimize-clsx": "^2.6.2", - "cross-env": "^7.0.3", - "eslint": "^7.32.0", - "eslint-config-next": "12.1.0", - "eslint-config-prettier": "^8.3.0", - "eslint-import-resolver-typescript": "^3.5.5", - "eslint-plugin-import": "2.25.4", - "eslint-plugin-jsx-a11y": "6.5.1", - "eslint-plugin-prettier": "^4.0.0", - "eslint-plugin-react": "7.29.2", - "eslint-plugin-react-hooks": "4.3.0", - "eslint-plugin-simple-import-sort": "7.0.0", - "husky": "^7.0.4", - "inquirer-directory": "^2.2.0", - "inspx": "^0.0.1-alpha.6", - "lint-staged": "^11.2.6", - "next-sitemap": "^2.5.14", - "next-transpile-modules": "^9.0.0", - "plop": "^3.1.1", - "prettier": "2.5.1", - "sass": "1.49.9", - "stylelint": "14.5.3", - "stylelint-config-prettier": "^9.0.3", - "stylelint-config-standard": "^23.0.0", - "stylelint-config-standard-scss": "^2.0.1", - "stylelint-prettier": "^1.2.0", - "typescript": "^4.8.4", - "use-indexed-children": "0.2.0" + "@playwright/test": "^1.37.0", + "@replayio/playwright": "2.0.0-alpha.10", + "@types/lodash": "^4.17.0", + "@types/mousetrap": "^1.6.15", + "@types/prismjs": "^1.26.3", + "eslint": "^8.56.0", + "eslint-config-next": "^14.0.4", + "eslint-config-prettier": "^9.1.0", + "eslint-plugin-prettier": "^5.1.3", + "prettier": "^3.1.1", + "prettier-plugin-tailwindcss": "^0.5.11", + "sass": "^1.72.0", + "sharp": "0.33.1" }, - "engines": { - "node": "18.x", - "yarn": "1.x" - }, - "browserslist": [ - ">0.2%", - "not dead", - "not ie <= 11", - "not op_mini all" - ], - "prettier": { - "semi": false, - "singleQuote": true, - "arrowParens": "always", - "tabWidth": 2, - "printWidth": 80, - "trailingComma": "none", - "endOfLine": "auto" - }, - "eslintConfig": { - "parser": "@typescript-eslint/parser", - "plugins": [ - "react", - "react-hooks", - "simple-import-sort", - "@typescript-eslint" - ], - "ignorePatterns": [], - "extends": [ - "eslint:recommended", - "plugin:import/recommended", - "plugin:import/typescript", - "plugin:react/recommended", - "plugin:@typescript-eslint/recommended", - "prettier", - "plugin:prettier/recommended", - "plugin:@next/next/recommended" - ], - "env": { - "es6": true, - "browser": true, - "node": true - }, - "rules": { - "react/react-in-jsx-scope": 0, - "react/display-name": 0, - "react/prop-types": 0, - "@typescript-eslint/explicit-function-return-type": 0, - "@typescript-eslint/explicit-member-accessibility": 0, - "@typescript-eslint/indent": 0, - "@typescript-eslint/member-delimiter-style": 0, - "@typescript-eslint/no-explicit-any": 0, - "@typescript-eslint/no-var-requires": 0, - "@typescript-eslint/no-use-before-define": 0, - "@typescript-eslint/ban-ts-comment": 0, - "simple-import-sort/imports": "warn", - "simple-import-sort/exports": "warn", - "react-hooks/exhaustive-deps": [ - "warn", - { - "additionalHooks": "(useIsomorphicLayoutEffect)" - } - ], - "react/no-unescaped-entities": 0, - "curly": [ - "error", - "multi-line" - ], - "react/jsx-no-target-blank": [ - 2, - { - "allowReferrer": true - } - ], - "@typescript-eslint/no-unused-vars": [ - 2, - { - "argsIgnorePattern": "^_" - } - ], - "no-console": [ - 1, - { - "allow": [ - "warn", - "error" - ] - } - ], - "prettier/prettier": [ - "warn", - { - "endOfLine": "auto" - } - ], - "@typescript-eslint/explicit-module-boundary-types": "off" - }, - "settings": { - "import/parsers": { - "@typescript-eslint/parser": [ - ".ts", - ".tsx" - ] - }, - "import/resolver": { - "typescript": { - "alwaysTryTypes": true, - "project": "." - } - }, - "react": { - "version": "detect" - } - } - }, - "stylelint": { - "ignoreFiles": [ - "**/*.{ts,tsx,js,jsx}" - ], - "extends": [ - "stylelint-config-standard", - "stylelint-config-standard-scss", - "stylelint-prettier/recommended" - ], - "plugins": [ - "stylelint-prettier" - ], - "rules": { - "scss/at-rule-no-unknown": [ - true, - { - "ignoreAtRules": [ - "tailwind", - "layer", - "apply", - "variants", - "responsive", - "screen", - "include", - "for", - "mixin", - "if", - "else", - "warn", - "return", - "function", - "use", - "each" - ] - } - ], - "selector-pseudo-class-no-unknown": [ - true, - { - "ignorePseudoClasses": [ - "global" - ] - } - ], - "property-no-unknown": [ - true, - { - "ignoreProperties": [ - "font-named-instance" - ] - } - ], - "declaration-block-trailing-semicolon": null, - "no-descending-specificity": null, - "number-leading-zero": null, - "length-zero-no-unit": null, - "alpha-value-notation": null, - "selector-id-pattern": null, - "selector-class-pattern": null, - "property-no-vendor-prefix": null, - "value-no-vendor-prefix": null, - "scss/no-global-function-names": null, - "scss/double-slash-comment-empty-line-before": null, - "scss/operator-no-newline-after": null - } - }, - "lint-staged": { - "*.@(ts|tsx|css|scss)": [ - "yarn lint --fix" - ] + "packageManager": "yarn@4.1.1", + "volta": { + "node": "20.12.0", + "yarn": "4.1.1" } } diff --git a/playwright.config.ts b/playwright.config.ts new file mode 100644 index 00000000..fbf058ff --- /dev/null +++ b/playwright.config.ts @@ -0,0 +1,64 @@ +import { defineConfig, devices } from '@playwright/test' +import { devices as replayDevices } from '@replayio/playwright' + +/** + * Read environment variables from file. + * https://github.com/motdotla/dotenv + */ +// require('dotenv').config(); + +/** + * See https://playwright.dev/docs/test-configuration. + */ +export default defineConfig({ + testDir: './tests', + + /* Run tests in files in parallel */ + fullyParallel: true, + + /* Fail the build on CI if you accidentally left test.only in the source code. */ + forbidOnly: !!process.env.CI, + + /* Retry on CI only */ + retries: process.env.CI ? 2 : 0, + + /* Opt out of parallel tests on CI. */ + workers: process.env.CI ? 1 : undefined, + + /* Reporter to use. See https://playwright.dev/docs/test-reporters */ + reporter: [ + ['line'], + [ + '@replayio/playwright/reporter', + { + apiKey: process.env.REPLAY_API_KEY, + upload: true + } + ], + ['html', { open: 'never' }] + ], + + /* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */ + use: { + trace: 'on-first-retry' + }, + + /* Configure projects for major browsers */ + projects: [ + { + name: 'chromium', + use: { ...devices['Desktop Chrome'] } + }, + { + name: 'replay-chromium', + use: { ...(replayDevices['Replay Chromium'] as any) } + } + ], + + /* Run your local dev server before starting the tests */ + webServer: { + command: 'yarn dev', + url: 'http://127.0.0.1:3000', + reuseExistingServer: !process.env.CI + } +}) diff --git a/plop-templates/component.hbs b/plop-templates/component.hbs deleted file mode 100644 index 0278ba97..00000000 --- a/plop-templates/component.hbs +++ /dev/null @@ -1,15 +0,0 @@ -import { FC } from 'react' - -import s from './{{dashedcase name}}.module.{{#if hasSass}}scss{{else}}css{{/if}}' - -type {{pascalcase name}}Props = { - -} - -export const {{pascalcase name}}: FC<{{pascalcase name}}Props> = () => { - return ( -
- -
- ) -} diff --git a/plopfile.js b/plopfile.js deleted file mode 100644 index 30676034..00000000 --- a/plopfile.js +++ /dev/null @@ -1,68 +0,0 @@ -/* - How to use this utility? - - Execute the plop command on the terminal followed by one of the available generators: - - component - - Example: "yarn plop component" - - All the template files are under ~/plop-templates. Plops templates use Handlebars. - - Plop Documentation: https://plopjs.com/documentation/ - Handlebars Documentation: https://handlebarsjs.com/guide/ -*/ -const package = require('./package.json') - -const COMPONENTS_DIR_BASEPATH = './src/components' -const HAS_SASS = !!package.dependencies.sass || !!package.devDependencies.sass - -module.exports = function (plop) { - /* Register plugin */ - plop.setPrompt('directory', require('inquirer-directory')) - - /* Register helpers */ - plop.setHelper('pascalcase', (text) => - text.replace(/(^\w|-\w)/g, (text) => text.replace(/-/, '').toUpperCase()) - ) - plop.setHelper('dashedcase', (text) => - text.replace(/(? + + diff --git a/public/images/hero-logos/apollo-graphql.svg.svg b/public/images/hero-logos/apollo-graphql.svg.svg new file mode 100644 index 00000000..be4d5ffd --- /dev/null +++ b/public/images/hero-logos/apollo-graphql.svg.svg @@ -0,0 +1,3 @@ + + + diff --git a/public/images/hero-logos/apollo.svg b/public/images/hero-logos/apollo.svg new file mode 100644 index 00000000..543d7fb2 --- /dev/null +++ b/public/images/hero-logos/apollo.svg @@ -0,0 +1,3 @@ + + + diff --git a/public/images/hero-logos/code-sandbox.png b/public/images/hero-logos/code-sandbox.png new file mode 100644 index 00000000..9e7bd9c0 Binary files /dev/null and b/public/images/hero-logos/code-sandbox.png differ diff --git a/public/images/hero-logos/code-sandbox.svg b/public/images/hero-logos/code-sandbox.svg new file mode 100644 index 00000000..1d7e33d9 --- /dev/null +++ b/public/images/hero-logos/code-sandbox.svg @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/public/images/hero-logos/codesandbox.svg b/public/images/hero-logos/codesandbox.svg new file mode 100644 index 00000000..8b8375bf --- /dev/null +++ b/public/images/hero-logos/codesandbox.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/public/images/hero-logos/glide.png b/public/images/hero-logos/glide.png new file mode 100644 index 00000000..52abe3a7 Binary files /dev/null and b/public/images/hero-logos/glide.png differ diff --git a/public/images/hero-logos/glide.svg b/public/images/hero-logos/glide.svg new file mode 100644 index 00000000..9932f0f0 --- /dev/null +++ b/public/images/hero-logos/glide.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/public/images/hero-logos/laravel.svg b/public/images/hero-logos/laravel.svg new file mode 100644 index 00000000..bfa63bd4 --- /dev/null +++ b/public/images/hero-logos/laravel.svg @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + diff --git a/public/images/hero-logos/metabase.svg b/public/images/hero-logos/metabase.svg new file mode 100644 index 00000000..98337533 --- /dev/null +++ b/public/images/hero-logos/metabase.svg @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/images/hero-logos/mirage.svg b/public/images/hero-logos/mirage.svg new file mode 100644 index 00000000..204df737 --- /dev/null +++ b/public/images/hero-logos/mirage.svg @@ -0,0 +1,17 @@ + + + + + + + + + + + + + diff --git a/public/images/hero-logos/react.svg b/public/images/hero-logos/react.svg new file mode 100644 index 00000000..37384a92 --- /dev/null +++ b/public/images/hero-logos/react.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/public/images/hero-logos/statamic.svg b/public/images/hero-logos/statamic.svg new file mode 100644 index 00000000..25d7ba6c --- /dev/null +++ b/public/images/hero-logos/statamic.svg @@ -0,0 +1,12 @@ + + + + + + + + + + diff --git a/public/images/hero-logos/statickit.svg b/public/images/hero-logos/statickit.svg new file mode 100644 index 00000000..381d21e7 --- /dev/null +++ b/public/images/hero-logos/statickit.svg @@ -0,0 +1,5 @@ + + + diff --git a/public/images/hero-logos/transistor.svg b/public/images/hero-logos/transistor.svg new file mode 100644 index 00000000..2b858cf4 --- /dev/null +++ b/public/images/hero-logos/transistor.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + diff --git a/public/images/hero-logos/tuple.svg b/public/images/hero-logos/tuple.svg new file mode 100644 index 00000000..2a9c2415 --- /dev/null +++ b/public/images/hero-logos/tuple.svg @@ -0,0 +1,13 @@ + + + + + + diff --git a/public/images/hero-logos/vercel.svg b/public/images/hero-logos/vercel.svg new file mode 100644 index 00000000..275f4139 --- /dev/null +++ b/public/images/hero-logos/vercel.svg @@ -0,0 +1,3 @@ + + + diff --git a/public/images/hero-logos/weights-and-biases.svg b/public/images/hero-logos/weights-and-biases.svg new file mode 100644 index 00000000..b1df6bea --- /dev/null +++ b/public/images/hero-logos/weights-and-biases.svg @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/public/images/homepage/check-out-this-replay.svg b/public/images/homepage/check-out-this-replay.svg new file mode 100644 index 00000000..b625d219 --- /dev/null +++ b/public/images/homepage/check-out-this-replay.svg @@ -0,0 +1,4 @@ + + + + diff --git a/public/images/homepage/testimonials/pantheon.png b/public/images/homepage/testimonials/pantheon.png deleted file mode 100644 index cd65eb68..00000000 Binary files a/public/images/homepage/testimonials/pantheon.png and /dev/null differ diff --git a/public/images/homepage/testimonials/tablecheck.png b/public/images/homepage/testimonials/tablecheck.png deleted file mode 100644 index 41b4306b..00000000 Binary files a/public/images/homepage/testimonials/tablecheck.png and /dev/null differ diff --git a/public/images/logan.png b/public/images/logan.png new file mode 100644 index 00000000..f4cc01ad Binary files /dev/null and b/public/images/logan.png differ diff --git a/public/images/logo-flake.svg b/public/images/logo-flake.svg new file mode 100644 index 00000000..ba20e279 --- /dev/null +++ b/public/images/logo-flake.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/public/images/logo-pass.svg b/public/images/logo-pass.svg new file mode 100644 index 00000000..01bfb150 --- /dev/null +++ b/public/images/logo-pass.svg @@ -0,0 +1,12 @@ + + + + + + + + + + + + diff --git a/public/images/logo.svg b/public/images/logo.svg new file mode 100644 index 00000000..337b2ad5 --- /dev/null +++ b/public/images/logo.svg @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/public/images/logos/apollo.svg b/public/images/logos/apollo.svg new file mode 100644 index 00000000..e8f93ef7 --- /dev/null +++ b/public/images/logos/apollo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/public/images/logos/metabase.svg b/public/images/logos/metabase.svg new file mode 100644 index 00000000..82584726 --- /dev/null +++ b/public/images/logos/metabase.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/public/images/logos/react.svg b/public/images/logos/react.svg new file mode 100644 index 00000000..3d5d391d --- /dev/null +++ b/public/images/logos/react.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/public/images/logos/vercel.svg b/public/images/logos/vercel.svg new file mode 100644 index 00000000..a45579fe --- /dev/null +++ b/public/images/logos/vercel.svg @@ -0,0 +1,41 @@ + + + + + + diff --git a/public/images/logos/weights-and-biases.svg b/public/images/logos/weights-and-biases.svg new file mode 100644 index 00000000..9f758847 --- /dev/null +++ b/public/images/logos/weights-and-biases.svg @@ -0,0 +1,106 @@ + + + + + + + + + + + + + + + + + + diff --git a/public/images/screenshots/add-console-logs.png b/public/images/screenshots/add-console-logs.png new file mode 100644 index 00000000..8df783a6 Binary files /dev/null and b/public/images/screenshots/add-console-logs.png differ diff --git a/public/images/screenshots/bg-course.png b/public/images/screenshots/bg-course.png new file mode 100644 index 00000000..07c4d9f8 Binary files /dev/null and b/public/images/screenshots/bg-course.png differ diff --git a/public/images/screenshots/contacts.png b/public/images/screenshots/contacts.png new file mode 100644 index 00000000..5901470b Binary files /dev/null and b/public/images/screenshots/contacts.png differ diff --git a/public/images/screenshots/content-1.png b/public/images/screenshots/content-1.png new file mode 100644 index 00000000..34a3e395 Binary files /dev/null and b/public/images/screenshots/content-1.png differ diff --git a/public/images/screenshots/content-2.png b/public/images/screenshots/content-2.png new file mode 100644 index 00000000..172b0845 Binary files /dev/null and b/public/images/screenshots/content-2.png differ diff --git a/public/images/screenshots/content-3.png b/public/images/screenshots/content-3.png new file mode 100644 index 00000000..36a78d07 Binary files /dev/null and b/public/images/screenshots/content-3.png differ diff --git a/public/images/screenshots/course-thumbnail.png b/public/images/screenshots/course-thumbnail.png new file mode 100644 index 00000000..c34a8c2c Binary files /dev/null and b/public/images/screenshots/course-thumbnail.png differ diff --git a/public/images/screenshots/dashboard-view.png b/public/images/screenshots/dashboard-view.png new file mode 100644 index 00000000..0c4667dc Binary files /dev/null and b/public/images/screenshots/dashboard-view.png differ diff --git a/public/images/screenshots/expenses.png b/public/images/screenshots/expenses.png new file mode 100644 index 00000000..ca35472e Binary files /dev/null and b/public/images/screenshots/expenses.png differ diff --git a/public/images/screenshots/inspect-react-components.png b/public/images/screenshots/inspect-react-components.png new file mode 100644 index 00000000..989c7cdc Binary files /dev/null and b/public/images/screenshots/inspect-react-components.png differ diff --git a/public/images/screenshots/inventory.png b/public/images/screenshots/inventory.png new file mode 100644 index 00000000..b98721c6 Binary files /dev/null and b/public/images/screenshots/inventory.png differ diff --git a/public/images/screenshots/jump-to-test-steps.png b/public/images/screenshots/jump-to-test-steps.png new file mode 100644 index 00000000..2fe21f45 Binary files /dev/null and b/public/images/screenshots/jump-to-test-steps.png differ diff --git a/public/images/screenshots/payroll.png b/public/images/screenshots/payroll.png new file mode 100644 index 00000000..16f5b5a7 Binary files /dev/null and b/public/images/screenshots/payroll.png differ diff --git a/public/images/screenshots/pr-comments.png b/public/images/screenshots/pr-comments.png new file mode 100644 index 00000000..fe9977e3 Binary files /dev/null and b/public/images/screenshots/pr-comments.png differ diff --git a/public/images/screenshots/profit-loss.png b/public/images/screenshots/profit-loss.png new file mode 100644 index 00000000..229df78a Binary files /dev/null and b/public/images/screenshots/profit-loss.png differ diff --git a/public/images/screenshots/rca-1.png b/public/images/screenshots/rca-1.png new file mode 100644 index 00000000..feecc032 Binary files /dev/null and b/public/images/screenshots/rca-1.png differ diff --git a/public/images/screenshots/reporting.png b/public/images/screenshots/reporting.png new file mode 100644 index 00000000..72b5e8e9 Binary files /dev/null and b/public/images/screenshots/reporting.png differ diff --git a/public/images/screenshots/runs-view.png b/public/images/screenshots/runs-view.png new file mode 100644 index 00000000..cf8f9473 Binary files /dev/null and b/public/images/screenshots/runs-view.png differ diff --git a/public/images/screenshots/tests-view.png b/public/images/screenshots/tests-view.png new file mode 100644 index 00000000..1a4bf53d Binary files /dev/null and b/public/images/screenshots/tests-view.png differ diff --git a/public/images/screenshots/vat-returns.png b/public/images/screenshots/vat-returns.png new file mode 100644 index 00000000..3dd043bd Binary files /dev/null and b/public/images/screenshots/vat-returns.png differ diff --git a/public/images/screenshots/view-network-requests.png b/public/images/screenshots/view-network-requests.png new file mode 100644 index 00000000..6dfca51a Binary files /dev/null and b/public/images/screenshots/view-network-requests.png differ diff --git a/public/images/team/brian.png b/public/images/team/brian.png new file mode 100644 index 00000000..150b0ba3 Binary files /dev/null and b/public/images/team/brian.png differ diff --git a/public/images/team/colin.png b/public/images/team/colin.png new file mode 100644 index 00000000..4d772da0 Binary files /dev/null and b/public/images/team/colin.png differ diff --git a/public/images/team/dan.png b/public/images/team/dan.png new file mode 100644 index 00000000..bc4e27e7 Binary files /dev/null and b/public/images/team/dan.png differ diff --git a/public/images/team/domi.png b/public/images/team/domi.png new file mode 100644 index 00000000..69e89c37 Binary files /dev/null and b/public/images/team/domi.png differ diff --git a/public/images/team/holger.png b/public/images/team/holger.png new file mode 100644 index 00000000..4ead240f Binary files /dev/null and b/public/images/team/holger.png differ diff --git a/public/images/team/jason.png b/public/images/team/jason.png new file mode 100644 index 00000000..87bfdc3e Binary files /dev/null and b/public/images/team/jason.png differ diff --git a/public/images/team/jon.png b/public/images/team/jon.png new file mode 100644 index 00000000..77513567 Binary files /dev/null and b/public/images/team/jon.png differ diff --git a/public/images/team/kannan.png b/public/images/team/kannan.png new file mode 100644 index 00000000..fc07720e Binary files /dev/null and b/public/images/team/kannan.png differ diff --git a/public/images/team/logan.jpeg b/public/images/team/logan.jpeg new file mode 100644 index 00000000..59ab2d2f Binary files /dev/null and b/public/images/team/logan.jpeg differ diff --git a/public/images/team/mark.png b/public/images/team/mark.png new file mode 100644 index 00000000..c5c66600 Binary files /dev/null and b/public/images/team/mark.png differ diff --git a/public/images/team/miriam.png b/public/images/team/miriam.png new file mode 100644 index 00000000..64f51420 Binary files /dev/null and b/public/images/team/miriam.png differ diff --git a/public/images/team/ryan.png b/public/images/team/ryan.png new file mode 100644 index 00000000..c6e66f91 Binary files /dev/null and b/public/images/team/ryan.png differ diff --git a/public/images/team/sophie.png b/public/images/team/sophie.png new file mode 100644 index 00000000..80b30aa2 Binary files /dev/null and b/public/images/team/sophie.png differ diff --git a/public/images/team/vaughn.jpeg b/public/images/team/vaughn.jpeg new file mode 100644 index 00000000..5c02c0d7 Binary files /dev/null and b/public/images/team/vaughn.jpeg differ diff --git a/public/images/testimonials/alex.png b/public/images/testimonials/alex.png new file mode 100644 index 00000000..b1534ca1 Binary files /dev/null and b/public/images/testimonials/alex.png differ diff --git a/public/images/testimonials/algodaily.png b/public/images/testimonials/algodaily.png new file mode 100644 index 00000000..acebf849 Binary files /dev/null and b/public/images/testimonials/algodaily.png differ diff --git a/public/images/testimonials/amjad.png b/public/images/testimonials/amjad.png new file mode 100644 index 00000000..fc2d4dd7 Binary files /dev/null and b/public/images/testimonials/amjad.png differ diff --git a/public/images/testimonials/cypress.png b/public/images/testimonials/cypress.png new file mode 100644 index 00000000..1bb736f7 Binary files /dev/null and b/public/images/testimonials/cypress.png differ diff --git a/public/images/testimonials/dan-abramov.png b/public/images/testimonials/dan-abramov.png new file mode 100644 index 00000000..906ea441 Binary files /dev/null and b/public/images/testimonials/dan-abramov.png differ diff --git a/public/images/testimonials/david.png b/public/images/testimonials/david.png new file mode 100644 index 00000000..a26921d1 Binary files /dev/null and b/public/images/testimonials/david.png differ diff --git a/public/images/testimonials/dom.png b/public/images/testimonials/dom.png new file mode 100644 index 00000000..fe1c18c5 Binary files /dev/null and b/public/images/testimonials/dom.png differ diff --git a/public/images/testimonials/erik.png b/public/images/testimonials/erik.png new file mode 100644 index 00000000..6b499c9f Binary files /dev/null and b/public/images/testimonials/erik.png differ diff --git a/public/images/testimonials/gleb.jpg b/public/images/testimonials/gleb.jpg new file mode 100644 index 00000000..2dbe0d2d Binary files /dev/null and b/public/images/testimonials/gleb.jpg differ diff --git a/public/images/testimonials/glide-apps.png b/public/images/testimonials/glide-apps.png new file mode 100644 index 00000000..3f38bb70 Binary files /dev/null and b/public/images/testimonials/glide-apps.png differ diff --git a/public/images/testimonials/glide.png b/public/images/testimonials/glide.png new file mode 100644 index 00000000..1fc7619f Binary files /dev/null and b/public/images/testimonials/glide.png differ diff --git a/public/images/testimonials/guillermo-rauch.jpg b/public/images/testimonials/guillermo-rauch.jpg new file mode 100644 index 00000000..d34256d0 Binary files /dev/null and b/public/images/testimonials/guillermo-rauch.jpg differ diff --git a/public/images/testimonials/harald.jpg b/public/images/testimonials/harald.jpg new file mode 100644 index 00000000..2a625774 Binary files /dev/null and b/public/images/testimonials/harald.jpg differ diff --git a/public/images/testimonials/ives.png b/public/images/testimonials/ives.png new file mode 100644 index 00000000..3c157320 Binary files /dev/null and b/public/images/testimonials/ives.png differ diff --git a/public/images/testimonials/jacob.jpg b/public/images/testimonials/jacob.jpg new file mode 100644 index 00000000..eb3d88c0 Binary files /dev/null and b/public/images/testimonials/jacob.jpg differ diff --git a/public/images/testimonials/jj-kasper.png b/public/images/testimonials/jj-kasper.png new file mode 100644 index 00000000..0b741a09 Binary files /dev/null and b/public/images/testimonials/jj-kasper.png differ diff --git a/public/images/testimonials/kenneth.jpg b/public/images/testimonials/kenneth.jpg new file mode 100644 index 00000000..7847fb74 Binary files /dev/null and b/public/images/testimonials/kenneth.jpg differ diff --git a/public/images/testimonials/lenz.png b/public/images/testimonials/lenz.png new file mode 100644 index 00000000..4d7a7288 Binary files /dev/null and b/public/images/testimonials/lenz.png differ diff --git a/public/images/testimonials/mark-erikson.png b/public/images/testimonials/mark-erikson.png new file mode 100644 index 00000000..3b25972c Binary files /dev/null and b/public/images/testimonials/mark-erikson.png differ diff --git a/public/images/testimonials/mark-probst.jpg b/public/images/testimonials/mark-probst.jpg new file mode 100644 index 00000000..b1093d74 Binary files /dev/null and b/public/images/testimonials/mark-probst.jpg differ diff --git a/public/images/testimonials/mateusz.png b/public/images/testimonials/mateusz.png new file mode 100644 index 00000000..fa83e52a Binary files /dev/null and b/public/images/testimonials/mateusz.png differ diff --git a/public/images/testimonials/matt.png b/public/images/testimonials/matt.png new file mode 100644 index 00000000..6166045c Binary files /dev/null and b/public/images/testimonials/matt.png differ diff --git a/public/images/testimonials/pantheon.png b/public/images/testimonials/pantheon.png new file mode 100644 index 00000000..b3b7b201 Binary files /dev/null and b/public/images/testimonials/pantheon.png differ diff --git a/public/images/testimonials/percy.png b/public/images/testimonials/percy.png new file mode 100644 index 00000000..cc5e6f18 Binary files /dev/null and b/public/images/testimonials/percy.png differ diff --git a/public/images/testimonials/rauch-g.png b/public/images/testimonials/rauch-g.png new file mode 100644 index 00000000..749442b1 Binary files /dev/null and b/public/images/testimonials/rauch-g.png differ diff --git a/public/images/testimonials/ryan-carniato.png b/public/images/testimonials/ryan-carniato.png new file mode 100644 index 00000000..1523fdcb Binary files /dev/null and b/public/images/testimonials/ryan-carniato.png differ diff --git a/public/images/testimonials/sebastian.png b/public/images/testimonials/sebastian.png new file mode 100644 index 00000000..3534ab3b Binary files /dev/null and b/public/images/testimonials/sebastian.png differ diff --git a/public/images/testimonials/shane.jpg b/public/images/testimonials/shane.jpg new file mode 100644 index 00000000..1bd7ed51 Binary files /dev/null and b/public/images/testimonials/shane.jpg differ diff --git a/public/images/testimonials/shawn.png b/public/images/testimonials/shawn.png new file mode 100644 index 00000000..fe1e5179 Binary files /dev/null and b/public/images/testimonials/shawn.png differ diff --git a/public/images/testimonials/simeon.jpg b/public/images/testimonials/simeon.jpg new file mode 100644 index 00000000..5e71d473 Binary files /dev/null and b/public/images/testimonials/simeon.jpg differ diff --git a/public/images/testimonials/stripe.png b/public/images/testimonials/stripe.png new file mode 100644 index 00000000..d49746bb Binary files /dev/null and b/public/images/testimonials/stripe.png differ diff --git a/public/images/testimonials/tablecheck.png b/public/images/testimonials/tablecheck.png new file mode 100644 index 00000000..bada21f0 Binary files /dev/null and b/public/images/testimonials/tablecheck.png differ diff --git a/public/images/testimonials/tim-haines.jpg b/public/images/testimonials/tim-haines.jpg new file mode 100644 index 00000000..ac1b158d Binary files /dev/null and b/public/images/testimonials/tim-haines.jpg differ diff --git a/public/images/testimonials/tim-neutkins.png b/public/images/testimonials/tim-neutkins.png new file mode 100644 index 00000000..ddbdb4aa Binary files /dev/null and b/public/images/testimonials/tim-neutkins.png differ diff --git a/public/images/testimonials/vs-code.png b/public/images/testimonials/vs-code.png new file mode 100644 index 00000000..5064fe6c Binary files /dev/null and b/public/images/testimonials/vs-code.png differ diff --git a/public/images/testimonials/zack-rosen.jpg b/public/images/testimonials/zack-rosen.jpg new file mode 100644 index 00000000..18420e3d Binary files /dev/null and b/public/images/testimonials/zack-rosen.jpg differ diff --git a/public/images/vamsi.jpeg b/public/images/vamsi.jpeg new file mode 100644 index 00000000..7a37405e Binary files /dev/null and b/public/images/vamsi.jpeg differ diff --git a/public/og-image.png b/public/og-image.png index 49a52f41..6c8cdf30 100644 Binary files a/public/og-image.png and b/public/og-image.png differ diff --git a/public/site.webmanifest b/public/site.webmanifest index b20abb7c..fa99de77 100644 --- a/public/site.webmanifest +++ b/public/site.webmanifest @@ -1,19 +1,19 @@ { - "name": "", - "short_name": "", - "icons": [ - { - "src": "/android-chrome-192x192.png", - "sizes": "192x192", - "type": "image/png" - }, - { - "src": "/android-chrome-512x512.png", - "sizes": "512x512", - "type": "image/png" - } - ], - "theme_color": "#ffffff", - "background_color": "#ffffff", - "display": "standalone" + "name": "", + "short_name": "", + "icons": [ + { + "src": "/android-chrome-192x192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "/android-chrome-512x512.png", + "sizes": "512x512", + "type": "image/png" + } + ], + "theme_color": "#ffffff", + "background_color": "#ffffff", + "display": "standalone" } diff --git a/src/app/(auth)/contact/page.tsx b/src/app/(auth)/contact/page.tsx new file mode 100644 index 00000000..9024b094 --- /dev/null +++ b/src/app/(auth)/contact/page.tsx @@ -0,0 +1,26 @@ +import { Metadata } from 'next' +import { Footer } from '~/components/Footer' +import { Header } from '~/components/Header' +import Script from 'next/script' + +import ContactForm from '~/components/sections/contact/ContactForm' + +export const metadata: Metadata = { + title: 'Contact' +} + +const Contact = () => { + return ( + <> + + ) +} diff --git a/src/lib/api-responses.ts b/src/lib/api-responses.ts index 3767d4e4..4248fd7e 100644 --- a/src/lib/api-responses.ts +++ b/src/lib/api-responses.ts @@ -4,25 +4,16 @@ import { formatError } from './utils' // Some helpers for usual http responses -export function success( - res: NextApiResponse, - json: { [key: string]: unknown } = {} -) { +export function success(res: NextApiResponse, json: { [key: string]: unknown } = {}) { return res.status(200).json(json) } -export function badRequest( - res: NextApiResponse, - error: unknown = 'Bad Request' -) { +export function badRequest(res: NextApiResponse, error: unknown = 'Bad Request') { console.error(error) return res.status(400).json({ error: formatError(error) }) } -export function notAuthorized( - res: NextApiResponse, - error: unknown = 'Not Authorized' -) { +export function notAuthorized(res: NextApiResponse, error: unknown = 'Not Authorized') { console.error(error) return res.status(401).json({ error: formatError(error) }) } @@ -32,11 +23,7 @@ export function notFound(res: NextApiResponse, error: unknown = 'Not Found') { return res.status(404).json({ error: formatError(error) }) } -export function internalServerError( - res: NextApiResponse, - error: unknown, - code = 500 -) { +export function internalServerError(res: NextApiResponse, error: unknown, code = 500) { console.error(error) return res.status(code).json({ error: formatError(error) }) } diff --git a/src/lib/basehub-queries.ts b/src/lib/basehub-queries.ts new file mode 100644 index 00000000..dbefcec5 --- /dev/null +++ b/src/lib/basehub-queries.ts @@ -0,0 +1,174 @@ +import { fragmentOn } from '.basehub' +import { link } from 'fs' + +export const linkFragment = fragmentOn('LinkComponent', { + _id: true, + href: true, + label: true, + variant: true +}) + +export const landingPageFragment = fragmentOn('LandingPage', { + hero: { + subtitle: { + json: { content: true } + }, + getStartedLink: linkFragment, + contactUsLink: linkFragment, + logosTitle: true, + testimonials: { + items: { + testimonial: { + name: true, + title: true, + quote: { + json: { content: true } + }, + image: true + } + } + } + }, + devTools: { + title: true, + subTitle: true, + replayUrl: true, + features: { + items: { + _title: true, + subTitle: true, + image: true, + video: true, + type: true + } + } + }, + testSuites: { + title: true, + subTitle: true, + superTitle: true, + features: { + items: { + _title: true, + subtitle: true, + description: true, + image: true + } + } + }, + faq: { + title: true, + subTitle: true, + questions: { + items: { + _title: true, + summary: true, + href: true, + logos: true + } + } + }, + cta: { + title: true, + getStartedLink: linkFragment + }, + dynamicAnalysis: { + title: true, + subtitle: true, + description: true, + features: { + items: { + _title: true, + feature: { json: { content: true } }, + icon: true + } + } + }, + testimonials: { + title: true, + subtitle: true, + caseStudyTitle: true, + caseStudySubTitle: true, + caseStudies: { + items: { + _title: true, + name: true, + handle: true, + quote: true, + image: true, + logo: true, + url: true + } + }, + testimonials: { + items: { + _title: true, + title: true, + quote: true, + image: true, + featured: true + } + } + }, + content: { + title: true, + subTitle: { json: { content: true } }, + blog: { + items: { + title: true, + href: true, + description: true, + imageUrl: true + } + }, + course: { + title: true, + description: true, + getStarted: linkFragment, + course: { + items: { + _title: true, + title: true, + href: true, + duration: true + } + } + } + } +}) + +export const pricingPageFragment = fragmentOn('PricingPage', { + hero: { + title: { + left: true, + right: true + }, + label: true, + description: { json: { content: true } } + }, + faq: { + title: true, + questions: { + items: { + _title: true, + answer: true + } + } + } +}) + +export const aboutPageFragment = fragmentOn('AboutPage', { + hero: { + title: true, + subTitle: true, + title1: true, + description1: { json: { content: true } }, + title2: true, + description2: { json: { content: true } } + } +}) + +export type LandingPageFragment = fragmentOn.infer +export type LinkFragment = fragmentOn.infer +export type PricingPageFragment = fragmentOn.infer +export type AboutPageFragment = fragmentOn.infer diff --git a/src/lib/constants.ts b/src/lib/constants.ts index 6361537e..23af5a0b 100644 --- a/src/lib/constants.ts +++ b/src/lib/constants.ts @@ -4,7 +4,10 @@ export const isProd = process.env.NODE_ENV === 'production' export const isClient = typeof document !== 'undefined' export const isServer = !isClient -if (typeof process.env.NEXT_PUBLIC_SITE_URL !== 'string') { +if ( + typeof process.env.NEXT_PUBLIC_SITE_URL !== 'string' && + typeof process.env.NEXT_PUBLIC_VERCEL_URL !== 'string' +) { throw new Error( `Please set the NEXT_PUBLIC_SITE_URL environment variable to your site's URL. @@ -15,7 +18,9 @@ if (typeof process.env.NEXT_PUBLIC_SITE_URL !== 'string') { ) } -export const siteURL = new URL(process.env.NEXT_PUBLIC_SITE_URL) +export const siteURL = new URL( + process.env.NEXT_PUBLIC_SITE_URL ?? `https://${process.env.NEXT_PUBLIC_VERCEL_URL}` +) export const siteOrigin = siteURL.origin // we like putting this in the JavaScript console, diff --git a/src/lib/feature-flags.ts b/src/lib/feature-flags.ts new file mode 100644 index 00000000..229f2769 --- /dev/null +++ b/src/lib/feature-flags.ts @@ -0,0 +1,4 @@ +export const featureFlags = { + showCalculator: false, + showTestSuiteTestimonials: true +} diff --git a/src/lib/ga.tsx b/src/lib/ga.tsx deleted file mode 100644 index 6ab6f7c1..00000000 --- a/src/lib/ga.tsx +++ /dev/null @@ -1,80 +0,0 @@ -import { useRouter } from 'next/router' -import Script from 'next/script' -import * as React from 'react' - -import { gaTrackingId } from './constants' - -declare global { - interface Window { - gtag: undefined | ((...args: any[]) => void) - } -} - -// https://developers.google.com/analytics/devguides/collection/gtagjs/pages -export const pageview = (url: string) => { - if (!window.gtag) { - console.warn('window.gtag is not defined') - return - } - window.gtag('config', gaTrackingId, { - page_path: url - }) -} - -// https://developers.google.com/analytics/devguides/collection/gtagjs/events -export const event = ({ - action, - category, - label, - value -}: { - action: string - category: string - label: string - value: string -}) => { - if (!window.gtag) { - console.warn('window.gtag is not defined') - return - } - window.gtag('event', action, { - event_category: category, - event_label: label, - value: value - }) -} - -// Put this in _document.tsx -export const GAScripts = () => { - return ( - <> - - - {getLayout({ Component, pageProps, ...rest })} - - ) -} - -/* APP HOOKS */ - -const useOverflowDebuggerInDev = () => { - React.useEffect(() => { - if (!isDev) return - let mousetrapRef: Mousetrap.MousetrapInstance | undefined = undefined - import('mousetrap').then(({ default: mousetrap }) => { - mousetrapRef = mousetrap.bind(['command+i', 'ctrl+i', 'alt+i'], () => { - document.body.classList.toggle('inspect') - }) - }) - - return () => { - mousetrapRef?.unbind(['command+i', 'ctrl+i', 'alt+i']) - } - }, []) -} - -const useUserIsTabbing = () => { - React.useEffect(() => { - function handleKeyDown(event: KeyboardEvent) { - if (event.code === `Tab`) { - document.body.classList.add('user-is-tabbing') - } - } - - function handleMouseDown() { - document.body.classList.remove('user-is-tabbing') - } - - window.addEventListener('keydown', handleKeyDown) - window.addEventListener('mousedown', handleMouseDown) - return () => { - window.removeEventListener('keydown', handleKeyDown) - window.removeEventListener('mousedown', handleMouseDown) - } - }, []) -} - -const usePauseAnimationOnTabChange = () => { - const { setTabIsFocused } = useAppStore() - - React.useEffect(() => { - const handleVisibilityChange = () => { - setTabIsFocused(document.visibilityState === 'visible') - } - - window.addEventListener('visibilitychange', handleVisibilityChange) - - return () => - window.removeEventListener('visibilitychange', handleVisibilityChange) - }, [setTabIsFocused]) -} - -const setMobileVh = () => { - const vh = window.innerHeight * 0.01 - document.documentElement.style.setProperty('--vh', `${vh}px`) -} - -const useMobileVh = () => { - React.useEffect(() => { - setMobileVh() - window.addEventListener('resize', setMobileVh) - - return () => { - window.removeEventListener('resize', setMobileVh) - } - }, []) -} - -/* TYPES */ - -export type Page

> = NextComponentType< - NextPageContext, - Record, - P -> & { getLayout?: GetLayoutFn

} - -export type GetLayoutFn

> = ( - props: Omit, 'pageProps'> & { pageProps: P } -) => React.ReactNode - -/* EXPORT */ - -export default App diff --git a/src/pages/_document.tsx b/src/pages/_document.tsx deleted file mode 100644 index dc2d14ad..00000000 --- a/src/pages/_document.tsx +++ /dev/null @@ -1,28 +0,0 @@ -import Document, { - DocumentContext, - Head, - Html, - Main, - NextScript -} from 'next/document' - -class MyDocument extends Document { - static async getInitialProps(ctx: DocumentContext) { - const initialProps = await Document.getInitialProps(ctx) - return { ...initialProps } - } - - render() { - return ( - - - -

- - - - ) - } -} - -export default MyDocument diff --git a/src/pages/_tests.tsx b/src/pages/_tests.tsx deleted file mode 100644 index 44c1c3cd..00000000 --- a/src/pages/_tests.tsx +++ /dev/null @@ -1,15 +0,0 @@ -import { Meta } from '~/components/common/meta' -import { PageLayout } from '~/components/layout/page' -import { Hero } from '~/components/sections/tests/hero' - -const Tests = () => { - return ( - - - - - - ) -} - -export default Tests diff --git a/src/pages/about.tsx b/src/pages/about.tsx deleted file mode 100644 index 1fff308b..00000000 --- a/src/pages/about.tsx +++ /dev/null @@ -1,22 +0,0 @@ -import { Meta } from '~/components/common/meta' -import { PageLayout } from '~/components/layout/page' -import { Hero } from '~/components/sections/about/hero' -import { Investors } from '~/components/sections/about/investors' -import { Team } from '~/components/sections/about/team' -import { Work } from '~/components/sections/about/work' - -const About = () => { - return ( - - - - - - -
-
-
- ) -} - -export default About diff --git a/src/pages/branding.tsx b/src/pages/branding.tsx deleted file mode 100644 index 70cb08cc..00000000 --- a/src/pages/branding.tsx +++ /dev/null @@ -1,30 +0,0 @@ -import { Meta } from '~/components/common/meta' -import { PageLayout } from '~/components/layout/page' -import { TitleAndSubtitle } from '~/components/primitives/texts' -import s from '~/components/sections/branding/branding.module.scss' -import LogoDownloadWidget from '~/components/sections/branding/LogoDownloadWidget' -import StyleGuide from '~/components/sections/branding/StyleGuide' - -const Branding = () => { - return ( - - - - - - - - - ) -} - -export default Branding diff --git a/src/pages/contact.tsx b/src/pages/contact.tsx deleted file mode 100644 index d47f2818..00000000 --- a/src/pages/contact.tsx +++ /dev/null @@ -1,27 +0,0 @@ -import Script from 'next/script' - -import { Meta } from '~/components/common/meta' -import { PageLayout } from '~/components/layout/page' -import ContactForm from '~/components/sections/contact/ContactForm' - -const Contact = () => { - return ( - <> -