Frontmatter Metadata Link Classes

approved

by Varvara Zmeeva / zmeeva.io

Adds classes to internal links based on frontmatter metadata.

7 stars270 downloadsUpdated 8mo ago0BSD
View on GitHub

✨ Metadata Link Classes Plugin

Enhance your Obsidian links by automatically adding classes based on frontmatter metadata! Style links dynamically using your custom CSS rules.

✨ Features

  • Automatic class assignment from page frontmatter metadata.
  • Handles boolean, string, and array metadata keys.
  • Target links with CSS like .link-publish-true or .link-tags-todo.

✨ How It Works

Given a note with frontmatter metadata:

draft: false
publish: true
danger: true
tags: ['todo', 'hit']
type: 'lorem-ipsum'

All internal links of this note will receive the following classes:

.link-publish-true
.link-danger-true
.link-tags-todo
.link-tags-hit
.link-type-lorem-ipsum

Simply target these in your custom CSS snippets.

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.

Frontmatter Metadata Link Classes | SimilarPlugins