Skip to content

Commit

Permalink
docs: refine documentation of halo:comment tag (#281)
Browse files Browse the repository at this point in the history
从 Halo 2.9 开始,判断评论组件是否显示的条件不再只是单纯的判断评论插件是否安装。

see halo-dev/halo#4271

/kind documentation


```release-note
None
```
  • Loading branch information
ruibaby authored Dec 1, 2023
1 parent 7e8a8ec commit df6ed25
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
3 changes: 2 additions & 1 deletion docs/developer-guide/theme/template-tag.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ Halo 为满足部分代码注入和模板扩展点的需求,提供了一些专
### 使用示例

```html title="/templates/post.html"
<div th:if="${pluginFinder.available('PluginCommentWidget')}">
<!-- 需要判断当前评论组件是否满足显示的条件,这个变量可能是是否安装评论插件、文章是否开启评论等条件的组合 -->
<div th:if="${haloCommentEnabled}">
<halo:comment
group="content.halo.run"
kind="Post"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ Halo 为满足部分代码注入和模板扩展点的需求,提供了一些专
### 使用示例

```html title="/templates/post.html"
<div th:if="${pluginFinder.available('PluginCommentWidget')}">
<!-- 需要判断当前评论组件是否满足显示的条件,这个变量可能是是否安装评论插件、文章是否开启评论等条件的组合 -->
<div th:if="${haloCommentEnabled}">
<halo:comment
group="content.halo.run"
kind="Post"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ Halo 为满足部分代码注入和模板扩展点的需求,提供了一些专
### 使用示例

```html title="/templates/post.html"
<div th:if="${pluginFinder.available('PluginCommentWidget')}">
<!-- 需要判断当前评论组件是否满足显示的条件,这个变量可能是是否安装评论插件、文章是否开启评论等条件的组合 -->
<div th:if="${haloCommentEnabled}">
<halo:comment
group="content.halo.run"
kind="Post"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ Halo 为满足部分代码注入和模板扩展点的需求,提供了一些专
### 使用示例

```html title="/templates/post.html"
<div th:if="${pluginFinder.available('PluginCommentWidget')}">
<!-- 需要判断当前评论组件是否满足显示的条件,这个变量可能是是否安装评论插件、文章是否开启评论等条件的组合 -->
<div th:if="${haloCommentEnabled}">
<halo:comment
group="content.halo.run"
kind="Post"
Expand Down

1 comment on commit df6ed25

@vercel
Copy link

@vercel vercel bot commented on df6ed25 Dec 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

halo-docs – ./

halo-docs-git-main-halo-dev.vercel.app
halo-docs-halo-dev.vercel.app
docs.halo.run
halo-docs.vercel.app

Please sign in to comment.