logancyang_obsidian-copilot/src/components
Zero Liu a92012dc4d
chore(lint): fix no-direct-set-state-in-use-effect violations (#2454)
* chore(lint): fix no-direct-set-state-in-use-effect violations

Replaced 56 setState-in-useEffect anti-patterns across 21 files with
idiomatic React patterns: derived state via useMemo, useSyncExternalStore
for external stores, key-prop resets, render-phase prev-value trackers,
and lazy useState initializers. Deleted dead defensive syncs in
PlusSettings, ModelEditDialog, and the fallback-notice effect in
CustomCommandChatModal. Narrowly suppressed three legitimate cases
(interval-driven animation, DOM measurement, Lexical pill→context absorb).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* address codex comment

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-14 16:23:55 -07:00
..
chat-components chore(lint): fix no-direct-set-state-in-use-effect violations (#2454) 2026-05-14 16:23:55 -07:00
command-ui chore(lint): fix no-direct-set-state-in-use-effect violations (#2454) 2026-05-14 16:23:55 -07:00
composer chore(lint): fix no-array-index-key and other React lint warnings (#2453) 2026-05-14 02:19:38 -07:00
modals fix(keychain): empty-keychain banner, reset modal copy, lifecycle reset (followup to #2364) (#2455) 2026-05-14 14:30:44 -07:00
project chore(lint): fix no-array-index-key and other React lint warnings (#2453) 2026-05-14 02:19:38 -07:00
quick-ask chore(eslint): enable no-unnecessary-type-assertion and no-misused-promises (#2441) 2026-05-13 21:27:35 -07:00
ui chore(lint): fix no-direct-set-state-in-use-effect violations (#2454) 2026-05-14 16:23:55 -07:00
Chat.tsx chore(lint): fix no-direct-set-state-in-use-effect violations (#2454) 2026-05-14 16:23:55 -07:00
CopilotView.tsx chore(popout): window-global API swaps — timers, globalThis, base64 (W3/9) (#2401) 2026-05-12 22:24:17 -07:00
CustomPromptSyntaxInstruction.tsx Add tw prefix to tailwind (#1497) 2025-05-31 22:30:54 -07:00
IndexingProgressCard.tsx chore(popout): window-global API swaps — timers, globalThis, base64 (W3/9) (#2401) 2026-05-12 22:24:17 -07:00
SystemPromptSyntaxInstruction.tsx fix(ui): improve system prompt template syntax hints (#2235) (#2245) 2026-03-02 21:58:29 -08:00
TruncatedText.tsx Merge 3.1.0 preview (#1906) 2025-10-10 21:38:50 -07:00