Skip to content

Banner: chevron nav not working and Attention 'Open Settings' shows while Settings is already open #526

@jschick04

Description

@jschick04

Summary

Two related problems with the banner cycle while the Settings modal is open:

  1. The < > chevron buttons in the banner do not appear to advance the displayed banner item.
  2. The Attention banner ("N databases need attention. Open Settings to enable or remove them.") still renders with its Open Settings button while the user is already in Settings.

Repro

  1. Trigger more than one banner item simultaneously (e.g. attention + a background upgrade + an info banner).
  2. Open Settings.
  3. Try the < and > chevrons on the banner that overlays / sits behind the modal.
  4. Note the Open Settings button on the attention banner.

Expected

  • < and > step through the banner cycle as they do outside Settings.
  • The attention banner is suppressed (or its Open Settings action hidden) while the Settings modal is open, since the user is already there.

Actual

  • Chevrons do not visibly switch which banner item is displayed.
  • Open Settings is still shown / wired even though Settings is the foreground modal.

Notes

BannerHost.OnCycleNext / OnCyclePrev mutate _displayedIndex and _selectedItem but do not call StateHasChanged; the re-render relies on RebuildItemsAndPickSelected re-running on the next render and re-pinning to _selectedItem via ItemMatches. Worth verifying that path actually fires while the Settings modal owns focus.

For the attention overlap: BannerService.AttentionEntries / AttentionDismissed doesn't know about modal state. Either the attention slice should be skipped while the Settings modal is open, or OnOpenSettingsClickedAsync should be a no-op (with the button hidden) in that case.

src/EventLogExpert.Components/BannerHost.razor lines 14-33, 98-121.
src/EventLogExpert.Components/BannerHost.razor.cs OnCycleNext, OnCyclePrev, OnOpenSettingsClickedAsync.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions