diff --git a/app/(default)/@breadcrumbs/[...slug]/page.tsx b/app/(default)/@breadcrumbs/[...slug]/page.tsx index 6b1510d..ec5d6b3 100644 --- a/app/(default)/@breadcrumbs/[...slug]/page.tsx +++ b/app/(default)/@breadcrumbs/[...slug]/page.tsx @@ -20,6 +20,7 @@ interface BreadcrumbItem { const BREADCRUMB_MAP: Record = { coe: "COE", + pqp: "PQP Rates", }; const generateBreadcrumbs = (slug: string[]): BreadcrumbItem[] => { diff --git a/app/(default)/coe/pqp/columns.tsx b/app/(default)/coe/pqp/columns.tsx new file mode 100644 index 0000000..942ba35 --- /dev/null +++ b/app/(default)/coe/pqp/columns.tsx @@ -0,0 +1,10 @@ +export const columns = [ + { + accessorKey: "month", + header: "Month", + }, + { accessorKey: "Category A", header: "Category A" }, + { accessorKey: "Category B", header: "Category B" }, + { accessorKey: "Category C", header: "Category C" }, + { accessorKey: "Category D", header: "Category D" }, +]; diff --git a/app/(default)/coe/pqp/page.tsx b/app/(default)/coe/pqp/page.tsx new file mode 100644 index 0000000..bfac9c4 --- /dev/null +++ b/app/(default)/coe/pqp/page.tsx @@ -0,0 +1,94 @@ +import { AlertCircle } from "lucide-react"; +import { StructuredData } from "@/components/StructuredData"; +import Typography from "@/components/Typography"; +import { Alert, AlertDescription, AlertTitle } from "@/components/ui/alert"; +import { DataTable } from "@/components/ui/data-table"; +import { API_URL, SITE_TITLE, SITE_URL } from "@/config"; +import { fetchApi } from "@/utils/fetchApi"; +import { columns } from "./columns"; +import type { WebPage, WithContext } from "schema-dts"; + +const title = "PQP Rates"; +const description = + "Latest Prevailing Quota Premium (PQP) rates for COE renewal in Singapore. These rates show the average COE prices over the last 3 months."; + +export const generateMetadata = () => { + const canonical = "/coe/pqp"; + + return { + title, + description, + openGraph: { + images: `${SITE_URL}/opengraph-image.png`, + url: canonical, + siteName: SITE_TITLE, + locale: "en_SG", + type: "website", + }, + twitter: { + card: "summary_large_image", + images: `${SITE_URL}/twitter-image.png`, + site: "@sgcarstrends", + creator: "@sgcarstrends", + }, + alternates: { + canonical, + }, + }; +}; + +const PQPRatesPage = async () => { + const pqpRates = await fetchApi< + Array>> + >(`${API_URL}/coe/pqp`); + + const data = Object.entries(pqpRates).map(([month, pqpRates]) => ({ + month, + ...pqpRates, + })); + + const structuredData: WithContext = { + "@context": "https://schema.org", + "@type": "WebPage", + name: title, + description, + url: `${SITE_URL}/coe/pqp`, + }; + + return ( + <> + +
+ PQP Rates + + + Understanding PQP Rates + + + Certificate of Entitlement (COE) Prevailing Quota Premium (PQP) + rates are specific to Singapore's vehicle ownership system. + They represent the average COE prices over the last 3 months, + which car owners must pay to renew their existing vehicle's + COE. + + + The PQP system allows car owners to extend their COE for another 5 + or 10 years by paying the prevailing market rate rather than + bidding in the open market. This is particularly relevant for + owners who wish to keep their vehicles beyond the initial 10-year + COE period. + + + The Land Transport Authority (LTA) calculates and updates these + rates monthly based on the moving average of COE prices in the + preceding three months. + + + + +
+ + ); +}; + +export default PQPRatesPage; diff --git a/components/AppSidebar.tsx b/components/AppSidebar.tsx index 5a22901..7b10ad0 100644 --- a/components/AppSidebar.tsx +++ b/components/AppSidebar.tsx @@ -265,6 +265,10 @@ const data: Nav = { icon: DollarSign, url: "/coe", }, + { + title: "PQP Rates", + url: "/coe/pqp", + }, // { // title: "COE", // icon: "", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index dfb5df1..27aaeeb 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -5283,7 +5283,7 @@ snapshots: '@babel/generator@7.17.7': dependencies: - '@babel/types': 7.17.0 + '@babel/types': 7.26.7 jsesc: 2.5.2 source-map: 0.5.7 optional: true @@ -8184,7 +8184,7 @@ snapshots: dom-helpers@5.2.1: dependencies: - '@babel/runtime': 7.26.0 + '@babel/runtime': 7.26.7 csstype: 3.1.3 domexception@4.0.0: @@ -10009,7 +10009,7 @@ snapshots: react-transition-group@4.4.5(react-dom@19.0.0(react@19.0.0))(react@19.0.0): dependencies: - '@babel/runtime': 7.26.0 + '@babel/runtime': 7.26.7 dom-helpers: 5.2.1 loose-envify: 1.4.0 prop-types: 15.8.1 @@ -10068,7 +10068,7 @@ snapshots: regenerator-transform@0.15.2: dependencies: - '@babel/runtime': 7.26.0 + '@babel/runtime': 7.26.7 regexp.prototype.flags@1.5.2: dependencies: