DR. MOHD ISKANDAR PUTRA, PH.DMOHD ISKANDAR PUTRA, PH.D
HOMEABOUTPROJECTSTOOLSBLOG
COFFEE
Iskandar Putra
MOHD ISKANDAR PUTRA

Architecting the invisible layer between hardware and possibility. Building systems that bridge the gap between physical reality and digital precision.

EXPLORE

  • About
  • Projects
  • Blog
  • Roadmap

RESEARCH

  • Google Scholar
  • Scopus
  • Substack Insights
  • Tools & Gear

CONNECT

  • Get in Touch
© 2026 MOHD ISKANDAR PUTRA, PH.D — All Rights Reserved.|Penang, Malaysia
Engineered on First Principles, Control Theory & Deterministic Logic.
All Projects
Documentation

Engineering · Reader

⌘K
Modules05
  • 01ccmon · A live dashboard for Claude Code
  • 02Docs Component Showcase
  • 03zy · A shell built from scratch in C
  • 04zyterm. A serial terminal.
  • 05Zyvrix Project
Tagged
MDXDocsComponentsReference
Module 02·Reference

Docs Component Showcase

CompleteBeginnerUpdated 2026-02-22

A complete reference page for every MDX component: callouts, code, math, diagrams, timeline, metrics, quotes, gallery, citations, and more.

Docs Component Showcase

This page is a living reference for every component, formatting primitive, and automatic-numbering feature available in this MDX documentation system. Use it to validate rendering and as a copy-paste starting point.

How to use this page

Each section below demonstrates one category of functionality. The section numbers, figure labels, equation numbers, and reference citations are all generated automatically. No manual counters required.


Callouts

Four semantic variants give you visual hierarchy for alerts and annotations.

Note

Use note for neutral information that supplements the main text.

Tip

Use tip to highlight a best practice, shortcut, or pro move.

Warning

Use warning when something can go wrong: configuration pitfalls, deprecations, etc.

Danger

Use danger for destructive or irreversible operations only.


Code Blocks

Syntax-highlighted via Shiki with dual theming (dark/light). Line numbers and titles are supported.

JavaScript

fibonacci.jsjs
function fibonacci(n) {
  if (n <= 1) return n;
  return fibonacci(n - 1) + fibonacci(n - 2);
}
 
console.log(fibonacci(10)); // 55

TypeScript with line highlights

types.tsts
interface Project {
  slug: string;
  title: string;       // highlighted
  publishedAt: string; // highlighted
  tags: string[];      // highlighted
}

Shell

bash
npm install
npm run dev
npm run build

Inline code: use backticks in prose for variable names, function() calls, or --cli-flags.


Mathematics

Block-level equations are wrapped in <Equation> for auto-numbering. Raw $$...$$ works too.

Euler's identity

eiπ+1=0e^{i\pi} + 1 = 0eiπ+1=0

Discrete PID controller

u[k]=Kp e[k]+Ki∑j=0ke[j] Δt+Kde[k]−e[k−1]Δtu[k] = K_p \, e[k] + K_i \sum_{j=0}^{k} e[j]\,\Delta t + K_d \frac{e[k] - e[k-1]}{\Delta t}u[k]=Kp​e[k]+Ki​∑j=0k​e[j]Δt+Kd​Δte[k]−e[k−1]​

Fourier transform

f^(ξ)=∫−∞∞f(x) e−2πixξ dx\hat{f}(\xi) = \int_{-\infty}^{\infty} f(x)\, e^{-2\pi i x \xi}\, dxf^​(ξ)=∫−∞∞​f(x)e−2πixξdx

Inline math also works: the quadratic formula is x=−b±b2−4ac2ax = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}x=2a−b±b2−4ac​​.


Diagrams

Mermaid diagrams render server-side with no client JS.

System architecture

Sequence diagram


Tabs

Group related variant content under named tabs.

bash
npm install next-mdx-remote
npm install rehype-pretty-code shiki
npm install remark-gfm rehype-katex katex
bash
pnpm add next-mdx-remote
pnpm add rehype-pretty-code shiki
pnpm add remark-gfm rehype-katex katex
bash
yarn add next-mdx-remote
yarn add rehype-pretty-code shiki
yarn add remark-gfm rehype-katex katex

Steps

Numbered procedural sequences with visual connectors.

Install dependencies

Run npm install to install all required packages.

Configure MDX options

Set up rehypePlugins and remarkPlugins in your mdxOptions config.

Add custom components

Pass docsComponents to <MDXRemote components={docsComponents} />.

Write your first MDX file

Create a .mdx file in the projects/ folder and add frontmatter.


Cards

Card grid

MDX Engine

next-mdx-remote/rsc compiled at build time with zero runtime overhead, full React component support inside .mdx files.

🎨

Syntax Highlighting

Shiki dual-theme (github-dark-default / github-light-default) with precise token-level CSS variable output.

∑

Math Rendering

KaTeX via rehype-katex with server-side rendering, no flicker, full LaTeX math support including display and inline modes.

Auto Numbering

CSS counters on .docs-article automatically label headings, figures, tables, and equations by section. No manual tracking.

Link cards

next-mdx-remote docs

Official docs for the MDX processing library used here.

→

Shiki documentation

Syntax highlighter powering all code blocks on this site.

→

Tables

Auto-numbering with caption

LibrarySSRBundle sizeCustom components
next-mdx-remote✓~40 kB✓
@mdx-js/react✓~25 kB✓
contentlayer✓~120 kB✓
mdx-bundler✓~30 kB✓

Comparison of MDX processing libraries

Plain GFM table (no caption, no auto-number)

PropTypeDefaultDescription
typestring"note"Callout variant
titlestring—Optional heading
childrenReactNode—Content

Figures

Images wrapped in <Figure> receive automatic section-scoped labels.

Docs component architecture
Layered architecture of the MDX component system
Counter cascade
CSS counter cascade: section resets propagate down through figures, tables, and equations

Keyboard & inline UI

Use Ctrl + K to open the command palette. Press ⌘ Shift P on macOS.

Badges classify content at a glance:

Stable Beta Deprecated New

Collapsible details

▶How do CSS counters work in this system?

Every .docs-article element carries counter-reset for all six counter families: docs-h2, docs-h3, docs-h4, docs-fig, docs-tab, and docs-eq. When a .docs-h2 heading is encountered, it increments docs-h2 and resets all subsection counters. Figures, tables, and equations then read both the current H2 counter and their own local counter to produce the X.Y label via ::before / ::after pseudo-elements.

▶Can I mix <Equation> with bare $$ math?

Yes. Bare $$...$$ paragraphs produce a .katex-display block which is styled but not auto-numbered. Wrap in <Equation> when you want the (X.Y) label to appear on the right.


Aside

The <Aside> component places a left-border callout without a header. Ideal for short tangential observations that don't warrant a full Callout block.


Highlight & Prose Utilities

You can highlight a span of text inline, or use a custom colour: accent gold.

The GFM extensions are also active:

  • remark-gfm enabled
  • Task list checkboxes render
  • Strikethrough works
  • Tables supported natively

Props Table

PropertyTypeDefaultDescription
type"note" | "tip" | "warning" | "danger" | "info""note"Visual variant of the callout
titlestring—Optional heading displayed in bold above content
childrenReactNode—The callout body content

Timeline

Vertical timeline for changelogs, milestones, or version history. Each item takes date, title, and an optional badge.

2026-02v3.0 — Academic numberingmajor

JS-driven heading counters, figure/table/equation auto-labels, IEEE reference components, and 4 new layout primitives.

2026-01v2.0 — Glassmorphic redesignminor

Rebuilt left sidebar with current-project card, numbered nav, progress bar. Right TOC with scroll-spy and section numbers.

2025-12v1.0 — Initial MDX enginerelease

Bootstrapped next-mdx-remote pipeline with Shiki dual-theme, KaTeX math, Mermaid diagrams, and first component library.


Metrics

Stat cards for benchmarks, performance numbers, or any quantitative summary. Supports value, label, unit, delta, and trend (up / down / neutral).

1.2ms
avg response time
↑ −18% vs v2
98%
Lighthouse score
↑ +4 pts
21
static pages
0B
client JS (docs)
↑ fully static
8.5s
build time
72ch
content width

Quote

Academic-style pull quote with author and optional source attribution. Great for referencing influential ideas or standards.

Premature optimization is the root of all evil.

Donald KnuthThe Art of Computer Programming

Simplicity is a great virtue but it requires hard work to achieve it and education to appreciate it. And to make matters worse: complexity sells better.

Edsger W. Dijkstra

Gallery

Responsive image grid. Pass an images array and optional cols (2 / 3 / 4, default 3).

Claude
Claude
ChatGPT
ChatGPT
Gemini
Gemini
Copilot
Copilot
DeepSeek
DeepSeek
Grok
Grok
HuggingFace
HuggingFace
Qwen
Qwen

Citations & References

This showcase references key standards [1] and tooling documentation [2, 3] used in the MDX pipeline design. The KaTeX rendering engine [4] allows full LaTeX math, while Shiki [5] provides fine-grained syntax highlighting.

References

  1. [1]IEEE Std 830-1998, IEEE Recommended Practice for Software Requirements Specifications. IEEE, 1998.
  2. [2]J. Bayer and contributors. "next-mdx-remote: Load MDX content from anywhere." GitHub, 2024. [Online]. Available: https://github.com/hashicorp/next-mdx-remote
  3. [3]A. Thomas and contributors. "Shiki — A beautiful syntax highlighter." shiki.style, 2024. [Online]. Available: https://shiki.style
  4. [4]KaTeX contributors. "KaTeX: Fast math typesetting for the web." katex.org, 2024. [Online]. Available: https://katex.org
  5. [5]rehype-pretty-code contributors. "rehype-pretty-code." GitHub, 2024. [Online]. Available: https://rehype-pretty-code.netlify.app

Advanced Components

Columns & Progress

Layout content flexibly and track status with ProgressBar.

Project Completion75%
Testing Phase40%
Design System95%
Did you know?
▶

You can now make callouts collapsible! This is great for keeping long code snippets or auxiliary information hidden until the user explicitly wants to read it.

Interactive Displays

Hover over the term Docs SystemA comprehensive software component library for MDX to see the tooltip in action.

Iskandar Putra
Iskandar Putra
Software Engineer

Rich Task Lists (GFM)

  • Create advanced components
  • Update stylings
  • Write integration tests

Embeds & Bookmarks

Enhance external links with <Bookmark> for automated OpenGraph-style previews.

Shiki: A beautiful yet powerful syntax highlighter

Shiki is a beautiful and powerful syntax highlighter based on TextMate grammar. It powers the robust codeblock highlighting on this page.

https://shiki.style/
Shiki: A beautiful yet powerful syntax highlighter

Kanban Board

A static kanban board primitive to demonstrate project workflows.

To Do

Review MDX plugins
Update documentation

In Progress

Implementing Kanban

Done

System Design
Initial Layout

Image Comparison

An interactive <ImageCompare> slider to showcase before/after scenarios in your docs.

Original
Grayscale Filter
Original
Grayscale Filter

On This Page

Reader · contents

  • Docs Component Showcase
  • 1.0Callouts
  • 2.0Code Blocks
  • 2.1JavaScript
  • 2.2TypeScript with line highlights
  • 3.0Mathematics
  • 3.1Euler's identity
  • 3.2Discrete PID controller
  • 3.3Fourier transform
  • 4.0Diagrams
  • 4.1System architecture
  • 4.2Sequence diagram
  • 5.0Tabs
  • 6.0Steps
  • 7.0Cards
  • 7.1Card grid
  • 7.2Link cards
  • 8.0Tables
  • 8.1Auto-numbering with caption
  • 8.2Plain GFM table (no caption, no auto-number)
  • 9.0Figures
  • 10.0Keyboard & inline UI
  • 11.0Collapsible details
  • 12.0Aside
  • 13.0Highlight & Prose Utilities
  • 14.0Props Table
  • 15.0Timeline
  • 16.0Metrics
  • 17.0Quote
  • 18.0Gallery
  • 19.0Citations & References
  • 20.0Advanced Components
  • 20.1Columns & Progress
  • 20.2Interactive Displays
  • 20.3Embeds & Bookmarks
  • 20.4Kanban Board
  • 20.5Image Comparison