Files
agendula/app/src/main/res/layout/widget_preview_glance.xml
T
makiolaj 58b34d5603 feat(widget): redesign the task widget in M3 Expressive style, add 'At a glance'
Tonal containers per section (grouped by list, or by due bucket when
not), an expressive tonal add button that seeds the widget's own list,
and per-widget background (solid/tinted/transparent) and theme
(follow app/light/dark) controls in the existing config screen.

Adds a small 'At a glance' widget: a quick-add button when too small
to show anything else, otherwise today's count, overdue count and the
next task with a check.

The shared Glance plumbing (theme, rounded surface, header, grouped
row, rollover alarm, update receiver) moves into floret-kit's new
glance module, bumped in via the submodule.
2026-10-02 18:19:02 +02:00

56 lines
2.2 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- Static mock shown in the widget picker (android:previewLayout); the live
widget is rendered by Glance. -->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:background="@drawable/preview_widget_bg"
android:padding="10dp"
tools:ignore="HardcodedText,UseAppTint">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal"
android:gravity="center_vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="3"
android:textColor="@color/widget_preview_primary"
android:textSize="24sp"
android:textStyle="bold" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:layout_marginStart="6dp"
android:orientation="vertical">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/smart_today"
android:textColor="@color/widget_preview_on_surface"
android:textSize="12sp" />
</LinearLayout>
<ImageView
android:layout_width="40dp"
android:layout_height="40dp"
android:padding="9dp"
android:contentDescription="@null"
android:background="@drawable/preview_add_bg"
android:src="@drawable/floret_ic_widget_add"
android:tint="@color/widget_preview_on_primary_container" />
</LinearLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:text="Water the plants"
android:textColor="@color/widget_preview_on_surface"
android:textSize="13sp" />
</LinearLayout>