medication
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
---
|
---
|
||||||
const { frontmatter, streakCount = 1 } = Astro.props;
|
const { frontmatter, streakCount = 1 } = Astro.props;
|
||||||
const { birthDate, health, manifestations, date, name } = frontmatter;
|
const { birthDate, health, manifestations, date, name } = frontmatter;
|
||||||
|
const medicationTaken = health?.mental?.medication ?? false;
|
||||||
|
|
||||||
// 1. CALCUL DU NIVEAU ET VARIABLES DE BASE
|
// 1. CALCUL DU NIVEAU ET VARIABLES DE BASE
|
||||||
const referenceDate = new Date(date);
|
const referenceDate = new Date(date);
|
||||||
@@ -157,6 +158,11 @@ const autoLayer = [
|
|||||||
status: hallucinations > 4 ? "alerte" : "calme",
|
status: hallucinations > 4 ? "alerte" : "calme",
|
||||||
},
|
},
|
||||||
{ label: "Stabilité", value: currentBiome.label, status: "info" },
|
{ label: "Stabilité", value: currentBiome.label, status: "info" },
|
||||||
|
{
|
||||||
|
label: "Traitement",
|
||||||
|
value: medicationTaken ? "Pris" : "Absent",
|
||||||
|
status: medicationTaken ? "stable" : "critique",
|
||||||
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
// LAYER MANUEL : Les leviers d'action et ressentis
|
// LAYER MANUEL : Les leviers d'action et ressentis
|
||||||
@@ -188,7 +194,16 @@ const manualLayer = [
|
|||||||
|
|
||||||
<div class="card-type-line">
|
<div class="card-type-line">
|
||||||
Niveau {age} — {frontmatter.identity?.job || "PROTO"}
|
Niveau {age} — {frontmatter.identity?.job || "PROTO"}
|
||||||
<span class="streak-tag">streak {streakCount}</span>
|
<div class="header-tags">
|
||||||
|
{
|
||||||
|
medicationTaken && (
|
||||||
|
<span class="med-tag" title="Médication prise">
|
||||||
|
💊
|
||||||
|
</span>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
<span class="streak-tag">streak {streakCount}</span>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
@@ -455,4 +470,14 @@ const manualLayer = [
|
|||||||
font-size: 0.8rem;
|
font-size: 0.8rem;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
.header-tags {
|
||||||
|
display: flex;
|
||||||
|
gap: 8px;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
.med-tag {
|
||||||
|
font-size: 0.9rem;
|
||||||
|
filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.5));
|
||||||
|
cursor: help;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user