Activity dateDisplay: detail double-renders same-day; cards omit end time #67
Labels
No labels
app:activities
app:chat
app:events
app:forum
app:libra
app:market
app:restaurant
app:tasks
app:wallet
app:webapp
bug
enhancement
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
aiolabs/webapp#67
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Two adjacent
dateDisplayrendering bugs in the activities module. Bundling them since the fix shape is shared (sameDay-aware compaction).(1) Detail page double-renders same-day events
Repro
Create a date-based activity (no start/end time, just dates). The form auto-mirrors the end date to the start date for single-day events (see
CreateEventDialog.vueend-date auto-mirror watcher), so a one-day event is published with bothstartandendset to the same date.On the activity detail page (
/activities/<id>), the "When" block reads:Expected: a single-day event should render the date once, e.g.
Tuesday, May 26, 2026.Root cause
src/modules/activities/views/ActivityDetailPage.vue:64-87—dateDisplayhas asameDaycollapse for the time-based branch but not for the date-based branch:The date-based branch unconditionally appends
— <end>wheneverendDateis present, even when it equals the start.Proposed fix
Add the same
sameDaycheck to the date-based branch and skip the— <end>suffix when start and end are the same calendar day. Multi-day date events (e.g. May 26 — May 28) still render the range as before.(2) Card omits end time entirely on time-based events
Repro
Create a time-based activity with both a start time and an end time (e.g. start 11:00, end 14:00). On the activities feed, the card's date row reads only:
The end time is dropped — the viewer can't tell whether the event runs 30 min or 6 hours without opening the detail page. The card has room to fit it.
Root cause
src/modules/activities/components/ActivityCard.vue:23-37—dateDisplaynever referencesendDate:Proposed fix
Mirror the detail-page logic with the card's shorter format strings, sameDay-aware:
Fri, May 22Fri, May 22 — Sun, May 24Fri, May 22 • 11:00Fri, May 22 • 11:00 — 14:00Fri, May 22 • 11:00 — Sat, May 23 • 14:00The card's date row has
class="truncate"so on very narrow viewports the multi-day time form may ellipsize — acceptable, and the detail page always has the full string.Related
The other surfaces that render activity dates probably want the same treatment — worth a quick audit while touching this:
ActivityCalendarView.vueActivitySearchOverlay.vueEventsPage.vue(Events list)🤖 Generated with Claude Code
Activity detail shows date twice when start and end fall on the same dayto Activity dateDisplay: detail double-renders same-day; cards omit end time