Is there a way to make tabs pinned by default?

Is there a way to default new pages to “pinned”? It’s hindering me to manually pin tabs every time I create a new page.

I’ve tried searching the manual section covering pinned pages, but it doesn’t address this possibility, so far as I can see.

For now, I’ve set a hotkey combo to toggle the pinned state, then mapped it to Stream Deck. I can punch a button in Steam Deck after creating a new page (if I remember to). That’s at least faster than remembering the hotkey combo, though still a distracting step.

1 Like

I can guess why, but can you include an explanation of what’s happening that makes you wish you could do this?

Is it because when using the File Explorer, Quick Switcher, or clicking links, etc. you always want a new tab to open by default? Or are you accidentally hitting the close button? Or something else?

Knowing why would help with suggesting workarounds. Also I’m curious, because I think I might like this too.

  • You can hold Cmd or Ctrl when clicking links or files to open in new tab.
  • There is a plugin “Open in New Tab”, but it sounds limited in what it does.
  • You can use CSS to make the X in the tabs unclickable or invisible, so you can’t accidentally close a note with the mouse. I do this for my pinned notes.

(There might be more. That’s all I can think of. And I don’t know any way to make pinned by default.)

1 Like

I appreciate your taking the time to understand my thought process and to offer possible solutions/workarounds.

Context: I’ve configured Obsidian for novel writing. If I am working on a scene (one scene per file), and I have forgotten to pin it, the scene will disappear in favor of a new page that was clicked from the file explorer or, more commonly, from a link in the scene (I use links in a scene to the scene’s characters, objects, locations, etc. so that I can quickly refer to them).

When lost in my imagination, it’s too easy to lose the thread of thought if my attention is drawn to Obsidian rather than what I’m writing. I think of it as “friction.” I aim to eliminate as much friction in Obsidian as possible so that the creativity continues flowing.

Right now, I find myself pinning every page that I open, since otherwise I risk inadvertently losing it to another page. While I do have a Stream Deck button for toggling the pin state, I have to remember to use it. When deep into writing, I often forget to do that. So that’s friction that I’d like to eliminate (hence, my original posting).

I appreciate the suggestion of Ctrl-clicking a link, which I have been aware of. I’m used to doing this with other apps (particularly web browsers) and it’s second nature. Even so, remembering to do that while writing a scene shifts my focus to the keyboard shortcut and away from the story playing in my head. Again, friction.

I’m now trying your suggestion of the “Open in New Tab” plugin and it looks like it could solve this for me, though the description suggests it’s more of a hack than a permanent solution.

Again, thank you for your suggestions.

1 Like

Yeah I hear you. Having things fixed and concrete in space really helps me. So I don’t like apps that reorder or shuffle things around on you, or where it isn’t easy to intuit if a process has navigated away from something I had open. Even the release notes popping up can break flow.

I honestly still use Scrivener for a lot of writing and journalling, since the binder has such a fixed view. I can keep a mental model. I only use Obsidian for topical research (organized by tags) and project management (organized by Kanban and url links from another project management app, Linear).

A thing I also miss from Roam was the sidebar where you could queue up a bunch of files or blocks, as a sort of thinking stack. And it was separate from the main editor, so it was additive/inbox, not disruptive.

1 Like

Good point. I hadn’t thought about the “reorder or shuffle things” versus the “fixed view” aspect. I do agree that Scrivener is quite fixed in its binder approach. Win to Scrivener on that; though, except for the issue with pinning, I haven’t felt that it shifts around. Seems pretty fixed and always remembers where I left off.

I find that Scrivener, which I pair with Aeon Timeline for plotting and tracking the myriad aspects of the story, is incredibly powerful, particularly since Aeon Timeline syncs with Scrivener. The only thing is, I don’t like having to maintain two apps, one for writing and the other for plotting/tracking. Three apps, actually, as I recently added Obsidian for story notes (characters, objects, places).

When I added Obsidian, I found it was so powerful that I wondered if I could use it for writing as well as story notes and tracking–in other words, use one app instead of three. It turns out it is perfect for that, like Scrivener and Aeon Timeline had a baby, haha. The only thing that I miss is the “subway” graph for story elements that Aeon Timeline provides, as I haven’t been able to figure out a way to recreate that in Obsidian (I’ve tried the graphing plugins). But it turns out that I didn’t need that–I can create Dataview pages to my heart’s content, which provides much more information at my fingertips than any chart.

So, rather than three apps, I now do it all in Obsidian. Now, if I can only get the powers that be to let us optionally default files to pinned, it would be the perfect frictionless writing app. :slight_smile:

How do you create the new pages? Which exact steps are you doing? I’m not sure how, but given you’re using some command or template it might be possible to extend/replace that way to also add a pin option to the tag after opening the page.

One idea could be creating a QuickAdd macro to chain the “create new note” and “pin active tab” commands. Other options also exists using more javascript centric solutions.

1 Like

Most often I right-click in the folder and select “new note.” That places the file within the folder and saves me the step of dragging the note into the proper folder. Less commonly I’ll use a hotkey to trigger the command for a new note, again mapped to Stream Deck.

I hadn’t thought of creating a macro to create a new page and set it to a pinned state. A macro could enable me to create new notes that default to a pinned state. I’ll look into that–thanks for the suggestion.

I haven’t tried the Templater plugin because I haven’t needed it. I checked the GitHub documentation for it and do not see any way to use it to set the pinned state. Do you know if it can be used for that?

The real hurdle is not in creating new notes, though. How do I open existing notes that default to the pinned state? The only way I’ve been able to do that, sort of, is with the “Open in New Tab” that was helpfully suggested by @rigmarole. After playing with it I’ve decided not to use it because it bypasses the “pinned/unpinned” selector and therefore ties my hands in case I want to unpin something–even though I want notes to open in the pinned state by default, I do sometimes just need an unpinned note. Hope this makes sense.

It’s not a command of Templater, but you could use it to trigger the command of linking a note if it was used when creating notes.

How to do it when opening notes I’m not that sure how to intercept. One could possibly add something to the open event, but not sure how easy that would be. It would however require to unpin those few which want supposed to be pinned.

1 Like

I’ve just posted this as a feature request. Thanks for the helpful discussion. :slight_smile:

Just to clarify, when I wrote “every time I create a new page,” I should have written “every time I create or open an existing note.” I think I clarified this part-way in the discussion, but I didn’t phrase it correctly at the start of this thread so I wanted to make sure I fixed that.

perhaps not exactly what you are looking for but if you paste this at the top of the note:

`$= let x=app.workspace.activeLeaf.setPinned(1); “”`

that page will be pinned. can’t remember but think you need dataview installed to make this work

1 Like

@triedmanyapps , You do need dataview to trigger that query, and the note needs to be in either live preview or reading mode . Furthermore, each time you turn into either of those mode it’ll pin the note again, making it hard to unpin it if needs be (it can be done by staying in source mode)

1 Like

@triedmanyapps and @holroy, thanks for the idea. I almost always keep notes in editing mode while writing, revising, and editing a novel. If it needs to be in live preview or reading mode, it wouldn’t work for me.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.