Repository navigation
Misc small stuff - #31
Merged
Merged
Conversation
Contributor
📦 Version Preview
|
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.
Summary
This branch improves ESLint hygiene, documents automation scope for contributors, and extracts testable pure helpers from several Foundry chat entry-point modules with Vitest coverage. Chat UX and runtime behavior are intended to stay the same; changes are refactor + tests + docs/config.
ESLint (
eslint.config.js)scripts/as intentionally out of scope for the ESLint gate (maintainer policy: no CI lint onscripts/).linterOptions.reportUnusedDisableDirectives: "warn"to surface stale disable comments.globalswithActiveEffectandTokenDocument(readonly).vitest.config.mjs(aligned withpackage.jsonlint).Published docs (
docs-site/)development.md: Clarifymake lint/npm run lintscope; document thatscripts/is not in Vitest or ESLint and is validated manually where the compendium guide describes script workflows.future-plans.md: Align the linting bullet with the same policy and optional follow-ups (stricter rules / globals / CI split), without implyingscripts/will be added to the gate.Pure helpers + chat wiring (
module/logic/)spell-save-from-chat-helpers.mjsgetSpellCastDataFromMessagefromflags.thirdera.spellCastspell-save-from-chat.mjsconcentration-from-chat-helpers.mjsparseConcentrationOtherInputsfor “Concentration (other)” damage vs custom DC (usesdamageWhileCastingDc)concentration-from-chat.mjs(reads dialog fields, builds localizedlabel)spell-sr-from-chat-helpers.mjsgetSpellPenetrationCastFlagsfromspellCast(SR key + caster level + targets)spell-sr-from-chat.mjs(speaker + permission checks)apply-damage-healing-chat-helpers.mjsgetApplyDataFromRollFields(isRoll,rolls,flavor— healing keyword, multi-roll sum, attack+damage last roll)apply-damage-healing-entry-points.mjsTests (
test/unit/logic/)spell-save-from-chat-helpers.test.mjsconcentration-from-chat-helpers.test.mjsspell-sr-from-chat-helpers.test.mjsapply-damage-healing-chat-helpers.test.mjsContributor matrix (
test/README.md)*-from-chat.mjsentry files remain Foundry/UI scope while the matching*-helpers.mjs(and apply chat helper) are covered in Node.Migration / data
None. No changes to persisted actor/item/world shapes or compendium JSON; message flag shapes used by the helpers are unchanged.