Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified public/assets/hero-demo.mp4
Binary file not shown.
Binary file modified public/assets/hero-poster.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 9 additions & 1 deletion src/app/(home)/roadmap/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,15 @@ function parseBlocks(markdown: string, docsSlugs: Set<string>) {

const flushParagraph = () => {
if (paragraph.length > 0) {
blocks.push({ kind: 'paragraph', text: paragraph.join(' ') });
// The markdown's checkbox notation (`[x]`/`[~]`/`[ ]`) means nothing to a
// visitor with no context for it and the page already renders status as
// dots, so strip it from prose rather than show it literally.
const text = paragraph
.join(' ')
.replace(/\s*marked\s*`\[[x~ ]\]`/g, '')
// The doc says "Open an issue" as plain prose; give it a real link here.
.replace(/Open an issue/, `[Open an issue](${repoBase}/issues)`);
blocks.push({ kind: 'paragraph', text });
paragraph = [];
}
};
Expand Down
4 changes: 2 additions & 2 deletions src/app/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import { cn } from '@/lib/cn';
const geistSans = Geist({ subsets: ['latin'], variable: '--font-sans' });
const geistMono = Geist_Mono({ subsets: ['latin'], variable: '--font-mono' });

const title = 'fossui — A Flutter UI Kit With Its Own Identity';
const title = 'fossui — The Fresh, Minimal Flutter UI Kit';
const description =
'A minimal, lightweight Flutter component set for developers tired of every app looking like Material. Drops into any Flutter app, no heavy dependencies.';
'A fresh, minimal Flutter UI kit: a lightweight component library and design system you drop into any app, no heavy dependencies.';

const jsonLd = {
'@context': 'https://schema.org',
Expand Down
29 changes: 14 additions & 15 deletions src/components/github-stars.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
'use client';

import { useEffect, useState } from 'react';
import { Star } from 'lucide-react';
import { gitConfig } from '@/lib/shared';

Expand All @@ -9,22 +12,18 @@ function formatCount(count: number) {
return `${(count / 1000).toFixed(1).replace(/\.0$/, '')}k`;
}

async function getStarCount(): Promise<number | null> {
try {
const res = await fetch(apiUrl, {
next: { revalidate: 86400 },
headers: { Accept: 'application/vnd.github+json' },
});
if (!res.ok) return null;
const data = (await res.json()) as { stargazers_count?: number };
return typeof data.stargazers_count === 'number' ? data.stargazers_count : null;
} catch {
return null;
}
}
export function GitHubStars() {
const [stars, setStars] = useState<number | null>(null);

useEffect(() => {
fetch(apiUrl, { headers: { Accept: 'application/vnd.github+json' } })
.then((res) => (res.ok ? res.json() : null))
.then((data: { stargazers_count?: number } | null) => {
if (typeof data?.stargazers_count === 'number') setStars(data.stargazers_count);
})
.catch(() => {});
}, []);

export async function GitHubStars() {
const stars = await getStarCount();
return (
<a
href={githubUrl}
Expand Down
Loading