Mojira Archive
MC-94800

URL shown in open URL dialog is not shortened

The bug

The URL shown in the "Are you sure you want to open the following website?" dialog is not shortened. This causes for example the warning to unreadable.

How to reproduce

  1. Use the following command
    /tellraw @p {"text":"Link","clickEvent":{"action":"open_url","value":"http://example.com/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"}}
    
  2. Click on the word "Link" in the chat

Expected behaviour

I would expect the link to be shortened to a maximum of two lines making sure that the protocol and domain are visible (and possibly highlighted?), replacing prefix and suffix with "..." if necessary.