Split character sheet in tabs #55
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?
Add tabs on the right of the character sheet (like bookmarks) that split the contents of the character sheet into ability scores, inventories, traits and spells
Now I have enough understanding. Let me implement the change. First, the script — add the tab definitions:
Now the template — wrap the content in a tabbed layout with a right-side bookmark rail:
Now update the CSS to add the tab rail and adjust the grid rules:
Now let me add the i18n tab labels to all three locales:
Let me validate the JSON and review the final component:
Let me make the bookmark tabs stay pinned while the sheet scrolls, which matches the bookmark behavior:
Now let me add a test following the existing source-reading convention. Let me check the settings-window test for style:
Now let me add a test following the source-reading convention used for windows:
The
addInventoryItemhandler is referenced without parentheses in the template. Let me fix the assertion:All 5 pass. Now let me run the full test suite to confirm nothing else broke:
23 failures — let me check whether these are pre-existing by comparing against the clean baseline:
Baseline has 28 failures (23 pre-existing + 5 from my new test running against the reverted source). With my changes, those 5 pass and no new failures appear. Let me confirm the 23 remaining failures are unrelated to the character sheet:
The 23 remaining failures are all pre-existing and unrelated (map pins, tokens, item-folder-sync — backend modules that need dependencies not installed here). My 5 new tests pass and introduce no regressions.
Let me do a final review of the modified template structure to confirm it's well-formed:
The implementation is complete. Let me review the final diff summary:
Implemented Gitea issue #55 — Split character sheet in tabs.
What changed
frontend/app/components/windows/CharacterSheetWindow.vue— the character sheet no longer stacks every panel on one long page. A vertical bookmark rail on the right edge now splits the contents into four tabs:Design details, following existing conventions:
tabsarray +activeTabref in<script setup>and rendered as arole="tablist"/aria-orientation="vertical"rail ofrole="tab"buttons.v-show(not unmounted), so an in-progress edit on one tab is preserved when switching — matching howlayouts/Tabs.vuebehaves.--color-border,--color-link,--color-background-soft/light,--color-button-hover); the active bookmark gets the accent left-edge + shadow, and the rail isposition: stickyso it stays pinned while the sheet scrolls.frontend/i18n/locales/{en,es,ca}/campaigns.json— addedcharacter-sheet.tabs(abilities,inventory,traits,spells) to all three locales.tests/character-sheet-tabs.test.js— new source-reading test (matching the repo'snode --testpattern used byitem-sheet-window.test.js/settings-window.test.js) verifying the four tabs and their i18n keys, the right-side vertical rail, that each tab shows only its own content, and that every locale names the tabs.Test status
node --test tests/character-sheet-tabs.test.js→ 5/5 pass.Full
node --test tests/→ 138 pass / 23 fail. I confirmed against the clean baseline (viagit stash) that those 23 failures are pre-existing and unrelated (map pins, map tokens, item-folder-sync — they load backend modules whose dependencies aren't installed in this environment); my change fixes the 5 new tests and introduces no new failures.No commits/push made, per instructions.
Implementation is ready for review: #62