commit cd4ca3e6c1aed73fad00b2fdd1d5b78add799859
parent 0ed0786e06e3a5c661708fe2114867759fbddb1c
Author: Vlada Svirsh <svirv1@bfh.ch>
Date: Wed, 29 Apr 2026 16:54:53 +0200
dd94 discounts and passes page in wallet UI
Diffstat:
6 files changed, 115 insertions(+), 0 deletions(-)
diff --git a/design-documents/094-discounts-passes-wallet.rst b/design-documents/094-discounts-passes-wallet.rst
@@ -0,0 +1,114 @@
+DD 94: Discounts & Passes Wallet UI
+###################################
+
+Summary
+=======
+
+This document describes the design and behavior of all wallet screens related to discounts and passes. It defines a unified
+way to present, manage, and display these entities across the wallet, including their states, structure, and visual representation.
+
+Motivation
+==========
+
+Merchants can provide users with discounts or passes that apply to specific products or services. The wallet must support:
+
+Clear presentation of available discounts and passes
+Ability for users to review and apply them during checkout
+Overview of all owned items, including:
+Currently active
+Not yet active (future validity)
+Available for use
+
+A consistent design ensures users can easily understand what benefits they have, when they can use them, and how they
+affect their purchases.
+
+Requirements
+============
+
+Proposed Solution
+=================
+
+Discounts & Passes Pages
+------------------------
+
+Available
+~~~~~~~~~
+
+.. list-table::
+ :widths: 50 50
+
+ * - .. image:: wallet-designs/discounts-page.png
+ :width: 100%
+
+ - .. image:: wallet-designs/passes-page.png
+ :width: 100%
+
+Inside card next information is displayed:
+
+- Name of the discount or pass
+- Description
+- For discount card: "Redeemable at:" with the merchant name. For pass card: "Provided by:" with the merchant name.
+- Validity section:
+
+ * For active items: "Valid until" with the expiration date. Background color is SecondaryContainer. Text color is onSecondaryContainer.
+ * For future items: "Valid from" with the start date.
+- Badge used to indicate number of items of the same type. If only one item of the same type is owned, the badge is not shown.
+
+ * For active items: badge background color is Primary. Text color is onPrimary.
+ * For future items: badge background color is SurfaceVariant. Text color is onSurfaceVariant.
+
+Expired
+~~~~~~~
+
+.. list-table::
+ :widths: 50 50
+
+ * - .. image:: wallet-designs/discounts-page-ex.png
+ :width: 100%
+
+ - .. image:: wallet-designs/passes-page-ex.png
+ :width: 100%
+
+Inside card next information is displayed:
+
+- Name of the discount or pass
+- Description
+- For discount card:
+
+ * Redeemed: "Redeemable at" + merchant name + "on" + redeemed date. Text button Primary color "View order" with the link to the order details page.
+ * Not redeemed: "Was redeemable at:" with the merchant name.
+
+- For pass card:
+
+ * "Provided by:" with the merchant name.
+ * For used pass show text button Primary color "View orders" with the link to the orders list.
+
+- Validity section: "Validity period" and date range.
+- Badge used to indicate number of items of the same type. If only one item of the same type is owned, the badge is not shown.
+
+
+Test Plan
+=========
+
+(If this DD concerns a new or changed feature, describe how it can be tested.)
+
+Definition of Done
+==================
+
+(Only applicable to design documents that describe a new feature. While the
+DoD is not satisfied yet, a user-facing feature **must** be behind a feature
+flag or dev-mode flag.)
+
+Alternatives
+============
+
+Drawbacks
+=========
+
+Discussion / Q&A
+================
+
+(This should be filled in with results from discussions on mailing lists / personal communication.)
+Got it — here’s a **design document–style description** aligned with your previous DD format and written for implementation.
+
+---
diff --git a/design-documents/index.rst b/design-documents/index.rst
@@ -105,4 +105,5 @@ Design documents that start with "XX" are considered deprecated.
091-wallet-coin-selection
092-incremental-backup-sync
093-checkout-page
+ 094-discounts-passes-wallet
999-template
diff --git a/design-documents/wallet-designs/discounts-page-ex.png b/design-documents/wallet-designs/discounts-page-ex.png
Binary files differ.
diff --git a/design-documents/wallet-designs/discounts-page.png b/design-documents/wallet-designs/discounts-page.png
Binary files differ.
diff --git a/design-documents/wallet-designs/passes-page-ex.png b/design-documents/wallet-designs/passes-page-ex.png
Binary files differ.
diff --git a/design-documents/wallet-designs/passes-page.png b/design-documents/wallet-designs/passes-page.png
Binary files differ.