Skip to content

Google location link is being cut off and placed in a new line #6216

Closed

Description

@isagoico

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Action Performed:

  1. Log in to e.cash and navigate to a conversation
  2. Paste and send this link
    https://www.google.com/maps/place/Poster+Auctions+International,+Inc./@40.7384572,-73.9942151,20.17z/data=!4m13!1m7!3m6!1s0x89c259a2c5fdee77:0x1439488db9133bae!2s26+W+17th+St,+New+York,+NY+10011!3b1!8m2!3d40.7383679!4d-73.993907!3m4!1s0x89c259a2c438eb63:0x115ba65a3675338b!8m2!3d40.7384793!4d-73.9937764
  3. Notice that the links are cut off after the colon and therefore don't hyperlink correctly.

Expected Result:

Link should be rendered without any breaks.

Actual Result:

Link is cut and placed in a new line before the period.

Workaround:

User needs to manually copy and paste the link to be able to navigate to the desired URL.

Platform:

Where is this issue occurring?

  • Web
  • iOS
  • Android
  • Desktop App
  • Mobile Web

Version Number: 1.1.13-0

Reproducible in staging?: Yes
Reproducible in production?: Yes

Logs: https://stackoverflow.com/c/expensify/questions/4856

Notes/Photos/Videos: Any additional supporting documentation

This similar issue was already fixed #4105

image

Expensify/Expensify Issue URL:

Issue reported by: @mallenexpensify
Slack conversation: https://expensify.slack.com/archives/C01GTK53T8Q/p1635954172411200

View all open jobs on GitHub

view the job on upwork

Activity

  1. MelvinBot commented on Nov 4, 2021

    @MelvinBot
    Contributor

    Triggered auto assignment to @flodnv (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

  2. changed the title [-]Google location link is being cut off and places in a new line before a Period[/-] [+]Google location link is being cut off and placed in a new line[/+] on Nov 4, 2021
  3. mateusbra commented on Nov 6, 2021

    @mateusbra
    Contributor

    First of all, I don't think its being "cut and placed in a new line", the main problem here is that the regex doesn't matches with some characteres( . , = ( + $ ! * ) right before /, we can reproduce this problem putting any of those characteres instead of . in the url
    -\w~@:%)

    E.G.:
    Input:
    https://www.google.com/maps/place/Poster+Auctions+International,+Inc./test
    Will match with:
    https://www.google.com/maps/place/Poster+Auctions+International,+Inc
    Ignoring all the rest of the link

    If this could be external I would like to fix this issue:

    PROPOSAL

    We have to add support to . and all the others characteres to the regex:
    At ExpensiMark.js we have to change URL_PATH_REGEX

    https://github.com/Expensify/expensify-common/blob/e6ba00d53b8119fa0e641ed1544257ac4bcb9aec/lib/ExpensiMark.js#L6-L10

    We will have:

    const URL_PATH_REGEX = `(?:\\/${addEscapedChar('[-\\w$@.+!*:(),=%~]')}*${addEscapedChar('[-\\w$@.+!*:%$(),=~]')}|\\/)*`;

    This way we guarantee any url will match with our REGEX even with thoses characteres in the end of the link, like what Github does.

  4. mateusbra commented on Nov 6, 2021

    @mateusbra
    Contributor

    Test with code changes:

    WhatsApp Image 2021-11-06 at 02 05 01

  5. removed their assignment
    on Nov 8, 2021
  6. added
    ExternalAdded to denote the issue can be worked on by a contributor
    on Nov 8, 2021
  7. MelvinBot commented on Nov 8, 2021

    @MelvinBot
    Contributor

    Triggered auto assignment to @jboniface (External), see https://stackoverflow.com/c/expensify/questions/8582 for more details.

  8. 7 remaining items

  9. removed
    Help WantedApply this label when an issue is open to proposals by contributors
    on Nov 8, 2021
  10. mateusbra commented on Nov 8, 2021

    @mateusbra
    Contributor

    @mateusbra I think your solution sounds good! Go ahead, @jboniface will be in charge of sending you the job in upwork.

    Proposal posted in upwork! Once it be accepted I'll rise the PR.

  11. mateusbra commented on Nov 11, 2021

    @mateusbra
    Contributor

    job here https://www.upwork.com/jobs/~011cb863d1e0871604

    @jboniface have you seen my proposal in upwork?

  12. mallenexpensify commented on Nov 12, 2021

    @mallenexpensify
    Contributor

    Hired "Matheus B" in Upwork! @mateusbra, when do you expect to have a PR submitted?

  13. mateusbra commented on Nov 12, 2021

    @mateusbra
    Contributor

    @mallenexpensify PR submitted!

  14. botify commented on Nov 16, 2021

    @botify

    @pecanoro @jboniface Be sure to fill out the Contact List!

  15. mateusbra commented on Nov 18, 2021

    @mateusbra
    Contributor

    @mallenexpensify when do you expect this job to be payed in UpWork?

  16. pecanoro commented on Nov 18, 2021

    @pecanoro
    Contributor

    @mateusbra We wait 7 days to check out for regressions. It is mentioned in the contributor's guidelines.

    Anyways, going to reopen since I think Botify closed it too fast and we still need to handle payment. cc/ @jboniface

  17. mateusbra commented on Nov 25, 2021

    @mateusbra
    Contributor

    @mateusbra We wait 7 days to check out for regressions. It is mentioned in the contributor's guidelines.

    Anyways, going to reopen since I think Botify closed it too fast and we still need to handle payment. cc/ @jboniface

    Do you think payment could be done? PR was merged has 10 days

  18. dylanexpensify commented on Nov 29, 2021

    @dylanexpensify
    Contributor

    @mateusbra I can handle payment today! Thanks for your patience and sorry about that!

  19. dylanexpensify commented on Nov 29, 2021

    @dylanexpensify
    Contributor

    @mateusbra payment sent, contract closed!

  20. botify commented on Nov 29, 2021

    @botify

    @pecanoro @jboniface Be sure to fill out the Contact List!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

EngineeringExternalAdded to denote the issue can be worked on by a contributorWeeklyKSv2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions