vue-files-preview-inno
Version:
A tool for previewing files such as doc, excel, pdf, image, markdown, txt, audio, and video and so on.
95 lines (94 loc) • 1.82 kB
JavaScript
var a, t;
function i() {
if (t) return a;
t = 1;
function c(s) {
const e = /([A-Za-z_][A-Za-z_0-9]*)?/, n = {
scope: "params",
begin: /\(/,
end: /\)(?=\:?)/,
endsParent: !0,
relevance: 7,
contains: [
{
scope: "string",
begin: '"',
end: '"'
},
{
scope: "keyword",
match: [
"true",
"false",
"in"
].join("|")
},
{
scope: "variable",
match: /[A-Za-z_][A-Za-z_0-9]*/
},
{
scope: "operator",
match: /\+|\-|\*|\/|\%|\=\=|\=|\!|\>|\<|\&\&|\|\|/
}
]
}, o = {
match: [
e,
/(?=\()/
],
scope: {
1: "keyword"
},
contains: [n]
};
return n.contains.unshift(o), {
name: "Leaf",
contains: [
// #ident():
{
match: [
/#+/,
e,
/(?=\()/
],
scope: {
1: "punctuation",
2: "keyword"
},
// will start up after the ending `)` match from line ~44
// just to grab the trailing `:` if we can match it
starts: {
contains: [
{
match: /\:/,
scope: "punctuation"
}
]
},
contains: [
n
]
},
// #ident or #ident:
{
match: [
/#+/,
e,
/:?/
],
scope: {
1: "punctuation",
2: "keyword",
3: "punctuation"
}
}
]
};
}
return a = c, a;
}
export {
i as __require
};
//# sourceMappingURL=leaf.mjs.map