Marc-André Bombeck
fd34ee13b9
fix(charts): round y ticks, calendar x ticks and labels beside the plot
...
The value chart's axes and labels, as drawn on a 90-day blood pressure
view on a tablet:
- Y ticks were whatever Recharts split the padded domain into, so the
labels read 57, 83, 109. The domain is now widened to a 1/2/5 step
and every tick is handed to the axis, evenly spaced and all drawn.
- X ticks were every n-th point, so their dates drifted with the data.
They now fall on a calendar grid (days, Mondays, two weeks, months,
quarters, years), each on the point nearest the grid line, and the
step is the smallest whose labels fit the measured plot width.
- The "your average" label sat inside the plot over the readings, and a
target zone's label was clipped to its first letter. Both now sit
beside the plot, in a right margin sized to the longest label.
A browser test draws the axes with Recharts and pins the tick values,
the Monday grid, and both labels outside the plot clear of every dot.
2026-10-23 19:53:28 +02:00
..
2026-10-08 08:32:15 +02:00
2026-10-09 13:37:14 +02:00
2026-10-23 17:19:21 +02:00
2026-10-20 09:08:40 +02:00
2026-10-20 09:08:40 +02:00
2026-10-20 09:08:40 +02:00
2026-06-28 03:20:49 +02:00
2026-10-22 13:01:10 +02:00
2026-10-05 21:57:49 +02:00
2026-09-11 12:37:54 +02:00
2026-10-15 22:55:40 +02:00
2026-09-26 16:23:14 +02:00
2026-10-21 19:24:21 +02:00
2026-10-20 09:08:40 +02:00
2026-10-23 19:53:28 +02:00
2026-10-04 20:00:07 +02:00
2026-10-20 09:08:40 +02:00
2026-09-27 13:03:27 +02:00
2026-10-15 22:49:00 +02:00
2026-10-20 09:08:40 +02:00
2026-10-20 09:08:40 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-21 19:24:21 +02:00
2026-10-04 11:33:42 +02:00
2026-10-08 10:02:39 +02:00
2026-10-08 08:32:15 +02:00
2026-10-21 21:39:15 +02:00
2026-09-03 02:02:30 +02:00
2026-10-08 08:32:15 +02:00
2026-07-31 08:52:23 +02:00
2026-10-20 16:52:08 +02:00
2026-06-19 22:20:31 +02:00
2026-10-21 21:39:15 +02:00
2026-07-16 09:55:35 +02:00
2026-05-17 13:22:51 +02:00
2026-07-18 06:47:32 +02:00
2026-10-01 13:23:17 +02:00
2026-10-22 14:49:55 +02:00
2026-10-20 09:47:20 +02:00
2026-10-20 09:08:40 +02:00
2026-09-26 16:23:14 +02:00
2026-09-26 16:23:14 +02:00
2026-10-05 21:22:57 +02:00
2026-10-14 18:57:01 +02:00
2026-10-15 22:55:40 +02:00
2026-10-16 05:32:13 +02:00
2026-10-20 09:47:20 +02:00
2026-06-01 20:26:26 +02:00
2026-08-22 16:14:54 +02:00
2026-09-24 10:17:00 +02:00
2026-09-24 09:06:22 +02:00
2026-10-20 09:08:40 +02:00
2026-10-21 21:39:15 +02:00
2026-10-08 09:40:12 +02:00
2026-10-09 16:25:48 +02:00
2026-06-19 22:20:31 +02:00
2026-10-20 04:23:10 +02:00
2026-10-08 10:32:11 +02:00
2026-08-08 07:40:07 +02:00
2026-08-08 01:34:59 +02:00
2026-09-03 02:07:29 +02:00
2026-06-19 22:20:31 +02:00
2026-10-15 23:39:11 +02:00
2026-08-08 01:43:32 +02:00
2026-10-04 11:33:45 +02:00
2026-09-24 10:17:00 +02:00
2026-10-16 01:38:05 +02:00
2026-07-19 13:25:32 +02:00
2026-10-20 09:08:40 +02:00
2026-08-01 20:04:10 +02:00
2026-10-20 09:47:20 +02:00
2026-10-04 11:33:45 +02:00
2026-09-24 10:17:00 +02:00
2026-10-20 09:47:20 +02:00
2026-10-20 09:47:20 +02:00
2026-10-20 05:01:18 +02:00
2026-10-20 09:08:40 +02:00
2026-10-19 14:57:00 +02:00
2026-10-09 16:45:39 +02:00
2026-10-20 09:08:40 +02:00
2026-10-08 08:32:15 +02:00
2026-10-05 21:22:57 +02:00
2026-10-06 20:53:39 +02:00
2026-10-05 21:22:57 +02:00
2026-06-11 23:20:38 +02:00
2026-09-24 09:06:22 +02:00
2026-09-24 10:17:00 +02:00
2026-10-20 09:08:40 +02:00
2026-09-24 09:06:22 +02:00
2026-09-24 12:15:56 +02:00
2026-07-24 07:45:02 +02:00
2026-10-22 14:50:10 +02:00
2026-10-22 18:21:02 +02:00
2026-10-20 09:08:40 +02:00
2026-09-09 22:39:39 +02:00
2026-10-20 09:08:40 +02:00
2026-10-02 21:21:38 +02:00
2026-10-03 21:14:08 +02:00
2026-10-20 09:16:43 +02:00
2026-06-04 17:47:17 +02:00
2026-06-26 12:29:29 +02:00
2026-10-22 00:25:29 +02:00
2026-10-20 09:08:40 +02:00
2026-10-20 09:08:40 +02:00
2026-10-01 13:23:17 +02:00
2026-10-15 22:55:40 +02:00
2026-06-03 08:56:20 +02:00
2026-10-20 09:08:40 +02:00