Conversation
…thin Cms.Web.Models assembly
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Unresolved authorization flaws allow cross-user content mutation, alongside pagination, UI, and response correctness issues.
Review effort: Lite
Findings: 4
Open (14)
Enforce post ownership during updates · New Enforce ownership when publishing content · New Scope content mutations to the authenticated user · New Verify ownership before deleting content · New Validate pagination bounds before querying · New Return the persisted publish status · New Handle cancelled publish dialogs safely · New Reset publishing state after validation failure · New Handle publish API failures before showing success · New Load posts during page initialization · New Render status control only after loading succeeds · New Correct the Italian blog pagination label · New Correct the blog pagination content label · New Enable coverage for content deletion · New
What changed in this PR
Adds blog post and content management across the CMS domain, API, persistence layer, clients, and Blazor UI.
Changes:
- Adds blog post creation, import, listing, editing, publishing, and deletion.
- Adds content publishing/deletion workflows and Markdown editing.
- Refactors endpoint organization and updates dependencies, migrations, localization, and tests.
| File | Summary |
|---|---|
tests/KITT.Web.Testing/KITT.Web.Testing.csproj |
Updates authentication dependencies. |
tests/KITT.Core.Test/Models/StreamingTests.cs |
Removes obsolete streaming coverage. |
tests/KITT.Core.Test/KITT.Core.Test.csproj |
Updates test dependencies. |
tests/KITT.Core.Test/Fixtures/KittDbContextFixture.cs |
Isolates in-memory databases. |
tests/KITT.Core.Test/Commands/StreamingCommandsTest.cs |
Updates fixtures and constructor tests. |
tests/KITT.Core.Test/Commands/ContentCommandsTest.cs |
Adds content command tests. |
tests/KITT.Core.Test/Commands/BlogPostCommandsTest.cs |
Adds blog post command tests. |
tests/KITT.Cms.Web.Api.Test/SettingsEndpointsTest.cs |
Removes settings endpoint tests. |
tests/KITT.Cms.Web.Api.Test/KITT.Cms.Web.Api.Test.csproj |
Updates API test dependencies. |
src/KITT.Web.Shared/KITT.Web.Shared.csproj |
Updates shared dependencies. |
src/KITT.Web.App/KITT.Web.App/KITT.Web.App.csproj |
Updates web app dependencies. |
src/KITT.Web.App/KITT.Web.App/Endpoints/CmsEndpoints.cs |
Adds CMS proxy routes. |
src/KITT.Web.App/KITT.Web.App.Client/Layout/NavMenu.razor |
Adds blog navigation. |
src/KITT.Web.App/KITT.Web.App.Client/KITT.Web.App.Client.csproj |
Updates client dependencies. |
src/KITT.Web.App.UI/KITT.Web.App.UI.csproj |
Adds Markdown editor support. |
src/KITT.Telegram.Messages/KITT.Telegram.Messages.csproj |
Updates messaging dependencies. |
src/KITT.Support.Seeder/KITT.Support.Seeder.csproj |
Updates seeder dependencies. |
src/KITT.ServiceDefaults/KITT.ServiceDefaults.csproj |
Updates service dependencies. |
src/KITT.Proposals.Web.App/KITT.Proposals.Web.App.csproj |
Updates proposal app dependencies. |
src/KITT.Proposals.Web.Api/KITT.Proposals.Web.Api.csproj |
Updates proposal API dependencies. |
src/KITT.Core/ReadModels/IDatabase.cs |
Exposes blog post queries. |
src/KITT.Core/ReadModels/Extensions/StreamingsExtensions.cs |
Removes duplicate user filtering. |
src/KITT.Core/ReadModels/Extensions/ContentExtensions.cs |
Adds content filtering and sorting. |
src/KITT.Core/ReadModels/Database.cs |
Adds blog post read access. |
src/KITT.Core/Persistence/Mapping/BlogPostMapper.cs |
Maps the blog post table. |
src/KITT.Core/Persistence/KittDbContext.cs |
Registers blog posts. |
src/KITT.Core/Models/BlogPost.cs |
Adds the blog post domain model. |
src/KITT.Core/Migrations/KittDbContextModelSnapshot.cs |
Updates the EF model snapshot. |
src/KITT.Core/Migrations/20260721061538_Add-BlogPosts.Designer.cs |
Adds migration metadata. |
src/KITT.Core/Migrations/20260721061538_Add-BlogPosts.cs |
Creates the blog post table. |
src/KITT.Core/KITT.Core.csproj |
Updates core dependencies. |
src/KITT.Core/DependencyInjection/ServiceCollectionExtensions.cs |
Registers blog and content commands. |
src/KITT.Core/Commands/StreamingCommands.cs |
Refactors constructor injection. |
src/KITT.Core/Commands/SettingsCommands.cs |
Removes obsolete settings commands. |
src/KITT.Core/Commands/ISettingsCommands.cs |
Removes obsolete settings interface. |
src/KITT.Core/Commands/IContentCommands.cs |
Defines content operations. |
src/KITT.Core/Commands/IBlogPostCommands.cs |
Defines blog post operations. |
src/KITT.Core/Commands/ContentCommands.cs |
Implements content operations. |
src/KITT.Core/Commands/BlogPostCommands.cs |
Implements blog post operations. |
src/KITT.Cms.Web.Models/Streamings/StreamingsQueryModel.cs |
Uses shared sort direction. |
src/KITT.Cms.Web.Models/Streamings/StreamingsListModel.cs |
Updates collection initialization. |
src/KITT.Cms.Web.Models/SortDirection.cs |
Adds shared sorting enum. |
src/KITT.Cms.Web.Models/QueryModel.cs |
Adds query model base type. |
src/KITT.Cms.Web.Models/KITT.Cms.Web.Models.csproj |
Adds result handling dependency. |
src/KITT.Cms.Web.Models/ContentStatus.cs |
Adds content status enum. |
src/KITT.Cms.Web.Models/Contents/PublishContentModel.cs |
Adds publish request model. |
src/KITT.Cms.Web.Models/BlogPosts/UpdateBlogPostModel.cs |
Adds update request model. |
src/KITT.Cms.Web.Models/BlogPosts/PublishBlogPostModel.cs |
Adds publish request model. |
src/KITT.Cms.Web.Models/BlogPosts/ImportBlogPostModel.cs |
Adds import request model. |
src/KITT.Cms.Web.Models/BlogPosts/DraftBlogPostModel.cs |
Adds draft request model. |
src/KITT.Cms.Web.Models/BlogPosts/BlogPostsQueryModel.cs |
Adds blog query parameters. |
src/KITT.Cms.Web.Models/BlogPosts/BlogPostListModel.cs |
Adds list response model. |
src/KITT.Cms.Web.Models/BlogPosts/BlogPostDetailModel.cs |
Adds detail response model. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Write.resx |
Adds English write-page resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Write.it.resx |
Adds Italian write-page resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Write.Designer.cs |
Generates write-page resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/PostDetail.resx |
Adds English detail resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/PostDetail.it.resx |
Adds Italian detail resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/PostDetail.Designer.cs |
Generates detail resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Index.resx |
Adds English blog-list resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Index.it.resx |
Adds Italian blog-list resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Index.Designer.cs |
Generates blog-list resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Import.resx |
Adds English import resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Import.it.resx |
Adds Italian import resources. |
src/KITT.Cms.Web.App/Resources/Pages/Blog/Import.Designer.cs |
Generates import resources. |
src/KITT.Cms.Web.App/Resources/Components/PublishContentDialog.resx |
Adds publish-dialog resources. |
src/KITT.Cms.Web.App/Resources/Components/PublishContentDialog.it.resx |
Adds Italian publish resources. |
src/KITT.Cms.Web.App/Resources/Components/PublishContentDialog.Designer.cs |
Generates publish-dialog resources. |
src/KITT.Cms.Web.App/Resources/Components/ContentStatusControl.resx |
Adds status-control resources. |
src/KITT.Cms.Web.App/Resources/Components/ContentStatusControl.it.resx |
Adds Italian status resources. |
src/KITT.Cms.Web.App/Resources/Components/ContentStatusControl.Designer.cs |
Generates status resources. |
src/KITT.Cms.Web.App/Pages/Streamings/StreamingDetail.razor |
Uses Markdown editing. |
src/KITT.Cms.Web.App/Pages/Streamings/Index.razor.cs |
Uses shared sorting. |
src/KITT.Cms.Web.App/Pages/Streamings/Index.razor |
Uses shared sorting in the UI. |
src/KITT.Cms.Web.App/Pages/Blog/Write.razor.cs |
Implements draft creation. |
src/KITT.Cms.Web.App/Pages/Blog/Write.razor |
Adds blog writing UI. |
src/KITT.Cms.Web.App/Pages/Blog/PostDetail.razor.cs |
Implements detail behavior. |
src/KITT.Cms.Web.App/Pages/Blog/PostDetail.razor |
Adds blog detail UI. |
src/KITT.Cms.Web.App/Pages/Blog/Index.razor.cs |
Implements blog listing behavior. |
src/KITT.Cms.Web.App/Pages/Blog/Index.razor |
Adds blog listing UI. |
src/KITT.Cms.Web.App/Pages/Blog/Import.razor.cs |
Implements import behavior. |
src/KITT.Cms.Web.App/Pages/Blog/Import.razor |
Adds blog import UI. |
src/KITT.Cms.Web.App/KITT.Cms.Web.App.csproj |
Registers resources and updates dependencies. |
src/KITT.Cms.Web.App/Components/StreamingForm.razor |
Adds Markdown editing. |
src/KITT.Cms.Web.App/Components/PublishContentDialog.razor.cs |
Implements publishing dialog logic. |
src/KITT.Cms.Web.App/Components/PublishContentDialog.razor |
Adds publishing dialog UI. |
src/KITT.Cms.Web.App/Components/ContentStatusControl.razor.cs |
Implements status actions. |
src/KITT.Cms.Web.App/Components/ContentStatusControl.razor |
Adds publish status UI. |
src/KITT.Cms.Web.App/Clients/IContentClient.cs |
Defines content client operations. |
src/KITT.Cms.Web.App/Clients/IBlogClient.cs |
Defines blog client operations. |
src/KITT.Cms.Web.App/Clients/Http/ContentHttpClient.cs |
Implements content HTTP calls. |
src/KITT.Cms.Web.App/Clients/Http/BlogHttpClient.cs |
Implements blog HTTP calls. |
src/KITT.Cms.Web.App/Clients/ClientsServiceCollectionExtensions.cs |
Registers HTTP clients. |
src/KITT.Cms.Web.App/_Imports.razor |
Adds shared UI imports. |
src/KITT.Cms.Web.Api/Streamings/StreamingsEndpointsServices.cs |
Refactors streaming services. |
src/KITT.Cms.Web.Api/Streamings/StreamingsEndpoints.cs |
Refactors streaming endpoints. |
src/KITT.Cms.Web.Api/Settings/SettingsEndpoints.cs |
Refactors settings endpoints. |
src/KITT.Cms.Web.Api/Settings/ChannelsEndpointsServices.cs |
Refactors channel services. |
src/KITT.Cms.Web.Api/Program.cs |
Registers and maps endpoint groups. |
src/KITT.Cms.Web.Api/Mapping/ModelMappingExtensions.cs |
Adds SEO mappings. |
src/KITT.Cms.Web.Api/KITT.Cms.Web.Api.csproj |
Updates API dependencies. |
src/KITT.Cms.Web.Api/Contents/ContentsEndpointsServices.cs |
Adds content endpoint services. |
src/KITT.Cms.Web.Api/Contents/ContentsEndpoints.cs |
Adds content endpoints. |
src/KITT.Cms.Web.Api/BlogPosts/MappingExtensions.cs |
Adds blog DTO mappings. |
src/KITT.Cms.Web.Api/BlogPosts/BlogPostsEndpointsServices.cs |
Implements blog queries and commands. |
src/KITT.Cms.Web.Api/BlogPosts/BlogPostsEndpoints.cs |
Adds blog post endpoints. |
src/KITT.Cms.Web.Api/BlogPosts/BlogPostQueryParameters.cs |
Adds API query binding. |
src/KITT.Cms.Settings/KITT.Cms.Settings.csproj |
Updates Azure Tables dependency. |
src/KITT.AppHost/KITT.AppHost.csproj |
Updates Aspire and AppHost dependencies. |
Files not reviewed (7)
- src/KITT.Cms.Web.App/Resources/Components/ContentStatusControl.Designer.cs: Generated file
- src/KITT.Cms.Web.App/Resources/Components/PublishContentDialog.Designer.cs: Generated file
- src/KITT.Cms.Web.App/Resources/Pages/Blog/Import.Designer.cs: Generated file
- src/KITT.Cms.Web.App/Resources/Pages/Blog/Index.Designer.cs: Generated file
- src/KITT.Cms.Web.App/Resources/Pages/Blog/PostDetail.Designer.cs: Generated file
- src/KITT.Cms.Web.App/Resources/Pages/Blog/Write.Designer.cs: Generated file
- src/KITT.Core/Migrations/20260721061538_Add-BlogPosts.Designer.cs: Generated file
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



This pull request introduces a set of significant enhancements and refactorings to the API layer of the CMS, focusing on modularizing endpoints, adding new blog post and content management endpoints, and updating dependencies. The most notable changes are the introduction of new endpoints for blog posts and content, improved internal service abstractions, and a general refactor to organize endpoint files by feature area. Additionally, several package dependencies have been updated to their latest versions.
API Endpoint Additions and Refactoring
BlogPostsEndpoints,BlogPostsEndpointsServices,BlogPostQueryParameters, and mapping extensions). [1] [2] [3] [4]ContentsEndpoints,ContentsEndpointsServices). [1] [2]Dependency and Project File Updates
Program Startup and Service Registration
BlogPostsEndpointsServices,ContentsEndpointsServices) and mapped new endpoints in the application startup (Program.cs). [1] [2] [3]Model Mapping Utilities
These changes collectively improve the modularity, maintainability, and capabilities of the CMS API, making it easier to extend and manage content and blog posts programmatically.