refactor(web): extract timeline drag cleanup

This commit is contained in:
2026-04-01 11:12:20 +02:00
parent 922394c56a
commit b14be80e32
5 changed files with 199 additions and 14 deletions
+15
View File
@@ -270,6 +270,17 @@ export const rules = [
],
forbidden: [],
},
{
file: "apps/web/src/hooks/timelineDragCleanup.ts",
maxLines: 80,
required: [
{
pattern: /\bexport function cleanupTimelineDragState\b/,
message: "timeline drag cleanup helpers must keep unmount teardown centralized",
},
],
forbidden: [],
},
{
file: "apps/web/src/hooks/timelineDocumentDrag.ts",
maxLines: 50,
@@ -342,6 +353,10 @@ export const rules = [
pattern: /from "\.\/timelineAllocationRelease\.js"/,
message: "timeline drag must keep allocation release classification delegated to the extracted helper module",
},
{
pattern: /from "\.\/timelineDragCleanup\.js"/,
message: "timeline drag must keep unmount teardown delegated to the extracted helper module",
},
{
pattern: /from "\.\/timelineDocumentDrag\.js"/,
message: "timeline drag must keep document mouse listener lifecycle delegated to the extracted helper module",