Embed Width Adjuster

unlisted

by Silso

Adds data-width attributes to embeds based on aliases (e.g. [[note|wide]]) in Live Preview.

ā˜… 1 starsUpdated 2mo agoMIT
View on GitHub

Embed Width Adjuster

Control embedded note widths using aliases in Live Preview.

[!WARNING] This plugin is provided as-is for personal use. The repository is public for anyone who wants to fork and adapt it. Please do not open issues for support or feature requests.

Features

šŸ“ Width aliases — Use |wide, |max, or |full to control embed width

✨ Live Preview support — Works in the editor, not just Reading view

šŸŽØ CSS-driven — Bring your own styles via CSS snippets

[!NOTE] This plugin is inspired by Kepano's Minimal theme image width feature. It extracts that concept for use with any theme.

Usage

Add an alias to your embed:

![[My Note|wide]]
![[Dashboard|max]]
![[Full Width Content|full]]

The plugin adds a data-width attribute to the embed element:

<div class="internal-embed" data-width="wide">...</div>

Required CSS

This plugin only adds the attribute — you need CSS to define what each width means. Example snippet:

/* Wide: break out of content width slightly */
.internal-embed[data-width="wide"] {
  max-width: 100%;
  width: 100%;
}

/* Max: full container width */
.internal-embed[data-width="max"] {
  max-width: none;
  width: calc(100% + 2rem);
  margin-left: -1rem;
}

/* Full: viewport width */
.internal-embed[data-width="full"] {
  max-width: none;
  width: 100vw;
  margin-left: calc(50% - 50vw);
}
AliasSuggested Use
wideSlightly wider than content column
maxFull container/pane width
fullFull viewport width

Installation

Manual

  1. Download main.js and manifest.json from the Releases page
  2. Create .obsidian/plugins/embed-width-adjuster/ in your vault
  3. Place the files in that folder
  4. Enable the plugin in Settings → Community plugins

BRAT

  1. Install Obsidian42 - BRAT
  2. Run BRAT: Add a beta plugin for testing
  3. Enter this repository URL

Credits

Width alias concept inspired by Minimal Theme by @kepano.

Images

SCR-20260128-ntha SCR-20260128-ntmu

License

MIT

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.