<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="zh_CN">
  <title>风绘笔记</title>
  <subtitle>HuiDev Notes</subtitle>
  <link href="https://huidev.com/" rel="alternate" type="text/html"/>
  <link href="https://huidev.com/atom.xml" rel="self" type="application/atom+xml"/>
  <id>https://huidev.com/</id>
  <updated>2026-06-15T00:00:00.000Z</updated>
  <entry>
    <title>Markdown Example</title>
    <link href="https://huidev.com/posts/markdown/" rel="alternate" type="text/html"/>
    <id>https://huidev.com/posts/markdown/</id>
    <published>2026-06-15T00:00:00.000Z</published>
    <updated>2026-06-15T00:00:00.000Z</updated>
    <summary>A simple example of a Markdown blog post.</summary>
    <content type="html"><![CDATA[<h1>An h1 header</h1>
<p>Paragraphs are separated by a blank line.</p>
<p>2nd paragraph. <em>Italic</em>, <strong>bold</strong>, and <code>monospace</code>. Itemized lists
look like:</p>
<ul>
<li>this one</li>
<li>that one</li>
<li>the other one</li>
</ul>
<p>Note that --- not considering the asterisk --- the actual text
content starts at 4-columns in.</p>
<blockquote>
<p>Block quotes are
written like so.</p>
<p>They can span multiple paragraphs,
if you like.</p>
</blockquote>
<p>Use 3 dashes for an em-dash. Use 2 dashes for ranges (ex., "it's all
in chapters 12--14"). Three dots ... will be converted to an ellipsis.
Unicode is supported. ☺</p>
<h2>An h2 header</h2>
<p>Here's a numbered list:</p>
<ol>
<li>first item</li>
<li>second item</li>
<li>third item</li>
</ol>
<p>Note again how the actual text starts at 4 columns in (4 characters
from the left side). Here's a code sample:</p>
<pre><code># Let me re-iterate ...
for i in 1 .. 10 { do-something(i) }
</code></pre>
<p>As you probably guessed, indented 4 spaces. By the way, instead of
indenting the block, you can use delimited blocks, if you like:</p>
<pre><code>define foobar() {
    print "Welcome to flavor country!";
}
</code></pre>
<p>(which makes copying &amp; pasting easier). You can optionally mark the
delimited block for Pandoc to syntax highlight it:</p>
<pre><code>import time
# Quick, count to ten!
for i in range(10):
    # (but not *too* quick)
    time.sleep(0.5)
    print i
</code></pre>
<h3>An h3 header</h3>
<p>Now a nested list:</p>
<ol>
<li>
<p>First, get these ingredients:</p>
<ul>
<li>carrots</li>
<li>celery</li>
<li>lentils</li>
</ul>
</li>
<li>
<p>Boil some water.</p>
</li>
<li>
<p>Dump everything in the pot and follow
this algorithm:</p>
<pre><code> find wooden spoon
 uncover pot
 stir
 cover pot
 balance wooden spoon precariously on pot handle
 wait 10 minutes
 goto first step (or shut off burner when done)
</code></pre>
<p>Do not bump wooden spoon or it will fall.</p>
</li>
</ol>
<p>Notice again how text always lines up on 4-space indents (including
that last line which continues item 3 above).</p>
<p>Here's a link to <a href="http://foo.bar">a website</a>, to a <a href="local-doc.html">local
doc</a>, and to a <a href="#an-h2-header">section heading in the current
doc</a>. Here's a footnote [^1].</p>
<p>[^1]: Footnote text goes here.</p>
<p>Tables can look like this:</p>
<p>size material color</p>
<hr />
<p>9 leather brown
10 hemp canvas natural
11 glass transparent</p>
<p>Table: Shoes, their sizes, and what they're made of</p>
<p>(The above is the caption for the table.) Pandoc also supports
multi-line tables:</p>
<hr />
<p>keyword text</p>
<hr />
<p>red Sunsets, apples, and
other red or reddish
things.</p>
<p>green Leaves, grass, frogs
and other things it's
not easy being.</p>
<hr />
<p>A horizontal rule follows.</p>
<hr />
<p>Here's a definition list:</p>
<p>apples
: Good for making applesauce.
oranges
: Citrus!
tomatoes
: There's no "e" in tomatoe.</p>
<p>Again, text is indented 4 spaces. (Put a blank line between each
term/definition pair to spread things out more.)</p>
<p>Here's a "line block":</p>
<p>| Line one
| Line too
| Line tree</p>
<p>and images can be specified like so:</p>
<p>Inline math equations go in like so: $\omega = d\phi / dt$. Display
math should get its own line and be put in in double-dollarsigns:</p>
<p>$$I = \int \rho R^{2} dV$$</p>
<p>$$
\begin{equation*}
\pi
=3.1415926535
;8979323846;2643383279;5028841971;6939937510;5820974944
;5923078164;0628620899;8628034825;3421170679;\ldots
\end{equation*}
$$</p>
<p>And note that you can backslash-escape any punctuation characters
which you wish to be displayed literally, ex.: `foo`, *bar*, etc.</p>
]]></content>
    <author><name>风绘</name></author>
    <category term="Examples"/>
  </entry>
  <entry>
    <title>MDX Integration and M3E Atomic Components</title>
    <link href="https://huidev.com/posts/mdx-showcase/" rel="alternate" type="text/html"/>
    <id>https://huidev.com/posts/mdx-showcase/</id>
    <published>2026-06-15T00:00:00.000Z</published>
    <updated>2026-06-15T00:00:00.000Z</updated>
    <summary>A comprehensive guide to composing rich interactive articles in Shirone using MDX, Svelte 5 interactive islands, and Material 3 Expressive design tokens.</summary>
    <content type="html"><![CDATA[<p>:::tip
<strong>MDX (Markdown + JSX)</strong> bridges the gap between static writing and application interfaces. In Shirone, authors can seamlessly mix dynamic logic, reactive Svelte 5 components, and Material 3 design tokens directly within post content.
:::</p>
<h2>1. Markdown vs MDX Capability Matrix</h2>
<table>
<thead>
<tr>
<th>Feature</th>
<th>Standard Markdown (<code>.md</code>)</th>
<th>Shirone MDX (<code>.mdx</code>)</th>
<th>Execution Mode</th>
</tr>
</thead>
<tbody>
<tr>
<td><strong>Typography &amp; Structure</strong></td>
<td>Full Support</td>
<td>Full Support</td>
<td>Static SSR</td>
</tr>
<tr>
<td><strong>Code Highlighting</strong></td>
<td>Line Numbers, Frames, Collapsible</td>
<td>Line Numbers, Frames, Collapsible</td>
<td>Static SSR (Expressive Code)</td>
</tr>
<tr>
<td><strong>Diagrams &amp; Mathematics</strong></td>
<td>Mermaid, KaTeX</td>
<td>Mermaid, KaTeX</td>
<td>Client Enhanced</td>
</tr>
<tr>
<td><strong>Callout Admonitions</strong></td>
<td>Note, Tip, Important, Warning, Caution</td>
<td>Note, Tip, Important, Warning, Caution</td>
<td>Static SSR</td>
</tr>
<tr>
<td><strong>M3E Display Atoms</strong></td>
<td>Not Available</td>
<td>Direct Integration (``, <code>&lt;Skeleton&gt;</code>)</td>
<td>Pure SSR (Zero Client JS)</td>
</tr>
<tr>
<td><strong>Svelte 5 Reactive Islands</strong></td>
<td>Not Available</td>
<td>On-Demand Hydration (<code>&lt;Button&gt;</code>, <code>&lt;Switch&gt;</code>)</td>
<td><code>client:visible</code> Lazy Hydrated</td>
</tr>
<tr>
<td><strong>Feedback &amp; Loading Atoms</strong></td>
<td>Not Available</td>
<td>Animated Morph (<code>&lt;LoadingIndicator&gt;</code>)</td>
<td><code>client:visible</code> Reactive</td>
</tr>
<tr>
<td><strong>Dynamic JSX Expressions</strong></td>
<td>Not Available</td>
<td>Native Evaluation (<code>{authorInfo.ui}</code>)</td>
<td>Compile-Time / Client</td>
</tr>
</tbody>
</table>
<hr />
<h2>2. Dynamic Expressions and Data Mapping</h2>
<p>MDX allows declaring scoped constants using <code>export const</code> at the top of the file, which can be evaluated inline or mapped across templates:</p>
<ul>
<li><strong>Core Framework</strong>: {authorInfo.framework}</li>
<li><strong>UI Engine</strong>: {authorInfo.ui}</li>
<li><strong>Design Tokens</strong>: {authorInfo.tokens}</li>
<li><strong>Architecture Pattern</strong>: {authorInfo.architecture}</li>
</ul>
<p>Arrays and collections can be rendered dynamically into grid layouts:</p>
<p>&lt;div class="grid grid-cols-1 md:grid-cols-2 gap-4 my-6"&gt;
{showcaseItems.map((item, idx) =&gt; (
&lt;div key={item.name} class="p-4 rounded-xl border border-[var(--outline-variant)] bg-[var(--surface-container-low)]"&gt;
&lt;div class="flex items-center gap-2 mb-1"&gt;
&lt;span class="w-6 h-6 rounded-full bg-[var(--primary)] text-[var(--on-primary)] text-xs flex items-center justify-center font-bold"&gt;
{idx + 1}
&lt;/span&gt;
&lt;span class="font-bold text-[var(--on-surface)]"&gt;{item.name}&lt;/span&gt;
&lt;/div&gt;
&lt;p class="text-sm text-[var(--on-surface-variant)] m-0"&gt;{item.desc}&lt;/p&gt;
&lt;/div&gt;
))}
&lt;/div&gt;</p>
<hr />
<h2>3. M3E Display and Layout Primitives (SSR-Only)</h2>
<p>In accordance with Shirone's component architecture (<code>docs/atomic-structure.md</code>), stateless display components output clean, accessible semantic HTML with no client-side runtime payload.</p>
<h3>3.1 Card Containers (<code>Card.svelte</code>)</h3>
<p>&lt;div class="grid grid-cols-1 md:grid-cols-3 gap-4 my-6"&gt;
&lt;Card variant="filled" class="!p-5"&gt;
&lt;div class="font-bold text-[var(--primary)] mb-2"&gt;Filled Card&lt;/div&gt;
&lt;div class="text-sm text-[var(--on-surface-variant)]"&gt;Default container background with no elevation shadow. Ideal for grouped content blocks.&lt;/div&gt;</p>
<pre><code>&lt;div class="font-bold text-[var(--primary)] mb-2"&gt;Elevated Card&lt;/div&gt;
&lt;div class="text-sm text-[var(--on-surface-variant)]"&gt;Level 1 container elevation with interactive state layering for heightened visual focus.&lt;/div&gt;



&lt;div class="font-bold text-[var(--primary)] mb-2"&gt;Outlined Card&lt;/div&gt;
&lt;div class="text-sm text-[var(--on-surface-variant)]"&gt;A crisp 1px outline boundary providing clean separation on neutral surfaces.&lt;/div&gt;
</code></pre>
<p>&lt;/div&gt;</p>
<h3>3.2 Accent Bars and Badges (<code>AccentBar</code> &amp; <code>Badge</code>)</h3>
<p>&lt;div class="flex items-center gap-4 my-4 p-4 rounded-lg bg-[var(--surface-container-high)]"&gt;</p>
<p>&lt;div class="flex-1"&gt;
&lt;span class="font-bold text-lg"&gt;System Announcement&lt;/span&gt;
&lt;p class="text-xs text-[var(--on-surface-variant)] m-0"&gt;Combine AccentBar with Badge to build prominent visual callouts&lt;/p&gt;
&lt;/div&gt;
M3E v0.192
&lt;/div&gt;</p>
<h3>3.3 Skeleton Placeholders (<code>Skeleton.svelte</code>)</h3>
<p>For previewing layout skeletons or prototyping async states:</p>
<p>&lt;div class="flex flex-col gap-3 my-6 p-5 rounded-xl border border-[var(--outline-variant)] bg-[var(--surface-container-low)]"&gt;
&lt;div class="flex items-center gap-3"&gt;</p>
<pre><code>&lt;div class="flex flex-col gap-1.5 flex-1"&gt;
  
  
&lt;/div&gt;
</code></pre>
<p>&lt;/div&gt;</p>
<p>&lt;/div&gt;</p>
<hr />
<h2>4. Feedback and Loading Indicators</h2>
<p>Shirone features full-fidelity Material 3 Expressive motion and feedback atoms:</p>
<h3>4.1 Morphing Loading Indicator (<code>LoadingIndicator.svelte</code>)</h3>
<p>Implemented with <code>androidx.graphics.shapes</code> polygon morphing, providing smooth spring-interpolated 7-shape animations:</p>
<p>&lt;div class="grid grid-cols-1 md:grid-cols-3 gap-4 my-6 p-6 rounded-2xl bg-[var(--surface-container)] border border-[var(--outline-variant)] text-center"&gt;
&lt;div class="flex flex-col items-center gap-2"&gt;
&lt;div class="h-16 flex items-center justify-center"&gt;</p>
<pre><code>&lt;/div&gt;
&lt;span class="text-xs text-[var(--on-surface-variant)]"&gt;Indeterminate Shape Morph&lt;/span&gt;
</code></pre>
<p>&lt;/div&gt;</p>
<p>&lt;div class="flex flex-col items-center gap-2"&gt;
&lt;div class="h-16 flex items-center justify-center"&gt;</p>
<pre><code>&lt;/div&gt;
&lt;span class="text-xs text-[var(--on-surface-variant)]"&gt;Contained Circular Variant&lt;/span&gt;
</code></pre>
<p>&lt;/div&gt;</p>
<p>&lt;div class="flex flex-col items-center gap-2"&gt;
&lt;div class="h-16 flex items-center justify-center"&gt;</p>
<pre><code>&lt;/div&gt;
&lt;span class="text-xs text-[var(--on-surface-variant)]"&gt;Determinate Progress (68%)&lt;/span&gt;
</code></pre>
<p>&lt;/div&gt;
&lt;/div&gt;</p>
<h3>4.2 Linear and Indeterminate Progress (<code>ProgressIndicator.svelte</code>)</h3>
<p>&lt;div class="flex flex-col gap-4 my-6 p-6 rounded-2xl bg-[var(--surface-container)] border border-[var(--outline-variant)]"&gt;
&lt;div class="flex flex-col gap-2"&gt;
&lt;div class="flex justify-between text-xs text-[var(--on-surface-variant)]"&gt;
&lt;span&gt;Pipeline Compilation&lt;/span&gt;
&lt;span&gt;80%&lt;/span&gt;
&lt;/div&gt;</p>
<p>&lt;/div&gt;</p>
<p>&lt;div class="flex flex-col gap-2 mt-2"&gt;
&lt;div class="text-xs text-[var(--on-surface-variant)]"&gt;Continuous Dual-Line Animation&lt;/div&gt;</p>
<p>&lt;/div&gt;
&lt;/div&gt;</p>
<hr />
<h2>5. Interactive Svelte 5 Islands</h2>
<p>Components declared with <code>client:visible</code> are lazy-hydrated via <code>IntersectionObserver</code> when entering the viewport:</p>
<h3>5.1 Button Matrix (<code>Button.svelte</code>)</h3>
<p>&lt;div class="flex flex-wrap items-center gap-3 my-6 p-4 rounded-xl border border-[var(--outline-variant)]"&gt;
Filled Button
Elevated
Tonal Button
Outlined
Text Button
&lt;/div&gt;</p>
<h3>5.2 Filter Chips and Segmented Buttons (<code>Chips</code> &amp; <code>SegmentedButton</code>)</h3>
<p>&lt;div class="flex flex-col gap-4 my-6 p-6 rounded-2xl bg-[var(--surface-container)] border border-[var(--outline-variant)]"&gt;
&lt;div&gt;
&lt;div class="text-xs font-bold text-[var(--on-surface-variant)] mb-2"&gt;M3E Filter Chips&lt;/div&gt;</p>
<p>&lt;/div&gt;</p>
<p>&lt;div&gt;
&lt;div class="text-xs font-bold text-[var(--on-surface-variant)] mb-2"&gt;Segmented Control&lt;/div&gt;</p>
<p>&lt;/div&gt;
&lt;/div&gt;</p>
<h3>5.3 Switches, Checkboxes, and Sliders (<code>Switch</code>, <code>Checkbox</code>, <code>Slider</code>)</h3>
<p>&lt;div class="flex flex-col gap-4 my-6 p-6 rounded-2xl bg-[var(--surface-container)] border border-[var(--outline-variant)]"&gt;
&lt;div class="flex items-center justify-between"&gt;
&lt;span class="font-bold text-sm"&gt;Switch with Status Icons&lt;/span&gt;</p>
<p>&lt;/div&gt;</p>
<p>&lt;div class="flex items-center justify-between"&gt;
&lt;span class="font-bold text-sm"&gt;Selection Checkboxes&lt;/span&gt;
&lt;div class="flex items-center gap-4"&gt;</p>
<pre><code>&lt;/div&gt;
</code></pre>
<p>&lt;/div&gt;</p>
<p>&lt;div class="flex flex-col gap-2"&gt;
&lt;span class="font-bold text-sm"&gt;Hue Spectrum Slider&lt;/span&gt;</p>
<p>&lt;/div&gt;
&lt;/div&gt;</p>
<h3>5.4 Input Controls (<code>TextField.svelte</code>)</h3>
<p>&lt;div class="grid grid-cols-1 md:grid-cols-2 gap-4 my-6"&gt;</p>
<p>&lt;/div&gt;</p>
<hr />
<h2>6. Markdown Extension Compatibility</h2>
<p>Shirone's SSOT unified plugin pipeline preserves full compatibility with all Markdown extensions:</p>
<h3>6.1 GitHub Repository Cards</h3>
<p>::github{repo="saicaca/fuwari"}</p>
<h3>6.2 Mermaid Architecture Diagrams</h3>
<pre><code>flowchart TD
    MDX[MDX Source Entry] --&gt; Compiler["@astrojs/mdx Compiler"]
    Compiler --&gt; Plugins["Remark / Rehype SSOT Pipeline"]
    Plugins --&gt; Islands["Svelte 5 Interactive Islands"]
    Islands --&gt; Swup["Swup Client Navigation Shell"]
    Swup --&gt; Screen["M3E Expressive Article View"]
</code></pre>
<h3>6.3 Mathematical Expressions (LaTeX / KaTeX)</h3>
<p>Inline equation: Mass-energy equivalence $E = mc^2$ and Gaussian integral $\int_{-\infty}^{\infty} e^{-x^2} dx = \sqrt{\pi}$.</p>
<p>Block equation:</p>
<p>$$
\mathcal{L}<em>{M3E} = \sum</em>{i=1}^{N} \left( \text{Token}_i \cdot \text{ContrastRatio} \right) + \lambda |\text{MotionElegance}|
$$</p>
<hr />
<h2>7. Summary</h2>
<p>The native integration of MDX empowers technical writers to build rich, interactive documentation while preserving Shirone's ultra-fast static performance. All components adhere to the Material 3 Expressive token design system, ensuring consistency, accessibility, and visual harmony.</p>
]]></content>
    <author><name>风绘</name></author>
    <category term="Guides"/>
  </entry>
</feed>
