Commit Graph

667 Commits (main)

Author SHA1 Message Date
John Niang 010bb8a569
Handle ghost users in user retrieval logic (#7745)
#### What type of PR is this?

/kind bug
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR fixes the always show of ghost user in post contributors.

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/7710

#### Does this PR introduce a user-facing change?

```release-note
修复文章贡献者中始终显示已删除用户的问题
```
2025-09-10 06:46:52 +00:00
John Niang 291d8dafb2
Restore context ClassLoader management during plugin lifecycle (#7746)
#### What type of PR is this?

/kind improvement
/area plugin
/milestone 2.21.x

#### What this PR does / why we need it:

This PR restores context ClassLoader mangement during plugin lifecycle to prevent resource leak.

Meanwhile, it also fixes Class initialization error when starting plugins.

Superseds https://github.com/halo-dev/halo/pull/7725

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-09-10 06:44:51 +00:00
John Niang 2a37366c92
Set context ClassLoader to plugin ClassLoader for correct class loading operations (#7725)
#### What type of PR is this?

/kind bug
/area plugin
/milestone 2.21.x

#### What this PR does / why we need it:

This PR fixes the problem that loading resources from class path during static initialization doesn't work.

#### Does this PR introduce a user-facing change?

```release-note
修复部分场景下无法正常启动插件的问题
```
2025-08-29 03:30:15 +00:00
John Niang 956e23dd7f
Allow deserializing ListResult (#7711)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR allows ListResult to be deserialized with JSON. So we can resolve ListResult response of APIs correctly.

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-08-21 10:15:48 +00:00
Ryan Wang 4ac80f5eb3
Update comment widget plugin to v3.0.0 (#7705) 2025-08-19 15:32:02 +08:00
Ryan Wang 3487132154
Add support for hidden comments (#7679)
* Add 'hidden' field to comment and reply requests

Signed-off-by: Ryan Wang <i@ryanc.cc>

* Add support for filtering comments with hidden

* Specify hidden=false and approved=true for anonymous users

* Set default hidden flag only if null in comments

* Add 'private reply' option to comment modals

* Add private tag for hidden comments and replies

* Allow hiding comments only

* Enhance comment visibility logic to allow owners to view hidden comments

* Remove hidden input for reply form

Signed-off-by: Ryan Wang <i@ryanc.cc>

* Refine i18n

Signed-off-by: Ryan Wang <i@ryanc.cc>

---------

Signed-off-by: Ryan Wang <i@ryanc.cc>
Co-authored-by: John Niang <johnniang@foxmail.com>
2025-08-19 14:47:37 +08:00
Ryan Wang 3345ccb035
Merge pull request #7695 from ruibaby/feat/comment-a-target
Allow target attribute on <a> tags in comment sanitizer
2025-08-17 23:38:00 +08:00
Ryan Wang 2bcfbbc371
Optimize comment notification template to support rich text rendering (#7683)
#### What type of PR is this?

/area core
/area ui
/milestone 2.21.x
/kind feature

#### What this PR does / why we need it:

Optimize comment notification template to support rich text rendering

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-08-13 07:32:50 +00:00
Ryan Wang eddcb5bc38
Allow <s> tag and class attribute on <code> in comments (#7682)
#### What type of PR is this?

/area code
/milestone 2.21.x
/kind improvement

#### What this PR does / why we need it:

Comments are allowed to contain `s` tags and `code` tags with class attributes for the following reasons:

1. `s`: The comment component uses tiptap editor's [strikethrough extension](https://tiptap.dev/docs/editor/extensions/marks/strike#:~:text=while%20you%20type.-,Restrictions,-The%20extension%20will) which enforces the use of `s` tags for strikethrough text and cannot be changed.
2. `code[class]`: Used for code highlighting (class="language-*")

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-08-13 07:14:50 +00:00
John Niang 6f608f12aa
Fix the problem of memory leak caused by thymeleaf (#7678)
#### What type of PR is this?

/kind bug
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR replaces the dependency `thymeleaf-spring6` to apply the memory leak fix of <https://github.com/halo-dev/thymeleaf/pull/1>.

Please note that this is a temporary fix, and we would revert this PR after Thymeleaf official released a new version including my fix.

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/7289

#### Special notes for your reviewer:

1. Execute command ab -c 100 -n 1000 -H 'Accept: text/html' -H 'Cache-Control: no-cache' http://localhost:8090/ and then press Ctrl + C to stop the thread.
2. See logs in Halo

#### Does this PR introduce a user-facing change?

```release-note
修复在特定情况下模板引擎可能出现内存泄漏的问题
```
2025-08-12 10:46:48 +00:00
John Niang 535fe01624
Check if the contents of comment and reply are valid before persistence (#7677)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR checks if the contents of comment and reply are valid before persistence to prevent users from XSS attacks.

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/7675

#### Special notes for your reviewer:

Try to comment or reply with the contents from <https://cheatsheetseries.owasp.org/cheatsheets/XSS_Filter_Evasion_Cheat_Sheet.html>.

#### Does this PR introduce a user-facing change?

```release-note
检测评论和回复内容是否合法以防止 XSS 攻击
```
2025-08-12 04:08:46 +00:00
Ryan Wang 59030f839a
Refactor SEO meta tag processors and update help texts for ui (#7665)
#### What type of PR is this?

/area core
/kind improvement
/milestone 2.21.x

#### What this PR does / why we need it:

This PR optimizes SEO tag generation with the following changes:

1. Site description and keywords settings now only apply to the homepage and are no longer inserted on other pages.
2. Added meta description tags for category archive pages, using the category description as content.
3. Improved the help text descriptions for SEO options in system settings.

#### Which issue(s) this PR fixes:

Fixes #7662 

#### Does this PR introduce a user-facing change?

```release-note
优化页面的 SEO 标签的生成
```
2025-08-08 12:42:41 +00:00
John Niang 576dda9d74
Add social login endpoint for remember-me support (#7670)
#### What type of PR is this?

/kind feature
/kind api-change
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR adds a new endpoint `POST /login/social/{auth_provider_name}?remember-me=true` to make the social login support remember-me mechanism. 

#### Does this PR introduce a user-facing change?

```release-note
支持社交登录时选择是否保持登录
```
2025-08-08 11:06:39 +00:00
Ryan Wang 9607ee4912
chore: bump preset plugins and theme version (#7667)
#### What type of PR is this?

/area core
/milestone 2.21.x

#### What this PR does / why we need it:

Bump all preset plugins and theme version

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-08-06 16:12:38 +00:00
John Niang 3a50fdc4e5
Optimize homepage post loading by eliminating N+1 queries for user data (#7668)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR refactors posts query to reduce database queries significantly.

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/7593

Supersedes https://github.com/halo-dev/halo/pull/7644

#### Does this PR introduce a user-facing change?

```release-note
优化首页、归档页加载速度
```
2025-08-06 16:08:37 +00:00
John Niang 6f6dbb8cc1
Fix the problem that notification might not work anymore (#7643)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR sets timeout on notification trigger to make sure the procedure won't getting stuck forever.

#### Does this PR introduce a user-facing change?

```release-note
修复运行过程中通知器可能失效的问题
```
2025-07-29 06:51:51 +00:00
Ryan Wang 395399f078
feat: add thumbnail records modal (#7630)
#### What type of PR is this?

/area ui
/kind feature
/milestone 2.21.x

#### What this PR does / why we need it:

Add thumbnail records viewing feature. The main goal is to keep track of failed thumbnail generations, making it easier to check if thumbnails were generated correctly and retry if needed.

<img width="1009" height="859" alt="image" src="https://github.com/user-attachments/assets/d968e416-0b88-45bf-a554-a0c1abcf97a0" />
<img width="1014" height="952" alt="image" src="https://github.com/user-attachments/assets/c5d1a11b-7acc-4ab5-a2da-cf9467cb6b70" />

#### Which issue(s) this PR fixes:

Fixes #

#### Special notes for your reviewer:

#### Does this PR introduce a user-facing change?

```release-note
支持查看附件缩略图记录
```
2025-07-22 13:54:18 +00:00
XiaoyuPeng a8b885709b
Fix typo for UnpublishPost api description (#7628)
Co-authored-by: pengxiaoyu <pengxiaoyu@shengqugames.com>
2025-07-15 11:54:58 +08:00
Takagi 6246da9b85
chore: upgrade tiptap to 2.24.1 (#7613)
#### What type of PR is this?

/kind chore
/area editor

#### What this PR does / why we need it:

升级 tiptap 至 2.24.1

#### Does this PR introduce a user-facing change?
```release-note
升级 tiptap 至 2.24.1
```
2025-07-04 05:03:40 +00:00
Ryan Wang a4a418b22e
feat: add support for remote URL attachment downloads (#7602)
#### What type of PR is this?

/area ui
/kind feature
/milestone 2.21.x

#### What this PR does / why we need it:

Add support for remote URL attachment downloads

<img width="1031" alt="image" src="https://github.com/user-attachments/assets/f85eee2f-a40b-49ff-9ced-31136f59e67c" />

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/7017

#### Does this PR introduce a user-facing change?

```release-note
支持通过远程地址下载到附件库
```
2025-07-04 04:37:40 +00:00
Golden Supreme Salted Fish 79226998d3
refactor: exclude post preview page from data tracking (#7582)
What type of PR is this?  
/kind bug  
/area core  
/milestone 2.21.x

What this PR does / why we need it:  
Prevents published post view counts from being incorrectly increased when previewing posts in the admin panel.

Previously, the preview mode would load the tracking script, which resulted in inflated view counts. This PR adds a condition to detect preview mode and disables the tracking logic to avoid counting views for unpublished content.

Does this PR introduce user-facing changes?
```release-note
文章预览页面不再统计访问数据
```
2025-07-04 04:33:41 +00:00
John Niang 7d560186e8
Add support for rewriting URL with trailing slash (#7559) 2025-06-17 11:29:54 +08:00
Ryan Wang 12ed2d5653
chore: bump preset plugins and themes version (#7555)
Signed-off-by: Ryan Wang <i@ryanc.cc>
2025-06-15 12:03:27 +08:00
John Niang 21e115165f
Reduce application size by removing unused JPA dependency (#7549)
#### What type of PR is this?

/kind cleanup
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR removes unused JPA dependency to reduce application size about 14.6% off.

```bash
# Before
❯ ll application/build/libs
total 123M
-rw-r--r--. 1 johnniang johnniang 123M Jun 13 15:37 halo-2.21.0-SNAPSHOT.jar
-rw-r--r--. 1 johnniang johnniang   64 Jun 13 15:37 halo-2.21.0-SNAPSHOT.jar.sha256
```

```bash
# After
❯ ll application/build/libs
total 105M
-rw-r--r--. 1 johnniang johnniang 105M Jun 13 15:36 halo-2.21.0-SNAPSHOT.jar
-rw-r--r--. 1 johnniang johnniang   64 Jun 13 15:36 halo-2.21.0-SNAPSHOT.jar.sha256
```

#### Does this PR introduce a user-facing change?

```release-note
移除无用的依赖,软件包的体积减少近 15%
```
2025-06-13 11:44:43 +00:00
John Niang 4a3d35a900
Remove deprecated migrations (#7535)
#### What type of PR is this?

/kind cleanup
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR removes deprecated Subscritpion and Thumbnail migrations.

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-06-12 16:24:40 +00:00
Ryan Wang bfbca99f1b
refactor: update attachment policy form using new configMap API (#7531)
#### What type of PR is this?

/area ui
/kind improvement
/milestone 2.21.x

#### What this PR does / why we need it:

Update attachment policy form using new configMap API

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-06-10 09:58:35 +00:00
John Niang aeea3a5488
Provide storage policy config APIs to make it easy to use (#7527)
* Provide storage policy config APIs to make it easy to use

* Update api client

Signed-off-by: Ryan Wang <i@ryanc.cc>

---------

Signed-off-by: Ryan Wang <i@ryanc.cc>
Co-authored-by: Ryan Wang <i@ryanc.cc>
2025-06-09 23:24:30 +08:00
John Niang f3023e6ec9
Add a system config changed event 2025-06-04 23:47:41 +08:00
John Niang fb62c1acff
Add support for configuring my preferences (#7495)
* Add support for configuring my preferences

* Update api client

Signed-off-by: Ryan Wang <i@ryanc.cc>

* Update api client

Signed-off-by: Ryan Wang <i@ryanc.cc>

---------

Signed-off-by: Ryan Wang <i@ryanc.cc>
Co-authored-by: Ryan Wang <i@ryanc.cc>
2025-06-04 11:55:03 +08:00
John Niang f80487b1d5
Add support for setting external URL at setup page (#7488)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR allows users to set external URL at setup page without performing a restart.

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/7479

#### Special notes for your reviewer:

1. Try to start Halo instance with a fresh environment.
2. Request index page and you will be redirected to setup page.
3. Check if the external URL is equal to the base URL in your browser.
4. Try to change external URL and finish the setup process.
5. Login to console and check the external URL in overview page.

#### Does this PR introduce a user-facing change?

```release-note
支持在初始化页面设置外部访问地址
```
2025-05-31 10:10:31 +00:00
John Niang d18f37df0a
Bump Lucene to 10.2.1 2025-05-26 22:44:51 +08:00
Ryan Wang c27cbb5204
Merge branch 'main' into chore/remove-deprecated-code 2025-05-26 21:15:25 +08:00
John Niang d706b5eb6c
Add support back for using relative permalink (#7475)
#### What type of PR is this?

/kind bug
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR fixes the problem of not working for relative permalink caused by <https://github.com/halo-dev/halo/pull/7459>.

#### Special notes for your reviewer:

1. Try to start Halo instance with `halo.use-absolute-permalink=false` and check the permalinks of posts and attachments.
1. Try to start Halo instance with `halo.use-absolute-permalink=true` and check the permalinks of posts and attachments.

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-05-26 10:12:18 +00:00
John Niang 301bbfb7c9
Remove deprecated code 2025-05-26 15:38:03 +08:00
John Niang ccdb97743b
Refactor logout handler (#7470)
#### What type of PR is this?

/kind cleanup
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR corrects location of LogoutHandler instead of in LogoutSuccessHandler. LogoutHanadler should be invoked before LogoutSuccessHandler.

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-05-26 03:44:14 +00:00
柳意梧情 5c27a0484b
Add shared events for listening user login and logout in plugins (#7440)
#### What type of PR is this?
/kind improvement

#### What this PR does / why we need it:

This PR adds UserLoginEvent and UserLogoutEvent which are shared to plugins.

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/7436

#### Does this PR introduce a user-facing change?

```release-note
添加用户登录/登出事件
```
2025-05-23 08:54:12 +00:00
John Niang 3df117511c
Remove deprecation warnings from Gradle (#7468) 2025-05-23 16:08:38 +08:00
John Niang fb2fc31cdd
Bump Spring Boot to 3.5.0 (#7467)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR bumps Spring Boot to [3.5.0](https://github.com/spring-projects/spring-boot/releases/tag/v3.5.0).

#### Does this PR introduce a user-facing change?

```release-note
升级依赖 Spring Boot 至 3.5.0
```
2025-05-23 04:22:12 +00:00
John Niang fb6b6f632d
Add support for configuring external URL online (#7459)
* Add support for configuring external URL online

* Fix the problem of timeout on external URL initialization

* Add external URL editing capability to overview page

Signed-off-by: Ryan Wang <i@ryanc.cc>

---------

Signed-off-by: Ryan Wang <i@ryanc.cc>
Co-authored-by: Ryan Wang <i@ryanc.cc>
2025-05-22 15:23:43 +08:00
John Niang 254bb9b225
Fix the problem of timeout on external URL initialization 2025-05-22 13:38:05 +08:00
John Niang 2d4e3b2c54
Fix the problem of undetermined locale (#7458)
#### What type of PR is this?

/kind bug
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR check if the locale is undetermined during resolving locale. Or it will cause the error below if locale is `und`:

```java
2025-05-21T17:28:45.953+08:00 ERROR 58760 --- [undedElastic-14] o.s.w.s.adapter.HttpWebHandlerAdapter    : [c1824fa5-1] 500 Server Error for HTTP GET "/"

org.thymeleaf.exceptions.TemplateOutputException: An error happened during template rendering
	at org.thymeleaf.engine.OutputTemplateHandler.handleText(OutputTemplateHandler.java:75) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.AbstractTemplateHandler.handleText(AbstractTemplateHandler.java:221) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ProcessorTemplateHandler.handleText(ProcessorTemplateHandler.java:587) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.Text.beHandled(Text.java:97) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.Model.process(Model.java:300) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.GatheringModelProcessable.process(GatheringModelProcessable.java:78) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ProcessorTemplateHandler.queueProcessable(ProcessorTemplateHandler.java:2106) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ProcessorTemplateHandler.handleCloseElement(ProcessorTemplateHandler.java:1642) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.CloseElementTag.beHandled(CloseElementTag.java:139) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.Model.process(Model.java:300) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.OpenElementTagModelProcessable.process(OpenElementTagModelProcessable.java:110) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ProcessorTemplateHandler.queueProcessable(ProcessorTemplateHandler.java:2106) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ProcessorTemplateHandler.handleOpenElement(ProcessorTemplateHandler.java:1559) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.OpenElementTag.beHandled(OpenElementTag.java:205) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.TemplateModel.process(TemplateModel.java:155) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ThrottledTemplateProcessor.process(ThrottledTemplateProcessor.java:235) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ThrottledTemplateProcessor.process(ThrottledTemplateProcessor.java:200) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.spring6.SpringWebFluxTemplateEngine$StreamThrottledTemplateProcessor.process(SpringWebFluxTemplateEngine.java:720) ~[thymeleaf-spring6-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.spring6.SpringWebFluxTemplateEngine.lambda$createChunkedStream$2(SpringWebFluxTemplateEngine.java:269) ~[thymeleaf-spring6-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at reactor.core.publisher.FluxGenerate$GenerateSubscription.slowPath(FluxGenerate.java:271) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.FluxGenerate$GenerateSubscription.request(FluxGenerate.java:213) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.FluxPeekFuseable$PeekFuseableSubscriber.request(FluxPeekFuseable.java:144) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.FluxSubscribeOn$SubscribeOnSubscriber.requestUpstream(FluxSubscribeOn.java:131) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.FluxSubscribeOn$SubscribeOnSubscriber.onSubscribe(FluxSubscribeOn.java:124) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.FluxPeekFuseable$PeekFuseableSubscriber.onSubscribe(FluxPeekFuseable.java:178) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.FluxGenerate.subscribe(FluxGenerate.java:85) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.InternalFluxOperator.subscribe(InternalFluxOperator.java:68) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.publisher.FluxSubscribeOn$SubscribeOnSubscriber.run(FluxSubscribeOn.java:194) ~[reactor-core-3.7.5.jar:3.7.5]
	at reactor.core.scheduler.BoundedElasticThreadPerTaskScheduler$SchedulerTask.run(BoundedElasticThreadPerTaskScheduler.java:1013) ~[reactor-core-3.7.5.jar:3.7.5]
	at java.base/java.lang.VirtualThread.run(VirtualThread.java:329) ~[na:na]
Caused by: org.thymeleaf.exceptions.TemplateProcessingException: Locale "" cannot be used as it does not specify a language. (template: "modules/layout" - line 12, col 49)
	at org.thymeleaf.messageresolver.StandardMessageResolutionUtils.computeMessageResourceNamesFromBase(StandardMessageResolutionUtils.java:202) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.messageresolver.StandardMessageResolutionUtils.resolveMessagesForTemplate(StandardMessageResolutionUtils.java:69) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.messageresolver.StandardMessageResolver.resolveMessagesForTemplate(StandardMessageResolver.java:380) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.messageresolver.StandardMessageResolver.resolveMessage(StandardMessageResolver.java:282) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.messageresolver.StandardMessageResolver.resolveMessage(StandardMessageResolver.java:227) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.context.AbstractEngineContext.getMessage(AbstractEngineContext.java:134) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.standard.expression.MessageExpression.executeMessageExpression(MessageExpression.java:265) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.standard.expression.SimpleExpression.executeSimple(SimpleExpression.java:69) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.standard.expression.Expression.execute(Expression.java:109) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.standard.expression.Expression.execute(Expression.java:138) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.standard.processor.StandardUtextTagProcessor.doProcess(StandardUtextTagProcessor.java:87) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.processor.element.AbstractAttributeTagProcessor.doProcess(AbstractAttributeTagProcessor.java:74) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.processor.element.AbstractElementTagProcessor.process(AbstractElementTagProcessor.java:95) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.util.ProcessorConfigurationUtils$ElementTagProcessorWrapper.process(ProcessorConfigurationUtils.java:633) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.ProcessorTemplateHandler.handleOpenElement(ProcessorTemplateHandler.java:1314) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.OpenElementTag.beHandled(OpenElementTag.java:205) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.TemplateModel.process(TemplateModel.java:136) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.TemplateManager.process(TemplateManager.java:519) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.util.LazyProcessingCharSequence.writeUnresolved(LazyProcessingCharSequence.java:85) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.util.AbstractLazyCharSequence.write(AbstractLazyCharSequence.java:103) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.AbstractTextualTemplateEvent.writeContent(AbstractTextualTemplateEvent.java:224) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.Text.write(Text.java:78) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	at org.thymeleaf.engine.OutputTemplateHandler.handleText(OutputTemplateHandler.java:71) ~[thymeleaf-3.1.3.RELEASE.jar:3.1.3.RELEASE]
	... 29 common frames omitted
```

#### Does this PR introduce a user-facing change?

```release-note
修复因 Locale 解析错误导致无法访问页面的问题
```
2025-05-22 03:14:00 +00:00
John Niang 79a4386c82
Make uploads resources protected (#7456)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR removes `/uploads/**` from static resources to make it protected by Halo security.

#### Does this PR introduce a user-facing change?

```release-note
None
```
2025-05-22 03:03:59 +00:00
John Niang e9011eb3ec
Add support for configuring external URL online 2025-05-22 00:00:55 +08:00
John Niang c73f0ddeee
Upgrade JSONAssert to 2.0-rc1 2025-05-21 10:37:04 +08:00
Ryan Wang d382b45236
Merge branch 'main' into refactor/libs-versions 2025-05-20 10:07:25 +08:00
John Niang 0c4be85467
Set Java 21 as minimal version (#7451)
#### What type of PR is this?

/kind improvement
/area core
/milestone 2.21.x

#### What this PR does / why we need it:

This PR sets Java 21 as minimal version. After doing that, Halo can only run on Java 21 or newer version.

Fortunately, all plugins and themes won't be affected by the restriction.

> https://docs.gradle.org/current/userguide/toolchains.html#sec:release-flag-toolchain

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/6867

#### Does this PR introduce a user-facing change?

```release-note
[Action Required] 更新最低运行环境为 Java 21
```
2025-05-20 02:05:25 +00:00
John Niang 1520188aac
Merge pull request #7441 from liuyiwuqing/added-search-for-users-by-email
Add support for querying users by email
2025-05-20 00:24:17 +08:00
John Niang d64f01d0d5
Fix unit test due to dependency update 2025-05-19 18:04:02 +08:00
John Niang 0dd1e13e82
Fix the problem of not resolving git properties
See https://github.com/n0mer/gradle-git-properties/issues/242 for more
2025-05-19 17:42:40 +08:00
John Niang e6f753bb5d
Refactor dependencies and plugins with version catelog 2025-05-19 16:05:56 +08:00