feedkeeper 0.28.7 → 0.28.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/server/dist/feeds/archive.js +2 -2
- package/server/dist/feeds/imageTypes.js +9 -0
- package/server/dist/setup-cli.js +2 -2
- package/server/package.json +1 -1
- package/web/dist/assets/index-BmomQBBn.js +32 -0
- package/web/dist/assets/index-DXH6vV2v.css +2 -0
- package/web/dist/index.html +2 -2
- package/web/dist/sw.js +8 -3
- package/web/dist/assets/index-BprbGvrl.css +0 -2
- package/web/dist/assets/index-CyPm9mJM.js +0 -32
package/package.json
CHANGED
|
@@ -9,7 +9,7 @@ import { loadFullText } from "./fullText.js";
|
|
|
9
9
|
import { canAccessItem, findItemById, findItemForUser } from "./repository.js";
|
|
10
10
|
import { decodeEntities } from "./text.js";
|
|
11
11
|
import { ImageCache, ImageCacheBusyError } from "./imageCache.js";
|
|
12
|
-
import { detectImageType } from "./imageTypes.js";
|
|
12
|
+
import { detectImageType, isVectorImageUrl } from "./imageTypes.js";
|
|
13
13
|
export { detectImageType } from "./imageTypes.js";
|
|
14
14
|
import { comparableImageKey } from "./heroImage.js";
|
|
15
15
|
const MAX_IMAGES_PER_ARTICLE = 30;
|
|
@@ -325,7 +325,7 @@ function proxiedImageUrl(origin, itemId, imageUrl, apiBase = "/api") {
|
|
|
325
325
|
export function withProxiedImages(items, origin, apiBase = "/api", withContent = true) {
|
|
326
326
|
const own = `${origin.replace(/\/$/, "")}/api/`;
|
|
327
327
|
return items.map((item) => {
|
|
328
|
-
const urls = new Set(itemImageUrls(item).filter((url) => !url.startsWith(own)));
|
|
328
|
+
const urls = new Set(itemImageUrls(item).filter((url) => !url.startsWith(own) && !isVectorImageUrl(url)));
|
|
329
329
|
if (urls.size === 0)
|
|
330
330
|
return item;
|
|
331
331
|
const replace = (url) => (urls.has(url) ? proxiedImageUrl(origin, item.id, url, apiBase) : undefined);
|
|
@@ -13,4 +13,13 @@ export function detectImageType(data) {
|
|
|
13
13
|
return { mime: "image/avif", ext: "avif" };
|
|
14
14
|
return null;
|
|
15
15
|
}
|
|
16
|
+
/** Vector images are never served by the image proxy, so their addresses stay as the publisher wrote them. */
|
|
17
|
+
export function isVectorImageUrl(url) {
|
|
18
|
+
try {
|
|
19
|
+
return new URL(url).pathname.toLowerCase().endsWith(".svg");
|
|
20
|
+
}
|
|
21
|
+
catch {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
16
25
|
//# sourceMappingURL=imageTypes.js.map
|
package/server/dist/setup-cli.js
CHANGED
|
@@ -49,8 +49,8 @@ stdin.on("data", (chunk) => {
|
|
|
49
49
|
line += char;
|
|
50
50
|
if (masked)
|
|
51
51
|
stdout.write("*");
|
|
52
|
-
else
|
|
53
|
-
stdout.write(char); //
|
|
52
|
+
else
|
|
53
|
+
stdout.write(char); // raw mode switches the terminal's own echo off, and piped input has none
|
|
54
54
|
}
|
|
55
55
|
});
|
|
56
56
|
function readLine(question, opts = {}) {
|