summaryrefslogtreecommitdiff
path: root/android-app/app/src/main/res
diff options
context:
space:
mode:
authorClaude <noreply@anthropic.com>2026-05-30 08:11:15 +0000
committerClaude <noreply@anthropic.com>2026-05-30 08:11:15 +0000
commit2b6a7599b3a9b0159ac3f45917e6e5d77841328c (patch)
tree3aebbc058a3b3e5b45194997d4a5a5a8077a97cf /android-app/app/src/main/res
parent1437d78b95b78e3f662b0d7e00669d386c3eedb6 (diff)
Redesign trip report: structured layout, remove generate button, fix photo entries
Layout: - Stats displayed as three large-number columns (distance / avg kt / max kt) - Date and time range as a clean header above stats - Conditions row (seas + temp) conditionally shown - Log entries rendered as a proper list with HH:mm timestamps - No GENERATE REPORT button — report auto-generates on open; RETRY shown only on error - Pirate mode (long-press title) still renders monospace narrative as before Generator: - Time format changed from 4-digit HHmm to HH:mm - "(photo only)" entries display as 📷 instead of literal "(photo only) [photo]" https://claude.ai/code/session_01KXYBuAHZkvv63DeUG6XaZD
Diffstat (limited to 'android-app/app/src/main/res')
-rw-r--r--android-app/app/src/main/res/layout/fragment_trip_report.xml190
1 files changed, 173 insertions, 17 deletions
diff --git a/android-app/app/src/main/res/layout/fragment_trip_report.xml b/android-app/app/src/main/res/layout/fragment_trip_report.xml
index c8092ba..ec3f58e 100644
--- a/android-app/app/src/main/res/layout/fragment_trip_report.xml
+++ b/android-app/app/src/main/res/layout/fragment_trip_report.xml
@@ -18,48 +18,204 @@
android:text="Trip Report"
android:textSize="24sp"
android:textStyle="bold"
- android:layout_marginBottom="24dp"
+ android:layout_marginBottom="20dp"
android:longClickable="true" />
- <com.google.android.material.card.MaterialCardView
+ <!-- Structured content (hidden in pirate mode) -->
+ <LinearLayout
+ android:id="@+id/layout_structured_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- app:cardCornerRadius="16dp"
- app:cardElevation="4dp"
- app:strokeWidth="1dp"
- app:strokeColor="?attr/colorOutlineVariant">
+ android:orientation="vertical"
+ android:visibility="gone">
+
+ <!-- Passage header: date + time range -->
+ <TextView
+ android:id="@+id/tv_passage_date"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="13sp"
+ android:textAllCaps="true"
+ android:letterSpacing="0.1"
+ android:alpha="0.6"
+ android:layout_marginBottom="2dp" />
+
+ <TextView
+ android:id="@+id/tv_passage_time"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="17sp"
+ android:layout_marginBottom="20dp" />
+
+ <!-- Stats row: distance · avg · max -->
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="horizontal"
+ android:layout_marginBottom="16dp">
+
+ <LinearLayout
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:orientation="vertical"
+ android:gravity="center_horizontal">
+ <TextView
+ android:id="@+id/tv_stat_distance"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="34sp"
+ android:textStyle="bold" />
+ <TextView
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="nm"
+ android:textSize="11sp"
+ android:alpha="0.55" />
+ </LinearLayout>
+
+ <LinearLayout
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:orientation="vertical"
+ android:gravity="center_horizontal">
+ <TextView
+ android:id="@+id/tv_stat_avg"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="34sp"
+ android:textStyle="bold" />
+ <TextView
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="avg kt"
+ android:textSize="11sp"
+ android:alpha="0.55" />
+ </LinearLayout>
+
+ <LinearLayout
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:orientation="vertical"
+ android:gravity="center_horizontal">
+ <TextView
+ android:id="@+id/tv_stat_max"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="34sp"
+ android:textStyle="bold" />
+ <TextView
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="max kt"
+ android:textSize="11sp"
+ android:alpha="0.55" />
+ </LinearLayout>
+
+ </LinearLayout>
+
+ <!-- Conditions row (seas / temp) — hidden if no data -->
+ <LinearLayout
+ android:id="@+id/layout_conditions"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="horizontal"
+ android:layout_marginBottom="20dp"
+ android:visibility="gone">
+
+ <TextView
+ android:id="@+id/tv_conditions"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:textSize="14sp"
+ android:alpha="0.7" />
+
+ </LinearLayout>
+ <!-- Divider before log -->
+ <View
+ android:id="@+id/divider_log"
+ android:layout_width="match_parent"
+ android:layout_height="1dp"
+ android:background="?attr/colorOutlineVariant"
+ android:visibility="gone" />
+
+ <!-- Log entries — hidden if none -->
<LinearLayout
+ android:id="@+id/layout_log_section"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
- android:padding="16dp">
+ android:layout_marginTop="16dp"
+ android:visibility="gone">
<TextView
- android:id="@+id/tv_narrative_content"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="LOG"
+ android:textSize="11sp"
+ android:textAllCaps="true"
+ android:letterSpacing="0.12"
+ android:alpha="0.5"
+ android:layout_marginBottom="8dp" />
+
+ <LinearLayout
+ android:id="@+id/ll_log_entries"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:text="Generate a report to see your passage summary…"
- android:textSize="15sp"
- android:fontFamily="monospace"
- android:lineSpacingExtra="4dp" />
+ android:orientation="vertical" />
</LinearLayout>
+
+ </LinearLayout>
+
+ <!-- Pirate mode: monospace narrative card -->
+ <com.google.android.material.card.MaterialCardView
+ android:id="@+id/cv_pirate"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ app:cardCornerRadius="16dp"
+ app:cardElevation="0dp"
+ app:strokeWidth="1dp"
+ app:strokeColor="?attr/colorOutlineVariant"
+ android:visibility="gone">
+
+ <TextView
+ android:id="@+id/tv_narrative_content"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:padding="16dp"
+ android:textSize="14sp"
+ android:fontFamily="monospace"
+ android:lineSpacingExtra="4dp" />
+
</com.google.android.material.card.MaterialCardView>
+ <!-- Error state -->
+ <TextView
+ android:id="@+id/tv_error"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:textSize="14sp"
+ android:alpha="0.7"
+ android:layout_marginBottom="16dp"
+ android:visibility="gone" />
+
<com.google.android.material.button.MaterialButton
- android:id="@+id/btn_refresh_report"
+ android:id="@+id/btn_retry"
android:layout_width="match_parent"
- android:layout_height="60dp"
- android:layout_marginTop="24dp"
- android:text="GENERATE REPORT" />
+ android:layout_height="wrap_content"
+ android:text="RETRY"
+ android:visibility="gone" />
<ProgressBar
android:id="@+id/progress_report"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
- android:layout_marginTop="16dp"
+ android:layout_marginTop="48dp"
android:visibility="gone" />
</LinearLayout>