Skip to content

feat: add support for default status on new notes#94

Merged
soler1212 merged 1 commit intomasterfrom
feature/default-status
Mar 18, 2026
Merged

feat: add support for default status on new notes#94
soler1212 merged 1 commit intomasterfrom
feature/default-status

Conversation

@soler1212
Copy link
Copy Markdown
Member

Changes Made

  1. Settings Extension: Added a new setting defaultStatusForNewNotes to the PluginSettings interface and initialized it to null.
  2. Settings UI: Added a "Default status for new notes" dropdown in the Behaviour settings section. This dropdown is populated with all currently enabled statuses
    (from both templates and custom statuses).
  3. Note Creation Listener: Integrated a new event listener in main.tsx that monitors the creation of markdown files. When a new note is created:
    • It waits briefly (500ms) to allow Obsidian and other plugins (like Templater) to finish initializing the file.
    • It checks if the note already has a status.
    • If no status is found, it automatically applies the configured default status.
  4. Synchronization: Added the new setting to the "Workflow" synchronization group so it can be synced across devices.
  5. Refactoring & Cleanup: Fixed minor mixed spaces and tabs issues in the settings type definitions that were causing lint errors

- Added 'defaultStatusForNewNotes' setting to PluginSettings.
- Added a dropdown in Behaviour settings to select the default status.
- Implemented a 'create' event listener in main.tsx to automatically apply the default status to new markdown files if they don't have any status.
- Included the new setting in the 'workflow' synchronization group.
- Fixed mixed spaces/tabs in pluginSettings.ts.
@soler1212 soler1212 self-assigned this Mar 18, 2026
@soler1212 soler1212 added this to the v3.1.0 milestone Mar 18, 2026
@soler1212 soler1212 added the enhancement New feature or request label Mar 18, 2026
@soler1212 soler1212 merged commit 75f0619 into master Mar 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[reddit] allow me to set a default status on all newly created notes. I'm going to try with templater atm

1 participant