Allow /*! in UserCSS metadata. Closes #571
This commit is contained in:
parent
99951efc80
commit
33df061b53
|
@ -12,7 +12,7 @@ function createMetaCompiler(cm) {
|
||||||
if (_cm !== cm) {
|
if (_cm !== cm) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
const match = text.match(/\/\*\s*==userstyle==[\s\S]*?==\/userstyle==\s*\*\//i);
|
const match = text.match(/\/\*\!?\s*==userstyle==[\s\S]*?==\/userstyle==\s*\*\//i);
|
||||||
if (!match) {
|
if (!match) {
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,7 +10,7 @@ const usercss = (() => {
|
||||||
// updateURL: 'updateUrl',
|
// updateURL: 'updateUrl',
|
||||||
name: undefined,
|
name: undefined,
|
||||||
};
|
};
|
||||||
const RX_META = /\/\*\s*==userstyle==[\s\S]*?==\/userstyle==\s*\*\//i;
|
const RX_META = /\/\*\!?\s*==userstyle==[\s\S]*?==\/userstyle==\s*\*\//i;
|
||||||
const ERR_ARGS_IS_LIST = new Set(['missingMandatory', 'missingChar']);
|
const ERR_ARGS_IS_LIST = new Set(['missingMandatory', 'missingChar']);
|
||||||
return {buildMeta, buildCode, assignVars};
|
return {buildMeta, buildCode, assignVars};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user