Declutter Aliases - show them only when needed


Aliases are great, but once I started sprinkling Aliases all over the place, my notes started getting bloated with them. Then I realized that I really don’t have to see these Aliases rems all the time. I just need to be able to find when when I search for them. Also current flow already lists all the available aliases for a given reference when we try to link it.

One unavoidable situation in which I need a handle to these Aliases rems is when I have to edit the name of any of these. So the following snippet will hide these Aliases rems unless you zoom in on it’s parent. When you zoom in on its parent the the Aliases become visible. That way, there will be an option to edit them if there is a need. While searching, tagging etc. these aliases show up as usual.

/* Hide aliases unless parent of the alias is zoomed in */
.tree-node-container .tree-node-container .rem[data-rem-tags~="aliases"] {
   display : none;

/* Hide aliases also inside full hover preview of references */
#document-hover-preview__popup .tree-node-container .rem[data-rem-tags~="aliases"] {
display: none;

If you zoom in like this, these Aliases become visible like this



This is really good, @liberated_potato, thanks for sharing. I just implemented it and seems to work perfectly. Cheers!

1 Like