mirror of
https://github.com/zadam/trilium.git
synced 2025-12-29 18:54:29 +01:00
chore(icon_pack): map woff attachment
This commit is contained in:
parent
5ad7323d03
commit
d121de5152
@ -45,4 +45,19 @@ describe("Mapping attachments", () => {
|
||||
const attachment = determineBestFontAttachment(iconPackNote);
|
||||
expect(attachment?.mime).toStrictEqual("font/woff2");
|
||||
});
|
||||
|
||||
it("handles woff", () => {
|
||||
const iconPackNote = buildNote({
|
||||
type: "text",
|
||||
attachments: [
|
||||
{
|
||||
role: "file",
|
||||
title: "Font",
|
||||
mime: "font/woff"
|
||||
}
|
||||
]
|
||||
});
|
||||
const attachment = determineBestFontAttachment(iconPackNote);
|
||||
expect(attachment?.mime).toStrictEqual("font/woff");
|
||||
});
|
||||
});
|
||||
|
||||
@ -3,7 +3,8 @@ import type BNote from "../becca/entities/bnote";
|
||||
import log from "./log";
|
||||
|
||||
const PREFERRED_MIME_TYPE = [
|
||||
"font/woff2"
|
||||
"font/woff2",
|
||||
"font/woff"
|
||||
];
|
||||
|
||||
export interface IconPackManifest {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user