diff --git a/README.md b/README.md index 0d04e92..068f15e 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ This is especially useful if you have many files with the same dataview block. I - Works with Dataview, Datacore and native Obisidan Bases - Lets you define rules using folderes, tags and properties - Rules can be set to include or exclude subfolders and subtags (recursive matching) -- Lets you select wether the "virtual content" gets added as a footer (end of file) or a header (below properties) +- Lets you select wether the "virtual content" gets added as a footer (end of file), a header (below properties) or in the sidebar - Allows for "virtual content" to be defined in the plugin settings, or in a markdown file - Rules can be enabled or disabled from the plugin settings @@ -107,6 +107,10 @@ if (relatedFiles.length > 0) { ``` ````` +### Displaying dataview in the sidebar +You can also use Virtual Footer to display dataview (or anything else) in the sidebar. This is useful if you want to see the results of a dataview query without having to scroll to the bottom of the file. +Just select the "Sidebar" option in the settings, and use the "Open virtual content in sidebar" command. + ## Limitations Links in the markdown text work natively when in Reading mode, however they don't in Live Preview, so I've added a workaround that gets most functionality back. This means that `left click` works to open the link in the current tab, and `middle mouse` and `ctrl/cmd + left click` works to open the link in a new tab. Right click currently doesn't work. diff --git a/main.ts b/main.ts index b08bc6f..88c33cd 100644 --- a/main.ts +++ b/main.ts @@ -269,13 +269,13 @@ export default class VirtualFooterPlugin extends Plugin { (leaf) => new VirtualContentView(leaf, this) ); - this.addRibbonIcon('layout-align-left', 'Open virtual content sidebar', () => { + this.addRibbonIcon('layout-align-left', 'Open virtual content in sidebar', () => { this.activateView(); }); this.addCommand({ id: 'open-virtual-content-sidebar', - name: 'Open virtual content sidebar', + name: 'Open virtual content in sidebar', callback: () => { this.activateView(); },