forked from jsnbuchanan/crowd-funder-for-time-pwa
refactor: centralize QR navigation logic and add export prompt after contact addition
- Create QRNavigationService to handle platform-specific QR routing - Remove direct Capacitor imports from ContactsView, ProjectsView, HelpView - Replace duplicated QR routing logic with centralized service calls - Update HelpView template to use platform service methods (isCapacitor, capabilities) - Add export data prompt after successfully adding a contact - Add NOTIFY_EXPORT_DATA_PROMPT notification constant - Implement exportContactData() method with platform service integration - Fix TypeScript compatibility for Vue Router route parameters - Maintain consistent QR navigation behavior across all views Eliminates code duplication and improves platform abstraction by using PlatformService instead of direct Capacitor references. Enhances user experience with automatic export prompts for data backup.
This commit is contained in:
@@ -846,6 +846,12 @@ export const NOTIFY_CONTACTS_ADDED = {
|
||||
message: "They were added.",
|
||||
};
|
||||
|
||||
// Used in: ContactsView.vue (addContact method - export data prompt after contact addition)
|
||||
export const NOTIFY_EXPORT_DATA_PROMPT = {
|
||||
title: "Export Your Data",
|
||||
message: "Would you like to export your contact data as a backup?",
|
||||
};
|
||||
|
||||
// Used in: ContactsView.vue (showCopySelectionsInfo method - info about copying contacts)
|
||||
export const NOTIFY_CONTACT_INFO_COPY = {
|
||||
title: "Info",
|
||||
|
||||
Reference in New Issue
Block a user