diff --git a/TASK.md b/TASK.md index ae9de97..f0d67c0 100644 --- a/TASK.md +++ b/TASK.md @@ -2,17 +2,19 @@ ## To Do -- [ ] docs pages -- [ ] fix site confg link - -- [ ] npm package - ## Current Status -v2.8.1 ready. Centralized defaultTheme in siteConfig.ts. +v2.8.2 ready. Fixed footer not displaying on docs section pages. ## Completed +- [x] Fix footer not displaying on docs section pages with showFooter: true + - [x] Added footer.md content query to Post.tsx (matching Home.tsx and Blog.tsx pattern) + - [x] Updated all 4 Footer component calls to use `post.footer || footerPage?.content` pattern + - [x] Footer now falls back to footer.md content when no per-post footer is specified + - [x] Priority order: per-post frontmatter `footer:` > synced footer.md content > siteConfig.footer.defaultContent + - [x] Updated docs.md, files.md, changelog.md, changelog-page.md with fix documentation + - [x] Centralize defaultTheme in siteConfig.ts - [x] Added `defaultTheme` field to siteConfig.ts (type: `Theme`) - [x] Added `Theme` type export to siteConfig.ts @@ -25,7 +27,6 @@ v2.8.1 ready. Centralized defaultTheme in siteConfig.ts. - [x] Updated fork-configuration-guide.md with siteConfig.ts reference - [x] Backward compatible: falls back to "tan" if defaultTheme not set - - [x] Docs sidebar group icons via frontmatter - [x] Added `docsSectionGroupIcon` frontmatter field for posts and pages - [x] Icon appears left of the group title expand/collapse chevron diff --git a/changelog.md b/changelog.md index 6233f01..f496e1c 100644 --- a/changelog.md +++ b/changelog.md @@ -4,6 +4,20 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). +## [2.8.2] - 2026-01-03 + +### Fixed + +- Footer not displaying on docs section posts/pages even with `showFooter: true` in frontmatter + - Post.tsx now fetches footer.md content from Convex (matching Home.tsx and Blog.tsx pattern) + - Footer falls back to footer.md content when no per-post `footer:` frontmatter is specified + - Priority order: per-post frontmatter `footer:` field > synced footer.md content > siteConfig.footer.defaultContent + +### Technical + +- Added `useQuery(api.pages.getPageBySlug, { slug: "footer" })` to Post.tsx +- Updated all 4 Footer component calls to use `post.footer || footerPage?.content` pattern + ## [2.8.1] - 2026-01-03 ### Changed diff --git a/content/blog/setup-guide.md b/content/blog/setup-guide.md index 4bfe7c5..6934470 100644 --- a/content/blog/setup-guide.md +++ b/content/blog/setup-guide.md @@ -370,6 +370,7 @@ Your markdown content here... | `docsSectionOrder` | No | Order within docs group. Lower numbers appear first within the group. | | `docsSectionGroupOrder` | No | Order of the group in docs sidebar. Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | No | Phosphor icon name for docs sidebar group (e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | No | Set `true` to use as the docs landing page (shown when navigating to `/docs`). | ### How Frontmatter Works diff --git a/content/blog/team-workflows-git-version-control.md b/content/blog/team-workflows-git-version-control.md index b58c205..ab82f3a 100644 --- a/content/blog/team-workflows-git-version-control.md +++ b/content/blog/team-workflows-git-version-control.md @@ -9,6 +9,7 @@ readTime: "6 min read" image: /images/team-sync.png featured: false layout: "sidebar" +showFooter: true newsletter: true excerpt: "Learn how teams use git for markdown version control, sync to Convex deployments, and automate production workflows." docsSection: true diff --git a/content/pages/changelog-page.md b/content/pages/changelog-page.md index 805bc1d..04759d8 100644 --- a/content/pages/changelog-page.md +++ b/content/pages/changelog-page.md @@ -12,6 +12,24 @@ docsSectionOrder: 4 All notable changes to this project. ![](https://img.shields.io/badge/License-MIT-yellow.svg) +## v2.8.2 + +Released January 3, 2026 + +**Footer fix for docs section pages** + +- Fixed footer not displaying on docs section posts/pages even with `showFooter: true` in frontmatter + - Post.tsx now fetches footer.md content from Convex (matching Home.tsx and Blog.tsx pattern) + - Footer falls back to footer.md content when no per-post `footer:` frontmatter is specified + - Priority order: per-post frontmatter `footer:` > synced footer.md content > siteConfig.footer.defaultContent + +**Technical details:** + +- Added `useQuery(api.pages.getPageBySlug, { slug: "footer" })` to Post.tsx +- Updated all 4 Footer component calls to use `post.footer || footerPage?.content` pattern + +Updated files: `src/pages/Post.tsx` + ## v2.8.1 Released January 3, 2026 diff --git a/content/pages/docs.md b/content/pages/docs.md index b809b25..1916993 100644 --- a/content/pages/docs.md +++ b/content/pages/docs.md @@ -141,6 +141,7 @@ Content here... | `docsSectionOrder` | No | Order within docs group. Lower numbers appear first within the group. | | `docsSectionGroupOrder` | No | Order of the group in docs sidebar. Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | No | Phosphor icon name for docs sidebar group (e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | No | Set `true` to use this post as the docs landing page (shown when navigating to `/docs`). | | `showImageAtTop` | No | Set `true` to display the `image` field at the top of the post above the header (default: `false`) | ### Static pages @@ -189,6 +190,7 @@ Content here... | `docsSectionOrder` | No | Order within docs group. Lower numbers appear first within the group. | | `docsSectionGroupOrder` | No | Order of the group in docs sidebar. Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | No | Phosphor icon name for docs sidebar group (e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | No | Set `true` to use this page as the docs landing page (shown when navigating to `/docs`). | **Hide pages from navigation:** Set `showInNav: false` to keep a page published and accessible via direct URL, but hidden from the navigation menu. Pages with `showInNav: false` remain searchable and available via API endpoints. Useful for pages you want to link directly but not show in the main nav. @@ -259,12 +261,14 @@ Created by [Your Name](https://x.com/yourhandle). Follow on [Twitter/X](https:// 2. Run `npm run sync` to sync to Convex -3. Footer content appears on homepage and blog page instantly (no rebuild needed) +3. Footer content appears on homepage, blog page, and all posts/pages instantly (no rebuild needed) **Markdown support:** Footer content supports full markdown including links, paragraphs, line breaks, and images. External links automatically open in new tabs. **Fallback:** If `footer` page is not found, the footer falls back to `siteConfig.footer.defaultContent`. +**Priority order:** Per-post/page frontmatter `footer:` field (custom override) > synced footer.md content > siteConfig.footer.defaultContent. + **Relationship with siteConfig:** The `content/pages/footer.md` page takes priority over `siteConfig.footer.defaultContent` when present. Use the markdown page for dynamic content that changes frequently, or keep using siteConfig for static footer content. ### Sidebar layout diff --git a/files.md b/files.md index ebf8d41..655b8c0 100644 --- a/files.md +++ b/files.md @@ -43,7 +43,7 @@ A brief description of each file in the codebase. | ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `Home.tsx` | Landing page with featured content and optional post list. Fetches home intro content from `content/pages/home.md` (slug: `home-intro`) for synced markdown intro text. Supports configurable post limit (homePostsLimit) and optional "read more" link (homePostsReadMore) via siteConfig.postsDisplay. Falls back to siteConfig.bio if home-intro page not found. Home intro content uses blog heading styles (blog-h1 through blog-h6) with clickable anchor links, matching blog post typography. Includes helper functions (generateSlug, getTextContent, HeadingAnchor) for heading ID generation and anchor links. Featured section title configurable via siteConfig.featuredTitle (default: "Get started:"). | | `Blog.tsx` | Dedicated blog page with featured layout: hero post (first blogFeatured), featured row (remaining blogFeatured in 2 columns with excerpts), and regular posts (3 columns without excerpts). Supports list/card view toggle. Includes back button in navigation | -| `Post.tsx` | Individual blog post or page view with optional left sidebar (TOC) and right sidebar (CopyPageDropdown). Includes back button (hidden when used as homepage), tag links, related posts section in footer for blog posts, footer component with markdown support, and social footer. Supports 3-column layout at 1135px+. Can display image at top when showImageAtTop: true. Can be used as custom homepage via siteConfig.homepage (update SITE_URL/SITE_NAME when forking) | +| `Post.tsx` | Individual blog post or page view with optional left sidebar (TOC) and right sidebar (CopyPageDropdown). Includes back button (hidden when used as homepage), tag links, related posts section in footer for blog posts, footer component with markdown support (fetches footer.md content from Convex), and social footer. Supports 3-column layout at 1135px+. Can display image at top when showImageAtTop: true. Can be used as custom homepage via siteConfig.homepage (update SITE_URL/SITE_NAME when forking) | | `Stats.tsx` | Real-time analytics dashboard with visitor stats and GitHub stars. Configurable via `siteConfig.statsPage` to enable/disable public access and navigation visibility. Shows disabled message when `enabled: false` (similar to NewsletterAdmin pattern). | | `TagPage.tsx` | Tag archive page displaying posts filtered by a specific tag. Includes view mode toggle (list/cards) with localStorage persistence | | `AuthorPage.tsx` | Author archive page displaying posts by a specific author. Includes view mode toggle (list/cards) with localStorage persistence. Author name clickable in posts links to this page. | @@ -177,6 +177,7 @@ Markdown files with frontmatter for blog posts. Each file becomes a blog post. | `docsSectionOrder` | Order within docs group (optional). Lower numbers appear first within the group. | | `docsSectionGroupOrder` | Order of the group in docs sidebar (optional). Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | Phosphor icon name for docs sidebar group (optional, e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | Use as docs landing page (optional). Set `true` to show this post when navigating to `/docs`. | ## Static Pages (`content/pages/`) @@ -213,6 +214,7 @@ Markdown files for static pages like About, Projects, Contact, Changelog. | `docsSectionOrder` | Order within docs group (optional). Lower numbers appear first within the group. | | `docsSectionGroupOrder` | Order of the group in docs sidebar (optional). Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | Phosphor icon name for docs sidebar group (optional, e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | Use as docs landing page (optional). Set `true` to show this page when navigating to `/docs`. | ## Scripts (`scripts/`) diff --git a/public/raw/about.md b/public/raw/about.md index fab6d9b..d3b0833 100644 --- a/public/raw/about.md +++ b/public/raw/about.md @@ -2,7 +2,7 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- An open-source publishing framework built for AI agents and developers to ship websites, docs, or blogs. Write markdown, sync from the terminal. Your content is instantly available to browsers, LLMs, and AI agents. Built on Convex and Netlify. diff --git a/public/raw/changelog.md b/public/raw/changelog.md index dc58120..402441c 100644 --- a/public/raw/changelog.md +++ b/public/raw/changelog.md @@ -2,12 +2,30 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- All notable changes to this project. ![](https://img.shields.io/badge/License-MIT-yellow.svg) +## v2.8.2 + +Released January 3, 2026 + +**Footer fix for docs section pages** + +- Fixed footer not displaying on docs section posts/pages even with `showFooter: true` in frontmatter + - Post.tsx now fetches footer.md content from Convex (matching Home.tsx and Blog.tsx pattern) + - Footer falls back to footer.md content when no per-post `footer:` frontmatter is specified + - Priority order: per-post frontmatter `footer:` > synced footer.md content > siteConfig.footer.defaultContent + +**Technical details:** + +- Added `useQuery(api.pages.getPageBySlug, { slug: "footer" })` to Post.tsx +- Updated all 4 Footer component calls to use `post.footer || footerPage?.content` pattern + +Updated files: `src/pages/Post.tsx` + ## v2.8.1 Released January 3, 2026 diff --git a/public/raw/contact.md b/public/raw/contact.md index 4171513..82a09fe 100644 --- a/public/raw/contact.md +++ b/public/raw/contact.md @@ -2,7 +2,7 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- You found the contact page. Nice diff --git a/public/raw/documentation.md b/public/raw/documentation.md index e3fa98d..8306990 100644 --- a/public/raw/documentation.md +++ b/public/raw/documentation.md @@ -2,7 +2,7 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- ## Getting Started @@ -131,6 +131,7 @@ Content here... | `docsSectionOrder` | No | Order within docs group. Lower numbers appear first within the group. | | `docsSectionGroupOrder` | No | Order of the group in docs sidebar. Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | No | Phosphor icon name for docs sidebar group (e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | No | Set `true` to use this post as the docs landing page (shown when navigating to `/docs`). | | `showImageAtTop` | No | Set `true` to display the `image` field at the top of the post above the header (default: `false`) | ### Static pages @@ -179,6 +180,7 @@ Content here... | `docsSectionOrder` | No | Order within docs group. Lower numbers appear first within the group. | | `docsSectionGroupOrder` | No | Order of the group in docs sidebar. Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | No | Phosphor icon name for docs sidebar group (e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | No | Set `true` to use this page as the docs landing page (shown when navigating to `/docs`). | **Hide pages from navigation:** Set `showInNav: false` to keep a page published and accessible via direct URL, but hidden from the navigation menu. Pages with `showInNav: false` remain searchable and available via API endpoints. Useful for pages you want to link directly but not show in the main nav. @@ -249,12 +251,14 @@ Created by [Your Name](https://x.com/yourhandle). Follow on [Twitter/X](https:// 2. Run `npm run sync` to sync to Convex -3. Footer content appears on homepage and blog page instantly (no rebuild needed) +3. Footer content appears on homepage, blog page, and all posts/pages instantly (no rebuild needed) **Markdown support:** Footer content supports full markdown including links, paragraphs, line breaks, and images. External links automatically open in new tabs. **Fallback:** If `footer` page is not found, the footer falls back to `siteConfig.footer.defaultContent`. +**Priority order:** Per-post/page frontmatter `footer:` field (custom override) > synced footer.md content > siteConfig.footer.defaultContent. + **Relationship with siteConfig:** The `content/pages/footer.md` page takes priority over `siteConfig.footer.defaultContent` when present. Use the markdown page for dynamic content that changes frequently, or keep using siteConfig for static footer content. ### Sidebar layout diff --git a/public/raw/footer.md b/public/raw/footer.md index aaea11d..c0a5d1a 100644 --- a/public/raw/footer.md +++ b/public/raw/footer.md @@ -2,7 +2,7 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- Built with [Convex](https://convex.dev) for real-time sync and deployed on [Netlify](https://netlify.com). Read the [project on GitHub](https://github.com/waynesutton/markdown-site) to fork and deploy your own. View [real-time site stats](/stats). diff --git a/public/raw/home-intro.md b/public/raw/home-intro.md index bdec283..fe4b068 100644 --- a/public/raw/home-intro.md +++ b/public/raw/home-intro.md @@ -2,7 +2,7 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- An open-source publishing framework built for AI agents and developers to ship **[docs](/docs)**, or **[blogs](/blog)** or **[websites](/)**. diff --git a/public/raw/newsletter.md b/public/raw/newsletter.md index f5d9776..197e7bc 100644 --- a/public/raw/newsletter.md +++ b/public/raw/newsletter.md @@ -2,7 +2,7 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- # Newsletter Demo Page diff --git a/public/raw/projects.md b/public/raw/projects.md index 26cfc19..a17c3fa 100644 --- a/public/raw/projects.md +++ b/public/raw/projects.md @@ -2,7 +2,7 @@ --- Type: page -Date: 2026-01-03 +Date: 2026-01-04 --- This markdown framework is open source and built to be extended. Here is what ships out of the box. diff --git a/public/raw/setup-guide.md b/public/raw/setup-guide.md index 7f35140..6475097 100644 --- a/public/raw/setup-guide.md +++ b/public/raw/setup-guide.md @@ -359,6 +359,7 @@ Your markdown content here... | `docsSectionOrder` | No | Order within docs group. Lower numbers appear first within the group. | | `docsSectionGroupOrder` | No | Order of the group in docs sidebar. Lower numbers make the group appear first. Groups without this field sort alphabetically. | | `docsSectionGroupIcon` | No | Phosphor icon name for docs sidebar group (e.g., "Rocket", "Book", "PuzzlePiece"). Icon appears left of the group title. See [Phosphor Icons](https://phosphoricons.com) for available icons. | +| `docsLanding` | No | Set `true` to use as the docs landing page (shown when navigating to `/docs`). | ### How Frontmatter Works diff --git a/src/pages/Post.tsx b/src/pages/Post.tsx index ef52f2a..1d04a13 100644 --- a/src/pages/Post.tsx +++ b/src/pages/Post.tsx @@ -54,6 +54,9 @@ export default function Post({ : "skip", ); + // Fetch footer content from Convex (synced via markdown) + const footerPage = useQuery(api.pages.getPageBySlug, { slug: "footer" }); + const [copied, setCopied] = useState(false); // Scroll to hash anchor after content loads @@ -264,7 +267,7 @@ export default function Post({ (page.showFooter !== undefined ? page.showFooter : siteConfig.footer.showOnPages) && ( -