diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..8fbac2b --- /dev/null +++ b/.dockerignore @@ -0,0 +1,26 @@ +# Versioning and metadata +.git +.vscode +.gitignore +.dockerignore + +# Build dependencies +dist +/node_modules + +# code formatter +.editorconfig +.eslintignore +.eslintrc.json +.huskyrc +.lintstagedrc.json +.prettierrc +README.md + +# test +coverage +vitest.config.js + +# docker +Dockerfile +docker-compose.yml diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..f107f00 --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +MIT License + +Copyright (c) 2023 Kliton + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/api/.dockerignore b/api/.dockerignore new file mode 100644 index 0000000..a0dc9ab --- /dev/null +++ b/api/.dockerignore @@ -0,0 +1,26 @@ +# Versioning and metadata +.git +.gitignore +.dockerignore + +# Build dependencies +.vscode +dist.do +/node_modules + +# code formatter +.editorconfig +.eslintignore +.eslintrc.json +.huskyrc +.lintstagedrc.json +.prettierrc +README.md + +# test +coverage +vitest.config.js + +# docker +Dockerfile +docker-compose.yml diff --git a/api/Dockerfile b/api/Dockerfile new file mode 100644 index 0000000..7927a3b --- /dev/null +++ b/api/Dockerfile @@ -0,0 +1,24 @@ +FROM node:alpine + +RUN apk update && apk add --no-cache nodejs && corepack enable +RUN addgroup backend && adduser -S -G backend francis + +USER francis + +WORKDIR /node-api + +COPY package.json tsconfig.json ./ + +USER root + +RUN chown -R francis:backend . + +USER francis + +RUN pnpm install + +COPY . . + +EXPOSE 4000 + +CMD ["pnpm", "start:dev"] \ No newline at end of file diff --git a/api/Dockerfile.prod b/api/Dockerfile.prod new file mode 100644 index 0000000..9dfc8ac --- /dev/null +++ b/api/Dockerfile.prod @@ -0,0 +1,35 @@ +FROM node:alpine AS builder + +RUN apk update && apk add --no-cache nodejs && corepack enable +RUN addgroup mern && adduser -S -G mern api + +USER api + +WORKDIR /api + +COPY package.json tsconfig.json ./ +COPY src ./ + +RUN pnpm ci && pnpm build + + +FROM node:alpine + +RUN apk update && apk add --no-cache nodejs && corepack enable +RUN addgroup mern && adduser -S -G mern api + +USER api + +WORKDIR /api + +COPY package.json tsconfig.json ./ +COPY src ./ + +RUN pnpm add -g pm2 +RUN pnpm ci && pnpm build +RUN pnpm ci --production +COPY --from=builder /api/build ./build + +EXPOSE 4000 + +CMD [ "pnpm", "start" ] \ No newline at end of file diff --git a/api/docker-compose-mongodb.yaml b/api/docker-compose-mongodb.yaml deleted file mode 100644 index 0627a6c..0000000 --- a/api/docker-compose-mongodb.yaml +++ /dev/null @@ -1,64 +0,0 @@ -version: "3.9" - -networks: - mongodb-cluster-net: - -services: - mongo0: - image: mongo - container_name: mongo0 - command: > - mongod - --replSet rs0 - --bind_ip localhost,mongo0 - ports: - - 27017:27017 - restart: unless-stopped - volumes: - - ./mongodb_cluster/db0:/data/db - networks: - - mongodb-cluster-net - - mongo1: - image: mongo - container_name: mongo1 - command: > - mongod - --replSet rs0 - --bind_ip localhost,mongo1 - ports: - - 27018:27017 - restart: unless-stopped - volumes: - - ./mongodb_cluster/db1:/data/db - networks: - - mongodb-cluster-net - - mongo2: - image: mongo - container_name: mongo2 - command: > - mongod - --replSet rs0 - --bind_ip localhost,mongo2 - ports: - - 27019:27017 - restart: unless-stopped - volumes: - - ./mongodb_cluster/db2:/data/db - networks: - - mongodb-cluster-net - - mongo-rs-init: - image: mongo - container_name: mongo-rs-init - depends_on: - - mongo0 - - mongo1 - - mongo2 - entrypoint: ["bash", "replica_set_init.sh"] - restart: on-failure - volumes: - - ./scripts/replica_set_init.sh:/usr/local/bin/replica_set_init.sh:ro - networks: - - mongodb-cluster-net \ No newline at end of file diff --git a/api/docker-compose.yaml b/api/docker-compose.yaml new file mode 100644 index 0000000..b254ec1 --- /dev/null +++ b/api/docker-compose.yaml @@ -0,0 +1,26 @@ +services: + api: + container_name: node-api + image: node-api + build: + context: . + dockerfile: Dockerfile + restart: unless-stopped + stdin_open: true + env_file: .env.development.local + depends_on: + - mongodb + networks: + - mern + ports: + - 4000:4000 + environment: + - NODE_ENV=development + - BASE_URL=http://localhost:4000 + volumes: + - .:/node-api + - node_modules:/node-api/node_modules + +volumes: + node_modules: + name: node-modules diff --git a/api/ecosystem.config.js b/api/ecosystem.config.js index 186c15d..15cae87 100644 --- a/api/ecosystem.config.js +++ b/api/ecosystem.config.js @@ -27,7 +27,7 @@ module.exports = { }, { name: 'dev', // pm2 start App name - script: '../node_modules/.bin/ts-node', // ts-node + script: './node_modules/.bin/ts-node', // ts-node args: '-r tsconfig-paths/register --transpile-only src/server.ts', // ts-node args exec_mode: 'cluster', // 'cluster' or 'fork' instance_var: 'INSTANCE_ID', // instance variable diff --git a/api/package.json b/api/package.json index b70e52e..bc4d588 100644 --- a/api/package.json +++ b/api/package.json @@ -6,7 +6,7 @@ "author": "Francis Lagares", "license": "MIT", "scripts": { - "start:dev": "pnpm prisma:generate && pnpm prisma:seed cross-env NODE_ENV=development && tsx watch src/server.ts", + "start:dev": "pnpm prisma:generate && tsx watch src/server.ts", "start": "pnpm build && NODE_ENV=production && node dist/server.js", "build": "tsc && tsc-alias", "deploy:clean": "pm2 stop all && pm2 delete all", @@ -65,12 +65,17 @@ "ts-node": "^10.9.1", "tsc-alias": "^1.8.6", "tsconfig-paths": "^4.2.0", - "tsx": "^4.16.0", + "tsx": "^4.16.2", "typescript-transform-paths": "^3.4.7" }, "config": { "commitizen": { "path": "cz-conventional-changelog" } - } + }, + "engines": { + "node": ">=22.0.0", + "pnpm": ">=9.4.0" + }, + "packageManager": "pnpm@9.4.0+sha512.f549b8a52c9d2b8536762f99c0722205efc5af913e77835dbccc3b0b0b2ca9e7dc8022b78062c17291c48e88749c70ce88eb5a74f1fa8c4bf5e18bb46c8bd83a" } diff --git a/api/src/app/index.ts b/api/src/app/index.ts index 1c206e4..dfe908d 100644 --- a/api/src/app/index.ts +++ b/api/src/app/index.ts @@ -7,7 +7,11 @@ import hpp from 'hpp'; import swaggerJSDoc from 'swagger-jsdoc'; import swaggerUi from 'swagger-ui-express'; -import { MongoDBInstance as dbConnection } from 'api/src/config/database'; +import { ErrorMiddleware } from '@/libs/shared/middlewares/error.middleware'; + +import logger from '@/utils/logger'; + +import { MongoDBInstance as dbConnection } from '@/config/database'; import { BASE_URL, CLIENT_URL, @@ -16,10 +20,9 @@ import { NODE_ENV, ORIGIN, PORT, -} from 'api/src/config/environment'; -import { ErrorMiddleware } from 'api/src/libs/shared/middlewares/error.middleware'; -import applicationRoutes from 'api/src/routes/index'; -import logger from 'api/src/utils/logger'; +} from '@/config/environment'; + +import applicationRoutes from '@/routes/index'; export class App { private app: Application; diff --git a/api/src/config/database.ts b/api/src/config/database.ts index 9f0817f..3809282 100644 --- a/api/src/config/database.ts +++ b/api/src/config/database.ts @@ -1,5 +1,6 @@ -import { database } from 'api/src/libs/shared/prisma/prisma'; -import logger from 'api/src/utils/logger'; +import { database } from '@/libs/shared/prisma/prisma'; + +import logger from '@/utils/logger'; export class MongoDBInstance { private static instance: MongoDBInstance; diff --git a/api/src/libs/shared/middlewares/error.middleware.ts b/api/src/libs/shared/middlewares/error.middleware.ts index f508650..6c52c57 100644 --- a/api/src/libs/shared/middlewares/error.middleware.ts +++ b/api/src/libs/shared/middlewares/error.middleware.ts @@ -1,7 +1,8 @@ import { NextFunction, Request, Response } from 'express'; -import { HttpException } from 'api/src/libs/shared/exceptions/httpException'; -import logger from 'api/src/utils/logger'; +import { HttpException } from '@/libs/shared/exceptions/httpException'; + +import logger from '@/utils/logger'; export const ErrorMiddleware = ( error: HttpException, diff --git a/api/src/libs/shared/prisma/middlewares/query-logger.ts b/api/src/libs/shared/prisma/middlewares/query-logger.ts index dc32d53..3ba74b3 100644 --- a/api/src/libs/shared/prisma/middlewares/query-logger.ts +++ b/api/src/libs/shared/prisma/middlewares/query-logger.ts @@ -1,6 +1,6 @@ import { Prisma } from '@prisma/client'; -import logger from 'api/src/utils/logger'; +import logger from '@/utils/logger'; export const queryLogger: Prisma.Middleware = async (params, next) => { const before = Date.now(); diff --git a/api/src/libs/shared/redis/cache-manager.ts b/api/src/libs/shared/redis/cache-manager.ts index 0e50217..9f7f181 100644 --- a/api/src/libs/shared/redis/cache-manager.ts +++ b/api/src/libs/shared/redis/cache-manager.ts @@ -1,6 +1,6 @@ import Redis from 'ioredis'; -import { REDIS_HOST, REDIS_PORT, REDIS_TTL } from 'api/src/config/environment'; +import { REDIS_HOST, REDIS_PORT, REDIS_TTL } from '@/config/environment'; export class CacheManager { private redis: Redis; diff --git a/api/src/routes/health.router.ts b/api/src/routes/health.router.ts index 7617b10..15659d0 100644 --- a/api/src/routes/health.router.ts +++ b/api/src/routes/health.router.ts @@ -1,6 +1,6 @@ import express, { Router } from 'express'; -import HealthController from 'api/src/controllers/health.controller'; +import HealthController from '@/controllers/health.controller'; export class HealthRoutes { private router: Router; diff --git a/api/src/tests/health.test.ts b/api/src/tests/health.test.ts index 35bd5da..434423d 100644 --- a/api/src/tests/health.test.ts +++ b/api/src/tests/health.test.ts @@ -2,8 +2,9 @@ import express, { Application } from 'express'; import request from 'supertest'; import { beforeAll, describe, expect, it } from 'vitest'; -import { App } from 'api/src/app'; -import HealthController from 'api/src/controllers/health.controller'; +import HealthController from '@/controllers/health.controller'; + +import { App } from '@/app'; describe('HealthController', () => { let app: Application; diff --git a/api/tsconfig.json b/api/tsconfig.json index 0865182..45be708 100644 --- a/api/tsconfig.json +++ b/api/tsconfig.json @@ -1,8 +1,41 @@ { - "extends": "../tsconfig.json", "compilerOptions": { - "module": "commonjs", + /* Project Setup */ + "target": "esnext", + "module": "NodeNext", + "outDir": "./dist", + "allowJs": true, + "sourceMap": true, + "removeComments": false, + "isolatedModules": true, + "downlevelIteration": true, + "skipLibCheck": true, + "lib": ["dom", "esnext", "es2022"], + + /* Strict Type-Checking */ + "strict": true, + + /* Module Resolution */ + "esModuleInterop": true, + "moduleResolution": "NodeNext", + "resolveJsonModule": true, + "allowSyntheticDefaultImports": true, + "baseUrl": ".", + "paths": { + "@/*": ["src/*"] + }, + + /* Linter Checks */ + "noFallthroughCasesInSwitch": true, + + /* Experimental Options */ + "emitDecoratorMetadata": true, + "experimentalDecorators": true, + + /* Advanced Options */ + "forceConsistentCasingInFileNames": true }, + "include": ["src/**/*.ts"], "exclude": ["node_modules", "coverage"] -} \ No newline at end of file +} diff --git a/client/.dockerignore b/client/.dockerignore new file mode 100644 index 0000000..bb18f09 --- /dev/null +++ b/client/.dockerignore @@ -0,0 +1,28 @@ +# Versioning and metadata +.git +.gitignore +.dockerignore + +# Build dependencies +.vscode +dist.do +/node_modules + +# code formatter +.editorconfig +.eslintignore +.eslintrc.json +.huskyrc +.lintstagedrc.json +.prettierrc +README.md + +# test +.storybook +cypress +coverage +vitest.config.js + +# docker +Dockerfile +docker-compose.yml diff --git a/client/Dockerfile.dev b/client/Dockerfile.dev new file mode 100644 index 0000000..90eef7a --- /dev/null +++ b/client/Dockerfile.dev @@ -0,0 +1,25 @@ +# Stage 1: Development environment +FROM node:alpine + +RUN apk update && apk add --no-cache nodejs && corepack enable +RUN addgroup mern && adduser -S -G mern francis + +USER francis + +WORKDIR /app + +COPY package.json . + +USER root + +RUN chown -R francis:mern . + +USER francis + +RUN pnpm install + +COPY . . + +EXPOSE 5173 + +CMD ["pnpm", "dev"] \ No newline at end of file diff --git a/client/docker-compose.yaml b/client/docker-compose.yaml new file mode 100644 index 0000000..6a9180c --- /dev/null +++ b/client/docker-compose.yaml @@ -0,0 +1,18 @@ +services: + client: + container_name: client + image: client/v1.0.0 + build: + context: . + dockerfile: Dockerfile.dev + networks: + - mern + ports: + - "5173:5173" + volumes: + - .:/app + - /app/node_modules + +networks: + mern: + name: mern \ No newline at end of file diff --git a/client/package.json b/client/package.json index 9f1312b..0d3def1 100644 --- a/client/package.json +++ b/client/package.json @@ -3,7 +3,7 @@ "version": "1.0.0", "private": true, "scripts": { - "dev": "vite", + "dev": "vite --host", "build": "tsc -p tsconfig.prod.json && vite build", "preview": "vite preview", "test": "vitest run", @@ -17,10 +17,10 @@ "dependencies": { "react": "^18.2.0", "react-dom": "^18.2.0", - "react-router-dom": "^6.11.2" + "react-router-dom": "^6.24.1" }, "devDependencies": { - "@chromatic-com/storybook": "^1.6.0", + "@chromatic-com/storybook": "^1.6.1", "@mdx-js/react": "^3.0.1", "@storybook/addon-actions": "^8.1.11", "@storybook/addon-docs": "^8.1.11", @@ -33,7 +33,6 @@ "@storybook/react": "^8.1.11", "@storybook/react-vite": "^8.1.11", "@storybook/test": "^8.1.11", - "@storybook/testing-library": "^0.2.2", "@testing-library/cypress": "^10.0.2", "@testing-library/dom": "^10.2.0", "@testing-library/jest-dom": "^6.4.6", @@ -61,7 +60,7 @@ "stylelint-a11y": "^1.2.3", "stylelint-config-standard": "^36.0.1", "stylelint-order": "^6.0.3", - "vite": "^5.3.2", + "vite": "^5.3.3", "vite-plugin-svgr": "^4.2.0", "vite-tsconfig-paths": "^4.2.0" }, @@ -82,5 +81,10 @@ "last 1 firefox version", "last 1 safari version" ] - } + }, + "engines": { + "node": ">=22.0.0", + "pnpm": ">=9.4.0" + }, + "packageManager": "pnpm@9.4.0+sha512.f549b8a52c9d2b8536762f99c0722205efc5af913e77835dbccc3b0b0b2ca9e7dc8022b78062c17291c48e88749c70ce88eb5a74f1fa8c4bf5e18bb46c8bd83a" } diff --git a/client/src/stories/Button.stories.ts b/client/src/stories/Button.stories.ts deleted file mode 100644 index ddd5ec6..0000000 --- a/client/src/stories/Button.stories.ts +++ /dev/null @@ -1,54 +0,0 @@ -import { fn } from '@storybook/test'; - -import { Button } from './Button'; - -import type { Meta, StoryObj } from '@storybook/react'; - -// More on how to set up stories at: https://storybook.js.org/docs/writing-stories#default-export -const meta = { - title: 'Example/Button', - component: Button, - parameters: { - // Optional parameter to center the component in the Canvas. More info: https://storybook.js.org/docs/configure/story-layout - layout: 'centered', - }, - // This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs - tags: ['autodocs'], - // More on argTypes: https://storybook.js.org/docs/api/argtypes - argTypes: { - backgroundColor: { control: 'color' }, - }, - // Use `fn` to spy on the onClick arg, which will appear in the actions panel once invoked: https://storybook.js.org/docs/essentials/actions#action-args - args: { onClick: fn() }, -} satisfies Meta; - -export default meta; -type Story = StoryObj; - -// More on writing stories with args: https://storybook.js.org/docs/writing-stories/args -export const Primary: Story = { - args: { - primary: true, - label: 'Button', - }, -}; - -export const Secondary: Story = { - args: { - label: 'Button', - }, -}; - -export const Large: Story = { - args: { - size: 'large', - label: 'Button', - }, -}; - -export const Small: Story = { - args: { - size: 'small', - label: 'Button', - }, -}; diff --git a/client/src/stories/Button.tsx b/client/src/stories/Button.tsx deleted file mode 100644 index 1ab4bc3..0000000 --- a/client/src/stories/Button.tsx +++ /dev/null @@ -1,51 +0,0 @@ -import './button.css'; - -interface ButtonProps { - /** - * Is this the principal call to action on the page? - */ - primary?: boolean; - /** - * What background color to use - */ - backgroundColor?: string; - /** - * How large should the button be? - */ - size?: 'small' | 'medium' | 'large'; - /** - * Button contents - */ - label: string; - /** - * Optional click handler - */ - onClick?: () => void; -} - -/** - * Primary UI component for user interaction - */ -export const Button = ({ - primary = false, - size = 'medium', - backgroundColor, - label, - ...props -}: ButtonProps) => { - const mode = primary - ? 'storybook-button--primary' - : 'storybook-button--secondary'; - return ( - - ); -}; diff --git a/client/src/stories/Configure.mdx b/client/src/stories/Configure.mdx deleted file mode 100644 index 5157090..0000000 --- a/client/src/stories/Configure.mdx +++ /dev/null @@ -1,364 +0,0 @@ -import { Meta } from "@storybook/blocks"; - -import Github from "./assets/github.svg"; -import Discord from "./assets/discord.svg"; -import Youtube from "./assets/youtube.svg"; -import Tutorials from "./assets/tutorials.svg"; -import Styling from "./assets/styling.png"; -import Context from "./assets/context.png"; -import Assets from "./assets/assets.png"; -import Docs from "./assets/docs.png"; -import Share from "./assets/share.png"; -import FigmaPlugin from "./assets/figma-plugin.png"; -import Testing from "./assets/testing.png"; -import Accessibility from "./assets/accessibility.png"; -import Theming from "./assets/theming.png"; -import AddonLibrary from "./assets/addon-library.png"; - -export const RightArrow = () => - - - - - -
-
- # Configure your project - - Because Storybook works separately from your app, you'll need to configure it for your specific stack and setup. Below, explore guides for configuring Storybook with popular frameworks and tools. If you get stuck, learn how you can ask for help from our community. -
-
-
- A wall of logos representing different styling technologies -

Add styling and CSS

-

Like with web applications, there are many ways to include CSS within Storybook. Learn more about setting up styling within Storybook.

- Learn more -
-
- An abstraction representing the composition of data for a component -

Provide context and mocking

-

Often when a story doesn't render, it's because your component is expecting a specific environment or context (like a theme provider) to be available.

- Learn more -
-
- A representation of typography and image assets -
-

Load assets and resources

-

To link static files (like fonts) to your projects and stories, use the - `staticDirs` configuration option to specify folders to load when - starting Storybook.

- Learn more -
-
-
-
-
-
- # Do more with Storybook - - Now that you know the basics, let's explore other parts of Storybook that will improve your experience. This list is just to get you started. You can customise Storybook in many ways to fit your needs. -
- -
-
-
- A screenshot showing the autodocs tag being set, pointing a docs page being generated -

Autodocs

-

Auto-generate living, - interactive reference documentation from your components and stories.

- Learn more -
-
- A browser window showing a Storybook being published to a chromatic.com URL -

Publish to Chromatic

-

Publish your Storybook to review and collaborate with your entire team.

- Learn more -
-
- Windows showing the Storybook plugin in Figma -

Figma Plugin

-

Embed your stories into Figma to cross-reference the design and live - implementation in one place.

- Learn more -
-
- Screenshot of tests passing and failing -

Testing

-

Use stories to test a component in all its variations, no matter how - complex.

- Learn more -
-
- Screenshot of accessibility tests passing and failing -

Accessibility

-

Automatically test your components for a11y issues as you develop.

- Learn more -
-
- Screenshot of Storybook in light and dark mode -

Theming

-

Theme Storybook's UI to personalize it to your project.

- Learn more -
-
-
-
-
-
-

Addons

-

Integrate your tools with Storybook to connect workflows.

- Discover all addons -
-
- Integrate your tools with Storybook to connect workflows. -
-
- -
-
- Github logo - Join our contributors building the future of UI development. - - Star on GitHub -
-
- Discord logo -
- Get support and chat with frontend developers. - - Join Discord server -
-
-
- Youtube logo -
- Watch tutorials, feature previews and interviews. - - Watch on YouTube -
-
-
- A book -

Follow guided walkthroughs on for key workflows.

- - Discover tutorials -
-
- - diff --git a/client/src/stories/Header.stories.ts b/client/src/stories/Header.stories.ts deleted file mode 100644 index 531a7be..0000000 --- a/client/src/stories/Header.stories.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { fn } from '@storybook/test'; - -import { Header } from './Header'; - -import type { Meta, StoryObj } from '@storybook/react'; - -const meta = { - title: 'Example/Header', - component: Header, - // This component will have an automatically generated Autodocs entry: https://storybook.js.org/docs/writing-docs/autodocs - tags: ['autodocs'], - parameters: { - // More on how to position stories at: https://storybook.js.org/docs/configure/story-layout - layout: 'fullscreen', - }, - args: { - onLogin: fn(), - onLogout: fn(), - onCreateAccount: fn(), - }, -} satisfies Meta; - -export default meta; -type Story = StoryObj; - -export const LoggedIn: Story = { - args: { - user: { - name: 'Jane Doe', - }, - }, -}; - -export const LoggedOut: Story = {}; diff --git a/client/src/stories/Header.tsx b/client/src/stories/Header.tsx deleted file mode 100644 index 0e47833..0000000 --- a/client/src/stories/Header.tsx +++ /dev/null @@ -1,69 +0,0 @@ -import { Button } from './Button'; -import './header.css'; - -type User = { - name: string; -}; - -interface HeaderProps { - user?: User; - onLogin?: () => void; - onLogout?: () => void; - onCreateAccount?: () => void; -} - -export const Header = ({ - user, - onLogin, - onLogout, - onCreateAccount, -}: HeaderProps) => ( -
-
-
- - - - - - - -

Acme

-
-
- {user ? ( - <> - - Welcome, {user.name}! - -
-
-
-); diff --git a/client/src/stories/Page.stories.ts b/client/src/stories/Page.stories.ts deleted file mode 100644 index 0039f51..0000000 --- a/client/src/stories/Page.stories.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { expect, userEvent, within } from '@storybook/test'; - -import { Page } from './Page'; - -import type { Meta, StoryObj } from '@storybook/react'; - -const meta = { - title: 'Example/Page', - component: Page, - parameters: { - // More on how to position stories at: https://storybook.js.org/docs/configure/story-layout - layout: 'fullscreen', - }, -} satisfies Meta; - -export default meta; -type Story = StoryObj; - -export const LoggedOut: Story = {}; - -// More on interaction testing: https://storybook.js.org/docs/writing-tests/interaction-testing -export const LoggedIn: Story = { - play: async ({ canvasElement }) => { - const canvas = within(canvasElement); - const loginButton = canvas.getByRole('button', { name: /Log in/i }); - await expect(loginButton).toBeInTheDocument(); - await userEvent.click(loginButton); - await expect(loginButton).not.toBeInTheDocument(); - - const logoutButton = canvas.getByRole('button', { name: /Log out/i }); - await expect(logoutButton).toBeInTheDocument(); - }, -}; diff --git a/client/src/stories/Page.tsx b/client/src/stories/Page.tsx deleted file mode 100644 index cc55884..0000000 --- a/client/src/stories/Page.tsx +++ /dev/null @@ -1,91 +0,0 @@ -import React from 'react'; - -import { Header } from './Header'; -import './page.css'; - -type User = { - name: string; -}; - -export const Page: React.FC = () => { - const [user, setUser] = React.useState(); - - return ( -
-
setUser({ name: 'Jane Doe' })} - onLogout={() => setUser(undefined)} - onCreateAccount={() => setUser({ name: 'Jane Doe' })} - /> - -
-

Pages in Storybook

-

- We recommend building UIs with a{' '} - - component-driven - {' '} - process starting with atomic components and ending with pages. -

-

- Render pages with mock data. This makes it easy to build and review - page states without needing to navigate to them in your app. Here are - some handy patterns for managing page data in Storybook: -

-
    -
  • - Use a higher-level connected component. Storybook helps you compose - such data from the "args" of child component stories -
  • -
  • - Assemble data in the page component from your services. You can mock - these services out using Storybook. -
  • -
-

- Get a guided tutorial on component-driven development at{' '} - - Storybook tutorials - - . Read more in the{' '} - - docs - - . -

-
- Tip Adjust the width of the canvas with - the{' '} - - - - - - Viewports addon in the toolbar -
-
-
- ); -}; diff --git a/client/src/stories/assets/accessibility.png b/client/src/stories/assets/accessibility.png deleted file mode 100644 index 6ffe6fe..0000000 Binary files a/client/src/stories/assets/accessibility.png and /dev/null differ diff --git a/client/src/stories/assets/accessibility.svg b/client/src/stories/assets/accessibility.svg deleted file mode 100644 index a328883..0000000 --- a/client/src/stories/assets/accessibility.svg +++ /dev/null @@ -1,5 +0,0 @@ - - Accessibility - - - \ No newline at end of file diff --git a/client/src/stories/assets/addon-library.png b/client/src/stories/assets/addon-library.png deleted file mode 100644 index 95deb38..0000000 Binary files a/client/src/stories/assets/addon-library.png and /dev/null differ diff --git a/client/src/stories/assets/assets.png b/client/src/stories/assets/assets.png deleted file mode 100644 index cfba681..0000000 Binary files a/client/src/stories/assets/assets.png and /dev/null differ diff --git a/client/src/stories/assets/avif-test-image.avif b/client/src/stories/assets/avif-test-image.avif deleted file mode 100644 index 530709b..0000000 Binary files a/client/src/stories/assets/avif-test-image.avif and /dev/null differ diff --git a/client/src/stories/assets/context.png b/client/src/stories/assets/context.png deleted file mode 100644 index e5cd249..0000000 Binary files a/client/src/stories/assets/context.png and /dev/null differ diff --git a/client/src/stories/assets/discord.svg b/client/src/stories/assets/discord.svg deleted file mode 100644 index 1204df9..0000000 --- a/client/src/stories/assets/discord.svg +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/client/src/stories/assets/docs.png b/client/src/stories/assets/docs.png deleted file mode 100644 index a749629..0000000 Binary files a/client/src/stories/assets/docs.png and /dev/null differ diff --git a/client/src/stories/assets/figma-plugin.png b/client/src/stories/assets/figma-plugin.png deleted file mode 100644 index 8f79b08..0000000 Binary files a/client/src/stories/assets/figma-plugin.png and /dev/null differ diff --git a/client/src/stories/assets/github.svg b/client/src/stories/assets/github.svg deleted file mode 100644 index 158e026..0000000 --- a/client/src/stories/assets/github.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/client/src/stories/assets/share.png b/client/src/stories/assets/share.png deleted file mode 100644 index 8097a37..0000000 Binary files a/client/src/stories/assets/share.png and /dev/null differ diff --git a/client/src/stories/assets/styling.png b/client/src/stories/assets/styling.png deleted file mode 100644 index d341e82..0000000 Binary files a/client/src/stories/assets/styling.png and /dev/null differ diff --git a/client/src/stories/assets/testing.png b/client/src/stories/assets/testing.png deleted file mode 100644 index d4ac39a..0000000 Binary files a/client/src/stories/assets/testing.png and /dev/null differ diff --git a/client/src/stories/assets/theming.png b/client/src/stories/assets/theming.png deleted file mode 100644 index 1535eb9..0000000 Binary files a/client/src/stories/assets/theming.png and /dev/null differ diff --git a/client/src/stories/assets/tutorials.svg b/client/src/stories/assets/tutorials.svg deleted file mode 100644 index 4b2fc7c..0000000 --- a/client/src/stories/assets/tutorials.svg +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - - - - - diff --git a/client/src/stories/assets/youtube.svg b/client/src/stories/assets/youtube.svg deleted file mode 100644 index 33a3a61..0000000 --- a/client/src/stories/assets/youtube.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/client/src/stories/button.css b/client/src/stories/button.css deleted file mode 100644 index dc91dc7..0000000 --- a/client/src/stories/button.css +++ /dev/null @@ -1,30 +0,0 @@ -.storybook-button { - font-family: 'Nunito Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif; - font-weight: 700; - border: 0; - border-radius: 3em; - cursor: pointer; - display: inline-block; - line-height: 1; -} -.storybook-button--primary { - color: white; - background-color: #1ea7fd; -} -.storybook-button--secondary { - color: #333; - background-color: transparent; - box-shadow: rgba(0, 0, 0, 0.15) 0px 0px 0px 1px inset; -} -.storybook-button--small { - font-size: 12px; - padding: 10px 16px; -} -.storybook-button--medium { - font-size: 14px; - padding: 11px 20px; -} -.storybook-button--large { - font-size: 16px; - padding: 12px 24px; -} diff --git a/client/src/stories/header.css b/client/src/stories/header.css deleted file mode 100644 index d9a7052..0000000 --- a/client/src/stories/header.css +++ /dev/null @@ -1,32 +0,0 @@ -.storybook-header { - font-family: 'Nunito Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif; - border-bottom: 1px solid rgba(0, 0, 0, 0.1); - padding: 15px 20px; - display: flex; - align-items: center; - justify-content: space-between; -} - -.storybook-header svg { - display: inline-block; - vertical-align: top; -} - -.storybook-header h1 { - font-weight: 700; - font-size: 20px; - line-height: 1; - margin: 6px 0 6px 10px; - display: inline-block; - vertical-align: top; -} - -.storybook-header button + button { - margin-left: 10px; -} - -.storybook-header .welcome { - color: #333; - font-size: 14px; - margin-right: 10px; -} diff --git a/client/src/stories/page.css b/client/src/stories/page.css deleted file mode 100644 index 098dad1..0000000 --- a/client/src/stories/page.css +++ /dev/null @@ -1,69 +0,0 @@ -.storybook-page { - font-family: 'Nunito Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif; - font-size: 14px; - line-height: 24px; - padding: 48px 20px; - margin: 0 auto; - max-width: 600px; - color: #333; -} - -.storybook-page h2 { - font-weight: 700; - font-size: 32px; - line-height: 1; - margin: 0 0 4px; - display: inline-block; - vertical-align: top; -} - -.storybook-page p { - margin: 1em 0; -} - -.storybook-page a { - text-decoration: none; - color: #1ea7fd; -} - -.storybook-page ul { - padding-left: 30px; - margin: 1em 0; -} - -.storybook-page li { - margin-bottom: 8px; -} - -.storybook-page .tip { - display: inline-block; - border-radius: 1em; - font-size: 11px; - line-height: 12px; - font-weight: 700; - background: #e7fdd8; - color: #66bf3c; - padding: 4px 12px; - margin-right: 10px; - vertical-align: top; -} - -.storybook-page .tip-wrapper { - font-size: 13px; - line-height: 20px; - margin-top: 40px; - margin-bottom: 40px; -} - -.storybook-page .tip-wrapper svg { - display: inline-block; - height: 12px; - width: 12px; - margin-right: 4px; - vertical-align: top; - margin-top: 3px; -} - -.storybook-page .tip-wrapper svg path { - fill: #1ea7fd; -} diff --git a/client/tsconfig.json b/client/tsconfig.json index 5133504..6707b38 100644 --- a/client/tsconfig.json +++ b/client/tsconfig.json @@ -1,9 +1,44 @@ { - "extends": "../tsconfig.json", "compilerOptions": { + /* Project Setup */ + "target": "ES2022", + "lib": ["dom", "dom.iterable", "esnext"], "jsx": "react-jsx", - "module": "esnext" - }, + "allowJs": true, + "sourceMap": true, + "skipLibCheck": true, + "isolatedModules": true, + "removeComments": true, + "downlevelIteration": true, + + /* Strict Type-Checking */ + "strict": true, + "noUncheckedIndexedAccess": true, + + /* Linter Checks */ + "noImplicitAny": true, + "noImplicitThis": true, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noImplicitReturns": false, + "noFallthroughCasesInSwitch": true, - "include": ["./src/**/*.ts", "./src/**/*.tsx", "@testing-library/jest-dom"] + "useDefineForClassFields": true, + + /* Module Resolution */ + "module": "ESNext", + "outDir": "./dist", + "esModuleInterop": true, + "moduleResolution": "bundler", + "resolveJsonModule": true, + "allowSyntheticDefaultImports": true, + "forceConsistentCasingInFileNames": true, + "baseUrl": ".", + "paths": { + "@/*": ["src/*"] + } + }, + "include": ["./src/**/*.ts", "./src/**/*.tsx", "@testing-library/jest-dom"], + "exclude": ["./cypress.config.ts"], + "types": ["vitest/globals"] } diff --git a/docker-compose.yaml b/docker-compose.yaml new file mode 100644 index 0000000..1db0e99 --- /dev/null +++ b/docker-compose.yaml @@ -0,0 +1,25 @@ +services: + mongodb: + extends: + service: mongodb + file: infra/docker/docker-compose-mongodb.yaml + + api: + extends: + service: api + file: api/docker-compose.yaml + + client: + extends: + service: client + file: client/docker-compose.yaml + +volumes: + mongodb: + name: mongodb + node_modules: + name: node-modules + +networks: + mern: + name: mern diff --git a/eslint.config.mjs b/eslint.config.mjs index 7e21bcf..3dd710d 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -75,7 +75,6 @@ export default [ caseInsensitive: true, }, pathGroups: [ - { pattern: '@/features/**', group: 'internal', @@ -133,9 +132,9 @@ export default [ { ignores: [ '*.{js,mjs,mts,config.js,config.ts}', - 'dist/**', - 'infra/**', 'node_modules/**', + 'infra/**', + '**/dist/**', '**/coverage/**', '**/build/**', ], diff --git a/infra/docker/docker-compose-mongodb.yaml b/infra/docker/docker-compose-mongodb.yaml new file mode 100644 index 0000000..0fbbc61 --- /dev/null +++ b/infra/docker/docker-compose-mongodb.yaml @@ -0,0 +1,20 @@ +services: + mongodb: + image: mongo + container_name: mongodb + ports: + - 27017:27017 + restart: unless-stopped + volumes: + - mongodb:/data/db + networks: + - mern + +volumes: + mongodb: + name: mongodb + driver: local + +networks: + mern: + name: mern diff --git a/api/docker-compose-redis.yaml b/infra/docker/docker-compose-redis.yaml similarity index 100% rename from api/docker-compose-redis.yaml rename to infra/docker/docker-compose-redis.yaml diff --git a/api/scripts/replica_set_init.sh b/infra/docker/scripts/replica_set_init.sh similarity index 100% rename from api/scripts/replica_set_init.sh rename to infra/docker/scripts/replica_set_init.sh diff --git a/lint-staged.config.js b/lint-staged.config.mjs similarity index 84% rename from lint-staged.config.js rename to lint-staged.config.mjs index 3af1407..c131584 100644 --- a/lint-staged.config.js +++ b/lint-staged.config.mjs @@ -1,6 +1,8 @@ -module.exports = { +const staged = { // Run type-check on changes to TypeScript files '**/*.ts?(x)': () => 'pnpm type-check', // Run ESLint on changes to JavaScript/TypeScript files '**/*.(ts|js)?(x)': filenames => `pnpm lint ${filenames.join(' ')}`, }; + +export default staged; diff --git a/package.json b/package.json index 1ad213a..3847135 100644 --- a/package.json +++ b/package.json @@ -52,10 +52,10 @@ "lint-staged": "^15.2.7", "prettier": "^3.3.2", "rimraf": "^5.0.1", - "tsx": "^4.16.0", + "tsx": "^4.16.2", "typescript": "^5.1.3", "typescript-eslint": "^7.15.0", - "vite": "^5.3.2", + "vite": "^5.3.3", "vite-tsconfig-paths": "^4.2.0", "vitest": "^1.6.0", "vitest-mock-extended": "^1.1.3" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index edc6628..a5b1b06 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -35,7 +35,7 @@ importers: version: 7.15.0(eslint@9.6.0)(typescript@5.5.3) '@vitest/coverage-v8': specifier: ^1.6.0 - version: 1.6.0(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)) + version: 1.6.0(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1)) commitizen: specifier: ^4.3.0 version: 4.3.0(@types/node@20.14.9)(typescript@5.5.3) @@ -73,8 +73,8 @@ importers: specifier: ^5.0.1 version: 5.0.7 tsx: - specifier: ^4.16.0 - version: 4.16.0 + specifier: ^4.16.2 + version: 4.16.2 typescript: specifier: ^5.1.3 version: 5.5.3 @@ -82,17 +82,17 @@ importers: specifier: ^7.15.0 version: 7.15.0(eslint@9.6.0)(typescript@5.5.3) vite: - specifier: ^5.3.2 - version: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + specifier: ^5.3.3 + version: 5.3.3(@types/node@20.14.9)(sugarss@4.0.1) vite-tsconfig-paths: specifier: ^4.2.0 - version: 4.3.2(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + version: 4.3.2(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@4.0.1)) vitest: specifier: ^1.6.0 - version: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1) + version: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1) vitest-mock-extended: specifier: ^1.1.3 - version: 1.3.1(typescript@5.5.3)(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)) + version: 1.3.1(typescript@5.5.3)(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1)) api: dependencies: @@ -215,8 +215,8 @@ importers: specifier: ^4.2.0 version: 4.2.0 tsx: - specifier: ^4.16.0 - version: 4.16.0 + specifier: ^4.16.2 + version: 4.16.2 typescript-transform-paths: specifier: ^3.4.7 version: 3.4.7(typescript@5.5.3) @@ -230,12 +230,12 @@ importers: specifier: ^18.2.0 version: 18.3.1(react@18.3.1) react-router-dom: - specifier: ^6.11.2 - version: 6.24.0(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + specifier: ^6.24.1 + version: 6.24.1(react-dom@18.3.1(react@18.3.1))(react@18.3.1) devDependencies: '@chromatic-com/storybook': - specifier: ^1.6.0 - version: 1.6.0(react@18.3.1) + specifier: ^1.6.1 + version: 1.6.1(react@18.3.1) '@mdx-js/react': specifier: ^3.0.1 version: 3.0.1(@types/react@18.3.3)(react@18.3.1) @@ -250,7 +250,7 @@ importers: version: 8.1.11(@types/react-dom@18.3.0)(@types/react@18.3.3)(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@storybook/addon-interactions': specifier: ^8.1.11 - version: 8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)) + version: 8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1)) '@storybook/addon-links': specifier: ^8.1.11 version: 8.1.11(react@18.3.1) @@ -262,16 +262,16 @@ importers: version: 8.1.11(@types/react-dom@18.3.0)(@types/react@18.3.3)(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) '@storybook/builder-vite': specifier: ^8.1.11 - version: 8.1.11(prettier@3.3.2)(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + version: 8.1.11(prettier@3.3.2)(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) '@storybook/react': specifier: ^8.1.11 version: 8.1.11(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.5.3) '@storybook/react-vite': specifier: ^8.1.11 - version: 8.1.11(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + version: 8.1.11(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) '@storybook/test': specifier: ^8.1.11 - version: 8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)) + version: 8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1)) '@storybook/testing-library': specifier: ^0.2.2 version: 0.2.2 @@ -283,7 +283,7 @@ importers: version: 10.3.0 '@testing-library/jest-dom': specifier: ^6.4.6 - version: 6.4.6(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)) + version: 6.4.6(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1)) '@testing-library/react': specifier: ^16.0.0 version: 16.0.0(@testing-library/dom@10.3.0)(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) @@ -298,7 +298,7 @@ importers: version: 18.3.0 '@vitejs/plugin-react': specifier: ^4.0.0 - version: 4.3.1(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + version: 4.3.1(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) '@vitest/ui': specifier: ^1.6.0 version: 1.6.0(vitest@1.6.0) @@ -307,7 +307,7 @@ importers: version: 13.13.0 cypress-vite: specifier: ^1.4.0 - version: 1.5.0(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + version: 1.5.0(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) eslint-plugin-jest-dom: specifier: ^5.0.0 version: 5.4.0(@testing-library/dom@10.3.0)(eslint@9.6.0) @@ -357,14 +357,14 @@ importers: specifier: ^6.0.3 version: 6.0.4(stylelint@16.6.1(typescript@5.5.3)) vite: - specifier: ^5.3.2 - version: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + specifier: ^5.3.3 + version: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) vite-plugin-svgr: specifier: ^4.2.0 - version: 4.2.0(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + version: 4.2.0(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) vite-tsconfig-paths: specifier: ^4.2.0 - version: 4.3.2(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + version: 4.3.2(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) packages: @@ -1042,8 +1042,8 @@ packages: '@bundled-es-modules/statuses@1.0.1': resolution: {integrity: sha512-yn7BklA5acgcBr+7w064fGV+SGIFySjCKpqjcWgBAIfrAkY+4GQTJJHQMeT3V/sgz23VTEVV8TtOmkvJAhFVfg==} - '@chromatic-com/storybook@1.6.0': - resolution: {integrity: sha512-6sHj0l194KMBIZ0D5SeJ+Ys+zslehKHcC2d6Hd/YEn4cCl7p9mLuxrZjvf8xharGKy8vf9Q1tKrU2YdldzUBoQ==} + '@chromatic-com/storybook@1.6.1': + resolution: {integrity: sha512-x1x1NB3j4xpfeSWKr96emc+7ZvfsvH+/WVb3XCjkB24PPbT8VZXb3mJSAQMrSzuQ8+eQE9kDogYHH9Fj3tb/Cw==} engines: {node: '>=16.0.0', yarn: '>=1.22.18'} '@colors/colors@1.5.0': @@ -1814,8 +1814,8 @@ packages: '@types/react': optional: true - '@remix-run/router@1.17.0': - resolution: {integrity: sha512-2D6XaHEVvkCn682XBnipbJjgZUU7xjLtA4dGJRBVUKpEaDYOZMENZoZjAOSb7qirxt5RupjzZxz4fK2FO+EFPw==} + '@remix-run/router@1.17.1': + resolution: {integrity: sha512-mCOMec4BKd6BRGBZeSnGiIgwsbLGp3yhVqAD8H+PxiRNEHgDpZb8J1TnrSDlg97t0ySKMQJTHCWBCmBpSmkF6Q==} engines: {node: '>=14.0.0'} '@rollup/pluginutils@5.1.0': @@ -3554,6 +3554,10 @@ packages: resolution: {integrity: sha512-AZL67abkUzIuvcHqk7c09cezpGNcxUxU4Ioi/05xHk4DQeTkWmGYftIE6ctU6AEt+Gn4n1lDStOtj7FKycP71A==} engines: {node: '>=8'} + cssstyle@4.0.1: + resolution: {integrity: sha512-8ZYiJ3A/3OkDd093CBT/0UKDWry7ak4BdPTFP2+QEP7cmhouyq/Up709ASSj2cK02BbZiMgk7kYjZNS4QP5qrQ==} + engines: {node: '>=18'} + csstype@3.1.3: resolution: {integrity: sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==} @@ -3597,6 +3601,10 @@ packages: resolution: {integrity: sha512-Jy/tj3ldjZJo63sVAvg6LHt2mHvl4V6AgRAmNDtLdm7faqtsx+aJG42rsyCo9JCoRVKwPFzKlIPx3DIibwSIaQ==} engines: {node: '>=12'} + data-urls@5.0.0: + resolution: {integrity: sha512-ZYP5VBHshaDAiVZxjbRVcFJpc+4xGgT0bK3vzy1HLN8jTO975HEbuYzZJcHoQEY5K1a0z8YayJkyVETa08eNTg==} + engines: {node: '>=18'} + data-view-buffer@1.0.1: resolution: {integrity: sha512-0lht7OugA5x3iJLOWFhWK/5ehONdprk0ISXqVFn/NFrDu+cuc8iADFrGQz5BnRK7LLU3JmkbXSxaqX+/mXYtUA==} engines: {node: '>= 0.4'} @@ -4764,6 +4772,10 @@ packages: resolution: {integrity: sha512-oWv4T4yJ52iKrufjnyZPkrN0CH3QnrUqdB6In1g5Fe1mia8GmF36gnfNySxoZtxD5+NmYw1EElVXiBk93UeskA==} engines: {node: '>=12'} + html-encoding-sniffer@4.0.0: + resolution: {integrity: sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==} + engines: {node: '>=18'} + html-escaper@2.0.2: resolution: {integrity: sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==} @@ -5364,6 +5376,15 @@ packages: canvas: optional: true + jsdom@24.1.0: + resolution: {integrity: sha512-6gpM7pRXCwIOKxX47cgOyvyQDN/Eh0f1MeKySBV2xGdKtqJBLj8P25eY3EVCWo2mglDDzozR2r2MW4T+JiNUZA==} + engines: {node: '>=18'} + peerDependencies: + canvas: ^2.11.2 + peerDependenciesMeta: + canvas: + optional: true + jsesc@0.5.0: resolution: {integrity: sha512-uZz5UnB7u4T9LvwmFqXii7pZSouaRPorGs5who1Ip7VO0wxanFvBL7GkM6dTHlgX+jhBApRetaWpnDabOeTcnA==} hasBin: true @@ -6692,15 +6713,15 @@ packages: '@types/react': optional: true - react-router-dom@6.24.0: - resolution: {integrity: sha512-960sKuau6/yEwS8e+NVEidYQb1hNjAYM327gjEyXlc6r3Skf2vtwuJ2l7lssdegD2YjoKG5l8MsVyeTDlVeY8g==} + react-router-dom@6.24.1: + resolution: {integrity: sha512-U19KtXqooqw967Vw0Qcn5cOvrX5Ejo9ORmOtJMzYWtCT4/WOfFLIZGGsVLxcd9UkBO0mSTZtXqhZBsWlHr7+Sg==} engines: {node: '>=14.0.0'} peerDependencies: react: '>=16.8' react-dom: '>=16.8' - react-router@6.24.0: - resolution: {integrity: sha512-sQrgJ5bXk7vbcC4BxQxeNa5UmboFm35we1AFK0VvQaz9g0LzxEIuLOhHIoZ8rnu9BO21ishGeL9no1WB76W/eg==} + react-router@6.24.1: + resolution: {integrity: sha512-PTXFXGK2pyXpHzVo3rR9H7ip4lSPZZc0bHG5CARmj65fTT6qG7sTngmb6lcYu1gf3y/8KxORoy9yn59pGpCnpg==} engines: {node: '>=14.0.0'} peerDependencies: react: '>=16.8' @@ -6940,6 +6961,12 @@ packages: engines: {node: '>=18.0.0', npm: '>=8.0.0'} hasBin: true + rrweb-cssom@0.6.0: + resolution: {integrity: sha512-APM0Gt1KoXBz0iIkkdB/kfvGOwC4UuJFeG/c+yV7wSc7q96cG/kJ0HiYCnzivD9SB53cLV1MlHFNfOuPaadYSw==} + + rrweb-cssom@0.7.1: + resolution: {integrity: sha512-TrEMa7JGdVm0UThDJSx7ddw5nVm3UJS9o9CCIZ72B1vSyEZoziDqBYP3XIoi/12lKrJR8rE3jeFHMok2F/Mnsg==} + run-async@2.4.1: resolution: {integrity: sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ==} engines: {node: '>=0.12.0'} @@ -7374,6 +7401,12 @@ packages: sugarss@1.0.1: resolution: {integrity: sha512-3qgLZytikQQEVn1/FrhY7B68gPUUGY3R1Q1vTiD5xT+Ti1DP/8iZuwFet9ONs5+bmL8pZoDQ6JrQHVgrNlK6mA==} + sugarss@4.0.1: + resolution: {integrity: sha512-WCjS5NfuVJjkQzK10s8WOBY+hhDxxNt/N6ZaGwxFZ+wN3/lKKFSaaKUNecULcTTvE4urLcKaZFQD8vO0mOZujw==} + engines: {node: '>=12.0'} + peerDependencies: + postcss: ^8.3.3 + superagent@9.0.2: resolution: {integrity: sha512-xuW7dzkUpcJq7QnhOsnNUgtYp3xRwpt2F7abdRYIpCsAt0hhUqia0EdxyXZQQpNmGtsCzYHryaKSV3q3GJnq7w==} engines: {node: '>=14.18.0'} @@ -7588,6 +7621,10 @@ packages: resolution: {integrity: sha512-l7FvfAHlcmulp8kr+flpQZmVwtu7nfRV7NZujtN0OqES8EL4O4e0qqzL0DC5gAvx/ZC/9lk6rhcUwYvkBnBnYA==} engines: {node: '>=12'} + tr46@5.0.0: + resolution: {integrity: sha512-tk2G5R2KRwBd+ZN0zaEXpmzdKyOYksXwywulIX95MBODjSzMIuQnQ3m8JxgbhnL1LeVo7lqQKsYa1O3Htl7K5g==} + engines: {node: '>=18'} + tree-kill@1.2.2: resolution: {integrity: sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==} hasBin: true @@ -7686,8 +7723,8 @@ packages: peerDependencies: typescript: '>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta' - tsx@4.16.0: - resolution: {integrity: sha512-MPgN+CuY+4iKxGoJNPv+1pyo5YWZAQ5XfsyobUG+zoKG7IkvCPLZDEyoIb8yLS2FcWci1nlxAqmvPlFWD5AFiQ==} + tsx@4.16.2: + resolution: {integrity: sha512-C1uWweJDgdtX2x600HjaFaucXTilT7tgUZHbOE4+ypskZ1OP8CRCSDkCxG6Vya9EwaFIVagWwpaVAn5wzypaqQ==} engines: {node: '>=18.0.0'} hasBin: true @@ -7992,8 +8029,8 @@ packages: vite: optional: true - vite@5.3.2: - resolution: {integrity: sha512-6lA7OBHBlXUxiJxbO5aAY2fsHHzDr1q7DvXYnyZycRs2Dz+dXBWuhpWHvmljTRTpQC2uvGmUFFkSHF2vGo90MA==} + vite@5.3.3: + resolution: {integrity: sha512-NPQdeCU0Dv2z5fu+ULotpuq5yfCS1BzKUIPhNbP3YBfAMGJXbt2nS+sbTFu+qchaqWTD+H3JK++nRwr6XIcp6A==} engines: {node: ^18.0.0 || >=20.0.0} hasBin: true peerDependencies: @@ -8059,6 +8096,10 @@ packages: resolution: {integrity: sha512-d+BFHzbiCx6zGfz0HyQ6Rg69w9k19nviJspaj4yNscGjrHu94sVP+aRm75yEbCh+r2/yR+7q6hux9LVtbuTGBw==} engines: {node: '>=14'} + w3c-xmlserializer@5.0.0: + resolution: {integrity: sha512-o8qghlI8NZHU1lLPrpi2+Uq7abh4GGPpYANlalzWxyWteJOCsr/P+oPBA49TOLu5FTZO4d3F9MnWJfiMo4BkmA==} + engines: {node: '>=18'} + watchpack@2.4.1: resolution: {integrity: sha512-8wrBCMtVhqcXP2Sup1ctSkga6uc2Bx0IIvKyT7yTFier5AXHooSI+QyQQAtTb7+E0IUCCKyTFmXqdqgum2XWGg==} engines: {node: '>=10.13.0'} @@ -8084,14 +8125,26 @@ packages: resolution: {integrity: sha512-p41ogyeMUrw3jWclHWTQg1k05DSVXPLcVxRTYsXUk+ZooOCZLcoYgPZ/HL/D/N+uQPOtcp1me1WhBEaX02mhWg==} engines: {node: '>=12'} + whatwg-encoding@3.1.1: + resolution: {integrity: sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==} + engines: {node: '>=18'} + whatwg-mimetype@3.0.0: resolution: {integrity: sha512-nt+N2dzIutVRxARx1nghPKGv1xHikU7HKdfafKkLNLindmPU/ch3U31NOCGGA/dmPcmb1VlofO0vnKAcsm0o/Q==} engines: {node: '>=12'} + whatwg-mimetype@4.0.0: + resolution: {integrity: sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==} + engines: {node: '>=18'} + whatwg-url@11.0.0: resolution: {integrity: sha512-RKT8HExMpoYx4igMiVMY83lN6UeITKJlBQ+vR/8ZJ8OCdSiN3RwCq+9gH0+Xzj0+5IrM6i4j/6LuvzbZIQgEcQ==} engines: {node: '>=12'} + whatwg-url@14.0.0: + resolution: {integrity: sha512-1lfMEm2IEr7RIV+f4lUNPOqfFL+pO+Xw3fJSqmjX9AbXcXcYOkCe1P6+9VBZB6n94af16NfZf+sSk0JCBZC9aw==} + engines: {node: '>=18'} + whatwg-url@5.0.0: resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} @@ -8200,6 +8253,18 @@ packages: utf-8-validate: optional: true + ws@8.18.0: + resolution: {integrity: sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==} + engines: {node: '>=10.0.0'} + peerDependencies: + bufferutil: ^4.0.1 + utf-8-validate: '>=5.0.2' + peerDependenciesMeta: + bufferutil: + optional: true + utf-8-validate: + optional: true + x-is-string@0.1.0: resolution: {integrity: sha512-GojqklwG8gpzOVEVki5KudKNoq7MbbjYZCbyWzEz7tyPA7eleiE0+ePwOWQQRb5fm86rD3S8Tc0tSFf3AOv50w==} @@ -8211,6 +8276,10 @@ packages: resolution: {integrity: sha512-ICP2e+jsHvAj2E2lIHxa5tjXRlKDJo4IdvPvCXbXQGdzSfmSpNVyIKMvoZHjDY9DP0zV17iI85o90vRFXNccRw==} engines: {node: '>=12'} + xml-name-validator@5.0.0: + resolution: {integrity: sha512-EvGK8EJ3DhaHfbRlETOWAS5pO9MZITeauHKJyb8wyajUfQUenkIg2MvLDTZ4T/TgIcm3HU0TFBgWWboAZ30UHg==} + engines: {node: '>=18'} + xmlchars@2.2.0: resolution: {integrity: sha512-JZnDKK8B0RCDw84FNdDAIpZK+JuJw+s7Lz8nksI7SIuU3UXJJslUthsi+uWBUYOwPFwW7W7PRLRfUKpxjtjFCw==} @@ -9154,7 +9223,7 @@ snapshots: dependencies: statuses: 2.0.1 - '@chromatic-com/storybook@1.6.0(react@18.3.1)': + '@chromatic-com/storybook@1.6.1(react@18.3.1)': dependencies: chromatic: 11.5.4 filesize: 10.1.2 @@ -9589,13 +9658,13 @@ snapshots: '@types/yargs': 17.0.32 chalk: 4.1.2 - '@joshwooding/vite-plugin-react-docgen-typescript@0.3.1(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1))': + '@joshwooding/vite-plugin-react-docgen-typescript@0.3.1(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1))': dependencies: glob: 7.2.3 glob-promise: 4.2.2(glob@7.2.3) magic-string: 0.27.0 react-docgen-typescript: 2.2.2(typescript@5.5.3) - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) optionalDependencies: typescript: 5.5.3 @@ -9900,7 +9969,7 @@ snapshots: optionalDependencies: '@types/react': 18.3.3 - '@remix-run/router@1.17.0': {} + '@remix-run/router@1.17.1': {} '@rollup/pluginutils@5.1.0(rollup@4.18.0)': dependencies: @@ -10057,11 +10126,11 @@ snapshots: dependencies: '@storybook/global': 5.0.0 - '@storybook/addon-interactions@8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1))': + '@storybook/addon-interactions@8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1))': dependencies: '@storybook/global': 5.0.0 '@storybook/instrumenter': 8.1.11 - '@storybook/test': 8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)) + '@storybook/test': 8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1)) '@storybook/types': 8.1.11 polished: 4.3.1 ts-dedent: 2.2.0 @@ -10159,7 +10228,7 @@ snapshots: - prettier - supports-color - '@storybook/builder-vite@8.1.11(prettier@3.3.2)(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1))': + '@storybook/builder-vite@8.1.11(prettier@3.3.2)(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1))': dependencies: '@storybook/channels': 8.1.11 '@storybook/client-logger': 8.1.11 @@ -10178,7 +10247,7 @@ snapshots: fs-extra: 11.2.0 magic-string: 0.30.10 ts-dedent: 2.2.0 - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) optionalDependencies: typescript: 5.5.3 transitivePeerDependencies: @@ -10493,11 +10562,11 @@ snapshots: react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - '@storybook/react-vite@8.1.11(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1))': + '@storybook/react-vite@8.1.11(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1))': dependencies: - '@joshwooding/vite-plugin-react-docgen-typescript': 0.3.1(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + '@joshwooding/vite-plugin-react-docgen-typescript': 0.3.1(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) '@rollup/pluginutils': 5.1.0(rollup@4.18.0) - '@storybook/builder-vite': 8.1.11(prettier@3.3.2)(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)) + '@storybook/builder-vite': 8.1.11(prettier@3.3.2)(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)) '@storybook/node-logger': 8.1.11 '@storybook/react': 8.1.11(prettier@3.3.2)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.5.3) '@storybook/types': 8.1.11 @@ -10508,7 +10577,7 @@ snapshots: react-dom: 18.3.1(react@18.3.1) resolve: 1.22.8 tsconfig-paths: 4.2.0 - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) transitivePeerDependencies: - '@preact/preset-vite' - encoding @@ -10571,14 +10640,14 @@ snapshots: - prettier - supports-color - '@storybook/test@8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1))': + '@storybook/test@8.1.11(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1))': dependencies: '@storybook/client-logger': 8.1.11 '@storybook/core-events': 8.1.11 '@storybook/instrumenter': 8.1.11 '@storybook/preview-api': 8.1.11 '@testing-library/dom': 10.1.0 - '@testing-library/jest-dom': 6.4.5(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)) + '@testing-library/jest-dom': 6.4.5(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1)) '@testing-library/user-event': 14.5.2(@testing-library/dom@10.1.0) '@vitest/expect': 1.6.0 '@vitest/spy': 1.6.0 @@ -10721,7 +10790,7 @@ snapshots: lz-string: 1.5.0 pretty-format: 27.5.1 - '@testing-library/jest-dom@6.4.5(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1))': + '@testing-library/jest-dom@6.4.5(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1))': dependencies: '@adobe/css-tools': 4.4.0 '@babel/runtime': 7.24.7 @@ -10732,9 +10801,9 @@ snapshots: lodash: 4.17.21 redent: 3.0.0 optionalDependencies: - vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1) + vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1) - '@testing-library/jest-dom@6.4.6(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1))': + '@testing-library/jest-dom@6.4.6(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1))': dependencies: '@adobe/css-tools': 4.4.0 '@babel/runtime': 7.24.7 @@ -10745,7 +10814,7 @@ snapshots: lodash: 4.17.21 redent: 3.0.0 optionalDependencies: - vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1) + vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1) '@testing-library/react@16.0.0(@testing-library/dom@10.3.0)(@types/react-dom@18.3.0)(@types/react@18.3.3)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)': dependencies: @@ -11160,18 +11229,18 @@ snapshots: '@ungap/structured-clone@1.2.0': {} - '@vitejs/plugin-react@4.3.1(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1))': + '@vitejs/plugin-react@4.3.1(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1))': dependencies: '@babel/core': 7.24.7 '@babel/plugin-transform-react-jsx-self': 7.24.7(@babel/core@7.24.7) '@babel/plugin-transform-react-jsx-source': 7.24.7(@babel/core@7.24.7) '@types/babel__core': 7.20.5 react-refresh: 0.14.2 - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) transitivePeerDependencies: - supports-color - '@vitest/coverage-v8@1.6.0(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1))': + '@vitest/coverage-v8@1.6.0(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1))': dependencies: '@ampproject/remapping': 2.3.0 '@bcoe/v8-coverage': 0.2.3 @@ -11186,7 +11255,7 @@ snapshots: std-env: 3.7.0 strip-literal: 2.1.0 test-exclude: 6.0.0 - vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1) + vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1) transitivePeerDependencies: - supports-color @@ -11221,7 +11290,7 @@ snapshots: pathe: 1.1.2 picocolors: 1.0.1 sirv: 2.0.4 - vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1) + vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1) '@vitest/utils@1.6.0': dependencies: @@ -12146,6 +12215,11 @@ snapshots: dependencies: cssom: 0.3.8 + cssstyle@4.0.1: + dependencies: + rrweb-cssom: 0.6.0 + optional: true + csstype@3.1.3: {} culvert@0.1.2: {} @@ -12154,11 +12228,11 @@ snapshots: dependencies: array-find-index: 1.0.2 - cypress-vite@1.5.0(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)): + cypress-vite@1.5.0(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)): dependencies: chokidar: 3.6.0 debug: 4.3.5(supports-color@8.1.1) - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) transitivePeerDependencies: - supports-color @@ -12237,6 +12311,12 @@ snapshots: whatwg-mimetype: 3.0.0 whatwg-url: 11.0.0 + data-urls@5.0.0: + dependencies: + whatwg-mimetype: 4.0.0 + whatwg-url: 14.0.0 + optional: true + data-view-buffer@1.0.1: dependencies: call-bind: 1.0.7 @@ -13677,6 +13757,11 @@ snapshots: dependencies: whatwg-encoding: 2.0.0 + html-encoding-sniffer@4.0.0: + dependencies: + whatwg-encoding: 3.1.1 + optional: true + html-escaper@2.0.2: {} html-tags@2.0.0: {} @@ -14286,6 +14371,35 @@ snapshots: - supports-color - utf-8-validate + jsdom@24.1.0: + dependencies: + cssstyle: 4.0.1 + data-urls: 5.0.0 + decimal.js: 10.4.3 + form-data: 4.0.0 + html-encoding-sniffer: 4.0.0 + http-proxy-agent: 7.0.2 + https-proxy-agent: 7.0.5 + is-potential-custom-element-name: 1.0.1 + nwsapi: 2.2.10 + parse5: 7.1.2 + rrweb-cssom: 0.7.1 + saxes: 6.0.0 + symbol-tree: 3.2.4 + tough-cookie: 4.1.4 + w3c-xmlserializer: 5.0.0 + webidl-conversions: 7.0.0 + whatwg-encoding: 3.1.1 + whatwg-mimetype: 4.0.0 + whatwg-url: 14.0.0 + ws: 8.18.0 + xml-name-validator: 5.0.0 + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate + optional: true + jsesc@0.5.0: {} jsesc@2.5.2: {} @@ -15689,16 +15803,16 @@ snapshots: optionalDependencies: '@types/react': 18.3.3 - react-router-dom@6.24.0(react-dom@18.3.1(react@18.3.1))(react@18.3.1): + react-router-dom@6.24.1(react-dom@18.3.1(react@18.3.1))(react@18.3.1): dependencies: - '@remix-run/router': 1.17.0 + '@remix-run/router': 1.17.1 react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - react-router: 6.24.0(react@18.3.1) + react-router: 6.24.1(react@18.3.1) - react-router@6.24.0(react@18.3.1): + react-router@6.24.1(react@18.3.1): dependencies: - '@remix-run/router': 1.17.0 + '@remix-run/router': 1.17.1 react: 18.3.1 react-style-singleton@2.2.1(@types/react@18.3.3)(react@18.3.1): @@ -16018,6 +16132,12 @@ snapshots: '@rollup/rollup-win32-x64-msvc': 4.18.0 fsevents: 2.3.3 + rrweb-cssom@0.6.0: + optional: true + + rrweb-cssom@0.7.1: + optional: true + run-async@2.4.1: {} run-parallel@1.2.0: @@ -16542,6 +16662,9 @@ snapshots: dependencies: postcss: 6.0.23 + sugarss@4.0.1: + optional: true + superagent@9.0.2: dependencies: component-emitter: 1.3.1 @@ -16772,6 +16895,11 @@ snapshots: dependencies: punycode: 2.3.1 + tr46@5.0.0: + dependencies: + punycode: 2.3.1 + optional: true + tree-kill@1.2.2: {} trim-newlines@1.0.0: {} @@ -16853,7 +16981,7 @@ snapshots: tslib: 1.14.1 typescript: 5.5.3 - tsx@4.16.0: + tsx@4.16.2: dependencies: esbuild: 0.21.5 get-tsconfig: 4.7.5 @@ -17155,7 +17283,7 @@ snapshots: debug: 4.3.5(supports-color@8.1.1) pathe: 1.1.2 picocolors: 1.0.1 - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) transitivePeerDependencies: - '@types/node' - less @@ -17166,29 +17294,57 @@ snapshots: - supports-color - terser - vite-plugin-svgr@4.2.0(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)): + vite-node@1.6.0(@types/node@20.14.9)(sugarss@4.0.1): + dependencies: + cac: 6.7.14 + debug: 4.3.5(supports-color@8.1.1) + pathe: 1.1.2 + picocolors: 1.0.1 + vite: 5.3.3(@types/node@20.14.9)(sugarss@4.0.1) + transitivePeerDependencies: + - '@types/node' + - less + - lightningcss + - sass + - stylus + - sugarss + - supports-color + - terser + + vite-plugin-svgr@4.2.0(rollup@4.18.0)(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)): dependencies: '@rollup/pluginutils': 5.1.0(rollup@4.18.0) '@svgr/core': 8.1.0(typescript@5.5.3) '@svgr/plugin-jsx': 8.1.0(@svgr/core@8.1.0(typescript@5.5.3)) - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) transitivePeerDependencies: - rollup - supports-color - typescript - vite-tsconfig-paths@4.3.2(typescript@5.5.3)(vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1)): + vite-tsconfig-paths@4.3.2(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1)): + dependencies: + debug: 4.3.5(supports-color@8.1.1) + globrex: 0.1.2 + tsconfck: 3.1.1(typescript@5.5.3) + optionalDependencies: + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) + transitivePeerDependencies: + - supports-color + - typescript + + vite-tsconfig-paths@4.3.2(typescript@5.5.3)(vite@5.3.3(@types/node@20.14.9)(sugarss@4.0.1)): dependencies: debug: 4.3.5(supports-color@8.1.1) globrex: 0.1.2 tsconfck: 3.1.1(typescript@5.5.3) optionalDependencies: - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@4.0.1) transitivePeerDependencies: - supports-color - typescript - vite@5.3.2(@types/node@20.14.9)(sugarss@1.0.1): + vite@5.3.3(@types/node@20.14.9)(sugarss@1.0.1): dependencies: esbuild: 0.21.5 postcss: 8.4.39 @@ -17198,13 +17354,23 @@ snapshots: fsevents: 2.3.3 sugarss: 1.0.1 - vitest-mock-extended@1.3.1(typescript@5.5.3)(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1)): + vite@5.3.3(@types/node@20.14.9)(sugarss@4.0.1): + dependencies: + esbuild: 0.21.5 + postcss: 8.4.39 + rollup: 4.18.0 + optionalDependencies: + '@types/node': 20.14.9 + fsevents: 2.3.3 + sugarss: 4.0.1 + + vitest-mock-extended@1.3.1(typescript@5.5.3)(vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1)): dependencies: ts-essentials: 9.4.2(typescript@5.5.3) typescript: 5.5.3 - vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1) + vitest: 1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1) - vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@20.0.3)(sugarss@1.0.1): + vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@1.0.1): dependencies: '@vitest/expect': 1.6.0 '@vitest/runner': 1.6.0 @@ -17223,13 +17389,48 @@ snapshots: strip-literal: 2.1.0 tinybench: 2.8.0 tinypool: 0.8.4 - vite: 5.3.2(@types/node@20.14.9)(sugarss@1.0.1) + vite: 5.3.3(@types/node@20.14.9)(sugarss@1.0.1) vite-node: 1.6.0(@types/node@20.14.9)(sugarss@1.0.1) why-is-node-running: 2.2.2 optionalDependencies: '@types/node': 20.14.9 '@vitest/ui': 1.6.0(vitest@1.6.0) - jsdom: 20.0.3 + jsdom: 24.1.0 + transitivePeerDependencies: + - less + - lightningcss + - sass + - stylus + - sugarss + - supports-color + - terser + + vitest@1.6.0(@types/node@20.14.9)(@vitest/ui@1.6.0)(jsdom@24.1.0)(sugarss@4.0.1): + dependencies: + '@vitest/expect': 1.6.0 + '@vitest/runner': 1.6.0 + '@vitest/snapshot': 1.6.0 + '@vitest/spy': 1.6.0 + '@vitest/utils': 1.6.0 + acorn-walk: 8.3.3 + chai: 4.4.1 + debug: 4.3.5(supports-color@8.1.1) + execa: 8.0.1 + local-pkg: 0.5.0 + magic-string: 0.30.10 + pathe: 1.1.2 + picocolors: 1.0.1 + std-env: 3.7.0 + strip-literal: 2.1.0 + tinybench: 2.8.0 + tinypool: 0.8.4 + vite: 5.3.3(@types/node@20.14.9)(sugarss@4.0.1) + vite-node: 1.6.0(@types/node@20.14.9)(sugarss@4.0.1) + why-is-node-running: 2.2.2 + optionalDependencies: + '@types/node': 20.14.9 + '@vitest/ui': 1.6.0(vitest@1.6.0) + jsdom: 24.1.0 transitivePeerDependencies: - less - lightningcss @@ -17250,6 +17451,11 @@ snapshots: dependencies: xml-name-validator: 4.0.0 + w3c-xmlserializer@5.0.0: + dependencies: + xml-name-validator: 5.0.0 + optional: true + watchpack@2.4.1: dependencies: glob-to-regexp: 0.4.1 @@ -17271,13 +17477,27 @@ snapshots: dependencies: iconv-lite: 0.6.3 + whatwg-encoding@3.1.1: + dependencies: + iconv-lite: 0.6.3 + optional: true + whatwg-mimetype@3.0.0: {} + whatwg-mimetype@4.0.0: + optional: true + whatwg-url@11.0.0: dependencies: tr46: 3.0.0 webidl-conversions: 7.0.0 + whatwg-url@14.0.0: + dependencies: + tr46: 5.0.0 + webidl-conversions: 7.0.0 + optional: true + whatwg-url@5.0.0: dependencies: tr46: 0.0.3 @@ -17411,12 +17631,18 @@ snapshots: ws@8.17.1: {} + ws@8.18.0: + optional: true + x-is-string@0.1.0: {} xdg-basedir@3.0.0: {} xml-name-validator@4.0.0: {} + xml-name-validator@5.0.0: + optional: true + xmlchars@2.2.0: {} xtend@4.0.2: {} diff --git a/tsconfig.json b/tsconfig.json index 959ef80..48c15ea 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -38,7 +38,14 @@ "forceConsistentCasingInFileNames": true }, "types": ["vitest/globals"], - "include": ["**/*.ts", "**/*.tsx", "api/vitest.config.mts", "client/vitest.config.mts", "vitest.config.mts", "vitest.workspace.mts"], + "include": [ + "**/*.ts", + "**/*.tsx", + "api/vitest.config.mts", + "client/vitest.config.mts", + "vitest.config.mts", + "vitest.workspace.mts" + ], "exclude": [ "node_modules", "**/node_modules/*", diff --git a/tsconfig.prod.json b/tsconfig.prod.json new file mode 100644 index 0000000..e9041fd --- /dev/null +++ b/tsconfig.prod.json @@ -0,0 +1,4 @@ +{ + "extends": "./tsconfig.json", + "include": ["src"] +} \ No newline at end of file