mirror of
https://github.com/noheartpen/obsidian-monokakido-copilot-plugin.git
synced 2026-07-22 05:48:11 +00:00
* docs(agent-skill):Add comprehensive guidelines for Obsidian plugin development - Introduced file operations documentation covering view access, editor vs vault API, atomic file operations, file management, and path handling. - Added memory management best practices, including event registration and cleanup strategies. - Established submission requirements for plugins, detailing repository structure, naming conventions, and the submission process. - Implemented type safety guidelines to enhance code reliability and prevent unsafe type casts. - Defined UI/UX standards to ensure consistent user experience across plugins, including command naming conventions and settings configuration. - Created CLAUDE.md for build and development instructions specific to the Monokakido plugin. - Added copilot-instructions.md for strict workspace instructions when editing or generating repository files. - Introduced skills-lock.json to manage skills related to the Obsidian plugin. * feat: enhance search functionality with dialog mode and raw word extraction * docs(spec): add design specifications for Dialog Mode in Japanese, English, and Chinese * feat: automatically open the default dictionary URL when a candidate word is clicked * fix: save and restore editor cursor position in dialog mode * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * fix: onChange callback parameter The dropdown .onChange callback parameter is annotated as 'quick' | 'dialog', but Obsidian's dropdown onChange signature provides a string. This narrower parameter type is not assignable and will fail type-checking under typical TS settings. Remove the explicit annotation and cast inside the handler. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * fix: onClose() does not clear the pending cursorAnalysisTimer onClose() does not clear the pending cursorAnalysisTimer. If the dialog is closed while a debounce is scheduled, the timer may fire after close and update detached DOM, causing errors and unnecessary work. Clear the timer in onClose (and prefer globalThis.setTimeout for consistency with other timer usage). Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * docs: update JSDoc Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * fix: status bar click handler calls it without awaiting/voiding/handling rejection saveSettings() returns a Promise, but the status bar click handler calls it without awaiting/voiding/handling rejection. This can lead to unhandled promise rejections if saveData fails. Explicitly void the promise (and ideally catch/log) to make the intent clear and avoid lint/type-aware warnings. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * fix: editorCallback is async but does not await the async searchWordAtCursor() call. This editorCallback is async but does not await the async searchWordAtCursor() call. Awaiting makes errors propagate correctly (or at least ensures the promise is handled) and avoids floating-promise lint warnings. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * fix: setTimeout callback is marked async The setTimeout callback is marked async, so it returns a Promise into a void-typed timer callback. This often triggers type-aware lint rules (no-misused-promises) and makes errors harder to surface. Wrap the async work in a void IIFE inside a non-async timer callback. Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Replace manual h3/p elements with Setting().setHeading() in settings tab * fix: pass app: App into writeToHistory, remove (window as any).app cast * fix: ensure editorCallback awaits searchWordAtCursor in command registration --------- Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
1.1 KiB
1.1 KiB
| description | applyTo |
|---|---|
| Strict workspace instruction for the Obsidian Monokakido Copilot plugin. Use when editing or generating repository files. | **/* |
Use the existing repository conventions and keep changes limited to the requested scope.
- Preserve the current TypeScript plugin structure in
src/, includingobsidianimports, plugin lifecycle methods, settings handling, and command registration. - Keep formatting and comments consistent with the repository style. Existing source files use TypeScript with descriptive JSDoc-style comments and mixed Chinese/Japanese annotations.
- Prefer minimal, targeted changes rather than broad refactors. Do not modify unrelated files or workflows.
- Maintain valid Obsidian plugin schema in
manifest.jsonand keep build-related files such aspackage.json,tsconfig.json, andesbuild.config.mjscompatible with the current build process. - When editing Markdown documentation in
README.mdordocs/, use concise explanations and preserve the existing bilingual approach where appropriate. - Avoid introducing new dependencies or major architectural changes unless explicitly requested.