mirror of
https://github.com/YGGverse/Yoda.git
synced 2026-03-31 08:35:28 +00:00
allow empty alt
This commit is contained in:
parent
43f348e9bb
commit
b8b85873ab
1 changed files with 3 additions and 3 deletions
|
|
@ -7,10 +7,10 @@ use gtk::{
|
||||||
use regex::Regex;
|
use regex::Regex;
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
|
|
||||||
const REGEX_LINK: &str = r"\[(?P<text>[^\]]+)\]\((?P<url>[^\)]+)\)";
|
const REGEX_LINK: &str = r"\[(?P<text>[^\]]*)\]\((?P<url>[^\)]+)\)";
|
||||||
const REGEX_IMAGE: &str = r"!\[(?P<alt>[^\]]+)\]\((?P<url>[^\)]+)\)";
|
const REGEX_IMAGE: &str = r"!\[(?P<alt>[^\]]*)\]\((?P<url>[^\)]+)\)";
|
||||||
const REGEX_IMAGE_LINK: &str =
|
const REGEX_IMAGE_LINK: &str =
|
||||||
r"\[(?P<is_img>!)\[(?P<alt>[^\]]+)\]\((?P<img_url>[^\)]+)\)\]\((?P<link_url>[^\)]+)\)";
|
r"\[(?P<is_img>!)\[(?P<alt>[^\]]*)\]\((?P<img_url>[^\)]+)\)\]\((?P<link_url>[^\)]+)\)";
|
||||||
|
|
||||||
struct Reference {
|
struct Reference {
|
||||||
uri: Uri,
|
uri: Uri,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue