Skip to content

fix(widgets): give each widget class its own default id - #11116

Merged
chrisgervang merged 1 commit into
masterfrom
chr/widgets-unique-default-ids
Nov 16, 2026
Merged

chrisgervang merged 1 commit into
masterfrom
chr/widgets-unique-default-ids

Conversation

@chrisgervang

@chrisgervang chrisgervang commented Nov 14, 2026 •

Copy link
Copy Markdown
Collaborator

For #11113

Background

PopupWidget defaults to 'info' like InfoWidget, ToggleWidget to 'icon' like IconWidget, and ScrollbarWidget falls back to the base 'widget'. Two of these used together without ids collide in WidgetManager. Default ids aren't documented, and nothing reads them outside widget matching.

Change List

  • PopupWidget: default id 'popup'
  • ToggleWidget: default id 'toggle'
  • ScrollbarWidget: default id 'scrollbar'
  • ScrollbarWidget: let Widget apply defaultProps instead of pre-merging
  • Unit test: every exported widget class has a unique default id

Verified with yarn lint, tsc -b modules/widgets and the headless tests for widgets.


Generated by Claude Code


Note

Low Risk
Low risk updates to default widget ID strings that resolve collisions, backed by a new unit test.

Overview
Assigns distinct default IDs to PopupWidget ('popup'), ToggleWidget ('toggle'), and ScrollbarWidget ('scrollbar') to prevent ID collisions in WidgetManager when used without custom IDs.

Additionally simplifies ScrollbarWidget's constructor by delegating default prop resolution to the base Widget class, and adds a test ensuring all exported widget classes have unique default IDs.

Reviewed by Cursor Bugbot for commit 48c6491. Bugbot is set up for automated code reviews on this repo. Configure here.

`PopupWidget` shared `'info'` with `InfoWidget`, `ToggleWidget` shared
`'icon'` with `IconWidget`, and `ScrollbarWidget` used the base
`'widget'`. Two of these used together without ids collided in
WidgetManager.

- `PopupWidget`: `'popup'`; `ToggleWidget`: `'toggle'`;
  `ScrollbarWidget`: `'scrollbar'`
- `ScrollbarWidget` lets `Widget` apply its default props

For #11113

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LGNhMnSJ94uYgx7ihcVwPn
@greptile-apps

greptile-apps Bot commented Nov 14, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge; no actionable issues were found.

Summary

Gives PopupWidget, ToggleWidget, and ScrollbarWidget distinct default IDs so different widget classes no longer collide.

  • Popup, toggle, and scrollbar widgets now get separate default IDs.
  • ScrollbarWidget now lets Widget fill in its default props.

Reviews (2) · Last reviewed commit: "fix(widgets): give each widget class its..." · Reviewed by Greptile

@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 83.325% (-0.003%) from 83.328% — chr/widgets-unique-default-ids into master

@chrisgervang
chrisgervang added this pull request to the merge queue Nov 16, 2026
Merged via the queue into master with commit 57a7399 Nov 16, 2026
9 checks passed
@chrisgervang
chrisgervang deleted the chr/widgets-unique-default-ids branch November 16, 2026 22:28
chrisgervang added a commit that referenced this pull request Nov 24, 2026
`PopupWidget` shared `'info'` with `InfoWidget`, `ToggleWidget` shared
`'icon'` with `IconWidget`, and `ScrollbarWidget` used the base
`'widget'`. Two of these used together without ids collided in
WidgetManager.

- `PopupWidget`: `'popup'`; `ToggleWidget`: `'toggle'`;
  `ScrollbarWidget`: `'scrollbar'`
- `ScrollbarWidget` lets `Widget` apply its default props

For #11113

Claude-Session: https://claude.ai/code/session_01LGNhMnSJ94uYgx7ihcVwPn

Co-authored-by: Claude <[email protected]>
(cherry picked from commit 57a7399)
@chrisgervang

Copy link
Copy Markdown
Collaborator Author

Released in deck.gl 9.4.2.

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.

4 participants