Repository navigation
fix: clear Obsidian review action errors in library code - #1
Merged
Merged
Conversation
Task Genius bundles this library into its Obsidian plugin, and the Obsidian review action (obsidianmd/obsidian-workflows) fails strict runs on these error-level findings. - DateFnsAdapter: replace `type DateFns = any` (and its restricted eslint-disable for no-explicit-any) with a structural DateFnsFunctions interface for the date-fns functions the adapter calls. Nothing is imported, so date-fns stays an optional peer; date-fns 2.30, 3.6 and 4.1 modules all satisfy it. - MonthRenderer: describe the two no-unused-vars disables. - DragController: toggle body.tg-is-dragging instead of writing body.style.cursor; hide the drag proxy with setStyles, matching the visibility: visible that onMove sets. - Month/Time renderers: mark clickable popover items with .tg-is-clickable instead of style.cursor = "pointer". - TimeRenderer: apply the slot-based column height through .tg-day-column.tg-has-slot-height instead of an inline height.
This was referenced Nov 28, 2026
Merged
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.
Why
Task Genius bundles this library into its Obsidian plugin. The plugin's CI runs the Obsidian review action (
obsidianmd/obsidian-workflows), which lints the checked-out submodule as well. In strict mode, error-level findings fail the job. Library code had 10 of them (taskgenius/taskgenius-plugin#667).Changes
DateFnsAdapter: replacestype DateFns = anyand its restrictedeslint-disableforno-explicit-anywith an exported structuralDateFnsFunctionsinterface. It lists the ~40 date-fns functions the adapter calls.new DateFnsAdapter(dateFns)against the real date-fns 2.30, 3.6 and 4.1 modules, and it passes for all three.no-unsafe-*warnings from theanyare gone.MonthRenderer: the twono-unused-varsdisables now have-- reasondescriptions.DragController:body.tg-is-dragging(CSScursor: grabbing) instead of writingbody.style.cursor.setStyles, matching thevisibility: "visible"thatonMovesets..tg-is-clickable(CSScursor: pointer) instead ofstyle.cursor = "pointer".TimeRenderer: the slot-based column height goes through.tg-day-column.tg-has-slot-height { height: var(--tg-column-height) }instead of an inlineheight.Verification
tsc --noEmitpasses.vitest run: 20 files / 291 tests pass.vite buildpasses.src/.