Also use sanitized URL for allow_hyperlinks=ask
This commit is contained in:
parent
306f9e5735
commit
468b6fab02
1 changed files with 2 additions and 2 deletions
|
|
@ -52,7 +52,7 @@
|
|||
from .utils import (
|
||||
docs_url, kitty_ansi_sanitizer_pat, load_shaders, log_error, open_cmd, open_url,
|
||||
parse_color_set, path_from_osc7_url, resolve_custom_file, resolved_shell,
|
||||
sanitize_for_bracketed_paste, sanitize_title,
|
||||
sanitize_for_bracketed_paste, sanitize_title, sanitize_url_for_dispay_to_user,
|
||||
)
|
||||
|
||||
MatchPatternType = Union[Pattern[str], Tuple[Pattern[str], Optional[Pattern[str]]]]
|
||||
|
|
@ -858,7 +858,7 @@ def open_url(self, url: str, hyperlink_id: int, cwd: Optional[str] = None) -> No
|
|||
if opts.allow_hyperlinks & 0b10:
|
||||
from kittens.tui.operations import styled
|
||||
get_boss().choose(
|
||||
'What would you like to do with this URL:\n' + styled(unquote(url), fg='yellow'),
|
||||
'What would you like to do with this URL:\n' + styled(sanitize_url_for_dispay_to_user(url), fg='yellow'),
|
||||
partial(self.hyperlink_open_confirmed, url, cwd),
|
||||
'o:Open', 'c:Copy to clipboard', 'n;red:Nothing', default='o',
|
||||
window=self,
|
||||
|
|
|
|||
Loading…
Reference in a new issue