Skip to content

Commit

Permalink
Show invalid URL message when link validity is broken.
Browse files Browse the repository at this point in the history
Prior to this the text field would turn red, but the "Not a valid URL"
message did not appear to the user.
  • Loading branch information
bjhess committed Nov 22, 2024
1 parent fc4e989 commit f7ad92b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/exports/elements/tip-tap-editor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,7 @@ export class TipTapEditor extends TipTapEditorBase {
} catch (error) {
inputElement.setCustomValidity("Not a valid URL");
this.__invalidLink__ = true;
inputElement.reportValidity();
return;
}

Expand Down

0 comments on commit f7ad92b

Please sign in to comment.