TextMate-style syntax highlighting in PHP
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

317 lines
8.1 KiB

{
"key": "links",
"patterns": [
{
"name": "reference.footnote.link.markup.md",
"match": "((?:\\[\\^)(?:[^\\[\\]]+)(?:\\]))(?!:)",
"captures": {
"1": {
"patterns": [
{
"include": "#link-label"
}
]
}
}
},
{
"name": "definition.footnote.link.markup.md",
"match": "((?:\\[\\^)(?:[^\\[\\]]+)(?:\\]))(:)",
"captures": {
"1": {
"patterns": [
{
"include": "#link-label"
}
]
},
"2": {
"name": "punctuation.md"
}
}
},
{
"name": "link.markup.md",
"match": "(?x) ( (?:\\[) (?: (?: (?:!\\[) (?:[^\\[\\]]*) (?:\\]) ) (?:\\() (?:[^ [:cntrl:]]+)? (?: (?:\\s+) (?: (?:[\"'\\(]) .*? (?:[\"'\\)]) ) (?:\\s*) )? (?:\\)) (?:\\{[[:ascii:]]*\\})? ) (?:\\]) ) (\\() ([^ [:cntrl:]]+)? (?: (?:\\s+) ( (?:[\"'\\(]) .*? (?:[\"'\\)]) ) (?:\\s*) )? (\\)) (\\{[^}]*\\})?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-text"
}
]
},
"2": {
"name": "punctuation.md"
},
"3": {
"patterns": [
{
"include": "#link-destination"
}
]
},
"4": {
"patterns": [
{
"include": "#link-title"
}
]
},
"5": {
"name": "punctuation.md"
},
"6": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"name": "link.markup.md",
"match": "(?x) ( (?:!?\\[) (?:[^\\[\\]]*) (?:\\]) ) (\\() ([^ [:cntrl:]()]+)? (?: (?:\\s+) ( (?:[\"'\\(]) .*? (?:[\"'\\)]) ) (?:\\s*) )? (\\)) (\\{[^}]*\\})?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-text"
}
]
},
"2": {
"name": "punctuation.md"
},
"3": {
"patterns": [
{
"include": "#link-destination"
}
]
},
"4": {
"patterns": [
{
"include": "#link-title"
}
]
},
"5": {
"name": "punctuation.md"
},
"6": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"name": "link.markup.md",
"match": "(?x) ( (?:!?\\[) (?:[^\\[\\]]*) (?:\\]) ) (\\() (<[^[:cntrl:]]*>) (?: (?:\\s+) ( (?:[\"'\\(]) .*? (?:[\"'\\)]) ) (?:\\s*) )? (\\)) (\\{[^}]*\\})?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-text"
}
]
},
"2": {
"name": "punctuation.md"
},
"3": {
"patterns": [
{
"include": "#link-destination"
}
]
},
"4": {
"patterns": [
{
"include": "#link-title"
}
]
},
"5": {
"name": "punctuation.md"
},
"6": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"name": "link.markup.md",
"match": "(?x) ( (?:\\[) (?: (?: (?:!\\[) (?:[^\\[\\]]*) (?:\\]) ) (?:\\() (?:[^ [:cntrl:]]+)? (?: (?:\\s+) (?: (?:[\"'\\(]) .*? (?:[\"'\\)]) ) (?:\\s*) )? (?:\\)) (?:\\{[[:ascii:]]*\\})? ) (?:\\]) ) ( (?:\\[) (?:[^\\[\\]]*) (?:\\]) ) (\\{[^}]*\\})?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-text"
}
]
},
"2": {
"patterns": [
{
"include": "#link-label"
}
]
},
"3": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"name": "link.markup.md",
"match": "(?x) ( (?:!?\\[) (?:[^\\[\\]]*) (?:\\]) ) ( (?:\\[) (?:[^\\[\\]]*) (?:\\]) ) (\\{[^}]*\\})?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-text"
}
]
},
"2": {
"patterns": [
{
"include": "#link-label"
}
]
},
"3": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"name": "link.markup.md",
"match": "(?x) ( (?:!\\[) (?:[^\\[\\]]*) (?:\\]) ) (\\{[^}]*\\})?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-text"
}
]
},
"2": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"name": "reference.link.markup.md",
"match": "(?x) ((?:\\[)(?:[^\\[\\]]*)(?:\\])) (:) (?:\\s) ([^ [:cntrl:]]+) (?:(?:\\s)((?:\")(?:.*?)(?:\")))? (?:(?:\\s)(\\{[[:ascii:]]*\\}))?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-label"
}
]
},
"2": {
"name": "punctuation.md"
},
"3": {
"patterns": [
{
"include": "#link-destination"
}
]
},
"4": {
"patterns": [
{
"include": "#link-title"
}
]
},
"5": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"match": "(?x) ( (?:\\[) (?:[^\\[\\]]*) (?:\\]) ) (?!:) (\\{[^}]*\\})?",
"captures": {
"1": {
"patterns": [
{
"include": "#link-label"
}
]
},
"2": {
"patterns": [
{
"include": "#special-attributes"
}
]
}
}
},
{
"name": "auto.link.markup.md",
"match": "(?i:(<)((coap|doi|javascript|aaa|aaas|about|acap|cap|cid|crid|data|dav|dict|dns|file|ftp|geo|go|gopher|h323|http|https|iax|icap|im|imap|info|ipp|iris|iris.beep|iris.xpc|iris.xpcs|iris.lwz|ldap|mailto|mid|msrp|msrps|mtqp|mupdate|news|nfs|ni|nih|nntp|opaquelocktoken|pop|pres|rtsp|service|session|shttp|sieve|sip|sips|sms|snmp|soap.beep|soap.beeps|tag|tel|telnet|tftp|thismessage|tn3270|tip|tv|urn|vemmi|ws|wss|xcon|xcon-userid|xmlrpc.beep|xmlrpc.beeps|xmpp|z39.50r|z39.50s|adiumxtra|afp|afs|aim|apt|attachment|aw|beshare|bitcoin|bolo|callto|chrome|chrome-extension|com-eventbrite-attendee|content|cvs|dlna-playsingle|dlna-playcontainer|dtn|dvb|ed2k|facetime|feed|finger|fish|gg|git|gizmoproject|gtalk|hcp|icon|ipn|irc|irc6|ircs|itms|jar|jms|keyparc|lastfm|ldaps|magnet|maps|market|message|mms|ms-help|msnim|mumble|mvn|notes|oid|palm|paparazzi|platform|proxy|psyc|query|res|resource|rmi|rsync|rtmp|secondlife|sftp|sgn|skype|smb|soldat|spotify|ssh|steam|svn|teamspeak|things|udp|unreal|ut2004|ventrilo|view-source|webcal|wtai|wyciwyg|xfire|xri|ymsgr):(?:[^ [:cntrl:]<>]+))(>))",
"captures": {
"1": {
"name": "punctuation.md"
},
"2": {
"name": "markup.underline.link"
},
"4": {
"name": "punctuation.md"
}
}
},
{
"name": "email.auto.link.markup.md",
"match": "(<)(([a-zA-Z0-9\\.!#$%&'\\*\\+/=?^_`{\\|}~-]+)(@)([a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*))(>)",
"captures": {
"1": {
"name": "punctuation.md"
},
"2": {
"name": "markup.underline.link"
},
"4": {
"name": "punctuation.md"
},
"6": {
"name": "punctuation.md"
}
}
}
]
}