-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Allow GM to Set Default Tabs for Each Actor Type #75
Labels
enhancement
New feature or request
Comments
kgar
added a commit
that referenced
this issue
Nov 24, 2023
* Added default tabs config settings to the config settings collection. * Renamed settings defaultCharacterSheetTab to initialCharacterSheetTab. Same for NPCs and vehicles. Renamed associated localization key. Added UI for selecting default tabs for PCs, NPCs, and Vehicles. Upgraded load and save for Sheet Settings to have room for additional data other than just the raw settings. Adjusted data type of the default tabs settings to be an array of strings. Made some adjustments to the application shell generic styles. * Wired in the default tabs to PCs, NPCs, and vehicles. Added reset to default functionality for the default tabs configs. * Refactored and extracted shared code for mapping default tab selection fields. Shared that code across settings form setup and use default button handling. * Added validation when saving settings. Extracted `getData()` function in the settings form application. Added English localization variables for tab selection validation errors. Removed misc code comments. * Extracted ListboxSetting component and shared in each actor type setting tab. Updated Tab Selection to use the configured default tabs when an actor flag is not present. * Changed the "Use Default" button to "Reset" to distinguish the button's purpose from the "Default Sheet Tabs" verbiage. Extracted Reset logic to the sheet to keep the scripting in the settings components to a minimum.
All done. 👏 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In Tidy Alpha 0.1.10, I added Tab Selection for the individual actor, available to PCs, NPCs, and vehicles.
Unfortunately, for tables that categorically want simpler NPC sheets, for example, the user has to update each actor individually. If there are some universal reasons not to use tabs by default, then the GM should be able to set default tabs for each actor type, so sheets start with the most agreeable arrangement of default tabs to start, and the user can adjust the tabs for the exceptions to the general tab loadout.
This feature will also open the door for other modules' tabs to be configured as default or not default for a given world, saving on some additional effort.
For now, a selection listbox in Player, NPC, and Vehicle settings tabs will allow GMs to establish the default tabs. The data type will be an array of tab ID strings. This array will default to the current Tidy 5e default tabs for the given actor type. Whenever a list of default tabs is being pulled for tab selection, this list will filter through all registered tabs and apply sorting order.
The text was updated successfully, but these errors were encountered: