feat(export): Replace CSV export with standardized JSON format

- Add contactsToExportJson utility function for standardized data export
- Replace CSV export with JSON format in DataExportSection
- Update file extension and MIME type to application/json
- Remove Dexie-specific export logic in favor of unified SQLite/Dexie approach
- Update success notifications to reflect JSON format
- Add TypeScript interfaces for export data structure

This change improves data portability and standardization by:
- Using a consistent JSON format for data export/import
- Supporting both SQLite and Dexie databases
- Including all contact fields in export
- Properly handling contactMethods as stringified JSON
- Maintaining backward compatibility with existing import tools

Security: No sensitive data exposure, maintains existing access controls
This commit is contained in:
Matthew Raymer
2025-06-07 05:02:33 +00:00
parent cfb186a04e
commit b9223d7fe2
9 changed files with 230 additions and 126 deletions

View File

@@ -1119,7 +1119,6 @@ export default class AccountViewView extends Vue {
*/
async mounted() {
try {
console.log("[AccountViewView] mounted");
// Initialize component state with values from the database or defaults
await this.initializeState();
await this.processIdentity();
@@ -1172,7 +1171,6 @@ export default class AccountViewView extends Vue {
}
}
} catch (error) {
console.log("[AccountViewView] error: ", JSON.stringify(error, null, 2));
// this can happen when running automated tests in dev mode because notifications don't work
logger.error(
"Telling user to clear cache at page create because:",
@@ -1206,7 +1204,6 @@ export default class AccountViewView extends Vue {
this.turnOffNotifyingFlags();
}
}
// console.log("Got to the end of 'mounted' call in AccountViewView.");
/**
* Beware! I've seen where we never get to this point because "ready" never resolves.
*/