init
Some checks failed
Code Quality / lint-and-build (push) Failing after 29s
Release Packages / release (push) Failing after 41s

This commit is contained in:
2026-01-31 19:26:46 +01:00
commit 9a0900e3ff
42 changed files with 8346 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
@tailwind base;
@tailwind components;
@tailwind utilities;
:root {
--background: #ffffff;
--foreground: #171717;
}
body {
color: var(--foreground);
background: var(--background);
font-family: Arial, Helvetica, sans-serif;
}

View File

@@ -0,0 +1,19 @@
import type { Metadata } from "next";
import "./globals.css";
export const metadata: Metadata = {
title: "Sample Website",
description: "A sample website using @mintel shared packages",
};
export default function RootLayout({
children,
}: Readonly<{
children: React.ReactNode;
}>) {
return (
<html lang="en">
<body>{children}</body>
</html>
);
}

View File

@@ -0,0 +1,36 @@
"use client";
import { isValidLang, rateLimit } from "@mintel/next-utils";
export default function Home() {
const testLang = "en";
const isLangValid = isValidLang(testLang);
const handleTestRateLimit = async () => {
try {
await rateLimit("test-user");
console.log("Rate limit check passed");
} catch (e) {
console.error(e);
}
};
return (
<main className="flex min-h-screen flex-col items-center justify-between p-24">
<div className="z-10 max-w-5xl w-full items-center justify-between font-mono text-sm lg:flex">
<h1 className="text-4xl font-bold">Sample Website</h1>
<p className="mt-4">
Testing @mintel/next-utils:
<br />
Is {'"'}en{'"'} valid? {isLangValid ? "Yes" : "No"}
</p>
<button
onClick={handleTestRateLimit}
className="mt-4 px-4 py-2 bg-blue-500 text-white rounded"
>
Test Rate Limit
</button>
</div>
</main>
);
}