Restructure Android project from nested module layout to standard
Capacitor plugin structure following community conventions.
Structure Changes:
- Move plugin code from android/plugin/ to android/src/main/java/
- Move test app from android/app/ to test-apps/android-test-app/app/
- Remove nested android/plugin module structure
- Remove nested android/app test app structure
Build Infrastructure:
- Add Gradle wrapper files (gradlew, gradlew.bat, gradle/wrapper/)
- Transform android/build.gradle from root project to library module
- Update android/settings.gradle for standalone plugin builds
- Add android/gradle.properties with AndroidX configuration
- Add android/consumer-rules.pro for ProGuard rules
Configuration Updates:
- Add prepare script to package.json for automatic builds on npm install
- Update package.json version to 1.0.1
- Update android/build.gradle to properly resolve Capacitor dependencies
- Update test-apps/android-test-app/settings.gradle with correct paths
- Remove android/variables.gradle (hardcode values in build.gradle)
Documentation:
- Update BUILDING.md with new structure and build process
- Update INTEGRATION_GUIDE.md to reflect standard structure
- Update README.md to remove path fix warnings
- Add test-apps/BUILD_PROCESS.md documenting test app build flows
Test App Configuration:
- Fix android-test-app to correctly reference plugin and Capacitor
- Remove capacitor-cordova-android-plugins dependency (not needed)
- Update capacitor.settings.gradle path verification in fix script
BREAKING CHANGE: Plugin now uses standard Capacitor Android structure.
Consuming apps must update their capacitor.settings.gradle to reference
android/ instead of android/plugin/. This is automatically handled by
Capacitor CLI for apps using standard plugin installation.
- Add null safety check to permission callback to prevent NPE
- Fix fetch time calculation bug that caused double subtraction
- scheduleFetch() now accepts pre-calculated fetchTime directly
- Calculate scheduledTime back from fetchTime for worker data
- Add structured logging (DN|FETCH_SCHEDULING) for better traceability
The permission callback was crashing with NullPointerException when
Capacitor passed a null call parameter. The prefetch scheduling had a
logic error where fetchTime was calculated twice - once in the plugin
and once in the fetcher, causing 10-minute delays instead of 5-minute.
Both issues are now fixed and verified working:
- Permission callback handles null gracefully
- Prefetch schedules correctly 5 minutes before notification
- WorkManager job fires at the correct time
- All structured logs appear in logcat
Closes prefetch scheduling investigation.
- Add requestPermissions method alias to fix Vue app compatibility
- Fix permission response format to include both string and boolean values
- Add comprehensive debugging for permission request flow
- Implement permission request throttling to prevent app crashes
- Fix capacitor.settings.gradle plugin path configuration
- Enhance Vue app logging for permission status debugging
Resolves permission dialog not appearing and UI showing incorrect status.
All permission functionality now works end-to-end with proper status updates.
- Add AAR Duplicate Class Issues section to BUILDING.md with step-by-step solutions
- Create dedicated docs/aar-integration-troubleshooting.md with complete troubleshooting guide
- Document project reference approach (recommended) vs AAR-only approach
- Add verification steps, prevention strategies, and best practices
- Update README.md with links to new documentation
- Resolve duplicate class issues through proper project reference configuration
Fixes AAR integration issues that caused build failures due to plugin being
included both as project reference and AAR file simultaneously.
- Fix plugin path in capacitor.settings.gradle to point to correct npm package location
- Remove duplicate local dailynotification module causing class conflicts
- Remove duplicate plugin dependency from app build.gradle
- Resolves Android SDK configuration and build system issues
Build now succeeds with proper plugin integration from npm package.
- Update package.json with modern build tooling and dependencies
- Streamline and enhance TypeScript definitions for better type safety
- Reorganize plugin structure for better maintainability
- Add comprehensive interface definitions for notification features
- Implement proper build configuration with rollup
- Update tsconfig.json for stricter type checking and ES2020 modules
Breaking Changes:
- Changed module structure to use ES modules
- Updated interface definitions with stricter typing
- Removed redundant notification options
- Simplified API surface while maintaining core functionality
Dependencies:
- Upgrade @capacitor dependencies to v5.7.8
- Add rollup and typescript build tools
- Update test framework configuration
- Add build scripts for Android and iOS platforms
- Remove duplicate web implementation (src/web.ts)
- Add proper TypeScript configuration
- Add module documentation to index.ts
- Clean up package.json scripts
This commit improves the project structure and build process by:
1. Adding dedicated build scripts for native platforms
2. Removing redundant web implementation
3. Adding proper TypeScript configuration with strict mode
4. Improving code documentation
5. Organizing package.json scripts
The changes maintain backward compatibility while improving
the development experience and code quality.