docs(doc-entries): Show examples as code blocks
Directive examples sat bare in the doc bodies, so rendering them as markdown executed the directives: live components, missing-file fetches, and style side effects on the dialog. Wrap each example in a markdown fence, matching the convention already used by md-table.
This commit is contained in:
@@ -9,18 +9,25 @@ title: 字体组件
|
||||
**语法:** `:md-font[字体名]{选项}`
|
||||
|
||||
**Google 字体:**
|
||||
```markdown
|
||||
:md-font[Noto Sans SC]{source="google"}
|
||||
```
|
||||
|
||||
**Emfont 字体:**
|
||||
```markdown
|
||||
:md-font[Source Han Serif]{source="emfont" weight="700"}
|
||||
```
|
||||
|
||||
**本地字体(默认):**
|
||||
```markdown
|
||||
:md-font[STSong]
|
||||
```
|
||||
|
||||
**设置文字颜色:**
|
||||
```markdown
|
||||
:md-font[Noto Sans SC]{source="google" color="#1a1a2e"}
|
||||
|
||||
:md-font[Noto Sans SC]{source="google" weight="700" color="crimson"}
|
||||
```
|
||||
|
||||
字体和颜色将应用到整个文档卡片。
|
||||
|
||||
|
||||
Reference in New Issue
Block a user