lachholden / obsidian-recipe-view

View your Obsidian notes as interactive recipe cards while you cook.
https://obsidian-recipe-view.readthedocs.io/en/latest/
MIT License
103 stars 4 forks source link

Recipe Card Image Based on Defined Page Property #21

Open aripatrick opened 7 months ago

aripatrick commented 7 months ago

I would like to request an enhancement to the Obsidian Recipe View plug-in allowing users to optionally populate the recipe card image from a defined property (e.g. "poster") instead of taking the first image linked in the page. This enhancement is beneficial for me, because I use a combination of the Minimal theme by kepano and dataview to create a grid view of recipes, similar to the movie database below (tutorial here) which allows me to easily view images and key metadata for all my recipes on one page.

movie-gallery

I would like to be able to use the following syntax in a recipe, and have Obsidian Recipe View's recipe card image based on image link in the "poster" property instead of relying on the first image linked in the page body:

---
poster: "![[carbonara.png]]"
rating: 10
tags:
  - recipes
---

I suspect a setting (defaulted to blank) that allow users to define a property to use for the recipe card, instead of the first image in the recipe body would be the best solution, as it preserves existing behavior for current users, but adds the option for overriding behavior for those who benefit from it. Please let me know if there is any additional info / examples I can add to help make the request clearer. Thanks for this wonderful plug-in! 😄