Thank you for your submission, an automated scan of your plugin code's revealed the following issues:

### Required

[[1](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L114)][[2](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L132)][[3](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L234)][[4](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L242)][[5](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L256)][[6](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L310)][[7](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L316)][[8](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L328)][[9](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/OpenAIConnectionModal.ts#L331)][[10](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L26)][[11](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L27)][[12](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L28)][[13](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L29)][[14](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L38)][[15](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L39)][[16](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L43)][[17](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L51)][[18](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L72)][[19](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L83)][[20](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L96)][[21](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L105)][[22](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/components/SystemPromptModal.ts#L120)][[23](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L41)][[24](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L50)][[25](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L65)][[26](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L72)][[27](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L78)][[28](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L81)][[29](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L85)][[30](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/settings.ts#L91)] and more :You should avoid assigning styles via JavaScript or in HTML and instead move all these styles into CSS so that they are more easily adaptable by themes and snippets.


[[1](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/main.ts#L112)][[2](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/main.ts#L264)][[3](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/main.ts#L277)][[4](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/main.ts#L407)]:Using `innerHTML`, `outerHTML` or similar API's is a security risk. Instead, use the DOM API or the Obsidian helper functions: <https://docs.obsidian.md/Plugins/User+interface/HTML+elements>

[[1](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/scanner.ts#L41)][[2](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L112)][[3](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L122)][[4](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L214)][[5](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L224)][[6](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L312)][[7](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L322)][[8](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L399)][[9](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L409)][[10](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L493)][[11](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L527)][[12](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L560)][[13](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L592)][[14](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/main.ts#L503)][[15](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/main.ts#L521)]:You should consider limiting the number of `console.log`s in your code, to not pollute the dev console.



---

### Optional

[[1](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L121)][[2](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L223)][[3](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L321)][[4](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/core/organizer.ts#L408)]:Use `app.fileManager.trashFile(file: TAbstractFile)` instead, this will make sure that the file is deleted according to the users preferences.

[[1](https://github.com/shiyuanyou/obsidian-diary-summaries/blob/94f158e5002d614754898216c8bef9695a8baac7/src/main.ts#L387)]:Casting to `any` should be avoided as much as possible.



---



Do <b>NOT</b> open a new PR for re-validation.
Once you have pushed all of the required changes to your repo, the bot will update the labels on this PR within 6 hours.
If you think some of the required changes are incorrect, please comment with `/skip` and the reason why you think the results are incorrect.