ui changes

added privacy policy
made dhiv text easier to read
This commit is contained in:
fISHIE
2026-02-08 10:20:37 +05:00
parent 9de2c7c8fb
commit a27bd536ba
8 changed files with 48 additions and 21 deletions

View File

@@ -2,15 +2,18 @@ import { BrowserRouter, Routes, Route } from "react-router-dom";
import { HomePage } from "@/pages/HomePage";
import { PetitionPage } from "@/pages/PetitionPage";
import { CreatePetitionPage } from "@/pages/CreatePetitionPage";
import { Layout } from "@/components/layout/Layout";
function App() {
return (
<BrowserRouter>
<Routes>
<Route path="/" element={<HomePage />} />
<Route path="/Petition/:slug" element={<PetitionPage />} />
<Route path="/CreatePetition" element={<CreatePetitionPage />} />
</Routes>
<Layout>
<Routes>
<Route path="/" element={<HomePage />} />
<Route path="/Petition/:slug" element={<PetitionPage />} />
<Route path="/CreatePetition" element={<CreatePetitionPage />} />
</Routes>
</Layout>
</BrowserRouter>
);
}

View File

@@ -0,0 +1,19 @@
export function Footer() {
return (
<footer className="mt-auto py-6 border-t border-slate-200">
<div className="container mx-auto px-4">
<div className="flex flex-col items-center gap-2 text-sm text-slate-500">
<span>Powered by Mv Devs Union</span>
<a
href="https://github.com/MvDevsUnion/WPetition/blob/master/privacy_policy.md"
target="_blank"
rel="noopener noreferrer"
className="hover:text-slate-700 transition-colors"
>
Privacy Policy
</a>
</div>
</div>
</footer>
);
}

View File

@@ -0,0 +1,14 @@
import { Footer } from "./Footer";
interface LayoutProps {
children: React.ReactNode;
}
export function Layout({ children }: LayoutProps) {
return (
<div className="min-h-screen flex flex-col">
<main className="flex-1">{children}</main>
<Footer />
</div>
);
}

View File

@@ -54,7 +54,7 @@ export function PetitionBody({
<button
onClick={() => setIsExpanded(!isExpanded)}
className={`mt-4 flex items-center gap-2 text-blue-600 hover:text-blue-700 font-medium transition-colors ${isRtl ? "flex-row-reverse" : ""}`}
className={`mt-4 flex items-center gap-2 text-blue-600 hover:text-blue-700 font-medium transition-colors ${isRtl ? "flex-row-reverse dhivehi" : ""}`}
>
{isExpanded ? (
<>

View File

@@ -126,10 +126,16 @@
/* Dhivehi text styles - using Faruma as primary font */
.dhivehi {
font-family: "Faruma", "Waheed", sans-serif;
font-size: 1.15em;
direction: rtl;
text-align: right;
}
/* Ensure Dhivehi font applies to all child elements (for markdown content) */
.dhivehi * {
font-family: inherit;
}
/* RTL document support */
html[dir="rtl"] {
direction: rtl;

View File

@@ -418,10 +418,6 @@ export function CreatePetitionPage() {
</div>
</form>
</div>
<footer className="text-center text-slate-500 text-sm mt-6 pb-4">
Powered by Mv Devs Union
</footer>
</div>
);
}

View File

@@ -105,10 +105,6 @@ export function HomePage() {
</div>
)}
</div>
<footer className="text-center text-slate-500 text-sm py-8">
Powered by Mv Devs Union
</footer>
</div>
);
}

View File

@@ -53,9 +53,6 @@ export function PetitionPage() {
<div className="max-w-4xl mx-auto bg-card rounded-lg shadow-lg p-10">
<ErrorState message="No petition found. Please use a valid petition URL." />
</div>
<footer className="text-center text-slate-500 text-sm mt-6 pb-4">
Powered by Mv Devs Union
</footer>
</div>
);
}
@@ -114,10 +111,6 @@ export function PetitionPage() {
</>
)}
</div>
<footer className="text-center text-slate-500 text-sm mt-6 pb-4">
Powered by Mv Devs Union
</footer>
</div>
);
}