Merged
Conversation
…eout syntax in world configurator Co-authored-by: Copilot <copilot@github.com>
…and versioning modules Co-authored-by: Copilot <copilot@github.com>
…oad functions Co-authored-by: Copilot <copilot@github.com>
✅ Deploy Preview for afmg ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Contributor
There was a problem hiding this comment.
Pull request overview
A collection of small fixes and cleanups across rendering, UI, and IO flows (including improved tree-shaking in the heightmap renderer, safer exports, and clearer user-facing messages).
Changes:
- Refactor
draw-heightmapto avoidd3namespace access and use an explicit curve map for better tree-shaking. - Improve robustness/UX of IO flows (save/load/export): better error messages, async handling, autosave feedback, URL-load timeout handling.
- Miscellaneous polish: optional chaining cleanup, typo fixes, formatting/readability improvements, and removal of outdated UI text.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/utils/commonUtils.ts | Formatting tweak to the global Window.clipPoly type signature. |
| src/renderers/draw-heightmap.ts | Replace d3 namespace usage with explicit curve imports and a curve lookup map to aid tree-shaking. |
| src/modules/states-generator.ts | Remove an outdated TODO comment. |
| src/modules/provinces-generator.ts | Use dot access (forms.Wild) instead of bracket access for consistency. |
| src/modules/military-generator.ts | Use optional chaining in an overlap check for readability. |
| src/modules/emblem/generator.ts | Improve Biome ignore comments with a real explanation. |
| src/index.html | Remove a paragraph referencing Foundry VTT export/module. |
| public/versioning.js | Fix “Worldbuilding” typo; fix compact version parsing logic by avoiding overwriting before slicing patch. |
| public/modules/ui/world-configurator.js | Fix setTimeout to defer ThreeD.update instead of calling it immediately. |
| public/modules/ui/options.js | Avoid infinite polling for speech voices; add fallback option when none are available. |
| public/modules/ui/heightmap-editor.js | Readability formatting and improved confirmation text for closing Image Converter. |
| public/modules/ui/general.js | Debounce tooltip mousemove handlers to reduce event spam; minor formatting. |
| public/modules/ui/ai-generator.js | Improve error parsing logging and make UI error messaging more resilient. |
| public/modules/io/save.js | Await async save targets, improve error strings, defer object URL revocation, add autosave failure tip, remove unused gzip compress helper. |
| public/modules/io/load.js | Convert URL-loading to async/await, add timeout via AbortController, improve error messaging, fix loading error text. |
| public/modules/io/export.js | Add try/catch and better error reporting for exports; rework PNG/JPEG export to promise-based image load + toBlob; add error handling for tiles zip creation. |
…error message handling Co-authored-by: Copilot <copilot@github.com>
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.
Description