AI Review Center
Commit Review Workspace ?
Select a commit on the left to inspect quality, security, business value, findings, and suggested code changes.
Project AI Score
?
63%
Quality Avg
?
68%
Security Avg
?
45%
Reviews
?
56
Review Result ?
jattin01/avriti · bd16c07d
The commit adds many repeated hardcoded product details to multiple pages, resulting in low code quality and maintainability. It introduces redundancy without apparent dynamic data handling or separation of concerns. While the use of Image components is good for optimization, the lack of comments, testing, or logic reduces business value and increases bug risk. No obvious security issues detected but minimal security improvements.
Quality
?
40%
Security
?
50%
Business Value
?
30%
Maintainability
?
60%
Issues & Suggested Fixes
?
1AI detects the issue
2Shows file, line, or evidence
3Suggests the fix to apply
Duplicate Logic
Where
app/cart/page.tsx:9
Issue / Evidence
repeated hardcoded data
Suggested Fix
use data-driven approach or JSON to avoid duplication
Duplicate Logic
Where
app/cart/page.tsx:19
Issue / Evidence
repeated hardcoded data
Suggested Fix
consolidate product info to a central data source
Duplicate Logic
Where
app/page.tsx:14
Issue / Evidence
repeated hardcoded data
Suggested Fix
refactor to avoid duplication across pages
Define Props And Types Clearly
Where
app/profile/page.tsx:32
Issue / Evidence
define props and types clearly
Suggested Fix
add comments for component usage clarity
Missing Test Coverage
Where
app/profile/page.tsx:74
Issue / Evidence
missing unit tests
Suggested Fix
add tests for new components like IconBtn and Card
Import Order
Where
components/site-footer.tsx:5
Issue / Evidence
import order
Suggested Fix
organize imports for readability
Import Order
Where
components/whatsapp-cta.tsx:3
Issue / Evidence
import order
Suggested Fix
organize imports consistently
Vague Commit Message
Where
commit message
Issue / Evidence
vague commit message
Suggested Fix
provide detailed description of changes and purpose
Code Change Preview · app/cart/page.tsx
?
Removed / Before Commit
- { - slug: "shuddhi-mopping-salt", - name: "Avriti Shuddhi - Mopping Salt - 1kg", - price: 299, - image: "/product2.jpeg", - tone: "from-[#E8EDFB] to-[#D0D9F7]", - }, - { - slug: "jal-shuddhi-bathroom-salt", - name: "Avriti Jal Shuddhi - Bathroom Salt - 250g", - price: 359, - image: "/product3.jpeg", - tone: "from-[#F4F0E8] to-[#EDE4DC]", - }, - { - slug: "drishti-tarot-78", - name: "Drishti Tarot Cards - Pack of 78 cards", - price: 299,
Added / After Commit
+ { + slug: "shuddhi-mopping-salt", + name: "Avriti Shuddhi - Mopping Salt - 1kg", + price: "299", + category: "Salt", + badge: "New", + description: "Premium mopping salt for daily use.", + image: "/product2.jpeg", + tone: "from-[#E8EDFB] to-[#D0D9F7]", + }, + { + slug: "jal-shuddhi-bathroom-salt", + name: "Avriti Jal Shuddhi - Bathroom Salt - 250g", + price: "359", + category: "Salt", + badge: "New", + description: "Premium mopping salt for daily use.", + image: "/product3.jpeg",
Removed / Before Commit
- { - slug: "shuddhi-mopping-salt", - name: "Avriti Shuddhi - Mopping Salt - 1kg", - price: 299, - image: "/product2.jpeg", - tone: "from-[#E8EDFB] to-[#D0D9F7]", - }, - { - slug: "jal-shuddhi-bathroom-salt", - name: "Avriti Jal Shuddhi - Bathroom Salt - 250g", - price: 359, - image: "/product3.jpeg", - tone: "from-[#F4F0E8] to-[#EDE4DC]", - }, - { - slug: "drishti-tarot-78", - name: "Drishti Tarot Cards - Pack of 78 cards", - price: 299,
Added / After Commit
+ { + slug: "shuddhi-mopping-salt", + name: "Avriti Shuddhi - Mopping Salt - 1kg", + price: "299", + image: "/product2.jpeg", + tone: "from-[#E8EDFB] to-[#D0D9F7]", + category: "Salt", + badge: "New", + description: "Premium mopping salt for daily use.", + }, + { + slug: "jal-shuddhi-bathroom-salt", + name: "Avriti Jal Shuddhi - Bathroom Salt - 250g", + price: "359", + image: "/product3.jpeg", + tone: "from-[#F4F0E8] to-[#EDE4DC]", + category: "Salt", + badge: "New",
Removed / Before Commit
- - import { useState } from "react"; - import Link from "next/link"; - import { FontAwesomeIcon } from "@fortawesome/react-fontawesome"; - import { - faUser, faBoxOpen, faMapMarkerAlt, faSignOutAlt, - { key: "security", label: "Security", icon: faShieldAlt }, - ]; - - function InfoRow({ label, value }) { - return ( - <div className="flex items-center justify-between py-3 border-b border-[#F0EDE9] last:border-0"> - <span className="text-sm text-[#9E9890]">{label}</span> - ); - } - - function Card({ children, className = "" }) { - return (
Added / After Commit
+ + import { useState } from "react"; + import Link from "next/link"; + import type { ReactNode } from "react"; + import { FontAwesomeIcon } from "@fortawesome/react-fontawesome"; + import { + faUser, faBoxOpen, faMapMarkerAlt, faSignOutAlt, + { key: "security", label: "Security", icon: faShieldAlt }, + ]; + + interface InfoRowProps { + label: string; + value: string; + } + + function InfoRow({ label, value }: InfoRowProps) { + return ( + <div className="flex items-center justify-between py-3 border-b border-[#F0EDE9] last:border-0">
Removed / Before Commit
- import { Camera, PlaySquare } from "lucide-react"; - import { Button } from "@/components/ui/button"; - import { Input } from "@/components/ui/input"; - - export function SiteFooter() { - return ( - <footer className="border-t border-[var(--color-border)] bg-[#f8fbff]"> - <div className="mx-auto grid max-w-7xl gap-10 px-4 py-12 sm:px-6 lg:grid-cols-[1.2fr_0.8fr_1fr] lg:px-8"> - <div> - <img - src="/logo1.png" - alt="Avriti" - fill - sizes="112px" - className="object-contain w-[100px]" - priority - /> - <p className="mt-4 max-w-sm text-sm leading-6 text-[var(--color-text-secondary)]">
Added / After Commit
+ import { Camera, PlaySquare } from "lucide-react"; + import { Button } from "@/components/ui/button"; + import { Input } from "@/components/ui/input"; + import Image from "next/image"; + + export function SiteFooter() { + return ( + <footer className="border-t border-[var(--color-border)] bg-[#f8fbff]"> + <div className="mx-auto grid max-w-7xl gap-10 px-4 py-12 sm:px-6 lg:grid-cols-[1.2fr_0.8fr_1fr] lg:px-8"> + <div> + <Image + src="/logo1.png" + alt="Avriti" + fill + sizes="112px" + className="object-contain" + priority + />
Removed / Before Commit
- import Link from "next/link"; - import { MessageCircle } from "lucide-react"; - - export function WhatsAppCta() { - return ( - className="fixed bottom-5 right-5 z-50 inline-flex h-14 w-14 items-center justify-center rounded-full bg-[#25D366] text-white shadow-[var(--shadow-soft)] transition hover:bg-[var(--color-primary-600)]" - aria-label="Message Avriti on WhatsApp" - > - <img - src="/whatsapp.png" - alt="Avriti" - fill
Added / After Commit
+ import Link from "next/link"; + import { MessageCircle } from "lucide-react"; + import Image from "next/image"; + + export function WhatsAppCta() { + return ( + className="fixed bottom-5 right-5 z-50 inline-flex h-14 w-14 items-center justify-center rounded-full bg-[#25D366] text-white shadow-[var(--shadow-soft)] transition hover:bg-[var(--color-primary-600)]" + aria-label="Message Avriti on WhatsApp" + > + <Image + src="/whatsapp.png" + alt="Avriti" + fill