Add privacy policy and terms pages

Replace placeholder pages with detailed legal documents covering data handling, Google Calendar use, user rights, and service terms. Add a shared legal page layout and metadata, plus Google site verification.
This commit is contained in:
Ichsan Kurniawan
2026-11-19 10:39:26 +07:00
parent d10603acc8
commit ef06bed081
5 changed files with 664 additions and 42 deletions
+1
View File
@@ -103,6 +103,7 @@ export default async function RootLayout({
return ( return (
<html lang="en" suppressHydrationWarning> <html lang="en" suppressHydrationWarning>
<head> <head>
<meta name="google-site-verification" content="q4skPMDX5KDkaJOhjnvBrAowMlMJc__AekSaH_Je4Hg" />
<link rel="apple-touch-icon" href="/assets/apple-touch-icon.png" /> <link rel="apple-touch-icon" href="/assets/apple-touch-icon.png" />
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@tabler/icons-webfont@3.35.0/dist/tabler-icons.min.css" crossOrigin="anonymous" referrerPolicy="no-referrer"></link> <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@tabler/icons-webfont@3.35.0/dist/tabler-icons.min.css" crossOrigin="anonymous" referrerPolicy="no-referrer"></link>
</head> </head>
+284 -21
View File
@@ -1,26 +1,289 @@
'use client' import type { Metadata } from 'next';
import { FC } from 'react'; import { A, DataTable, LegalLayout, LegalSection, UL } from '@/components/legal/LegalLayout';
import { Button } from '@/components/ui/button'; import { LEGAL } from '@/lib/legal';
import { useRouter } from 'next/navigation';
type Props = {}; export const metadata: Metadata = {
title: `Privacy Policy | ${LEGAL.shortName}`,
description: `How ${LEGAL.appName} collects, uses, stores and protects personal data, including data from Google Calendar.`,
};
const PrivacyPolicyPage: FC<Props> = ({ }) => { const sections: LegalSection[] = [
const router = useRouter() {
id: 'about',
title: 'Who we are and what this covers',
body: (
<>
<p>
{LEGAL.appName} ({LEGAL.shortName}) is a workplace web application at{' '}
<A href={LEGAL.siteUrl}>{LEGAL.siteUrl}</A>. It is operated by {LEGAL.operator} and used by employees and
administrators for attendance, task and project assignment, leave and permit requests, and approvals.
</p>
<p>
This policy explains what personal data {LEGAL.shortName} handles, why, who can see it, how long it is kept,
and the choices you have. It applies to the {LEGAL.shortName} website, the installable web app (PWA) and
its integration with Google Calendar.
</p>
</>
),
},
{
id: 'data-we-collect',
title: 'Data we collect',
body: (
<>
<p>We only collect data needed to run the features you use.</p>
<DataTable
head={['Category', 'What it includes', 'Why we need it']}
rows={[
[
'Account',
'Name, work email, password (stored by our backend in protected form), role, division, area, employee position and type.',
'To sign you in and decide what you are allowed to see and do.',
],
[
'Attendance',
'Check-in and check-out time, GPS coordinates at that moment, a photo taken with your device camera, work status (for example office or remote), and device details.',
'To record working hours and let managers verify attendance.',
],
[
'Leave, permit and sick requests',
'Request type, dates, reason, supporting attachments, signature, and approval decisions.',
'To process requests and produce the request documents (PDF).',
],
[
'Tasks and projects',
'Task titles, descriptions, due dates, status, assignees, client and project names.',
'To plan and track work assigned to you or your team.',
],
[
'Notifications',
'A push notification token from Firebase Cloud Messaging for your browser or device.',
'To deliver reminders and approval alerts you have allowed.',
],
[
'Usage and security logs',
'Sign-in events, audit trail entries (who changed what and when), IP address, browser type and error logs.',
'To keep the service secure, investigate problems and keep an audit record.',
],
]}
/>
<p>
Camera and location are requested through your browser. They are only used when you open an attendance
screen, and you can refuse the permission. Without them, attendance that requires a photo or location
cannot be submitted.
</p>
</>
),
},
{
id: 'google-data',
title: 'Google user data and Google Calendar',
body: (
<>
<p>
{LEGAL.shortName} connects to the <strong>Google Calendar API</strong> to show and manage work schedules and
task due dates on a Google Calendar owned by the organisation. This section describes exactly what is
accessed and how it is used.
</p>
<p>
<strong>How access works.</strong> Employees sign in to {LEGAL.shortName} with their work email and
password, not with Google. The Calendar connection is made once by an administrator, using an
organisation-managed Google account that authorises {LEGAL.shortName} through Google OAuth 2.0. The resulting
refresh token is kept on our server as a protected configuration value. It is never sent to your browser.
{LEGAL.shortName} does not read the personal calendar, email, contacts or Drive files of employees.
</p>
<p>The scopes requested, and why:</p>
<DataTable
head={['Scope', 'What it allows', 'How H.A.T.s uses it']}
rows={[
[
<code key="a" className="break-all text-[13px]">https://www.googleapis.com/auth/calendar</code>,
'See, create, edit and delete calendars and their events.',
'Reads the shared work calendar so schedules appear in the app, and manages that calendar when authorised users publish or change work items.',
],
[
<code key="b" className="break-all text-[13px]">https://www.googleapis.com/auth/calendar.events</code>,
'See, create, edit and delete events on calendars.',
'Creates, updates and removes events and due dates when a user adds, edits or deletes a schedule or task, and optionally adds a Google Meet link and guest emails.',
],
]}
/>
<p>The Google data involved is limited to:</p>
<UL>
<li>Event title, description, location, start and end time, all-day flag and colour.</li>
<li>Guest email addresses on an event, and Google Meet or event links.</li>
<li>The creator email and created or updated timestamps of an event.</li>
</UL>
<p>
<strong>Use and storage.</strong> Calendar data is requested from Google when a page needs it and is
displayed to authorised users. {LEGAL.shortName} does not build a separate copy of calendar content for any
other purpose. Items that users create inside {LEGAL.shortName} are saved in our own database as well as in
the calendar.
</p>
<p>
<strong>Limited Use.</strong> {LEGAL.shortName}&apos;s use and transfer of information received from Google
APIs to any other app adheres to the{' '}
<A href="https://developers.google.com/terms/api-services-user-data-policy">
Google API Services User Data Policy
</A>
, including the Limited Use requirements. In particular:
</p>
<UL>
<li>We use Google data only to provide and improve the user-facing calendar and task features described here.</li>
<li>We do not sell Google data and do not transfer it to third parties, except where needed to provide these features, to follow the law, or to protect the security of the service.</li>
<li>We do not use Google data for advertising, including retargeting or interest-based ads.</li>
<li>We do not use Google data to develop, improve or train generalised AI or machine learning models.</li>
<li>Our staff do not read Google data unless an administrator gives permission for a specific support case, it is needed for security or abuse investigation, or the law requires it.</li>
</UL>
<p>
<strong>Revoking access.</strong> The administrator of the connected Google account can remove{' '}
{LEGAL.shortName} at any time at{' '}
<A href="https://myaccount.google.com/permissions">myaccount.google.com/permissions</A>. After that, the
calendar features stop working and Google data is no longer fetched. To ask us to delete items created by
the integration, contact us using the details in section 11.
</p>
</>
),
},
{
id: 'how-we-use',
title: 'How we use data',
body: (
<UL>
<li>Authenticate you and enforce role-based access.</li>
<li>Record, display and report attendance, leave, permits and approvals.</li>
<li>Assign, schedule and track tasks and projects, including syncing them with Google Calendar.</li>
<li>Send notifications you have enabled.</li>
<li>Protect the service, detect misuse such as falsified location or photos, and keep an audit trail.</li>
<li>Fix bugs and keep the application working.</li>
</UL>
),
},
{
id: 'sharing',
title: 'Who can see your data and who we share it with',
body: (
<>
<p>
<strong>Inside your organisation.</strong> Your managers, HR and administrators can see attendance, leave and
task data that their role permits. Colleagues see only what the features they use expose, such as shared
calendar entries.
</p>
<p>
<strong>Service providers.</strong> We rely on a small set of providers to run the service:
</p>
<UL>
<li><strong>Google</strong> for the Calendar API (section 3) and Firebase Cloud Messaging for push notifications.</li>
<li><strong>Our hosting provider</strong> for the server and database that run {LEGAL.shortName}.</li>
</UL>
<p>
We do not sell personal data and we do not share it for advertising. We may disclose data when the law or a
valid legal request requires it.
</p>
</>
),
},
{
id: 'cookies',
title: 'Cookies and local storage',
body: (
<>
<p>{LEGAL.shortName} uses only what it needs to work:</p>
<UL>
<li>A secure session cookie that keeps you signed in.</li>
<li>Local storage for your theme choice (light, dark or system).</li>
<li>A service worker and cache so the installed web app can load and show an offline page.</li>
</UL>
<p>We do not use advertising or cross-site tracking cookies.</p>
</>
),
},
{
id: 'retention',
title: 'How long we keep data',
body: (
<>
<p>
Attendance, leave and audit records are kept while your account is active and for as long as your organisation
needs them for payroll, labour and audit obligations. After that they are deleted or anonymised.
</p>
<p>
When an account is deactivated, access ends right away. Data tied to it is removed or anonymised on request,
unless a record must be kept by law or for an open dispute. Push tokens are removed when you sign out or
revoke notification permission. Server logs are kept only as long as needed for security and debugging.
</p>
</>
),
},
{
id: 'security',
title: 'How we protect data',
body: (
<UL>
<li>Traffic between your device and {LEGAL.shortName} is encrypted with HTTPS.</li>
<li>Role-based access control limits each user to the data their job needs.</li>
<li>Google OAuth tokens and API credentials are held on the server as protected configuration, not in the browser or the source code shared with users.</li>
<li>Changes to important records are written to an audit trail.</li>
</UL>
),
},
{
id: 'your-rights',
title: 'Your rights and choices',
body: (
<>
<p>You can ask us to:</p>
<UL>
<li>Give you a copy of the personal data we hold about you.</li>
<li>Correct data that is wrong or out of date.</li>
<li>Delete your data, where we are not required to keep it.</li>
<li>Stop optional processing, for example by turning off notifications in your browser settings.</li>
</UL>
<p>
Some changes, such as editing a submitted attendance record, may need approval from your administrator
because the organisation relies on it as a record. Where Indonesian data protection law (Law No. 27 of 2022
on Personal Data Protection) applies, you hold the rights it provides.
</p>
</>
),
},
{
id: 'children',
title: 'Children',
body: (
<p>
{LEGAL.shortName} is a workplace tool for employees and is not directed to children under 17. We do not knowingly
collect data from children. If you believe a child&apos;s data was submitted, contact us and we will delete it.
</p>
),
},
{
id: 'contact',
title: 'Contact and changes to this policy',
body: (
<>
<p>
For privacy questions, access or deletion requests, or Google data concerns, email{' '}
<A href={`mailto:${LEGAL.contactEmail}`}>{LEGAL.contactEmail}</A>. We aim to reply within 14 days.
</p>
<p>
If we change this policy, we will update the date at the top of this page. For material changes, including
any new Google scope, we will tell users inside the app before the change takes effect. See also our{' '}
<A href="/terms">Terms of Service</A>.
</p>
</>
),
},
];
return ( export default function PrivacyPolicyPage() {
<> return (
<div className="h-screen flex flex-col justify-center items-center"> <LegalLayout
<h2 className="text-xl sm:text-2xl font-semibold tracking-tight text-center">Privacy Policy</h2> current="privacy-policy"
<span className="text-center mt-2 text-zinc-600 dark:text-zinc-400 w-11/12 sm:w-9/12">Idihh rajin amat sampe buka buka privacy policy segala, kepoo yaa</span> title="Privacy Policy"
<span className="text-center mb-6 text-zinc-600 dark:text-zinc-400 w-11/12 sm:w-9/12">emang boleh sekepo itu? &#128527;</span> summary={`This page explains what ${LEGAL.shortName} collects, why, who can see it and how to control it. Section 3 covers our use of Google Calendar data in full.`}
<div className="flex items-center space-x-2"> sections={sections}
<Button onClick={() => { router.back(); router.refresh() }}>Ayok balik lagi yukk :)</Button> />
</div> );
</div>
</>
);
} }
export default PrivacyPolicyPage;
+185 -21
View File
@@ -1,26 +1,190 @@
'use client' import type { Metadata } from 'next';
import { FC } from 'react'; import { A, LegalLayout, LegalSection, UL } from '@/components/legal/LegalLayout';
import { Button } from '@/components/ui/button'; import { LEGAL } from '@/lib/legal';
import { useRouter } from 'next/navigation';
type Props = {}; export const metadata: Metadata = {
title: `Terms of Service | ${LEGAL.shortName}`,
description: `The rules for using ${LEGAL.appName}.`,
};
const TermsPage: FC<Props> = ({ }) => { const sections: LegalSection[] = [
const router = useRouter() {
id: 'acceptance',
title: 'Acceptance of these terms',
body: (
<p>
These terms govern your use of {LEGAL.appName} ({LEGAL.shortName}) at <A href={LEGAL.siteUrl}>{LEGAL.siteUrl}</A>,
operated by {LEGAL.operator}. By signing in or using the service you agree to them and to our{' '}
<A href="/privacy-policy">Privacy Policy</A>. If you do not agree, do not use the service.
</p>
),
},
{
id: 'service',
title: 'What the service does',
body: (
<>
<p>{LEGAL.shortName} is a workplace application that provides:</p>
<UL>
<li>Attendance check-in and check-out with location and photo.</li>
<li>Leave, permit and sick requests with approval workflow and generated documents.</li>
<li>Task, client and project assignment.</li>
<li>Calendar scheduling through an integration with Google Calendar.</li>
<li>Reports, notifications and administration tools for authorised staff.</li>
</UL>
<p>Features available to you depend on the role your administrator gives you.</p>
</>
),
},
{
id: 'accounts',
title: 'Accounts',
body: (
<UL>
<li>Accounts are created or approved by your organisation. You must give accurate information.</li>
<li>Keep your password private. You are responsible for activity under your account, so tell us promptly if you suspect misuse.</li>
<li>Do not share your account or sign in as someone else.</li>
</UL>
),
},
{
id: 'acceptable-use',
title: 'Acceptable use',
body: (
<>
<p>You agree not to:</p>
<UL>
<li>Submit false attendance, for example fake GPS location, photos of someone else, or photos of photos.</li>
<li>Submit leave, permit or sick requests with false reasons or forged attachments or signatures.</li>
<li>Access data or areas of the service your role does not allow, or try to bypass access controls.</li>
<li>Probe, scan, overload or interfere with the service, or introduce malware.</li>
<li>Copy, resell or reverse engineer the service, except where the law allows it.</li>
<li>Use the service to harass others or to store unlawful content.</li>
</UL>
<p>Your organisation may take disciplinary action under its own policies for misuse of attendance records.</p>
</>
),
},
{
id: 'your-content',
title: 'Your data and content',
body: (
<>
<p>
You keep ownership of what you submit, such as requests, attachments and task details. You give {LEGAL.operator}{' '}
permission to process it to run the service for you and your organisation, as described in the Privacy Policy.
</p>
<p>
Attendance, leave and task records are also records of your organisation, which decides how they are used for
HR and payroll purposes.
</p>
</>
),
},
{
id: 'google',
title: 'Google Calendar integration',
body: (
<>
<p>
The calendar features use Google APIs through an account connected by an administrator. Use of Google data is
covered by section 3 of the <A href="/privacy-policy#google-data">Privacy Policy</A>, which includes our
compliance with the Google API Services User Data Policy and its Limited Use requirements.
</p>
<p>
Your use of Google Calendar and Google Meet is also subject to{' '}
<A href="https://policies.google.com/terms">Google&apos;s Terms of Service</A>. Calendar features may stop if
Google changes or withdraws its APIs, or if the connected account revokes access.
</p>
</>
),
},
{
id: 'permissions',
title: 'Device permissions',
body: (
<p>
Attendance features ask your browser for camera and location access, and notifications ask for permission to
send alerts. You can refuse or withdraw these at any time in your browser or device settings. Features that need a
permission will not work without it.
</p>
),
},
{
id: 'ip',
title: 'Intellectual property',
body: (
<p>
The {LEGAL.shortName} software, name, logo and design belong to {LEGAL.operator} or its licensors. You receive a
limited, non-exclusive, non-transferable right to use the service for your work while your account is active.
</p>
),
},
{
id: 'availability',
title: 'Availability and changes',
body: (
<p>
We work to keep {LEGAL.shortName} available, but it may be interrupted for maintenance, updates or events outside our
control. We may change or remove features. We will give notice of significant changes where we reasonably can.
</p>
),
},
{
id: 'disclaimer',
title: 'Disclaimers and limits of liability',
body: (
<>
<p>
The service is provided &quot;as is&quot; and &quot;as available&quot;. To the extent the law allows, we do not
promise it will be uninterrupted or error free, and we are not responsible for decisions made from attendance or
report data without checking it.
</p>
<p>
To the extent the law allows, {LEGAL.operator} is not liable for indirect or consequential loss arising from use of
the service. Nothing in these terms limits liability that cannot be limited by law.
</p>
</>
),
},
{
id: 'termination',
title: 'Suspension and termination',
body: (
<p>
Your access ends when your organisation deactivates your account or you stop being part of it. We may suspend an
account that breaks these terms or puts the service or others at risk. You may stop using the service at any time and
can request deletion of your data as described in the Privacy Policy.
</p>
),
},
{
id: 'law',
title: 'Governing law, changes and contact',
body: (
<>
<p>
These terms are governed by the laws of the Republic of Indonesia. We will first try to settle disputes through
discussion before any formal proceedings.
</p>
<p>
We may update these terms. The date at the top of this page shows the latest version, and continued use after a
change means you accept it. For questions, email{' '}
<A href={`mailto:${LEGAL.contactEmail}`}>{LEGAL.contactEmail}</A>.
</p>
</>
),
},
];
return ( export default function TermsPage() {
<> return (
<div className="h-screen flex flex-col justify-center items-center"> <LegalLayout
<h2 className="text-xl sm:text-2xl font-semibold tracking-tight text-center">Terms of Service</h2> current="terms"
<span className="text-center mt-2 text-zinc-600 dark:text-zinc-400 w-11/12 sm:w-9/12">Gausah sok rajin, sok sok an baca terms condition segala</span> title="Terms of Service"
<span className="text-center mb-6 text-zinc-600 dark:text-zinc-400 w-11/12 sm:w-9/12">emang boleh serajin itu? &#128524;</span> summary={`The rules for using ${LEGAL.shortName}: who can use it, what is expected of you, and what you can expect from us.`}
<div className="flex items-center space-x-2"> sections={sections}
<Button onClick={() => { router.back(); router.refresh() }}>Yuk balik lagi yukk :)</Button> />
</div> );
</div>
</>
);
} }
export default TermsPage;
+184
View File
@@ -0,0 +1,184 @@
import Link from 'next/link';
import { ReactNode } from 'react';
import Logo from '@/app/(dashboard)/components/Logo';
import { ToggleTheme } from '@/components/ToggleTheme';
import { LEGAL } from '@/lib/legal';
export type LegalSection = {
id: string;
title: string;
body: ReactNode;
};
type Props = {
title: string;
summary: string;
current: 'privacy-policy' | 'terms';
sections: LegalSection[];
};
const linkClass =
'text-[#B8391A] dark:text-[#FF8F70] underline underline-offset-4 decoration-1 hover:decoration-2 rounded-sm focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-[#B8391A] dark:focus-visible:outline-[#FF8F70]';
export function LegalLayout({ title, summary, current, sections }: Props) {
const other =
current === 'privacy-policy'
? { href: '/terms', label: 'Terms of Service' }
: { href: '/privacy-policy', label: 'Privacy Policy' };
return (
<div className="h-dvh overflow-y-auto scroll-smooth text-zinc-800 dark:text-zinc-200">
<header className="border-b border-zinc-200 dark:border-zinc-800 bg-white dark:bg-zinc-950">
<div className="mx-auto flex max-w-6xl items-center justify-between gap-4 px-4 py-2 sm:px-6">
<Logo />
<nav aria-label="Legal pages" className="flex items-center gap-1 sm:gap-3 text-sm">
<Link
href="/privacy-policy"
aria-current={current === 'privacy-policy' ? 'page' : undefined}
className="inline-flex min-h-11 items-center px-2 rounded-sm aria-[current=page]:font-semibold aria-[current=page]:underline underline-offset-8 decoration-2 decoration-his hover:text-zinc-950 dark:hover:text-white"
>
Privacy
</Link>
<Link
href="/terms"
aria-current={current === 'terms' ? 'page' : undefined}
className="inline-flex min-h-11 items-center px-2 rounded-sm aria-[current=page]:font-semibold aria-[current=page]:underline underline-offset-8 decoration-2 decoration-his hover:text-zinc-950 dark:hover:text-white"
>
Terms
</Link>
<ToggleTheme />
</nav>
</div>
</header>
<main className="mx-auto max-w-6xl px-4 py-8 sm:px-6 sm:py-12 lg:grid lg:grid-cols-[15rem_minmax(0,1fr)] lg:gap-12">
<aside className="mb-6 lg:mb-0">
<div className="lg:sticky lg:top-8">
<details className="group rounded-md border border-zinc-200 dark:border-zinc-800 bg-white dark:bg-zinc-900 lg:hidden">
<summary className="flex min-h-11 cursor-pointer items-center justify-between px-4 text-sm font-medium focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-[#B8391A] dark:focus-visible:outline-[#FF8F70]">
On this page
<span aria-hidden className="text-zinc-500 transition-transform group-open:rotate-180">
&#9662;
</span>
</summary>
<TocList sections={sections} />
</details>
<div className="hidden lg:block">
<p className="mb-3 text-sm font-semibold text-zinc-900 dark:text-zinc-100">On this page</p>
<TocList sections={sections} />
</div>
</div>
</aside>
<article className="min-w-0 rounded-lg border border-zinc-200 dark:border-zinc-800 bg-white dark:bg-zinc-900 px-5 py-8 sm:px-10 sm:py-12">
<p className="text-sm text-zinc-600 dark:text-zinc-400">
{LEGAL.appName} &middot; Last updated {LEGAL.updated}
</p>
<h1 className="mt-2 text-3xl font-bold tracking-tight text-zinc-950 dark:text-white sm:text-4xl">
{title}
</h1>
<p className="mt-4 max-w-prose text-base leading-7 text-zinc-700 dark:text-zinc-300">{summary}</p>
<div className="mt-10 space-y-12">
{sections.map((s, i) => (
<section key={s.id} id={s.id} aria-labelledby={`${s.id}-title`} className="scroll-mt-6">
<h2
id={`${s.id}-title`}
className="text-xl font-semibold tracking-tight text-zinc-950 dark:text-white"
>
<span className="mr-2 tabular-nums text-zinc-500 dark:text-zinc-400">{i + 1}.</span>
{s.title}
</h2>
<div className="mt-4 space-y-4 text-[15px] leading-7 text-zinc-700 dark:text-zinc-300 [&_strong]:font-semibold [&_strong]:text-zinc-950 dark:[&_strong]:text-white">
{s.body}
</div>
</section>
))}
</div>
<footer className="mt-14 flex flex-col gap-3 border-t border-zinc-200 dark:border-zinc-800 pt-6 text-sm sm:flex-row sm:items-center sm:justify-between">
<p className="text-zinc-600 dark:text-zinc-400">
Questions? Write to{' '}
<a className={linkClass} href={`mailto:${LEGAL.contactEmail}`}>
{LEGAL.contactEmail}
</a>
</p>
<div className="flex gap-4">
<Link className={linkClass} href={other.href}>
{other.label}
</Link>
<Link className={linkClass} href="/">
Back to app
</Link>
</div>
</footer>
</article>
</main>
</div>
);
}
function TocList({ sections }: { sections: LegalSection[] }) {
return (
<ol className="space-y-0.5 px-2 pb-2 text-sm lg:px-0 lg:pb-0">
{sections.map((s, i) => (
<li key={s.id}>
<a
href={`#${s.id}`}
className="flex min-h-11 items-baseline gap-2 rounded-sm px-2 py-2.5 text-zinc-700 hover:bg-zinc-100 hover:text-zinc-950 dark:text-zinc-300 dark:hover:bg-zinc-800 dark:hover:text-white focus-visible:outline-2 focus-visible:outline-[#B8391A] dark:focus-visible:outline-[#FF8F70] lg:min-h-0 lg:py-1.5"
>
<span className="w-5 shrink-0 tabular-nums text-zinc-500 dark:text-zinc-400">{i + 1}.</span>
<span>{s.title}</span>
</a>
</li>
))}
</ol>
);
}
export function UL({ children }: { children: ReactNode }) {
return <ul className="list-disc space-y-2 pl-5 marker:text-zinc-400">{children}</ul>;
}
export function A({ href, children }: { href: string; children: ReactNode }) {
const external = href.startsWith('http');
return (
<a
href={href}
className={linkClass}
{...(external ? { target: '_blank', rel: 'noopener noreferrer' } : {})}
>
{children}
</a>
);
}
export function DataTable({ head, rows }: { head: string[]; rows: ReactNode[][] }) {
return (
<div className="overflow-x-auto rounded-md border border-zinc-200 dark:border-zinc-800">
<table className="w-full min-w-136 border-collapse text-left text-sm">
<thead className="bg-zinc-100 dark:bg-zinc-800 text-zinc-900 dark:text-zinc-100">
<tr>
{head.map((h) => (
<th key={h} scope="col" className="px-4 py-3 font-semibold">
{h}
</th>
))}
</tr>
</thead>
<tbody className="divide-y divide-zinc-200 dark:divide-zinc-800 align-top">
{rows.map((r, i) => (
<tr key={i}>
{r.map((c, j) => (
<td key={j} className={j === 0 ? 'px-4 py-3 font-medium text-zinc-950 dark:text-white' : 'px-4 py-3'}>
{c}
</td>
))}
</tr>
))}
</tbody>
</table>
</div>
);
}
+10
View File
@@ -0,0 +1,10 @@
// Single source for facts repeated across the legal pages.
// Update LEGAL_UPDATED when the policy text changes materially.
export const LEGAL = {
appName: 'HIS Attendance Task System (H.A.T.s)',
shortName: 'H.A.T.s',
operator: 'HIS',
siteUrl: 'https://hats.hisnutech.my.id',
contactEmail: 'his.nutech@gmail.com',
updated: '19 November 2026',
} as const;