Doesn't allow route for e.g. "/profile" as href.

The link dialog uses a standard <input type="url"> along with its default constraints (requiring an absolute URL). Absolute URLs make the resulting HTML more portable so I don't think we'll change anything to allow relative paths by default, but you could do so in your app. Here's an example:
addEventListener("trix-initialize", event => {
const { toolbarElement } = event.target
const inputElement = toolbarElement.querySelector("input[name=href]")
inputElement.type = "text"
inputElement.pattern = "(https?://|/).+"
})
Most helpful comment
The link dialog uses a standard
<input type="url">along with its default constraints (requiring an absolute URL). Absolute URLs make the resulting HTML more portable so I don't think we'll change anything to allow relative paths by default, but you could do so in your app. Here's an example: