Skip to content
Go back

astro-minimax Feature Overview

A comprehensive guide to all astro-minimax features, including content management, visualization components, AI integration, and interactive systems.

astro-minimax is a feature-rich Astro blog theme built with a modular architecture. This article provides a comprehensive overview of all features and how to use them.

Architecture Overview

astro-minimax consists of four core packages:

PackageDescriptionRequired
@astro-minimax/coreCore theme: layouts, components, styles, visualizations (Mermaid/Markmap etc.)Yes
@astro-minimax/aiAI integration: multi-provider chat, RAG retrieval, streamingOptional
@astro-minimax/notifyNotification system: Telegram, Email, Webhook multi-channel notificationsOptional
@astro-minimax/cliCLI tools: blog scaffolding, AI processing, profile building, quality evalRecommended

Content Management

Markdown / MDX

All posts are written in Markdown or MDX with support for:

Multi-language

Built-in Chinese/English bilingual support. Posts are organized by language:

src/data/blog/
├── zh/     # Chinese posts
└── en/     # English posts
plaintext

Languages are distinguished by URL prefix: /zh/posts/... and /en/posts/....

Content Organization

Tags

Each post can have multiple tags for flexible cross-categorization:

tags:
  - astro
  - typescript
  - tutorial
yaml

The tags page (/tags/) displays a tag cloud. Click any tag to see all posts with that tag.

Categories

Hierarchical categories supported with / separators:

category: Tutorial/Configuration
yaml

The categories page (/categories/) displays a tree-structured category view.

Series

Organize related posts into ordered series:

series:
  name: Rust Getting Started
  order: 1
yaml

Series pages auto-generate navigation showing previous/next posts.

Archives

A timeline-based archive page (/archives/) showing all posts. Controlled by the features.archives toggle.

Frontmatter

Post metadata is defined via frontmatter:

---
title: Post Title
pubDatetime: 2026-03-14T10:00:00Z
modDatetime: 2026-03-20T01:46:35Z
author: Souloss
description: Post description
tags: [astro, tutorial]
category: Tutorial/Configuration
series: { name: "Series Name", order: 1 }
featured: true
draft: false
ogImage: ./cover.png
---
yaml

See Adding New Posts for details.

Cover Image

Two image fields in frontmatter serve different purposes:

When cover is not set but ogImage is, the OG image is used as the cover. When neither is set, a dynamic OG image is auto-generated.


Two search providers available, configurable via search.provider:

Pagefind Full-text Search (Default)

Built-in Pagefind static search engine:

The search index is automatically generated during pnpm run build.

Algolia DocSearch

Support for Algolia DocSearch cloud search:

Configuration:

search: {
  provider: 'docsearch',
  docsearch: {
    appId: 'YOUR_APP_ID',
    apiKey: 'YOUR_SEARCH_API_KEY',
    indexName: 'YOUR_INDEX_NAME',
  },
},
typescript

For a detailed comparison and setup walkthrough of both search providers, see the Search Configuration Guide.


Themes & Styling

Light/Dark Mode

Three theme modes supported:

Theme switching uses View Transitions animation for smooth transitions. Controlled by darkMode.

Custom Color Schemes

Customize the entire site’s colors through CSS variables:

:root {
  --background: #ffffff;
  --foreground: #1a1a2e;
  --accent: #3b82f6;
  --muted: #6b7280;
  --border: #e5e7eb;
}

[data-theme="dark"] {
  --background: #0f172a;
  --foreground: #e2e8f0;
  --accent: #60a5fa;
  --muted: #94a3b8;
  --border: #334155;
}
css

See Customizing Color Schemes for details.

Responsive Design

Mobile-first responsive design throughout:


Visualization Components

The @astro-minimax/core package provides rich visualization components.

Mermaid Diagrams

Write Mermaid diagrams directly in Markdown:

```mermaid
graph TD
  A[Start] --> B{Decision}
  B -->|Yes| C[Execute]
  B -->|No| D[Skip]
```
markdown

Supports flowcharts, sequence diagrams, Gantt charts, pie charts, class diagrams, and all Mermaid chart types. Automatically adapts to light/dark themes.

Markmap Mind Maps

Generate interactive mind maps from Markdown outlines:

```markmap
# Central Topic
## Branch A
### Leaf 1
### Leaf 2
## Branch B
### Leaf 3
```
markdown

Supports zoom, pan, and expand/collapse interactions.

Rough.js Hand-drawn Graphics

Use hand-drawn style SVG shapes with the :::rough directive:

:::rough{config='{"width":400,"height":200,"shapes":[{"type":"rectangle","x":10,"y":10,"width":200,"height":100}]}'}
markdown

Excalidraw Whiteboard

Embed Excalidraw whiteboard-style diagrams with the :::excalidraw directive:

:::excalidraw{src="https://excalidraw.com/#json=..." height="500px"}
markdown

Automatically adapts to light/dark themes.

Asciinema Terminal Replay

Embed terminal recording playback with the :::asciinema directive:

:::asciinema{src="/casts/demo.cast" cols="120" rows="30"}
markdown

Markdown Directives

All visualization and media components are available as Markdown directives — no imports needed, works in both .md and .mdx files:

DirectiveDescription
:::excalidraw{src="..." height="500px"}Excalidraw whiteboard embed
:::asciinema{src="..." rows="24" speed="1"}Terminal session replay
:::rough{config='...'}Rough.js hand-drawn graphics
:::video{bilibili="..."}Bilibili video embed
:::audio{netease="..."}Music player (NetEase, QQ Music, etc.)
:::coderunner{lang="javascript" title="..."}Interactive JavaScript code runner
:::htmlembed{src="..." height="1600px"}Full HTML page embed
:::colorsColor palette display

AI Chat

The @astro-minimax/ai package provides intelligent conversation capabilities.

Key Features

AI Tool Calling

The AI assistant has 7 built-in page interaction tools: toggleTheme, navigateToArticle, scrollToSection, toggleImmersiveMode, highlightText, setPreference, searchArticles. Users can switch themes, jump to articles, scroll to sections, and more without leaving the chat panel.

See the AI Tool Calling Guide for details.

Action System

A three-stage client-side pipeline: ActionExecutor + ActionQueue + URLHandler. Supports cross-page action chaining and URL-based action sharing. Encode action parameters into a URL, share it, and the recipient’s page executes the preset actions automatically. Combined with tool calling, it enables compound actions like “bookmark and navigate.”

See the AI Tool Calling Guide for details.

Usage

The AI chat appears as a floating widget in the bottom-right corner. Click to open the chat window where you can:

Configuration

Enable in src/config.ts:

ai: {
  enabled: true,
  mockMode: false,       // Set to false for production
  apiEndpoint: "/api/chat",
},
js

See Configuration Guide for details.


Interactive Systems

Waline Comments

Built-in Waline comment system:

Requires self-hosted Waline server. See Configuration Guide.

Sponsorship

Donation feature supporting multiple payment methods:

Shows donation buttons and QR codes at the bottom of posts. Supports displaying a sponsors list.

Notification System

Multi-channel notifications to stay updated on blog activity:

Rich notification content including token usage, phase timing, referenced articles, and automatic session ID anonymization for privacy.

See Notification System Configuration Guide for details.


SEO & Performance

Dynamic OG Images

Posts without a specified OG image get one auto-generated:

See Dynamic OG Images for details.

SEO Optimization

Performance


Code Enhancement

Syntax Highlighting

Shiki provides beautiful code highlighting:

Math Equations

LaTeX math equations rendered via KaTeX:

Inline: $E = mc^2$

Block:

$$
\int_{-\infty}^{\infty} e^{-x^2} dx = \sqrt{\pi}
$$
latex

See How to Add LaTeX Equations for details.


Analytics

Umami

Integrated Umami privacy-friendly web analytics:

Requires self-hosted Umami instance.


Additional Features

FeatureDescription
Friends pageDisplay friend links with avatars and descriptions
Projects showcaseGitHub repo cards with auto-fetched repo info
Image lightboxClick-to-zoom image preview
Reading positionSave and restore reading position
Floating TOCSidebar floating table of contents
BreadcrumbPage hierarchy navigation
Copyright noticeLicense info at post bottom
Edit link”Edit on GitHub” link under post title
Keyboard navigationKeyboard shortcut support
AccessibilityWCAG 2.1 AA compliance
View TransitionsPage transition animations
PrefetchingLink prefetching for faster navigation

Feature Toggle Quick Reference

Control all feature toggles in features inside src/config.ts:

features: {
  tags: true,        // Tag system
  categories: true,  // Category system
  series: true,      // Series posts
  archives: true,    // Archives page
  friends: true,     // Friends page
  projects: true,    // Projects showcase
  search: true,      // Full-text search
},
darkMode: true,     // Light/dark theme
js

CLI Tools

The @astro-minimax/cli package provides a comprehensive command-line toolkit for blog management and AI content processing.

Installation

CLI tools are included with the @astro-minimax/cli package, or use npx astro-minimax for one-off commands.

Main Commands

CommandDescription
astro-minimax initCreate a new blog project
astro-minimax aiAI content processing (summaries, SEO, eval)
astro-minimax ai profileAuthor profile management (retained canonical entrypoint)
astro-minimax postPost management (new, list, stats)
astro-minimax dataData management (status, clear)
astro-minimax hooksInstall, uninstall, and inspect Git hooks

Usage Examples

astro-minimax post new "Post Title"   # Create a new post
astro-minimax ai process               # AI process all articles
astro-minimax ai eval                  # Evaluate AI chat quality
astro-minimax ai profile build         # Build complete author profile
astro-minimax data status              # View data status
bash

All commands also have pnpm run shortcuts (e.g. pnpm run ai:process). See CLI Guide.

AI Evaluation System

Built-in golden test set (datas/eval/gold-set.json) for automated AI chat quality assessment:

pnpm run ai:eval                                  # Local test
pnpm run ai:eval -- --url=https://your-blog.com   # Remote test
bash

More Resources



Previous Post
Deployment Guide: Deploy astro-minimax to Multiple Platforms
Next Post
How to configure astro-minimax theme

评论区

文明评论,共建和谐社区