> For the complete documentation index, see [llms.txt](https://docs.nullcraft.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nullcraft.org/tutorial/syntax/gitbook.md).

# GitBook 语法

{% hint style="warning" %}
这个主要是给在使用 Github 编辑上想调用 GitBook 语法而准备的示例页面

注：此语法并不适用于其它地方使用，仅限此文档使用。
{% endhint %}

## Hint (提示)

### 语法

{% code lineNumbers="true" fullWidth="false" %}

```
```

{% endcode %}

\`\`\` {% hint style="info" %} 这里写内容，同时也支持 MarkDown 语法和引入图片、超链接等。 {% endhint %}

```

</div>

参数 `style=""` 可选 `info`、`warning`、`danger`、`success`

### 效果

Info 风格

<div data-gb-custom-block data-tag="hint" data-style='info'>

Info - 信息 蓝色 "i" 圆图标

</div>

```

{% hint style="info" %} Info - 信息 蓝色 "i" 圆图标 {% endhint %}

```

Warning 风格

<div data-gb-custom-block data-tag="hint" data-style='warning'>

Warning - 警告 橙色 "!" 圆图标

</div>

```

{% hint style="warning" %} Warning - 警告 橙色 "!" 圆图标 {% endhint %}

```

Danger 风格

<div data-gb-custom-block data-tag="hint" data-style='danger'>

Danger - 危险 红色 "!" 三角图标

</div>

```

{% hint style="danger" %} Danger - 危险 红色 "!" 三角图标 {% endhint %}

```

Success 风格

<div data-gb-custom-block data-tag="hint" data-style='success'>

Success - 成功 绿色 "√" 圆图标

</div>

```

{% hint style="success" %} Success - 成功 绿色 "√" 圆图标 {% endhint %}

```

## Embed (嵌入)

### 超链接卡片

#### 语法

```

{% embed url="<https://nullcraft.org/>" %}

```

#### 效果

<div data-gb-custom-block data-tag="embed" data-url='https://nullcraft.org/'></div>

### 超链接文档卡片

#### 语法

```

{% content-ref url="路径" %} [文档文件名字](https://github.com/NullCraftOrg/docs/blob/master/tutorial/syntax/文档文件路径/README.md) {% endcontent-ref %}

{% content-ref url="../../" %} [..](/readme.md) {% endcontent-ref %}

{% content-ref url="../../donate/" %} [donate](/donate.md) {% endcontent-ref %}

```

参数 `url="../../"` url内填写文档的路径，以调用文档为基准，向上(../)或向下(/)写路径。

参数内容：使用MarkDown 超链接语法，\[文件名]\(文件路径)

#### 效果

<div data-gb-custom-block data-tag="content-ref" data-url='../../readthis/'>

[readthis](../../readthis/)

</div>

```

{% content-ref url="../../" %} [..](/readme.md) {% endcontent-ref %}

```

<div data-gb-custom-block data-tag="content-ref" data-url='../../donate/'>

[donate](../../donate/)

</div>

```

{% content-ref url="../../donate/" %} [donate](/donate.md) {% endcontent-ref %}

\`\`\`


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.nullcraft.org/tutorial/syntax/gitbook.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
