完成世界书、骰子、apiconfig页面处理
This commit is contained in:
43
frontend/node_modules/refractor/lang/clike.js
generated
vendored
Normal file
43
frontend/node_modules/refractor/lang/clike.js
generated
vendored
Normal file
@@ -0,0 +1,43 @@
|
||||
// @ts-nocheck
|
||||
/**
|
||||
* @import {Refractor} from '../lib/core.js'
|
||||
*/
|
||||
clike.displayName = 'clike'
|
||||
clike.aliases = []
|
||||
|
||||
/** @param {Refractor} Prism */
|
||||
export default function clike(Prism) {
|
||||
Prism.languages.clike = {
|
||||
comment: [
|
||||
{
|
||||
pattern: /(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,
|
||||
lookbehind: true,
|
||||
greedy: true
|
||||
},
|
||||
{
|
||||
pattern: /(^|[^\\:])\/\/.*/,
|
||||
lookbehind: true,
|
||||
greedy: true
|
||||
}
|
||||
],
|
||||
string: {
|
||||
pattern: /(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,
|
||||
greedy: true
|
||||
},
|
||||
'class-name': {
|
||||
pattern:
|
||||
/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,
|
||||
lookbehind: true,
|
||||
inside: {
|
||||
punctuation: /[.\\]/
|
||||
}
|
||||
},
|
||||
keyword:
|
||||
/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,
|
||||
boolean: /\b(?:false|true)\b/,
|
||||
function: /\b\w+(?=\()/,
|
||||
number: /\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,
|
||||
operator: /[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,
|
||||
punctuation: /[{}[\];(),.:]/
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user