- Use PlatformServiceMixin for platform and database access
- Replace manual PlatformService instantiation with mixin methods/properties
- Use $contacts() for contact export
- Use capabilities for platform checks in template and logic
- Remove unused imports and redundant code
- Lint clean
- Created UsageLimitsSection.vue using vue-facing-decorator (class-based, TypeScript, @Component, @Prop, @Emit).
- Moved 'Usage Limits' UI and logic (status, spinner, message, recheck button) into the new component.
- Replaced original usage limits section markup in AccountViewView.vue with <UsageLimitsSection />.
- Passed loadingLimits and limitsMessage props, and wired up @recheck-limits event to call checkLimits().
- Ensured all linter errors are resolved and code is consistent with project conventions.
- Created LocationSearchSection.vue using vue-facing-decorator (class-based, TypeScript, @Component, @Prop, @Emit).
- Moved 'Location for Searches' UI and logic into the new component.
- Replaced original location section markup in AccountViewView.vue with <LocationSearchSection />.
- Passed isRegistered and searchAreaLabel props, and wired up @set-search-area event to a new placeholder openSearchAreaDialog() method.
- Added placeholder openSearchAreaDialog() with a TODO for future implementation.
- Ensured all linter errors are resolved and code is consistent with project conventions.
- Created RegistrationNotice.vue using vue-facing-decorator (class-based, TypeScript, @Component, @Prop, @Emit).
- Moved registration prompt (yellow box) and "Share Your Info" button into the new component.
- Replaced original registration notice markup in AccountViewView.vue with <RegistrationNotice />.
- Passed isRegistered and show props, and wired up @share-info event to a new placeholder openShareDialog() method.
- Added placeholder openShareDialog() with a TODO for future implementation.
- Ensured all linter errors are resolved and code is consistent with project conventions.
- Created IdentitySection.vue using vue-facing-decorator (class-based, TypeScript, @Component, @Prop, @Emit).
- Moved all identity-related UI and logic (name, QR code, profile image, DID) into the new component.
- Replaced original identity section markup in AccountViewView.vue with <IdentitySection />.
- Passed all necessary props and implemented event handlers in AccountViewView.vue to maintain existing behavior.
- Ensured all linter errors are resolved and code is consistent with project conventions.
- Migrated all notification calls in AccountViewView.vue to use a notify helper initialized in mounted(), ensuring this.$notify is available and preventing runtime errors.
- Removed NotificationMixin and $notifyHelper usage; restored and standardized notify helper pattern.
- Migrated all database and platform service operations to use PlatformServiceMixin ultra-concise methods ($accountSettings, $saveSettings, $saveUserSettings, etc.).
- Cleaned up unused imports and code related to previous notification and database patterns.
- Ensured all linter errors and warnings are resolved in both AccountViewView.vue and notification utility files.
- Replaced direct $notify calls with notification helper utilities for consistency and reduced duplication.
- Updated AccountViewView.vue, PlatformServiceMixin.ts, and ShareMyContactInfoView.vue to use notification helpers.
- Added explicit TypeScript types and constants for notification patterns.
- Suppressed ESLint 'any' warning in notification mixin helper.
- Ensured all affected files pass linting.
Created notification utility approaches to consolidate verbose $notify calls:
- Simple function utility (src/utils/notify.ts) - recommended approach
- Vue 3 composable (src/composables/useNotifications.ts)
- Utility class with mixin (src/utils/notificationUtils.ts)
Updated ClaimView.vue to demonstrate usage, reducing notification code by ~70%.
Enhanced PlatformServiceMixin with improved caching and database methods.
Updated ShareMyContactInfoView.vue with mixin improvements.
Provides consistent timeouts, standardized patterns, and type safety.
Ready for migration alongside mixin updates.
- Move all complex template logic to computed properties and methods
- Replace all `as any` usages with proper TypeScript types (OfferClaim, GiveActionClaim)
- Add computed property for claim image, removing inline image access
- Route all logging through PlatformServiceMixin
- Ensure all icon-only buttons have aria-labels for accessibility
- Remove unused imports and direct logger usage
- Lint clean: no warnings or errors remain
Convert undefined values to null in database operations to prevent
"tried to bind a value of an unknown type" errors in SQL.js worker.
- Fix $insertContact() method undefined-to-null conversion
- Fix $insertEntity() method undefined-to-null conversion
- Preserve boolean false/0 values vs null distinction
- Maintain parameterized queries for SQL injection protection
- Fix contact creation errors in ContactsView component
Resolves database binding failures when inserting contacts with
undefined properties. All linting errors resolved.
Replace generic 'any' types with specific type definitions:
- EntitySummaryButton: Define edit-requested event payload type
- GiftDetailsStep: Add proper types for edit-entity and submit events
- HomeView: Use GiftedDialog type for customDialog ref
Resolves 7 TypeScript linting warnings, improves type safety
- Replace console.log with structured logger.debug() calls in AmountInput,
GiftDetailsStep, and GiftedDialog components
- Fix duplicate enum values in constants/app.ts for LOCAL_*_API_SERVER
- Replace Record<string, any> with Record<string, string> for query params
- Update error handling from catch(err: any) to catch(err: unknown)
- Add EntityData interface and fix entity prop typing
- Remove USE_DEXIE_DB conditionals and unused database imports
- Fix duplicate imports and class members in GiftedDialog.vue
- Correct createAndSubmitGive function call parameters
Resolves 12 linting errors and 9 TypeScript any type warnings.
Improves type safety, logging practices, and removes deprecated code.
- Replace Record<string, any> with Record<string, string> for query params
- Fix error handling from catch(err: any) to catch(err: unknown)
- Add EntityData interface for proper entity typing
- Update EntitySelectionEvent interface with union types
- Remove USE_DEXIE_DB conditionals and unused import
- Clean up database service calls removing Dexie fallbacks
Resolves 9 TypeScript any type warnings, improves type safety across
entity selection components, and removes deprecated database migration code.
Remove CORS headers to enable universal image support and fix local API server settings.
## Changes
**Remove CORS Headers**
- Remove Cross-Origin-Opener-Policy and Cross-Origin-Embedder-Policy headers
- Enables images from any domain (Facebook, Medium, arbitrary websites)
- Database falls back to IndexedDB mode (minimal performance impact)
**Fix Local Development Configuration**
- Set LOCAL_ENDORSER_API_SERVER to http://127.0.0.1:3000 (was "/api")
- Create .env.development with local API server config
- Fix ensureCorrectApiServer() method in HomeView.vue
- "Use Local" button now sets proper localhost address
**Fix Settings Cache Issues**
- Add PlatformServiceMixin to AccountViewView.vue
- Disable settings caching to prevent stale data
- Settings changes now apply immediately without browser refresh
## Impact
**Tradeoffs:**
- Lost: ~2x SharedArrayBuffer database performance
- Gained: Universal image support from any domain
- Result: Better user experience, database still fast via IndexedDB
**Files Modified:**
- Configuration: vite.config.*.mts, index.html, .env.development
- Source: constants/app.ts, libs/util.ts, views/*.vue, utils/PlatformServiceMixin.ts
## Rationale
For a community platform, universal image support is more critical than marginal
database performance gains. Users share images from arbitrary websites, making
CORS restrictions incompatible with Time Safari's core mission.
- Replace any type assertions with proper type definitions
- Add null safety with fallback values for undefined fields
- Improve error handling with type-safe string assignments
- Use JSON.stringify for non-string error objects
- Maintain runtime compatibility while improving type safety
Files changed:
- src/views/DIDView.vue: Fix claim type assertions and error handling
- src/views/ContactsView.vue: Fix registration payload and catch block typing
- Fix EntityIcon.vue to import blank-square.svg as module instead of using relative path
- Update template to use imported SVG path for proper Electron compatibility
- Make contact prop optional in EntityIcon component to fix TypeScript error
- Add proper Settings type imports and method signatures in PlatformServiceMixin.ts
- Replace console statements with logger calls across multiple files
- Resolves SVG loading failures in Electron builds while maintaining web compatibility
- Reduces TypeScript 'any' type warnings from 81 to 53
- Reduce migration/platform logging verbosity in development mode (~80-90% less noise)
- Fix AbsurdSQL platform check to support 'development' alongside 'web'
- Add missing WebPlatformService methods (isWorker, initSharedArrayBuffer)
- Fix Electron API endpoint resolution to prevent JSON parsing errors
- Prevent circular database logging that caused [DB-PREVENTED-INFO] spam
Console now shows only essential information while preserving all errors/warnings
- Applied transformImageUrlForCors to all image-displaying components
- Added followRedirects: true to image proxy to serve actual content
- Proxy now returns 200 OK with image data instead of 301 redirects
- Maintains CORS headers required for SharedArrayBuffer support
- Added debug logging for proxy response monitoring
Resolves all image loading failures in development environment.
- TopMessage: Replace 50+ lines of settings logic with single () call
- HomeView: Replace databaseUtil calls with () and ()
- Remove unused imports (MASTER_SETTINGS_KEY, databaseUtil) from HomeView
- Settings updates now use automatic cache invalidation for performance
- Reduce settings boilerplate by 80-90% with cached shortcuts
- Add (), (), () for shortest possible database calls
- Add (), () for query+mapping combinations
- Add (), (), () specialized shortcuts
- Apply TypeScript declaration merging to eliminate type assertions
- Reduce HomeView database calls from 3 lines to 1 line (64% reduction)
- Convert settings loading from 6 lines to 4 lines (44% reduction)
- Replace all (this as any) type assertions with proper typing
- Implement worker-only database access to eliminate double migrations
- Add parameter serialization in usePlatformService to prevent Capacitor "object could not be cloned" errors
- Fix infinite logging loop with circuit breaker in databaseUtil
- Use dynamic imports in WebPlatformService to prevent worker thread errors
- Add higher-level database methods (getContacts, getSettings) to composable
- Eliminate Vue Proxy objects through JSON serialization and Object.freeze protection
Resolves Proxy(Array) serialization failures and worker context conflicts across Web/Capacitor/Electron platforms.
- Add comprehensive IndexedDB to SQLite migration service (1,397 lines)
- Create migration UI with progress tracking and validation (1,492 lines)
- Fix Electron TypeScript compilation and SQLite plugin issues
- Expand migration system with detailed documentation and error handling
- Add development guide and coding standards
Resolves: #electron-startup #database-migration #typescript-errors
Impact: Enables user-friendly database migration with full data verification
- Enhanced migration service error handling and logging
- Added better recovery mechanisms for failed migrations
- Improved database state validation before migration execution
- Added comprehensive error reporting in migration service
- Updated HomeView to handle migration errors gracefully
- Fixed database initialization sequence to prevent constraint violations
This addresses UNIQUE constraint failed errors during app startup
and provides better user feedback during database migration issues.
Code formatting improvements across multiple files:
1. databaseUtil.ts:
- Convert single quotes to double quotes for string literals
- Maintain consistency with project style guidelines
2. CapacitorPlatformService.ts:
- Convert single quotes to double quotes for string literals
- Align with TypeScript formatting standards
3. NewEditProjectView.vue:
- Improve code formatting for error handling lambda
- Better readability with proper line breaks and indentation
These changes improve code consistency and readability without
affecting functionality. All changes follow project style guidelines.
- Added Electron dependencies to package.json:
* @capacitor-community/electron ^5.0.1
* electron-builder ^26.0.12
* better-sqlite3-multiple-ciphers ^12.1.1
* electron-json-storage ^4.6.0
- Added Electron development scripts:
* electron:dev - Build and run Electron in development mode
* electron:setup - Initialize Electron environment
* electron:dev-full - Full development workflow script
- Updated .gitignore to exclude sql-wasm.wasm file
- Updated package-lock.json with new dependency resolutions
Note: Main app source files (router, platform service, views) also
have minor modifications from previous development work
- Fix TypeScript compilation errors in platform services
- Add missing rotateCamera method and isNativeApp property
- Fix index.html path resolution for packaged Electron apps
- Create separate Vite config for Electron renderer process
- Migrate from nostr-tools to @nostr/tools via JSR for ESM compatibility
- Update all Vite configs to handle mixed npm/JSR package management
- Add comprehensive documentation in BUILDING.md
- Fix preload script path resolution in packaged builds
Resolves build failures with deep imports and missing UI in AppImage.
- Add name, description, and agent as optional properties to GenericVerifiableCredential
- Improve type safety and IntelliSense for common claim properties
- Maintain backward compatibility with existing code
- Reduce need for type assertions when accessing claim properties
- Restore runMigrations functionality for database schema migrations
- Remove indexedDBMigrationService.ts (was for IndexedDB to SQLite migration)
- Recreate migrationService.ts and db-sql/migration.ts for schema management
- Add proper TypeScript error handling with type guards in AccountViewView
- Fix CreateAndSubmitClaimResult property access in QuickActionBvcBeginView
- Remove LeafletMouseEvent from Vue components array (it's a type, not component)
- Add null check for UserNameDialog callback to prevent undefined assignment
- Implement extractErrorMessage helper function for consistent error handling
- Update router to remove database-migration route
The migration system now properly handles database schema evolution
across app versions, while the IndexedDB to SQLite migration service
has been removed as it was specific to that one-time migration.