feat: add reusable ConfirmDialog component for deletion operations #135
Labels
Clear labels
AI Gen
area:auth
area:backend
area:ci
area:db
area:frontend
area:shared
good first issue
Need Triage
page:admin-users
page:album-detail
page:albums
page:cosplayer-detail
page:cosplayers
page:home
page:jobs
page:login
page:photos
page:register
page:settings
page:stats
page:user
performance
priority:critical
priority:high
priority:low
priority:medium
type:docs
type:refactor
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
Autogenerated By AI
Authentication, JWT, refresh tokens
Lactose API (controllers, repos, services, models)
Docker, CI/CD, Gitea Actions
EF Core, migrations, pgvector
MilkStream WASM client (Blazor UI, SCSS, components)
Butter shared library (DTOs, enums, MIME types)
Good for new contributors
Needs to be categorized by a Human
Admin user management (/Users)
Album detail page (/albums/{id})
Albums list (/albums)
Cosplayer detail page (/cosplayer/{id})
Cosplayers list (/cosplayers)
Home page (/)
Background jobs page (/Jobs)
Login page (/login)
Photos page (/photos)
Register page (/Register)
Settings page (/Settings)
Statistics page (/Stats)
User profile page (/User/{id})
Performance or scalability concern
Blocker / must fix immediately
Must fix / urgent
Nice to have
Should fix
Documentation
Code cleanup or refactoring
Something is not working
This issue or pull request already exists
New feature
Need some help
Something is wrong
More information is needed
This won't be fixed
Milestone
No items
No Milestone
v1.0 - Initial Release
Projects
Clear projects
No projects
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: MilkyShots/MilkyShots#135
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Summary
Introduces a reusable
ConfirmDialogcomponent that wrapsModalFrameand applies it to all deletion operations across the frontend.Closes #57
Changes
New component
MilkStream.Client/Components/Shared/ConfirmDialog.razor— wrapsModalFramewithShow,Title,Message/Body,ConfirmText,ConfirmButtonClass,CancelText,OnConfirm,OnCancelparameters. Supports both plain-text messages and customRenderFragmentbody content.Updated pages (7 files)
AdminUsers.razorwindow.confirm())User.razorwindow.confirm())AlbumDetail.razorCosplayerDetail.razorAlbums.razorCosplayers.razorSettings.razor+FolderBox.razorOnDeleteRequested)Testing needed
/Usersand/User/{id}: verify the ConfirmDialog appears, Cancel closes it, Confirm performs the delete/albums/{id}: verify dialog for "Delete album" and bulk "Delete N" in select mode/cosplayer/{id}: verify dialog for "Delete Cosplayer" and bulk "Delete N" albums/albums: enter select mode, verify dialog before "Delete N"/cosplayers: enter select mode, verify dialog before "Delete N"/Settings→ Folders: verify dialog before folder delete