Skip to content

feat: configurable show_person_badges toggle (closes #148)#236

Closed
TheDave94 wants to merge 1 commit into
TheRealSimon42:mainfrom
TheDave94:feat/toggle-person-badges
Closed

feat: configurable show_person_badges toggle (closes #148)#236
TheDave94 wants to merge 1 commit into
TheRealSimon42:mainfrom
TheDave94:feat/toggle-person-badges

Conversation

@TheDave94
Copy link
Copy Markdown

Closes #148.

Problem

Auto-generated person chip badges (via createPersonBadges) appear in the overview header by default. Users running their own person badges through custom_badges (e.g. because they want a different home/away label than the integration's auto-derived one) had no way to suppress the defaults — leading to duplicate person chips next to each other.

Change

Adds:

strategy:
  type: custom:simon42-dashboard
  show_person_badges: false

When false, the auto badges are skipped entirely. custom_badges still flow through, so a user can swap the defaults for their own. Default is true — existing behaviour unchanged.

Editor UI

Adds a checkbox under the Overview section (alongside the existing search-card checkbox). With description text explaining why someone might want to disable.

Test plan

  • npm run build — green
  • Without setting the field: person chips appear as before (no regression)
  • Set show_person_badges: false: person chips disappear from the header
  • custom_badges still render in their place
  • Editor checkbox round-trips correctly

AI-drafted under human supervision by @TheDave94. Tested live on Home Assistant — fully when the relevant hardware is available, otherwise only along the code paths that don't require an actual sensor of that type.

Auto-generated person chip badges (createPersonBadges) appear in the
overview header. Users running custom person badges via custom_badges
had no way to suppress the defaults — leading to duplicate chips.

Adds:
- show_person_badges?: boolean (default true). When false, the auto
  badges are skipped entirely; custom_badges still flow through.
- Editor checkbox in the Overview section + description.
- de + en translations.

Default-on so behaviour is unchanged for existing dashboards.
@codacy-production
Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 0 complexity · 0 duplication

Metric Results
Complexity 0
Duplication 0

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@TheDave94
Copy link
Copy Markdown
Author

Superseded by #276 — bundled with the other overview-presentation PRs because they all touch the badge builder, person handling, and overview section composition. Closing this one in favor of the bundled review.

@TheDave94 TheDave94 closed this May 19, 2026
@TheDave94 TheDave94 deleted the feat/toggle-person-badges branch May 20, 2026 22:44
@TheDave94 TheDave94 restored the feat/toggle-person-badges branch May 21, 2026 09:17
@TheDave94 TheDave94 reopened this May 21, 2026
@TheDave94 TheDave94 closed this May 22, 2026
@TheDave94 TheDave94 deleted the feat/toggle-person-badges branch May 22, 2026 05:55
@TheDave94 TheDave94 restored the feat/toggle-person-badges branch May 23, 2026 20:42
@TheDave94 TheDave94 reopened this May 23, 2026
@TheDave94
Copy link
Copy Markdown
Author

Closing again — this was inadvertently restored alongside #276 which supersedes it. The toggle_person_badges work is covered by the grouped persons-overview-tweaks PR (#276). Apologies for the noise.

@TheDave94 TheDave94 closed this May 23, 2026
TheDave94 added a commit to TheDave94/oriel-dashboard that referenced this pull request May 23, 2026
Bulk branch deletion in TheDave94/oriel-dashboard on 2026-05-19 and
2026-05-22 silently closed 49 cross-fork PRs in
TheRealSimon42/simon42-dashboard-strategy. GitHub auto-closes a PR
when its head branch is deleted, recording the deleting account as
the close actor — looks like deliberate closure to the maintainer
but isn't.

All 49 PRs have since been recovered (Cluster C 17-PR batch
restored on 2026-05-23; TheRealSimon42#250 restored after the rebundling-map
investigation). The next bulk cleanup is the actual risk; this
entry pins the safety check before any future automation lands.

Recovery state at time of writing: 17 grouped/standalone Cluster C
PRs open, TheRealSimon42#236 re-closed (superseded by TheRealSimon42#276 within Cluster C),
TheRealSimon42#250 open as standalone. Remaining ~30 closed-not-merged
originals from May 19 were deliberately rebundled into the
grouped/* PRs and stay closed correctly.

Co-authored-by: AutoCoder <autocoder@claudebox>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Personen Batches deaktivierbar machen

1 participant