diff --git a/__tests__/card.test.tsx b/__tests__/card.test.tsx
deleted file mode 100644
index 0013132..0000000
--- a/__tests__/card.test.tsx
+++ /dev/null
@@ -1,77 +0,0 @@
-import { render } from "@testing-library/react";
-import { createRef } from "react";
-import { describe, expect, it } from "vitest";
-import { Card, CardContent, CardHeader, CardTitle } from "@/components/atoms/card";
-
-describe("Card", () => {
- it("renders its children", () => {
- const { getByText } = render(card content);
- expect(getByText("card content")).toBeInTheDocument();
- });
-
- it("forwards the ref to the underlying div", () => {
- const ref = createRef();
- render(card);
- expect(ref.current).toBeInstanceOf(HTMLDivElement);
- });
-
- it("merges custom className", () => {
- const { container } = render(card);
- expect(container.firstElementChild?.className).toContain("my-custom");
- });
-});
-
-describe("CardHeader", () => {
- it("renders its children", () => {
- const { getByText } = render(header content);
- expect(getByText("header content")).toBeInTheDocument();
- });
-
- it("forwards the ref to the underlying div", () => {
- const ref = createRef();
- render(header);
- expect(ref.current).toBeInstanceOf(HTMLDivElement);
- });
-
- it("merges custom className", () => {
- const { container } = render(header);
- expect(container.firstElementChild?.className).toContain("my-custom");
- });
-});
-
-describe("CardTitle", () => {
- it("renders its children as an h3", () => {
- const { container, getByText } = render(title content);
- expect(getByText("title content")).toBeInTheDocument();
- expect(container.querySelector("h3")).not.toBeNull();
- });
-
- it("forwards the ref to the underlying heading", () => {
- const ref = createRef();
- render(title);
- expect(ref.current).toBeInstanceOf(HTMLHeadingElement);
- });
-
- it("merges custom className", () => {
- const { container } = render(title);
- expect(container.querySelector("h3")?.className).toContain("my-custom");
- });
-});
-
-describe("CardContent", () => {
- it("renders its children", () => {
- const { getByText } = render(content body);
- expect(getByText("content body")).toBeInTheDocument();
- });
-
- it("forwards the ref to the underlying div", () => {
- const ref = createRef();
- render(content);
- expect(ref.current).toBeInstanceOf(HTMLDivElement);
- });
-
- it("merges custom className", () => {
- const { container } = render(content);
- expect(container.firstElementChild?.className).toContain("my-custom");
- });
-});
diff --git a/__tests__/stat-box.test.tsx b/__tests__/stat-box.test.tsx
index 4977793..8cca41e 100644
--- a/__tests__/stat-box.test.tsx
+++ b/__tests__/stat-box.test.tsx
@@ -15,21 +15,11 @@ describe("StatBox", () => {
expect(container.firstElementChild?.className).toContain("border-emerald-100");
});
- it("renders with the warning variant", () => {
- const { container } = render();
- expect(container.firstElementChild?.className).toContain("border-amber-100");
- });
-
it("renders with the danger variant", () => {
const { container } = render();
expect(container.firstElementChild?.className).toContain("border-red-100");
});
- it("renders with the purple variant", () => {
- const { container } = render();
- expect(container.firstElementChild?.className).toContain("border-purple-100");
- });
-
it("renders subValue only when provided", () => {
const { queryByText, rerender } = render();
expect(queryByText("extra info")).toBeNull();
diff --git a/components/atoms/card.tsx b/components/atoms/card.tsx
deleted file mode 100644
index a7b4aea..0000000
--- a/components/atoms/card.tsx
+++ /dev/null
@@ -1,35 +0,0 @@
-import * as React from "react";
-import { cn } from "@/lib/utils";
-
-const Card = React.forwardRef>(({ className, ...props }, ref) => (
-
-));
-Card.displayName = "Card";
-
-const CardHeader = React.forwardRef>(
- ({ className, ...props }, ref) => (
-
- ),
-);
-CardHeader.displayName = "CardHeader";
-
-const CardTitle = React.forwardRef>(
- ({ className, ...props }, ref) => (
-
- ),
-);
-CardTitle.displayName = "CardTitle";
-
-const CardContent = React.forwardRef>(
- ({ className, ...props }, ref) => ,
-);
-CardContent.displayName = "CardContent";
-
-export { Card, CardContent, CardHeader, CardTitle };
diff --git a/components/molecules/copy-button.tsx b/components/molecules/copy-button.tsx
index 62093e1..13d9321 100644
--- a/components/molecules/copy-button.tsx
+++ b/components/molecules/copy-button.tsx
@@ -11,8 +11,7 @@ const STATUS_MESSAGES: Record = {
failed: "Não foi possível copiar",
};
-const STATUS_RESET_MS: Record = {
- idle: 0,
+const STATUS_RESET_MS: Record, number> = {
copied: 2000,
failed: 4000,
};
diff --git a/components/molecules/stat-box.tsx b/components/molecules/stat-box.tsx
index e99a260..1f2f5a7 100644
--- a/components/molecules/stat-box.tsx
+++ b/components/molecules/stat-box.tsx
@@ -6,7 +6,7 @@ interface StatBoxProps extends React.HTMLAttributes {
value: string;
subValue?: string;
icon?: React.ReactNode;
- variant?: "default" | "success" | "warning" | "danger" | "purple";
+ variant?: "default" | "success" | "danger";
}
export function StatBox({ label, value, subValue, icon, variant = "default", className, ...props }: StatBoxProps) {
@@ -17,9 +17,7 @@ export function StatBox({ label, value, subValue, icon, variant = "default", cla
{
"bg-blue-50/50 border-blue-100 dark:bg-blue-900/10 dark:border-blue-800": variant === "default",
"bg-emerald-50/50 border-emerald-100 dark:bg-emerald-900/10 dark:border-emerald-800": variant === "success",
- "bg-amber-50/50 border-amber-100 dark:bg-amber-900/10 dark:border-amber-800": variant === "warning",
"bg-red-50/50 border-red-100 dark:bg-red-900/10 dark:border-red-800": variant === "danger",
- "bg-purple-50/50 border-purple-100 dark:bg-purple-900/10 dark:border-purple-800": variant === "purple",
},
className,
)}
@@ -33,9 +31,7 @@ export function StatBox({ label, value, subValue, icon, variant = "default", cla
className={cn("text-2xl font-bold tracking-tight tabular-nums", {
"text-blue-600 dark:text-blue-400": variant === "default",
"text-emerald-600 dark:text-emerald-400": variant === "success",
- "text-amber-600 dark:text-amber-400": variant === "warning",
"text-red-600 dark:text-red-400": variant === "danger",
- "text-purple-600 dark:text-purple-400": variant === "purple",
})}
>
{value}
diff --git a/metadata.json b/metadata.json
deleted file mode 100644
index 2fa5479..0000000
--- a/metadata.json
+++ /dev/null
@@ -1,5 +0,0 @@
-{
- "name": "WorkLoad",
- "description": "Calculadora inteligente de jornada e valor de trabalho.",
- "requestFramePermissions": []
-}
diff --git a/next.config.ts b/next.config.ts
index 4651b50..b72dd64 100644
--- a/next.config.ts
+++ b/next.config.ts
@@ -3,10 +3,6 @@ import type { NextConfig } from "next";
const nextConfig: NextConfig = {
reactStrictMode: true,
poweredByHeader: false,
- typescript: {
- ignoreBuildErrors: false,
- },
- transpilePackages: ["motion"],
};
export default nextConfig;
diff --git a/package-lock.json b/package-lock.json
index 3dcf858..7e0d7a4 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -9,7 +9,6 @@
"version": "1.0.0",
"dependencies": {
"@next/third-parties": "^16.2.4",
- "autoprefixer": "^10.4.21",
"clsx": "^2.1.1",
"date-fns": "^4.1.0",
"lucide-react": "^0.553.0",
@@ -2800,42 +2799,6 @@
"dev": true,
"license": "MIT"
},
- "node_modules/autoprefixer": {
- "version": "10.5.4",
- "resolved": "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.5.4.tgz",
- "integrity": "sha512-MaU0U/za7N3r6brxD4YB/l4NSrFzLPlANv6wEuQVaIPlD3L4W9rFcQPbL/EilY9BHhHvhfcz3gInDLrEtWT4EA==",
- "funding": [
- {
- "type": "opencollective",
- "url": "https://opencollective.com/postcss/"
- },
- {
- "type": "tidelift",
- "url": "https://tidelift.com/funding/github/npm/autoprefixer"
- },
- {
- "type": "github",
- "url": "https://github.com/sponsors/ai"
- }
- ],
- "license": "MIT",
- "dependencies": {
- "browserslist": "^4.28.6",
- "caniuse-lite": "^1.0.30001806",
- "fraction.js": "^5.3.4",
- "picocolors": "^1.1.1",
- "postcss-value-parser": "^4.2.0"
- },
- "bin": {
- "autoprefixer": "bin/autoprefixer"
- },
- "engines": {
- "node": "^10 || ^12 || >=14"
- },
- "peerDependencies": {
- "postcss": "^8.1.0"
- }
- },
"node_modules/axe-core": {
"version": "4.12.1",
"resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.12.1.tgz",
@@ -2953,18 +2916,6 @@
"bare-path": "^3.0.0"
}
},
- "node_modules/baseline-browser-mapping": {
- "version": "2.11.10",
- "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.11.10.tgz",
- "integrity": "sha512-35JEvJ5/KKlbCHjMCsONI2w6HE88STjVdHk+C7d8LtcFxUjZR1KeLP9izofn2qs0KUxX5r4z73bwH/rd+JHacw==",
- "license": "Apache-2.0",
- "bin": {
- "baseline-browser-mapping": "dist/cli.cjs"
- },
- "engines": {
- "node": ">=6.0.0"
- }
- },
"node_modules/basic-ftp": {
"version": "5.3.1",
"resolved": "https://registry.npmjs.org/basic-ftp/-/basic-ftp-5.3.1.tgz",
@@ -3038,39 +2989,6 @@
"concat-map": "0.0.1"
}
},
- "node_modules/browserslist": {
- "version": "4.28.7",
- "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.7.tgz",
- "integrity": "sha512-JxV13hNrFxqjOc8alRbq9dK1MM79NEXYpma2B2J4wAtpWS5zIEIKqWPGCl7N4o7Uc7B7itylh7SuDujATRyyTw==",
- "funding": [
- {
- "type": "opencollective",
- "url": "https://opencollective.com/browserslist"
- },
- {
- "type": "tidelift",
- "url": "https://tidelift.com/funding/github/npm/browserslist"
- },
- {
- "type": "github",
- "url": "https://github.com/sponsors/ai"
- }
- ],
- "license": "MIT",
- "dependencies": {
- "baseline-browser-mapping": "^2.10.44",
- "caniuse-lite": "^1.0.30001806",
- "electron-to-chromium": "^1.5.393",
- "node-releases": "^2.0.51",
- "update-browserslist-db": "^1.2.3"
- },
- "bin": {
- "browserslist": "cli.js"
- },
- "engines": {
- "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7"
- }
- },
"node_modules/buffer-crc32": {
"version": "0.2.13",
"resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz",
@@ -3758,12 +3676,6 @@
"dev": true,
"license": "MIT"
},
- "node_modules/electron-to-chromium": {
- "version": "1.5.399",
- "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.399.tgz",
- "integrity": "sha512-lEcqhErbHjXRvd41rnWLpzbyU/IXfIYo7QwaFWmxGeLiLyY2TBCdHnWY88vB+p3ubnihRypDm66panXl7TylLA==",
- "license": "ISC"
- },
"node_modules/emoji-regex": {
"version": "8.0.0",
"resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz",
@@ -3889,6 +3801,7 @@
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz",
"integrity": "sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=6"
@@ -4228,19 +4141,6 @@
"node": ">= 0.6"
}
},
- "node_modules/fraction.js": {
- "version": "5.3.4",
- "resolved": "https://registry.npmjs.org/fraction.js/-/fraction.js-5.3.4.tgz",
- "integrity": "sha512-1X1NTtiJphryn/uLQz3whtY6jK3fTqoE3ohKs0tT+Ujr1W59oopxmoEh7Lu5p6vBaPbgoM0bzveAW4Qi5RyWDQ==",
- "license": "MIT",
- "engines": {
- "node": "*"
- },
- "funding": {
- "type": "github",
- "url": "https://github.com/sponsors/rawify"
- }
- },
"node_modules/framer-motion": {
"version": "12.43.0",
"resolved": "https://registry.npmjs.org/framer-motion/-/framer-motion-12.43.0.tgz",
@@ -5973,15 +5873,6 @@
"webidl-conversions": "^3.0.0"
}
},
- "node_modules/node-releases": {
- "version": "2.0.51",
- "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.51.tgz",
- "integrity": "sha512-wRNIrw4DmVLKQlbgOMdkMx27Wrpzes2hh5Jtbi2bjPd+4wJstWIqP5A+lscnqbm0xxmT5Bpg8Lec5ItEBwx6BQ==",
- "license": "MIT",
- "engines": {
- "node": ">=18"
- }
- },
"node_modules/object-inspect": {
"version": "1.13.4",
"resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz",
@@ -6304,12 +6195,6 @@
"node": "^10 || ^12 || >=14"
}
},
- "node_modules/postcss-value-parser": {
- "version": "4.2.0",
- "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz",
- "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==",
- "license": "MIT"
- },
"node_modules/pretty-format": {
"version": "27.5.1",
"resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-27.5.1.tgz",
@@ -7537,36 +7422,6 @@
"node": ">= 0.8"
}
},
- "node_modules/update-browserslist-db": {
- "version": "1.2.3",
- "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.2.3.tgz",
- "integrity": "sha512-Js0m9cx+qOgDxo0eMiFGEueWztz+d4+M3rGlmKPT+T4IS/jP4ylw3Nwpu6cpTTP8R1MAC1kF4VbdLt3ARf209w==",
- "funding": [
- {
- "type": "opencollective",
- "url": "https://opencollective.com/browserslist"
- },
- {
- "type": "tidelift",
- "url": "https://tidelift.com/funding/github/npm/browserslist"
- },
- {
- "type": "github",
- "url": "https://github.com/sponsors/ai"
- }
- ],
- "license": "MIT",
- "dependencies": {
- "escalade": "^3.2.0",
- "picocolors": "^1.1.1"
- },
- "bin": {
- "update-browserslist-db": "cli.js"
- },
- "peerDependencies": {
- "browserslist": ">= 4.21.0"
- }
- },
"node_modules/utils-merge": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz",
diff --git a/package.json b/package.json
index 3d6e314..06a9f4d 100644
--- a/package.json
+++ b/package.json
@@ -24,7 +24,6 @@
},
"dependencies": {
"@next/third-parties": "^16.2.4",
- "autoprefixer": "^10.4.21",
"clsx": "^2.1.1",
"date-fns": "^4.1.0",
"lucide-react": "^0.553.0",
diff --git a/playwright.config.ts b/playwright.config.ts
index 0baa2eb..7e6f1de 100644
--- a/playwright.config.ts
+++ b/playwright.config.ts
@@ -27,7 +27,6 @@ export default defineConfig({
],
},
},
- testIgnore: [],
testMatch: "**/*.spec.ts",
projects: [
{