Skip to content

Comments

Clean up example app and release v1.0.0#15

Merged
mlaucis merged 4 commits intomainfrom
fix-notification-tap-payload
Jun 17, 2025
Merged

Clean up example app and release v1.0.0#15
mlaucis merged 4 commits intomainfrom
fix-notification-tap-payload

Conversation

@mlaucis
Copy link
Member

@mlaucis mlaucis commented Jun 17, 2025

Filter FCM metadata from notification tap payloads, clean up example app, and bump to v1.0.0 stable release.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jun 17, 2025

📝 Walkthrough

Summary by CodeRabbit

  • New Features
    • Added a new navigation route for the profile page, accessible via deep link.
  • Refactor
    • Simplified app state management and centralized SDK initialization for a cleaner user experience.
    • Streamlined the UI to focus on notification status and payload display.
    • Renamed the main screen and updated related class names for clarity.
  • Documentation
    • Updated the README and changelog to focus on stable release information and direct users to external examples.
  • Chores
    • Updated version numbers to reflect the stable 1.0.0 release.

Summary by CodeRabbit

  • New Features
    • Added navigation to a new profile page accessible via deep link.
  • Improvements
    • Simplified notification state management and streamlined the main page UI to focus on notification status and payload display.
    • Centralized SDK initialization for a smoother startup experience.
  • Bug Fixes
    • Improved intent handling to ignore specific system keys in notification payloads.
  • Chores
    • Updated versioning to 1.0.0 stable and simplified the changelog to reflect only the initial stable release.

Walkthrough

The changes transition the project from a development phase to a stable release by updating version identifiers, simplifying the changelog, refining notification payload handling in the Android plugin, and streamlining the example app's initialization, state management, and UI. The intent extras filtering logic is enhanced, and the example app's structure is modernized.

Changes

File(s) Change Summary
CHANGELOG.md Removed all development version entries; retained only the stable 1.0.0 release note.
pubspec.yaml, lib/src/version.dart Updated version from 1.0.0-dev.5 to 1.0.0.
android/src/main/kotlin/.../PntaFlutterPlugin.kt Modified onNewIntent to filter out intent extras with keys starting with "google.", "gcm.", or specific keys.
example/lib/main.dart Centralized and simplified SDK initialization, renamed widgets, redesigned UI, and added a new route.

Sequence Diagram(s)

sequenceDiagram
    participant AppMain as main()
    participant PntaFlutter as PntaFlutter SDK
    participant HomePage as HomePage Widget

    AppMain->>PntaFlutter: initialize(projectId, userMetadata, config)
    AppMain->>HomePage: runApp(MyApp)
    HomePage->>PntaFlutter: Listen for notifications
    PntaFlutter-->>HomePage: onNotificationReceived(payload)
    HomePage->>HomePage: Update _lastNotification
    HomePage->>UI: Display notification payload and status
Loading

Possibly related PRs


🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Nitpick comments (2)
CHANGELOG.md (1)

1-3: Consider preserving dev-build history
Stripping pre-release entries makes the file concise, but you lose a traceable audit of changes between dev builds. You may want to append rather than replace to retain that history.

android/src/main/kotlin/io/pnta/pnta_flutter/PntaFlutterPlugin.kt (1)

137-139: Broaden numeric type handling
Instead of enumerating every primitive, treating all Number sub-classes in one clause is safer and future-proof:

-        when (value) {
-          is String, is Int, is Boolean, is Double, is Float, is Long -> payload[key] = value
+        when (value) {
+          is String, is Boolean -> payload[key] = value
+          is Number            -> payload[key] = value
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 027b780 and a8add26.

⛔ Files ignored due to path filters (1)
  • example/pubspec.lock is excluded by !**/*.lock
📒 Files selected for processing (5)
  • CHANGELOG.md (1 hunks)
  • android/src/main/kotlin/io/pnta/pnta_flutter/PntaFlutterPlugin.kt (2 hunks)
  • example/lib/main.dart (1 hunks)
  • lib/src/version.dart (1 hunks)
  • pubspec.yaml (1 hunks)
🧰 Additional context used
🪛 GitHub Actions: CI
example/lib/main.dart

[error] 1-1: dart format check failed. The file was changed by the formatter, indicating formatting issues. Run 'dart format .' to fix code style.

🔇 Additional comments (3)
lib/src/version.dart (1)

3-3: Version bump looks correct and consistent
The constant now matches the stable 1.0.0 release. No other action required.

pubspec.yaml (1)

3-3: Remember to publish the tag after changing version:
Everything else in the manifest remains untouched, so a straight flutter pub publish --dry-run should succeed.

android/src/main/kotlin/io/pnta/pnta_flutter/PntaFlutterPlugin.kt (1)

145-145: Confirm intent propagation policy
Returning false lets other plugins / the activity keep handling the intent. Double-check that no downstream component relies on seeing the raw FCM extras (now stripped) before deciding to continue.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
README.md (1)

298-300: Enhance link to example app
Consider making the example/ folder reference a clickable relative link (e.g., [example/](./example/) or linking directly to example/README.md) to improve discoverability and navigation.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f733f4a and d3855a4.

📒 Files selected for processing (1)
  • README.md (2 hunks)
🔇 Additional comments (1)
README.md (1)

20-20: ToC entry update looks good
The new Example entry correctly replaces the old inline sections and aligns with the consolidated Example section below.

@mlaucis mlaucis merged commit 674fd34 into main Jun 17, 2025
2 checks passed
@mlaucis mlaucis deleted the fix-notification-tap-payload branch June 17, 2025 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant