[priority: 6] Consolidate all tab components into src/components/game/tabs/ #84
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Tab components are scattered across 3 different locations instead of living in the dedicated
tabs/subfolder:src/components/game/tabs/DisciplinesTab.tsxtabs/src/components/game/tabs/ActivityLog.tsxtabs/src/components/game/SpellsTab.tsxgame/rootsrc/components/game/StatsTab.tsxgame/rootThe
tabs/index.tsbarrel file already re-exportsSpellsTabandStatsTabfrom their loose paths (../SpellsTab,../StatsTab), which means it knows they should be intabs/but they haven't been moved yet.What needs to happen
src/components/game/SpellsTab.tsx→src/components/game/tabs/SpellsTab.tsxsrc/components/game/StatsTab.tsx→src/components/game/tabs/StatsTab.tsxsrc/components/game/StatsTab/(subfolder with section components) →src/components/game/tabs/StatsTab/tabs/index.tsbarrel to use relative imports (./SpellsTab,./StatsTab) instead of../SpellsTab,../StatsTabgame/index.tsbarrel — remove the directSpellsTab/StatsTabre-exports sincetabs/index.tsalready covers them (or keep them but point to the new location)from '../SpellsTab'orfrom './SpellsTab')bun run buildor equivalent)Notes
ActivityLog.tsxis already intabs/and is a shared component (used by bothActivityLogPaneland potentially as a tab), so it can stay.StatsTab/subfolder contains:CombatStatsSection.tsx,ElementStatsSection.tsx,LoopStatsSection.tsx,ManaStatsSection.tsx,PactStatusSection.tsx,StudyStatsSection.tsx— these are internal to StatsTab and should move with it.SpellsTab.tsxorStatsTab.tsxoutside of the barrel files.Acceptance Criteria
SpellsTab,StatsTab,DisciplinesTab,ActivityLog) live undersrc/components/game/tabs/StatsTab/section subfolder lives undersrc/components/game/tabs/StatsTab/tabs/index.tsuses relative imports (./SpellsTab,./StatsTab)Starting work on consolidating tab components into src/components/game/tabs/. Will move SpellsTab.tsx, StatsTab.tsx, and StatsTab/ subfolder, then update all imports.
✅ Completed. All tab components consolidated into
src/components/game/tabs/.Changes made:
SpellsTab.tsx→tabs/SpellsTab.tsxStatsTab.tsx→tabs/StatsTab.tsxStatsTab/subfolder (6 section files) →tabs/StatsTab/tabs/index.tsbarrel to use relative imports (./SpellsTab,./StatsTab)game/index.tsbarrel to point to new locations (./tabs/SpellsTab,./tabs/StatsTab)./StatsTab/...) remain correct since the file and subfolder are both undertabs/3dcd967Issue complete. All tab components now live under src/components/game/tabs/. Build passes, pre-commit checks pass.