You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: code-notes.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -45,7 +45,8 @@ Current architectural reference for the OneClickPrompts Chrome extension (Manife
45
45
-**`modules/selector-auto-detector/selector-guard.js`** ("The Guard"): Adapter that replaces direct `document.querySelector` calls. Tries configured selectors, skips disabled/custom buttons, reports success/failure to the Brain.
46
46
-**`modules/selector-auto-detector/base-heuristics.js`**: Generic heuristics (textarea + any `[contenteditable]`, shadow-root walk; buttons/role=button scoring). Also hosts `OneClickPromptsSiteHeuristics` registry and resolver.
47
47
-**Site heuristics modules**: e.g., `modules/selector-auto-detector/heuristics-deepseek.js` registers DeepSeek-specific editor/button scoring (ignores OCP UI). If present, the Brain picks the site module by `InjectionTargetsOnWebsite.activeSite`; otherwise it falls back to the base heuristics.
48
-
-**Integration**: Site scripts call `SelectorGuard.findEditor()/findSendButton()`; on repeated failures the Brain runs heuristics, shows toasts on success/error, and returns the guessed element to the caller.
48
+
-**Integration**: Site scripts call `SelectorGuard.findEditor()/findSendButton()`; on repeated failures the Brain runs heuristics, shows toasts on success/error, and returns the guessed element to the caller. When both editor and send-button selectors are missing, the Guard now surfaces the editor failure toast first to match dependency order.
49
+
-**Auto-detect toggles**: If heuristics are disabled in the popup toggles, the Brain still shows a "not found; auto-detect off" toast so the user sees which element is missing even without running scans.
0 commit comments