[android] Show "Opens / Closes X at Y" using formatter + add i18n strings

- Wire `PlacePageView.refreshOpenState()` to `OpenStateTextFormatter`.
- Keep <= 60 min branch with plurals (“Closes in %d minutes • at HH:mm”).
- Add day hint when next change is not today (“Opens Sat at 09:00”).
- Add localized strings with positional placeholders:
  - `opens_at` / `closes_at` (... `%s`).
  - `opens_day_at` / `closes_day_at` (`%1$s=%day`, `%2$s=%time`).

Refs: #2303

Signed-off-by: NoelClick <dev@noel.click>
(cherry picked from commit be80c7486882ab64a64efc30d0979d3674bbcc29)
Signed-off-by: NoelClick <dev@noel.click>
This commit is contained in:
NoelClick
2025-10-30 17:38:35 -07:00
committed by jeanbaptisteC
parent 94542456a2
commit 83256c4895
2 changed files with 93 additions and 48 deletions

View File

@@ -441,6 +441,14 @@
<string name="opens_in">Opens in %s</string>
<string name="closes_in">Closes in %s</string>
<string name="closed">Closed</string>
<string name="opens_at">Opens at %s</string>
<string name="closes_at">Closes at %s</string>
<string name="opens_day_at">Opens %1$s at %2$s</string>
<string name="closes_day_at">Closes %1$s at %2$s</string>
<plurals name="minutes">
<item quantity="one">%d minute</item>
<item quantity="other">%d minutes</item>
</plurals>
<!-- Used in the opening_hours fragment for the last checked date, eg. "Confirmed two weeks ago" -->
<string name="hours_confirmed_time_ago">Confirmed %s</string>
<!-- Used on the place page for the last checked date, eg. "Existence confirmed two weeks ago" -->