-
-
Notifications
You must be signed in to change notification settings - Fork 363
doc(Select): update ShowSwal sample code #6248
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Reviewer's GuideThis PR refactors the Select demo to leverage the ShowSwal confirmation feature by replacing the OnBeforeSelectedItemChange handler, enriches the demo with an ignored descriptive section, and adds new localization entries for SwalTitle, SwalContent, and SwalFooter in both en-US and zh-CN locales. Class diagram for Select component demo updateclassDiagram
class Select {
+TValue
+Items
+ShowSwal: bool
+SwalTitle: string
+SwalContent: string
+SwalFooter: string
}
%% OnBeforeSelectedItemChange handler removed from usage in demo
class DemoBlock {
+Title
+Introduction
+Name
}
File-Level Changes
Assessment against linked issues
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6248 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 704 704
Lines 31130 31130
Branches 4402 4402
=========================================
Hits 31130 31130
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @ArgoZhang - I've reviewed your changes and they look great!
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location> `src/BootstrapBlazor.Server/Components/Samples/Selects.razor:369` </location>
<code_context>
Name="ConfirmSelect">
+ <section ignore>
+ <ul class="ul-demo">
+ <li>@((MarkupString)Localizer["SelectConfifrmSelectDesc1"].Value)</li>
+ <li>@((MarkupString)Localizer["SelectConfifrmSelectDesc2"].Value)</li>
+ </ul>
+ </section>
</code_context>
<issue_to_address>
Typo in localization key names
"Confirm" is misspelled as "Confifrm" in the localization keys. Please update to match the correct spelling and the JSON resource entries.
</issue_to_address>
<suggested_fix>
<<<<<<< SEARCH
<li>@((MarkupString)Localizer["SelectConfifrmSelectDesc1"].Value)</li>
<li>@((MarkupString)Localizer["SelectConfifrmSelectDesc2"].Value)</li>
=======
<li>@((MarkupString)Localizer["SelectConfirmSelectDesc1"].Value)</li>
<li>@((MarkupString)Localizer["SelectConfirmSelectDesc2"].Value)</li>
>>>>>>> REPLACE
</suggested_fix>Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
| <li>@((MarkupString)Localizer["SelectConfifrmSelectDesc1"].Value)</li> | ||
| <li>@((MarkupString)Localizer["SelectConfifrmSelectDesc2"].Value)</li> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
issue (typo): Typo in localization key names
"Confirm" is misspelled as "Confifrm" in the localization keys. Please update to match the correct spelling and the JSON resource entries.
| <li>@((MarkupString)Localizer["SelectConfifrmSelectDesc1"].Value)</li> | |
| <li>@((MarkupString)Localizer["SelectConfifrmSelectDesc2"].Value)</li> | |
| <li>@((MarkupString)Localizer["SelectConfirmSelectDesc1"].Value)</li> | |
| <li>@((MarkupString)Localizer["SelectConfirmSelectDesc2"].Value)</li> |
Link issues
fixes #6247
Summary By Copilot
Regression?
Risk
Verification
Packaging changes reviewed?
☑️ Self Check before Merge
Summary by Sourcery
Update the Select component demo to showcase the new ShowSwal option by replacing the OnBeforeSelectedItemChange handler with ShowSwal and adding an explanatory ignore-only section; sync corresponding localization entries in English and Chinese.
Enhancements:
Documentation: