Skip to content

Improvement: Disable catalog/table search and filter controls when there are no items #2802

Description

@yannickmonney

Problem

Search / filter / sort controls should be disabled when the underlying list has no items at all. Some surfaces already do this; others (notably Automations) leave the controls interactive on an empty set.

Current behaviour

  • DataTable already disables search/filters when data.length === 0 && !hasActiveFilters (searchDisabled in data-table.tsx ~L465–469, applied to DataTableFilters).
  • Integrations catalog mirrors that with a local searchDisabled (integrations.tsx).
  • Automations (automations-grid.tsx): loading disables search; true empty org catalog hides the toolbar; but when the catalog has entries and the Installed tab (or filter) shows zero rows, CatalogToolbar search stays enabled with no disabled flag (~L695–701). Same class of gap likely on other catalog toolbars that don’t pass disabled for empty scopes.
  • Skills/agents hide the toolbar on total empty, but filter/search affordances on empty scoped tabs are inconsistent.

Proposed change

  • Establish one rule: if the unfiltered dataset for the current scope is empty, disable search/filter/sort (keep them enabled only when the empty state is “no matches for current query/filters”).
  • Fix Automations (Installed-empty and peers) to pass disabled: true on CatalogToolbar search (and any filter controls) in that case.
  • Sweep other catalogs / tables that diverge from DataTable’s searchDisabled behaviour.

Acceptance criteria

  • Automations: with zero items in the active scope (e.g. Installed empty), search/filter controls are disabled (or omitted), not interactive.
  • DataTable behaviour remains the reference for settings tables.
  • Sweep: skills, agents, integrations, and other CatalogToolbar users either match or document an intentional exception.
  • When the empty state is “no search results”, controls stay enabled so the user can clear the query.

Affected service

Platform (web app)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions