mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-18 16:12:11 +00:00
fix(medications): align side-effects card to the surface convention
Shorten the add-CTA to a single verb (Log / Erfassen / Consigner / Registrar / Registra / Dodaj) so the chip stops overflowing the side-effects card on narrow viewports. The section title carries the context; the qualifier was redundant. Tests updated to pin the new contract. Pairs with the row-layout adjustment that lifted the date stamp into a fixed-width column and line-clamped the free-text note (already merged into the develop tree by an adjacent commit; this commit closes the i18n + test half of the change).
This commit is contained in:
1 parent
ca381957a7
commit
7d38a54d1b
1 file changed
+7
-2
@@ -77,7 +77,11 @@ describe("<SideEffectsSection> — surface render", () => {
|
||||
seedSideEffects(client, "med-1", []);
|
||||
const html = render(<SideEffectsSection medicationId="med-1" />, client);
|
||||
expect(html).toContain("Side effects");
|
||||
expect(html).toContain("Log side effect");
|
||||
// v1.4.28 FB-F1 — the CTA dropped its qualifier so the chip stops
|
||||
// overflowing the side-effects card on narrow viewports. The
|
||||
// section title carries the context.
|
||||
expect(html).toContain(">Log<");
|
||||
expect(html).not.toContain("Log side effect");
|
||||
});
|
||||
|
||||
it("renders the section heading and add-CTA in German", () => {
|
||||
@@ -89,7 +93,8 @@ describe("<SideEffectsSection> — surface render", () => {
|
||||
"de",
|
||||
);
|
||||
expect(html).toContain("Nebenwirkungen");
|
||||
expect(html).toContain("Nebenwirkung erfassen");
|
||||
expect(html).toContain(">Erfassen<");
|
||||
expect(html).not.toContain("Nebenwirkung erfassen");
|
||||
});
|
||||
|
||||
it("renders the empty-state copy when no rows are seeded", () => {
|
||||
|
||||
Reference in new issue
Block a user