136 Commits

Author SHA1 Message Date
1a13ba263c feat: Implement About/Settings screens and refactor JSON import/export UI
This commit introduces new About and Settings screens, accessible from the navigation drawer.
The JSON import/export functionality has been refactored into a single dialog, improving UI clarity and reducing clutter in the drawer.

Key changes include:
- Added AboutScreen and SettingsScreen composables.
- Updated Screen sealed class with About and Settings entries.
- Added corresponding string resources for About and Settings.
- Replaced individual JSON import/export drawer items with a single "JSON Import/Export" button.
- Implemented JsonImportExportDialog to handle all JSON import/export options in a centralized dialog.
- Added HorizontalDividers to the drawer for better visual separation.
- Implemented dynamic versioning in build.gradle.kts using Git commit count for versionCode and versionName.
- Corrected BuildConfig access in AboutScreen.kt to use PackageManager for version info.
- Cleaned up unused launcher declarations in MainActivity.kt.
2025-10-13 22:56:23 +02:00
c806f9ba49 feat: Implement note export functionality
Implemented note export functionality, including a formatting function in the ViewModel and UI integration in MainActivity.
2025-10-13 19:59:39 +02:00
5bedc0f91d refactor: Localize "Export" string and update "Standard" to "Default"
Localized the "Export" string and updated the English translation of "standard_list_name".
2025-10-13 19:45:39 +02:00
2b38853ad2 feat: Extract hardcoded strings to string resources
Extracted several hardcoded strings in the UI layer to string resources for improved localization and maintainability.
2025-10-13 19:25:32 +02:00
af4cf289f9 feat: Add displayOrder to notes and implement UI 2025-10-13 18:13:00 +02:00
13531415c5 feat(ui): Update 'add single item' icon to ExposurePlus1
Changes the icon for the 'add single item' functionality in the shopping list detail view from 'LooksOne' to 'ExposurePlus1' for better visual representation.
2025-10-13 14:12:07 +02:00
9522b385c2 feat(shopping): Implement standard list loading and refined search UX 2025-10-13 13:57:14 +02:00
0dae398b4d feat(shopping): Implement list export and improve item suggestions
Implements two new features for shopping lists:

1.  **Export to Text File:**
    - Adds an "Exportieren" option to the shopping list detail view menu.
    - Allows users to save a shopping list as a .txt file using the Storage Access Framework.
    - The exported format includes the list name, item names, quantity, and a marker for completed items (`[x]`)

2.  **Improved Item Suggestions:**
    - Suggestions now appear for any existing item in the list, not just completed ones.
    - The suggestion text now differentiates between completed items ("(erledigt)") and items already on the list ("(ist schon in der liste)")

Also includes a minor theme adjustment to set the status and navigation bar colors.
2025-10-13 12:55:53 +02:00
f87aeec6d5 fix(state): Preserve UI state on screen rotation
This commit addresses the critical issue of UI state loss on screen rotation.

- The `Screen` sealed class is now made `Parcelable` using the `kotlin-parcelize` plugin, ensuring that navigation state (`currentScreen`, `selectedListId`) is preserved.
- Dialog visibility state (`showListDialog`) is also preserved using `rememberSaveable`.
- This prevents the app from navigating back to the list overview and losing input field/dialog state when the device orientation changes.
2025-10-13 00:34:31 +02:00
ef781e23c9 fix(ui): Improve item suggestion selection logic
Corrects the behavior of item suggestion selection in the shopping list detail screen.

- When a suggested item is clicked, the input field now correctly preserves previous entries (before the last comma or space) and only replaces the last part of the input with the selected item's name.
- This ensures that users can select suggestions without losing previously typed items in a comma/space-separated input.
2025-10-13 00:07:05 +02:00
1bb7f38fe9 feat(theme): Update primary app color to 419ae6
Updates the primary color of the application theme to #419ae6.

This change affects:
- The primary color definition in Color.kt and Theme.kt.
- Automatically regenerated launcher icons (ic_launcher and ic_launcher_foreground) across various densities, as they likely reference the primary theme color.
2025-10-12 23:33:01 +02:00
a7151b226f fix(ui): Resolve dark theme card border and ensure consistent styling
This commit addresses a visual issue where card borders appeared dark in the dark theme, obscuring rounded corners.

- The Card's background color is now explicitly set to MaterialTheme.colorScheme.surface when not dragging, ensuring a solid background and proper visibility of rounded corners in both light and dark themes.
- This change is applied to both the shopping list detail screen and the main shopping lists screen for consistent styling.
2025-10-12 22:59:42 +02:00
9ab79eca8e fix(ui): Correct reorder mode behavior and layout
This commit fixes several issues related to the recently implemented reorder mode.

- Adds the missing right-side drag handle in the detail view to support both left- and right-handed users.
- Corrects the behavior of the back button in the detail view to first exit reorder mode before navigating away.
- Implements a proper exit mechanism for reorder mode in the list view by changing the navigation icon to a back arrow.
2025-10-12 22:12:17 +02:00
6b80a06c2f feat(ui): Implement reorder mode for shopping lists
Extends the reorder mode functionality to the main shopping lists screen.

- A long press on a shopping list card now activates reorder mode.
- In this mode, drag handles are shown on both the left and right sides of each card to support left- and right-handed use.
- Other actions (edit, delete, navigation) are disabled while in reorder mode.
- Navigating away from the screen via the drawer correctly disables the reorder mode.
2025-10-12 21:52:33 +02:00
69cdc03277 feat(ui): Implement reorder mode for shopping list items
Implements a "reorder mode" for the shopping list detail screen to resolve the conflict between scrolling and drag-to-reorder gestures.

- A long press on a list item now activates reorder mode.
- In this mode, a drag handle is shown on each item, and list items can be reordered. Regular clicks for checking items are disabled.
- The back button deactivates the reorder mode.
- Gesture handling has been consolidated to correctly detect both taps and long presses on list items.
2025-10-12 21:49:07 +02:00
04876d1860 refactor(ui): Vereinheitlichung des Drag-and-Drop-Verhaltens
Das Drag-and-Drop-Verhalten für Einkaufslisten und deren Einträge wurde überarbeitet und vereinheitlicht, um eine konsistentere und intuitivere Benutzererfahrung zu schaffen.

- Das separate Verschiebe-Icon wurde sowohl in der Listen- als auch in der Detailansicht entfernt. Stattdessen kann nun das gesamte Element (Karte oder Zeile) durch langes Drücken verschoben werden.

- In der Detailansicht werden die Artikel nun als 'Cards' dargestellt, um beim Verschieben ein klares visuelles Feedback (Schatten/Anhebung) zu geben, analog zur Listenansicht.

- Das Bearbeiten-Icon in der Detailansicht wurde durch ein "Mehr"-Menü ersetzt. Dieses Menü bietet nun die Optionen "Umbenennen" und "Menge ändern" und sorgt für eine klare und explizite Interaktion.
2025-10-12 19:57:30 +02:00
85bd89cce1 feat: Improve visual feedback for reorderable lists
Enhances the visual experience when reordering items in both shopping list
detail and shopping lists screens.

- Implemented animated scaling and background color changes for items
  being dragged to provide clearer visual feedback.
- Adjusted shadow behavior during dragging to be consistent across themes,
  specifically removing the shadow in dark theme for a cleaner look.
2025-10-12 16:44:44 +02:00
8cc05a2069 commit part two drag and drop 2025-10-12 14:53:37 +02:00
ebac764465 Feat: UI-Anpassungen und Fehlerbehebungen
- Behebt Probleme bei der Artikelauswahl und beim Neuanordnen in der Einkaufslistendetailansicht.
- Passt Abstände und Farben für eine sauberere Benutzeroberfläche an.
- Behebt Probleme mit den Fensterrändern im Hoch- und Querformat.
2025-10-12 13:09:20 +02:00
f5c1127191 Refactor: Überarbeitung der Einkaufslistendetailansicht
- Checkboxen entfernt und durch Antippen der Artikel zum Abhaken ersetzt.
- Drag-and-Drop zum Neuanordnen von Artikeln implementiert.
- Buttons zum Verschieben von Artikeln nach oben/unten hinzugefügt, mit Langdruck zum Verschieben an den Anfang/Ende.
- Menü zum Umbenennen und Festlegen der Menge für ausgewählte Artikel hinzugefügt.
- Build-Fehler und Lint-Warnungen behoben.
2025-10-12 02:08:27 +02:00
b53245b643 commit part one add move buttons and remove checkbuttons 2025-10-12 01:33:16 +02:00
63da3b4369 Feat: Verbesserte visuelle Darstellung und Header-Anpassungen
- Dunklere Markierung für ausgewählte Artikel im dunklen Thema.
- Header-Titel im TopAppBar verkleinert.
- Icons in den TopAppBar-Aktionen verkleinert.
2025-10-11 17:48:39 +02:00
2970834778 feat: Refine ShoppingListDetailScreen UI and interaction\n\nThis commit refines the user interface and interaction for the ShoppingListDetailScreen.\n\nKey changes include:\n- Removed the duplicate list name display above the input field.\n- Removed the back navigation icon from the default TopAppBar when no item is selected, relying on system back navigation.\n- Ensured the contextual TopAppBar title is empty when an item is selected.\n- Added a quantity edit button to the contextual TopAppBar for selected items. 2025-10-11 14:54:02 +02:00
2f088ad9c2 feat: Implement item selection mode with contextual actions and fix build errors 2025-10-11 14:37:30 +02:00
f74da803ca feat: Implement drag-and-drop reordering for shopping list items and externalize UI strings 2025-10-11 12:43:32 +02:00
333b43abe0 feat: Implement item quantity, rename, and list reordering
- Add quantity field to ShoppingListItem and allow users to edit it via a dialog.
- Allow users to rename shopping list items through a long-press context menu.
- Implement drag-and-drop reordering for shopping lists on the main screen using the reorderable library.
- Add necessary database migrations for new fields.
2025-10-11 12:09:03 +02:00
52da1101d2 feat: Enhance shopping list detail screen
- Rework layout to use a BottomAppBar for actions.
- Fix keyboard overlapping issue by removing fixed height and using imePadding.
- Prevent adding duplicate items to the shopping list.
- Add search-as-you-type functionality to show completed items as suggestions.
2025-10-11 11:42:05 +02:00
1f06eae886 fix imports on replace buttons with icons 2025-10-11 11:17:43 +02:00
233760ad48 Fix: Resolve build warnings and clean up code
This commit addresses the remaining build warnings and cleans up the code:

- Updated `MainActivity.kt` to use `Icons.AutoMirrored.Filled.ArrowBack` to resolve a deprecation warning.
- Removed the unused `onBack` parameter from the `ShoppingListDetailScreen` composable function signature in `ShoppingListDetailScreen.kt`.

These changes ensure a cleaner build and adhere to best practices.
2025-10-11 01:57:45 +02:00
781c3e50f2 Feat: Shopping List views enhanced with search, item management, and UI improvements. 2025-10-11 01:54:18 +02:00
a2c9932d90 Feat: Implementiere ShoppingListDetailScreen für die Artikelverwaltung
Dieser Commit führt einen neuen Detailbildschirm zur Verwaltung von Artikeln innerhalb einer Einkaufsliste ein.

Die wichtigsten Änderungen umfassen:
- Added `ShoppingListDetailScreen` to display items of a selected shopping list.
- Implemented navigation from `ShoppingListsScreen` to `ShoppingListDetailScreen` upon clicking a list card.
- Updated `MainActivity.kt` to handle navigation state and display a back button for the detail view.
- Enhanced `ShoppingListsViewModel.kt` to provide a stream for a single shopping list with its items.
- Added new string resources for the detail screen.
- Users can now view and toggle the checked status of individual items within a dedicated screen.
2025-10-11 00:49:19 +02:00
7704441137 Fix: Behebe Build-Kompilierungsfehler und committe alle ausstehenden Änderungen
Dieser Commit behebt die Kompilierungsfehler, die während des Build-Prozesses aufgetreten sind.
Im Einzelnen:
- Der nicht aufgelöste Verweis auf `saveItem` in `ShoppingListsScreen.kt` wurde korrigiert, indem er in `saveShoppingListItem` geändert wurde.
- Der Fehler `No value passed for parameter 'item'` in `ShoppingListsScreen.kt` wurde behoben, indem `itemDetails.toShoppingListItem()` korrekt an `viewModel.saveShoppingListItem()` übergeben wurde.

Zusätzlich sind alle anderen ausstehenden Änderungen im Arbeitsverzeichnis, wie gewünscht, in diesem Commit enthalten.
2025-10-11 00:31:00 +02:00
8d1f45c93f feat: Implement core data architecture (Room, Repository, ViewModels) and UI integration 2025-10-10 22:56:12 +02:00
d38c4c5517 add svg file to header and color header 2025-10-10 22:09:34 +02:00
dbb1d877b1 add svg file to header and color header 2025-10-10 22:09:03 +02:00
9ba57e6af1 feat: Add initial app structure with navigation drawer 2025-10-10 19:53:39 +02:00