Locally add prismjs
This commit is contained in:
parent
35af792c6a
commit
6aa044cf9b
701 changed files with 35787 additions and 0 deletions
54
node_modules/prismjs/components/prism-abnf.js
generated
vendored
Normal file
54
node_modules/prismjs/components/prism-abnf.js
generated
vendored
Normal file
|
@ -0,0 +1,54 @@
|
|||
(function (Prism) {
|
||||
|
||||
var coreRules = '(?:ALPHA|BIT|CHAR|CR|CRLF|CTL|DIGIT|DQUOTE|HEXDIG|HTAB|LF|LWSP|OCTET|SP|VCHAR|WSP)';
|
||||
|
||||
Prism.languages.abnf = {
|
||||
'comment': /;.*/,
|
||||
'string': {
|
||||
pattern: /(?:%[is])?"[^"\n\r]*"/,
|
||||
greedy: true,
|
||||
inside: {
|
||||
'punctuation': /^%[is]/
|
||||
}
|
||||
},
|
||||
'range': {
|
||||
pattern: /%(?:b[01]+-[01]+|d\d+-\d+|x[A-F\d]+-[A-F\d]+)/i,
|
||||
alias: 'number'
|
||||
},
|
||||
'terminal': {
|
||||
pattern: /%(?:b[01]+(?:\.[01]+)*|d\d+(?:\.\d+)*|x[A-F\d]+(?:\.[A-F\d]+)*)/i,
|
||||
alias: 'number'
|
||||
},
|
||||
'repetition': {
|
||||
pattern: /(^|[^\w-])(?:\d*\*\d*|\d+)/,
|
||||
lookbehind: true,
|
||||
alias: 'operator'
|
||||
},
|
||||
'definition': {
|
||||
pattern: /(^[ \t]*)(?:[a-z][\w-]*|<[^<>\r\n]*>)(?=\s*=)/m,
|
||||
lookbehind: true,
|
||||
alias: 'keyword',
|
||||
inside: {
|
||||
'punctuation': /<|>/
|
||||
}
|
||||
},
|
||||
'core-rule': {
|
||||
pattern: RegExp('(?:(^|[^<\\w-])' + coreRules + '|<' + coreRules + '>)(?![\\w-])', 'i'),
|
||||
lookbehind: true,
|
||||
alias: ['rule', 'constant'],
|
||||
inside: {
|
||||
'punctuation': /<|>/
|
||||
}
|
||||
},
|
||||
'rule': {
|
||||
pattern: /(^|[^<\w-])[a-z][\w-]*|<[^<>\r\n]*>/i,
|
||||
lookbehind: true,
|
||||
inside: {
|
||||
'punctuation': /<|>/
|
||||
}
|
||||
},
|
||||
'operator': /=\/?|\//,
|
||||
'punctuation': /[()\[\]]/
|
||||
};
|
||||
|
||||
}(Prism));
|
Loading…
Add table
Add a link
Reference in a new issue