Open-source gym & body-weight tracker, now in the App Store (iPhone + Apple Watch) and as an Android APK. Plan routines, log workouts, see which muscles are trained, import from Strong/Hevy/FitNotes. Self-host it or use it on the phone alone.
JavaScript apple-watchbodyweightdockerfitnessfitness-trackergymhealthiosmcpnodejspasskeysprogressive-web-applicationspwareactself-hostedself-hostingvitewebauthnweightliftingworkout-tracker
Home: the Today row drops its mini body map below 360px, so the routine name keeps its line
Duarte Santosb903ec246848
diff --git a/frontend/src/home-today-narrow.test.js b/frontend/src/home-today-narrow.test.jsnew file mode 100644index 000000000..12ab715e8--- /dev/null+++ b/frontend/src/home-today-narrow.test.js@@ -0,0 +1,26 @@+// Home's Today row at 320px: the routine name shared ~120px with the mini body map and the Start+// tag, so even "Push Day" wrapped in ru (night QA 10-19). Below 360px the map steps aside; wider+// screens keep it, and the name still clamps to two lines with an ellipsis.+import { describe, expect, it } from 'vitest'+import { readFileSync } from 'node:fs'+import { resolve } from 'node:path'++const css = readFileSync(resolve(process.cwd(), 'src/index.css'), 'utf8').replace(/\/\*[\s\S]*?\*\//g, '')++describe("Home's Today row on a narrow phone", () => {+ it('hides the mini body map below 360px only', () => {+ const narrow = [...css.matchAll(/@media \(max-width:(\d+)px\)\{([\s\S]*?)\n\}/g)]+ .filter(m => /\.today-row \.bm-mini-wrap\{display:none\}/.test(m[2]))+ expect(narrow).toHaveLength(1)+ expect(+narrow[0][1]).toBe(359)+ // Nowhere outside that query is the map hidden.+ const outside = css.replace(narrow[0][0], '')+ expect(outside).not.toMatch(/\.today-row \.bm-mini-wrap\{[^}]*display:none/)+ })++ it('still clamps the name to two lines', () => {+ const rule = css.match(/\.today-row \.ttl\{([^}]*)\}/)?.[1] || ''+ expect(rule).toMatch(/line-clamp:2/)+ expect(rule).toMatch(/text-overflow:ellipsis/)+ })+})diff --git a/frontend/src/index.css b/frontend/src/index.cssindex 203b8a4b3..130744372 100644--- a/frontend/src/index.css+++ b/frontend/src/index.css@@ -2000,6 +2000,12 @@ button.wl-summary{width:100%;padding:0 0 10px;text-align:start;border-radius:vardisplay:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;}+/* Below 360px the mini body map and the Start tag leave the name about 120px, so "Push Day"+ already wrapped in ru. The map is a nice-to-have there; the name is what the row is for. */+@media (max-width:359px){+ .today-row .bm-mini-wrap{display:none}+}+/* Only where a pointer really hovers — on a phone :hover sticks to the row after the tap.Lighter than :active, which goes all the way to --surface-3, so the two stay distinct. */@media (hover:hover){