Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Phone inputs should expose dialcode in the formdata value automatically #34744

Open
1 task done
leonlazic opened this issue Jul 5, 2024 · 2 comments
Open
1 task done
Assignees
Labels
App Viewers Pod This label assigns issues to the app viewers pod Bug Something isn't working Cloud Community Reported issues reported by community members Medium Issues that frustrate users due to poor UX Needs Triaging Needs attention from maintainers to triage Phone Input Widget Issues related to the Phone Input widget Production

Comments

@leonlazic
Copy link

leonlazic commented Jul 5, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Description

I noticed this behaviour when I put a phone number input widget inside a Form widget. When I try to send with my query and the country code and the dial number I cannot append at the end .dialCode or .text.

I think this should work and I can just bypass the form reference altogether but it seems to me, like it would be better practice to reference anything in the form with Form.widget.specificvalue.

Screenshot

Screenshot
8e2332)

Steps To Reproduce

  1. Put a phone number input into a form widget
  2. Try to extract the dialCode or formatted number from the field by referencing the Form.data.inp_phone.text, Form.data.inp_phone.dialCode
  3. It will not work

Public Sample App

No response

Environment

Production

Severity

Medium (Frustrating UX)

Issue video log

No response

Version

Cloud

@leonlazic leonlazic added Bug Something isn't working Needs Triaging Needs attention from maintainers to triage labels Jul 5, 2024
@Nikhil-Nandagopal Nikhil-Nandagopal added Cloud Community Reported issues reported by community members Medium Issues that frustrate users due to poor UX Production labels Jul 5, 2024
@Nikhil-Nandagopal
Copy link
Contributor

@leonlazic I think the right solution here would be to append the dial code to the start of the input in the form data field.
The form data field is meant to only contain the data entered by the user as a convenient way to send data to a query. So I'm against nesting an object of dial code and country code and other values inside it because it would defeat the purpose of the field and can be accessed from that widget directly.

@Nikhil-Nandagopal Nikhil-Nandagopal changed the title [Bug]: Can't select specific values when the field is in a Form widget [Bug]: Phone inputs should expose dialcode in the formdata value automatically Jul 5, 2024
@Nikhil-Nandagopal Nikhil-Nandagopal added the Phone Input Widget Issues related to the Phone Input widget label Jul 5, 2024
@github-actions github-actions bot added the App Viewers Pod This label assigns issues to the app viewers pod label Jul 5, 2024
@leonlazic
Copy link
Author

I can understand you opinion. Appending the dial code at the start is an okay remedy for keeping everything referenced in the form data field simple.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
App Viewers Pod This label assigns issues to the app viewers pod Bug Something isn't working Cloud Community Reported issues reported by community members Medium Issues that frustrate users due to poor UX Needs Triaging Needs attention from maintainers to triage Phone Input Widget Issues related to the Phone Input widget Production
Projects
None yet
Development

No branches or pull requests

4 participants