mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-24 12:19:20 +00:00
@@ -18,6 +18,8 @@ function getKnownVariableNames() {
|
||||
return knownVariables;
|
||||
}
|
||||
|
||||
const iconVariable = /^--vscode-icon-.+-(content|font-family)$/;
|
||||
|
||||
export interface IValidator {
|
||||
(value: string, report: (message: string) => void): void;
|
||||
}
|
||||
@@ -29,7 +31,7 @@ export function getVariableNameValidator(): IValidator {
|
||||
let match;
|
||||
while (match = RE_VAR_PROP.exec(value)) {
|
||||
const variableName = match[1];
|
||||
if (variableName && !allVariables.has(variableName)) {
|
||||
if (variableName && !allVariables.has(variableName) && !iconVariable.test(variableName)) {
|
||||
report(variableName);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user