Skip to content

feat(Table): remove AutoSearchOnInput parameter#7674

Merged
ArgoZhang merged 5 commits intomainfrom
feat-table
Feb 15, 2026
Merged

feat(Table): remove AutoSearchOnInput parameter#7674
ArgoZhang merged 5 commits intomainfrom
feat-table

Conversation

@ArgoZhang
Copy link
Member

@ArgoZhang ArgoZhang commented Feb 15, 2026

Link issues

fixes #7673

Summary By Copilot

Regression?

  • Yes
  • No

Risk

  • High
  • Medium
  • Low

Verification

  • Manual (required)
  • Automated

Packaging changes reviewed?

  • Yes
  • No
  • N/A

☑️ Self Check before Merge

⚠️ Please check all items below before review. ⚠️

  • Doc is updated/provided or not needed
  • Demo is updated/provided or not needed
  • Merge the latest code from the main branch

Summary by Sourcery

New Features:

  • Introduce AutoSearchOnValueChanged parameter to control whether the table triggers a search when the fuzzy search text value changes.

Copilot AI review requested due to automatic review settings February 15, 2026 02:00
@bb-auto bb-auto bot added the enhancement New feature or request label Feb 15, 2026
@bb-auto bb-auto bot added this to the v10.3.0 milestone Feb 15, 2026
@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Feb 15, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adds a new AutoSearchOnValueChanged parameter to the Table component and wires the search box value-changed event to optionally trigger a search when the text changes.

Sequence diagram for auto search on search text value change

sequenceDiagram
    actor User
    participant SearchInput
    participant Table_TItem as Table_TItem
    participant SearchService

    User->>SearchInput: Type_in_search_text
    SearchInput->>Table_TItem: OnSearchTextValueChanged(value)
    activate Table_TItem
    Table_TItem->>Table_TItem: Set_SearchText(value)
    alt AutoSearchOnValueChanged_is_true
        Table_TItem->>Table_TItem: SearchClick()
        activate Table_TItem
        Table_TItem->>SearchService: ExecuteSearch(SearchText)
        SearchService-->>Table_TItem: SearchResults
        deactivate Table_TItem
    else AutoSearchOnValueChanged_is_false
        Table_TItem-->>User: Wait_for_manual_search_trigger
    end
    deactivate Table_TItem
Loading

Class diagram for updated Table component search parameters

classDiagram
    class Table_TItem {
        +bool AutoSearchOnInput
        +bool AutoSearchOnValueChanged
        -string SearchText
        +List~IFilterAction~ GetSearches()
        +Task OnSearchTextValueChanged(string value)
        +Task SearchClick()
    }

    class IFilterAction

    Table_TItem ..> IFilterAction : uses
Loading

File-Level Changes

Change Details Files
Introduce AutoSearchOnValueChanged parameter on Table and use it to trigger search when the search text value changes.
  • Added a new AutoSearchOnValueChanged boolean [Parameter] to the Table component with XML doc comments in both Chinese and English.
  • Implemented a new OnSearchTextValueChanged async handler that updates SearchText and conditionally invokes SearchClick when AutoSearchOnValueChanged is true.
  • Hooked the search-text value change path to use the new handler so that updating the fuzzy search bar can automatically execute a search based on the new parameter.
src/BootstrapBlazor/Components/Table/Table.razor.cs
src/BootstrapBlazor/Components/Table/Table.razor.Search.cs

Assessment against linked issues

Issue Objective Addressed Explanation
#7673 Add a new public parameter AutoSearchOnValueChanged to the Table<TItem> component to control whether a search is automatically triggered when the fuzzy search bar value changes.
#7673 Implement logic so that when the search text value changes, the component updates SearchText and, if AutoSearchOnValueChanged is true, automatically performs the search.

Possibly linked issues


Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've left some high level feedback:

  • The interaction and behavioral difference between AutoSearchOnInput and AutoSearchOnValueChanged is not obvious from the code; consider either consolidating these options or clarifying (e.g., via naming or XML comments) when one should be used over the other to avoid confusion for consumers.
  • In OnSearchTextValueChanged, you might want to short-circuit when value == SearchText to avoid triggering redundant searches for unchanged text values.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The interaction and behavioral difference between `AutoSearchOnInput` and `AutoSearchOnValueChanged` is not obvious from the code; consider either consolidating these options or clarifying (e.g., via naming or XML comments) when one should be used over the other to avoid confusion for consumers.
- In `OnSearchTextValueChanged`, you might want to short-circuit when `value == SearchText` to avoid triggering redundant searches for unchanged text values.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@codecov
Copy link

codecov bot commented Feb 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (b6272ee) to head (6b1faa7).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #7674   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          749       749           
  Lines        33192     33190    -2     
  Branches      4603      4603           
=========================================
- Hits         33192     33190    -2     
Flag Coverage Δ
BB 100.00% <100.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new AutoSearchOnValueChanged parameter to the Table component that enables automatic search triggering when the fuzzy search bar's value changes. This complements the existing AutoSearchOnInput parameter, which triggers search on every keystroke. The new parameter is intended to provide a less aggressive search behavior that triggers only when the value is committed (e.g., on blur).

Changes:

  • Added AutoSearchOnValueChanged boolean parameter to Table component (defaults to false)
  • Implemented OnSearchTextValueChanged callback method that triggers search when the parameter is enabled

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
src/BootstrapBlazor/Components/Table/Table.razor.cs Adds new AutoSearchOnValueChanged parameter with bilingual documentation
src/BootstrapBlazor/Components/Table/Table.razor.Search.cs Implements OnSearchTextValueChanged handler method to trigger search on value change

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ArgoZhang ArgoZhang changed the title feat(Table): add AutoSearchOnValueChanged parameter feat(Table): remove AutoSearchOnInput parameter Feb 15, 2026
@ArgoZhang ArgoZhang merged commit 8f705f4 into main Feb 15, 2026
6 checks passed
@ArgoZhang ArgoZhang deleted the feat-table branch February 15, 2026 03:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(Table): remove AutoSearchOnInput parameter

1 participant