Skip to content

Conversation

@saifsultanc
Copy link
Contributor

Context

⛑️ Ticket(s): https://secure.helpscout.net/conversation/3060906774/88732

Summary

Enable search input in the country code dropdown.

@coderabbitai
Copy link

coderabbitai bot commented Sep 10, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

Adds a JavaScript snippet that hooks into Gravity Perks Advanced Phone Field’s intl-tel-input options via a gform filter to enable country search by setting options.countrySearch = true.

Changes

Cohort / File(s) Summary
Advanced Phone Field country search
gp-advanced-phone-field/gpapf-enable-country-search.js
New snippet registers gform.addFilter('gpapf_intltelinput_options', ...) to set options.countrySearch = true and return the modified options. Includes usage header comments.

Sequence Diagram(s)

sequenceDiagram
    participant GF as Gravity Forms
    participant APF as Advanced Phone Field (intl-tel-input)
    participant Snip as Snippet (gpapf-enable-country-search)

    GF->>APF: Initialize IntlTelInput with default options
    APF->>Snip: gpapf_intltelinput_options(options, formId, fieldId, instance)
    activate Snip
    Snip->>Snip: options.countrySearch = true
    Snip-->>APF: return options
    deactivate Snip
    APF-->>GF: IntlTelInput initialized with countrySearch enabled
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Suggested reviewers

  • veryspry

Tip

👮 Agentic pre-merge checks are now available in preview!

Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.

  • Built-in checks – Quickly apply ready-made checks to enforce title conventions, require pull request descriptions that follow templates, validate linked issues for compliance, and more.
  • Custom agentic checks – Define your own rules using CodeRabbit’s advanced agentic capabilities to enforce organization-specific policies and workflows. For example, you can instruct CodeRabbit’s agent to verify that API documentation is updated whenever API schema files are modified in a PR. Note: Upto 5 custom checks are currently allowed during the preview period. Pricing for this feature will be announced in a few weeks.

Example:

reviews:
  pre_merge_checks:
    custom_checks:
      - name: "Undocumented Breaking Changes"
        mode: "warning"
        instructions: |
          Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).

Please share your feedback with us on this Discord post.


📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between e5ae702 and d69f115.

📒 Files selected for processing (1)
  • gp-advanced-phone-field/gpapf-enable-country-search.js (1 hunks)
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch saif/add/88732-enable-country-search

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@saifsultanc saifsultanc merged commit 6239a9e into master Sep 10, 2025
1 of 3 checks passed
@saifsultanc saifsultanc deleted the saif/add/88732-enable-country-search branch September 10, 2025 05:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants