Skip to content

Showing first two lines in the button label when address formatting #345

@WebDevTX

Description

@WebDevTX

How can I get the first two lines (name and address1) of the address to appear in the button label but while maintaining the address multiline format in the menu?

ui-selectmenu-item-header is obviously used for the button label, but I cant figure out how to get the first two lines in there w/o loosing the newline for the address.

I'd like it to look like this:

Button:
[ John Doe - 123 Main Street, Suite 100 ]

Menu:
| John Doe
| 123 Main Street, Suite 100
| Somewhere, US 12345
| (footer text)

But so far, I can only manage this (by matching on the first | instead of -):

Button:
[ John Doe - 123 Main Street, Suite 100 ]

Menu:
| John Doe - 123 Main Street, Suite 100
| Somewhere, US 12345
| (footer text)

Or, the normal:

Button:
[ John Doe ]

Menu:
| John Doe
| 123 Main Street, Suite 100
| Somewhere, US 12345
| (footer text)

John Doe could have multiple addresses, and only showing the name in the button doesn't provide enough feedback for what was/is selected

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions