Skip to content

Commit 75e4482

Browse files
committed
bd sync: 2026-01-07 02:04:10
1 parent 49ca4cd commit 75e4482

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

.beads/issues.jsonl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{"id":"para_plugin-090","title":"Remove unused TFile import and clarify archiving scope","description":"## Problem\nsrc/main.ts:1 imports TFile but the code intentionally handles TAbstractFile generically now. The import is used in the instanceof check on line 92.\n\nLooking at the code:\n```typescript\nif (!(file instanceof TFolder) \u0026\u0026 !(file instanceof TFile)) {\n return;\n}\n```\n\nThis allows archiving both folders AND files. This appears intentional (method renamed to archiveItem), but need to confirm the check is correct.\n\n## Analysis\nThe check should be: allow TFolder and TFile (which are the concrete types). TAbstractFile is abstract.\nCurrent code is correct - it filters out anything that's not a folder or file.\n\n## Verdict\nThe import IS used on line 92. No change needed for the import.\n\nHowever, the original spec said 'folders only'. If files should NOT be archivable, change line 92 to:\n```typescript\nif (!(file instanceof TFolder)) {\n return;\n}\n```\n\nAnd remove TFile from imports.\n\n## Decision Needed\nThis is a feature scope question. For now, KEEP the current behavior (files archivable) since:\n1. The code was deliberately refactored to use archiveItem\n2. It's a superset of functionality\n3. README will be updated to reflect this\n\nMark this task as 'wont-fix' - behavior is intentional.\n\n## Files\n- src/main.ts (no change needed)","status":"closed","priority":1,"issue_type":"bug","created_at":"2026-01-06T13:50:10.529488-06:00","created_by":"zain","updated_at":"2026-01-06T13:50:19.764141-06:00","closed_at":"2026-01-06T13:50:19.764141-06:00","close_reason":"Intentional behavior - files are archivable by design. README being updated to reflect this."}
22
{"id":"para_plugin-0rr","title":"Use official API instead of unsafe type cast in FolderInputSuggest","description":"In src/settings.ts lines 31-32, FolderInputSuggest.selectSuggestion() uses unsafe casts:\n```typescript\n(this as any).inputEl.value = folder.path;\n(this as any).inputEl.trigger(\"input\");\n```\n\nAbstractInputSuggest has official public methods setValue() and getValue() (since Obsidian 1.4.10).\n\n**Fix:**\nReplace the method body with:\n```typescript\nselectSuggestion(folder: TFolder): void {\n this.setValue(folder.path);\n this.close();\n}\n```","status":"closed","priority":2,"issue_type":"bug","assignee":"zain","created_at":"2026-01-06T17:45:50.391669-06:00","created_by":"zain","updated_at":"2026-01-06T17:53:56.764921-06:00","closed_at":"2026-01-06T17:53:56.764921-06:00","close_reason":"Implemented via sub-agent parallel execution. All tests pass.","comments":[{"id":40,"issue_id":"para_plugin-0rr","author":"zain","text":"Starting work: Examining current implementation of FolderInputSuggest.selectSuggestion()","created_at":"2026-01-06T23:49:16Z"},{"id":41,"issue_id":"para_plugin-0rr","author":"zain","text":"Current implementation uses direct textInputEl access. Will refactor to use official AbstractInputSuggest API methods: setValue() and getValue(). These are the recommended methods since Obsidian 1.4.10.","created_at":"2026-01-06T23:49:22Z"},{"id":42,"issue_id":"para_plugin-0rr","author":"zain","text":"DONE. Files modified: src/settings.ts - Refactored FolderInputSuggest to use official AbstractInputSuggest API methods (setValue()) instead of direct DOM manipulation. Removed unnecessary textInputEl property. All tests pass and typecheck clean.","created_at":"2026-01-06T23:49:40Z"}]}
33
{"id":"para_plugin-0xj","title":"Remove main.js from git and add to .gitignore","description":"Anti-pattern: Generated build artifacts should not be committed to git.\n\n**Current state:**\n- main.js is tracked in git\n- .gitignore has main.js commented out (line 5: '# main.js')\n\n**Fix:**\n1. Uncomment main.js in .gitignore\n2. Remove main.js from git tracking: git rm --cached main.js\n3. Commit the change\n\n**Note:** The release workflow already builds main.js fresh and attaches it to the GitHub release, so this won't affect distribution.","status":"closed","priority":2,"issue_type":"task","created_at":"2026-01-07T01:54:14.391118-06:00","created_by":"zain","updated_at":"2026-01-07T01:55:15.334432-06:00","closed_at":"2026-01-07T01:55:15.334432-06:00","close_reason":"Fixed: Uncommented main.js in .gitignore and removed it from git tracking with git rm --cached. Commit 870dfc0."}
4+
{"id":"para_plugin-14q","title":"Remove console.debug() from production code","description":"Anti-pattern: console.debug() should not be in production code.\n\n**Location:**\n- src/folder-ops.ts:106: `console.debug(\"aPARAtus: Could not focus folder\", error);`\n\n**Options to fix:**\n1. Remove entirely (silent failure is acceptable for this UX enhancement)\n2. Replace with console.warn() if the error is important\n3. Gate behind a dev mode check\n\nSince this is in a try-catch for a best-effort UI enhancement (focusing folder after archive), silent failure (option 1) is recommended.","status":"open","priority":4,"issue_type":"task","created_at":"2026-01-07T02:03:55.755091-06:00","created_by":"zain","updated_at":"2026-01-07T02:03:55.755091-06:00"}
45
{"id":"para_plugin-1ao","title":"Fix project folder sorting not working","description":"**Problem:**\nProject folder sorting settings (Disabled/Last Modified/Date Prefix) had no effect.\n\n**Root Cause:**\nTwo issues found by comparing with obsidian-custom-sort reference implementation:\n\n1. When user changed sort setting, only requestSort() was called but NOT installSortingPatch()\n - If user started with 'disabled' (default) and switched to 'lastModified', the patch was never installed\n - Patch only installed on load, not when setting changed\n\n2. installSortingPatch() was called immediately in onload() before onLayoutReady\n - File explorer may not exist yet during onload\n - Reference implementation waits for onLayoutReady\n\n**Fixes Applied:**\n- settings.ts: Call plugin.installSortingPatch() when projectSortOrder setting changes\n- main.ts: Made installSortingPatch() public (was private)\n- main.ts: Wrap initial installSortingPatch() in onLayoutReady callback\n- main.ts: Add validation that getSortedFolderItems and requestSort methods exist\n- main.ts: Add console.warn messages for debugging\n\n**Files Modified:**\n- src/main.ts\n- src/settings.ts","status":"closed","priority":1,"issue_type":"bug","created_at":"2026-01-07T00:25:41.240085-06:00","created_by":"zain","updated_at":"2026-01-07T00:25:47.769668-06:00","closed_at":"2026-01-07T00:25:47.769668-06:00","close_reason":"Fixed. Changes: (1) settings.ts calls installSortingPatch() when sort order changes, (2) main.ts waits for onLayoutReady before initial patch, (3) Added method existence validation and console warnings. All tests pass, build succeeds."}
56
{"id":"para_plugin-25f","title":"Move inline modal styles to CSS","description":"modals.ts has inline JavaScript styles that should move to styles.css for better theme compatibility:\n\nsrc/modals.ts:\n input.style.width = '100%';\n input.style.marginBottom = '1em';\n\nShould create CSS class like .para-manager-modal-input and apply via addClass().","status":"open","priority":4,"issue_type":"task","created_at":"2026-01-07T01:51:51.593601-06:00","created_by":"zain","updated_at":"2026-01-07T01:51:51.593601-06:00"}
67
{"id":"para_plugin-2f3","title":"Add support for archiving Areas and Resources (full PARA)","description":"## Feature\nExtend the plugin to support archiving from all PARA source folders, not just Projects.\n\n## Current State\n- Only `projectsPath` (default: 'Projects') is supported\n- Context menu and commands only work on items in Projects folder\n\n## Desired State\nSupport three source folders:\n- `projectsPath` (default: 'Projects') - existing\n- `areasPath` (default: 'Areas') - new\n- `resourcesPath` (default: 'Resources') - new\n\nAll three should be archivable to the single `archivePath` (default: 'Archive').\n\n## Changes Required\n\n### 1. Update Settings Interface (`src/settings.ts`)\n\n```typescript\nexport interface ArchiveProjectSettings {\n projectsPath: string;\n areasPath: string; // NEW\n resourcesPath: string; // NEW\n archivePath: string;\n focusAfterArchive: boolean;\n confirmBeforeArchive: boolean;\n}\n\nexport const DEFAULT_SETTINGS: ArchiveProjectSettings = {\n projectsPath: 'Projects',\n areasPath: 'Areas', // NEW\n resourcesPath: 'Resources', // NEW\n archivePath: 'Archive',\n focusAfterArchive: true,\n confirmBeforeArchive: false,\n};\n```\n\n### 2. Add Settings UI (`src/settings.ts`)\n\nAdd two new text inputs for areasPath and resourcesPath, with same validation pattern as existing paths (can't match archivePath or each other).\n\n### 3. Update Context Menu (`src/main.ts`)\n\nChange the file-menu handler to check if item is direct child of ANY source folder:\n\n```typescript\nthis.registerEvent(\n this.app.workspace.on('file-menu', (menu, file) =\u003e {\n if (!(file instanceof TFolder) \u0026\u0026 !(file instanceof TFile)) {\n return;\n }\n\n const sourceFolders = this.getSourceFolders();\n const isTopLevel = sourceFolders.some(src =\u003e \n isTopLevelProjectFolder(file.path, src)\n );\n \n if (!isTopLevel) return;\n\n menu.addItem((item) =\u003e {\n item.setTitle('Archive it').setIcon('archive').onClick(async () =\u003e {\n await this.archiveItem(file);\n });\n });\n })\n);\n```\n\n### 4. Add Helper Method (`src/main.ts`)\n\n```typescript\nprivate getSourceFolders(): string[] {\n return [\n normalizePath(this.settings.projectsPath),\n normalizePath(this.settings.areasPath),\n normalizePath(this.settings.resourcesPath),\n ].filter(Boolean); // Filter out empty strings\n}\n```\n\n### 5. Update Settings Validation\n\nIn `loadSettings()` and settings onChange handlers, validate that:\n- No two source folders are the same\n- No source folder matches archivePath\n\n### 6. Update focusProjectsFolder\n\nConsider renaming to `focusSourceFolder` and making it focus the appropriate source folder based on where the item came from. Or keep simple and always focus projectsPath.\n\n## Dependencies\n- Should implement after para_plugin-rdh and para_plugin-vx8 (commands) since they set up `getSourceFolders()` pattern\n\n## Files\n- src/settings.ts (interface, defaults, UI)\n- src/main.ts (context menu, helper method, validation)","status":"closed","priority":2,"issue_type":"feature","created_at":"2026-01-06T13:41:27.304579-06:00","created_by":"zain","updated_at":"2026-01-06T14:22:54.503402-06:00","closed_at":"2026-01-06T14:22:54.503402-06:00","close_reason":"Full PARA support implemented (Projects, Areas, Resources)","dependencies":[{"issue_id":"para_plugin-2f3","depends_on_id":"para_plugin-rdh","type":"blocks","created_at":"2026-01-06T13:41:34.614756-06:00","created_by":"zain"},{"issue_id":"para_plugin-2f3","depends_on_id":"para_plugin-vx8","type":"blocks","created_at":"2026-01-06T13:41:34.651247-06:00","created_by":"zain"}]}

0 commit comments

Comments
 (0)