chore(ui): Rename constants#133
Merged
Merged
Conversation
Owner
tab
commented
May 30, 2026
- Rename TipRotationTicks to UITipRotationTicks
- Rename StatsCallTimeout to UIStatsCallTimeout
- Rename MinPanelHeight to PanelMinHeight
- Rename BorderEdgeWidth to BorderSpacerWidth
- Rename NameWidthShort/Medium/Long to ServiceNameWidthShort/Medium/Long
- Rename DefaultTimelineSlots to TimelineDefaultSlots
- Rename TipRotationTicks to UITipRotationTicks - Rename StatsCallTimeout to UIStatsCallTimeout - Rename MinPanelHeight to PanelMinHeight - Rename BorderEdgeWidth to BorderSpacerWidth - Rename NameWidthShort/Medium/Long to ServiceNameWidthShort/Medium/Long - Rename DefaultTimelineSlots to TimelineDefaultSlots
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #133 +/- ##
==========================================
- Coverage 89.48% 89.45% -0.04%
==========================================
Files 63 63
Lines 5899 5899
==========================================
- Hits 5279 5277 -2
- Misses 488 489 +1
- Partials 132 133 +1
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
Pure rename refactor of UI/component constants in internal/app/ui/components/constants.go, regrouping them by UI domain (Panel, Border, Row, Status, Metric, ServiceName, Timeline, LogStream) and updating all call sites and tests accordingly.
Changes:
- Regroups and renames constants in
constants.goto use domain-prefixed names (e.g.UITipRotationTicks,PanelMinHeight,BorderSpacerWidth,ServiceNameWidth*,TimelineDefaultSlots,LogStreamMaxServiceNameLen). - Updates all consumers in
internal/app/ui/services/*andinternal/app/render/log.goto the new names. - Updates the matching unit tests to reference the new constant names.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| internal/app/ui/components/constants.go | Regroups constants by domain and renames them with domain prefixes. |
| internal/app/ui/components/layout.go | Updates layout/border helpers to use renamed constants. |
| internal/app/ui/components/layout_test.go | Updates tests to use ServiceNameWidth*/ServiceNameTrailingGap. |
| internal/app/ui/services/view.go | Uses UITipRotationTicks, ServiceNameTrailingGap, RowErrorPadding. |
| internal/app/ui/services/view_test.go | Updates test references to renamed constants. |
| internal/app/ui/services/update.go | Uses PanelMinHeight and TimelineDefaultSlots. |
| internal/app/ui/services/update_test.go | Updates test references to TimelineDefaultSlots. |
| internal/app/ui/services/monitor.go | Uses UIStatsCallTimeout. |
| internal/app/render/log.go | Uses LogStreamMaxServiceNameLen. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.