mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-03 15:07:42 +02:00
Transfer to @napi-rs/canvas again (this time w/ line breaks)
This commit is contained in:
+1
-5
@@ -34,11 +34,7 @@ module.exports = class FontArgument extends Argument {
|
||||
});
|
||||
if (found.size === 0) return null;
|
||||
if (found.size === 1) return found.first();
|
||||
const foundExact = found.filter(font => {
|
||||
if (font.name.toLowerCase() === choice) return true;
|
||||
if (font.filenameNoExt.toLowerCase() === choice) return true;
|
||||
return false;
|
||||
});
|
||||
const foundExact = found.filter(font => font.filenameNoExt.toLowerCase() === choice);
|
||||
if (foundExact.size === 1) return foundExact.first();
|
||||
return null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user