When configuring a telephone input with the checkbox "Enhance support for international phone numbers" there is an option to set the initial country to "Auto detect" but this actually does nothing.

To make it work a geoIpLookup function must be specified in Drupal.webform.intlTelInput.options as per the documentation https://github.com/jackocnr/intl-tel-input#options.

Since no such function is described, this should be documented when configuring the telephone element so that people know the option won't do anything unless they specifically add their own custom geoIP function to drupalSettings.

CommentFileSizeAuthor
#3 3069653-3.patch694 bytesjrockowitz
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Rob230 created an issue. See original summary.

Rob230’s picture

Issue summary: View changes
jrockowitz’s picture

Status: Active » Needs review
FileSize
694 bytes

Because the autodetect option requires custom JavaScript configuration. I think we should remove this option from the UI and assume any developer implementing this feature can do so using custom JavaScript.

  • jrockowitz authored 53e3aed on 8.x-5.x
    Issue #3069653 by jrockowitz: "Auto detect" option in telephone input...
jrockowitz’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.