Changes in 0.1.4 and after — every release from
0.1.4through0.2.1. (chore: regenerate docsand merge commits are omitted.)
- Mobile docs context: mobile documentation headers now show the active documentation name and version, so users can identify their location in a Docs Hub without opening the sidebar.
- AI docs:
docsmith install:aisets up MCP tools and adocsmith-docsskill for Grok, Claude Code, Codex, Cursor, OpenCode, and Google Antigravity. Agents write docs in words unless the user asked for screenshots or videos.capture_mediathen inspects a running page, crops a widget screenshot with padding, or records a short video framed the same way. Login goes in off-camerabeforesteps. Grok gets.grok/config.tomland.grok/skills/. - Asset minification: CSS and JavaScript are minified using
matthiasmullie/minifyduring the build step. Output files are stripped of comments, unnecessary whitespace, and redundant characters. Falls back to unminified output on failure so builds never break.
Republish of 0.4.0. The v0.4.0 tag was deleted and recreated during the release, and Packagist does not re-import a tag name it has already seen, so 0.4.0 never became installable through Composer. Use 0.4.1 or later.
- GitHub-style alerts: block quotes starting with
[!NOTE],[!TIP],[!IMPORTANT],[!WARNING], or[!CAUTION]render as colored callout boxes with icons in light and dark themes. Markers are case-insensitive and must be alone on the first line of the block quote. The feature is always enabled; unknown markers and regular block quotes are unaffected. Callouts use GitHub-compatible class names (.markdown-alert markdown-alert-{type}), so custom CSS written for GitHub works with Docsmith too.
- Autoloader resolution: the
docsmithbinary now finds the Composer autoloader when Docsmith is installed as a dependency (vendor/mrpunyapal/docsmith). Previously every CLI command failed with "Failed opening required .../bin/../vendor/autoload.php". If no autoloader is found, the binary exits with a hint to runcomposer install(#13).
- Media support: images, videos, audio, and PDFs kept in the source tree are published into the built site automatically, preserving their relative structure (png/jpg/jpeg/gif/svg/webp/avif/ico/bmp, mp4/webm/mov/m4v/ogv, mp3/wav/ogg/m4a/flac/aac, pdf). Built pages sit one level deeper than the source mirror (
guides/configuration.md->guides/configuration/index.html), so Docsmith also rewrites relative media references at render time:<img>,<video>/<audio>sources and posters, subtitle tracks, and download links resolve from the built URL (images/setup.pngbecomes../images/setup.png). Remote URLs, root-relative paths, data URIs, and references outside the published set are left untouched. Works across plain, versioned, and hub builds; self-hosted builds (output inside the source) skip self-copying. Opt out with->publishMedia(false). Content styles forimg,video, andaudioare included in the generated stylesheet.
- Internal link rewriting: body links to Markdown files (
[text](other-page.md)) now resolve on built sites. Docsmith rewrites them to built page URLs at render time, including relative paths (../installation.md) and fragments (configuration.md#options), across plain, versioned, and hub builds. Links whose target is not part of the build are left untouched, as are external URLs and anchors.
- Full documentation rewrite with a linked page index, a frontmatter reference, CLI option tables matching the binary, and corrected examples (versioned builds require
source(); sidebar search matches from one character). - New
docs-writingagent skill alongsidedocsmith-development; both install vianpx skills add MrPunyapal/docsmith/resources/boost/skillsor automatically through Laravel Boost.
- Private remote sources — sync from private Git repositories by adding
'token' => '${ENV_VAR}'(and optionally'username') to adocsmith.sources.phpentry. Tokens resolve from the environment at sync time; without an explicit token,DOCSMITH_TOKENis used for any host andGITHUB_TOKEN/GH_TOKENonly for github.com hosts (never sent to third-party hosts). Requires mrpunyapal/git-reader 0.2.0. - .env support — a
.envfile next todocsmith.sources.phpis loaded Laravel-style (immutable); real environment variables always win.
- Docs Hub — build several independent documentation sets into one site via
->hub(). Each entry gets a single dropdown option mounted at/{slug}/; the root forwards to the first entry. A hub entry may embed its ownversionslist: it stays one dropdown item while its pages carry v1/v2 pills. - Remote Sources — pull Markdown documentation from other Git repositories into your project via a new
docsmith.sources.phpmanifest anddocsmith sync/build --sync. Implemented on top of mrpunyapal/git-reader, a standalone read-only Git smart-HTTP client (protocol v0, shallowdeepen 1fetches, streaming packfile parser with ofs/ref delta support): no provider APIs, no systemgitbinary, no clones, works with GitHub/GitLab/Bitbucket/Gitea/self-hosted over plain HTTPS. Includes ref resolution (branch/tag/annotated-tag peel/tip SHA), SHA-keyed incremental sync viadocsmith.sources.lock.json, atomic staging materialization with path-traversal/symlink/device-name guards, size & file-count budgets, typed error taxonomy, and a deterministic offline wire-protocol test suite.
- Versioned docs refined (existing feature): the header dropdown switcher is replaced by v1/v2 pill buttons on every page; per-version sidebar order via a
navigationkey with fallback to global->navigationOrder(); versioned builds are fully decoupled from hub builds internally. - Hub dropdown UI uses
.hub-switcher/.hub-select(data-docsmith-hub-*) so hub and version markup are named after their own features. - Generated assets renamed to
assets/app.css/assets/app.jsconsistently across single-site, versioned, and hub builds.
- Stale root assets: previously built sites kept their old
app.js/app.cssforever because assets were only copied when the outputassets/directory did not exist. Root assets now refresh on every build.
- Fix: breadcrumb 404 on nested pages without a section index. Directory crumbs now resolve to the section's
index.htmlwhen one exists, otherwise to the first page inside that directory (respecting frontmatterorder/ navigation sort) instead of linking to a page that was never generated.
navigationOrder(array $order)— configure the sidebar page sequence. Entries match a page title,sidebar_label, relative Markdown path, or output path (case-insensitive); unlisted pages keep their existing order. Wired throughBuilder→SiteMetadata→SiteBuilder(incl. versioned builds).- Configurable DocSmith attribution badge (
showDocsmithBadge()) witharia-label="Built with DocSmith". - Code copy button — anchored to the active code block (block whose center is closest to a 45%-viewport probe line), positioned at its top-right and clamped into view. Hover-only on pointer devices; always visible over the active block on touch devices.
- Scrollable tables —
.doc-body table { display: block; overflow-x: auto }; tables scroll internally instead of breaking the layout. - Long-token wrapping —
overflow-wrap: anywhereon.doc-body,.doc-head,.hero; mobile.shellusesminmax(0, 1fr). Zero horizontal overflow verified at 320/390/768 px (<pre>still scrolls internally). - Mobile drawer positioning — the sidebar panel is pinned to the sticky header's bottom edge (re-synced on open/resize/load/fonts) so content never hides behind the header.
- Modern hamburger toggle — borderless ghost button with a two-bar SVG icon (bottom bar shorter) that swaps to an X when open; hover tint,
:focus-visiblering, press scale, icon-only everywhere.
- Tables wrapped in
.table-scrollcontainers server-side (CommonMarkRenderer::wrapTables()). - Trailing newlines trimmed from code blocks before highlighting.
- Refreshed slate design (
#0f172abase /#1e293baccents /#94a3b8muted /#334155divider). - Title (2 lines) and description (3 lines) line-clamped to prevent overflow.
- PHPStan fixes in
sortNavigationDocuments()(docblock formatting, typed casts); Rector cleanup.
- Configurable DocSmith attribution badge in the sidebar (
showDocsmithBadge()builder option).
- Fix: corrected the Edit this page link generation.
- Fix: improved
og:imagehandling for subpath base URLs.
- Fix: OG image generation edge cases ("og image stuff").
- OG image generation with capturist cache —
ogGeneratedPerPage(),ogTemplate(),captureOg()support. - Uses capturist 0.1.3 native cache for incremental OG builds (no re-render on unchanged pages).
- Playwright + capturist explicitly required as OG dependencies.
- Docs GitHub Actions without npm lockfile cache.
.gitattributes/.gitignoreupdated for/docsand/node_modules.laravel/paoadded to require-dev.
- Standalone
bin/docsmithCLI command. - Fix:
llms.txt/llms-full.txtexport for versioned builds.
composer.lockadded to.gitignore.- Docs: CLI usage documented.
- Versioned documentation with a version switcher — switcher links respect
baseUrland preserve the current page; default (no versions) builds to root without duplication. - Keyboard-navigation search overlay (
⌘K) with live results, "1 character" minimum, and fixed reopen/close loop bugs. - AI-agent exports:
llmsExport()generatesllms.txt,llms-full.txt, and a plain-Markdown export page. - Front-matter
hiddensupport — pages marked hidden are excluded from the site/nav. - GitHub Actions workflow for automatic documentation builds.
- Pages added for versioned docs, LLM export, search overlay, frontmatter hidden, and a CI example.