Update cookcli-recipe-strategy.js
This commit is contained in:
parent
ee3d7f24aa
commit
fca2315afb
5
dist/cookcli-recipe-strategy.js
vendored
5
dist/cookcli-recipe-strategy.js
vendored
|
|
@ -213,7 +213,8 @@ class CookCliRecipeViewStrategy extends HTMLElement {
|
||||||
|
|
||||||
static _summaryTab(recipe, config, stepCount) {
|
static _summaryTab(recipe, config, stepCount) {
|
||||||
let content = "";
|
let content = "";
|
||||||
if (recipe.image_url) content += `\n\n`;
|
//if (recipe.image_url) content += `\n\n`;
|
||||||
|
if (recipe.image_url) content += `<img src='${recipe.image_url}' alt='image de la recette' style='width: 100%;aspect-ratio: 16 / 10;object-fit: cover;border-radius: 12px;margin-bottom: 8px; '></img>\n\n`;
|
||||||
content += `## ${recipe.title || ""}\n`;
|
content += `## ${recipe.title || ""}\n`;
|
||||||
if (recipe.cookware && recipe.cookware.length) {
|
if (recipe.cookware && recipe.cookware.length) {
|
||||||
content += `\n**Ustensiles** : ${recipe.cookware.map((c) => c.name).join(", ")}\n`;
|
content += `\n**Ustensiles** : ${recipe.cookware.map((c) => c.name).join(", ")}\n`;
|
||||||
|
|
@ -226,7 +227,7 @@ class CookCliRecipeViewStrategy extends HTMLElement {
|
||||||
style: `
|
style: `
|
||||||
img[alt="image de la recette"] {
|
img[alt="image de la recette"] {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
max-height: 250px;
|
aspect-ratio: 16 / 10;
|
||||||
object-fit: cover;
|
object-fit: cover;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
margin-bottom: 8px;
|
margin-bottom: 8px;
|
||||||
|
|
|
||||||
Reference in a new issue