diff --git a/src/file-viewer/rules.ts b/src/file-viewer/rules.ts index 34a4ef454f83bfcbf58299d521c2340fffcba591..af412047595d06591593549d7451e5d4edc0125c 100644 --- a/src/file-viewer/rules.ts +++ b/src/file-viewer/rules.ts @@ -140,18 +140,6 @@ export function fileIcon( return "file"; } -// -- viewer rules -- -const pathToCanvas = new Map(Object.entries({ - "/2017": "2017", - "/2018": "2018", - "/2019": "2019", - "/2020": "2020", - "/2021": "2021", - "/2022": "2022", - "/2023": "2023", - "/2024": "2024", -})); - import { MediaFile, MediaFileKind } from "#src/file-viewer/models/MediaFile.ts"; import * as path from "node:path"; import type * as highlight from "./highlight.ts"; diff --git a/src/file-viewer/tags/media-panel.marko b/src/file-viewer/tags/media-panel.marko index 49d660aec255c970e12219ba7853b6878baa2b5d..e17597640aa492a3b04ac09a48be4dcdbecc9a44 100644 --- a/src/file-viewer/tags/media-panel.marko +++ b/src/file-viewer/tags/media-panel.marko @@ -124,7 +124,15 @@ static const cotyledonEndingFile = "/2024/for everone"; - + + + + + + diff --git a/src/file-viewer/tags/view-audio.marko b/src/file-viewer/tags/view-audio.marko index 80ead08e5aeedecfaf5b66b8e15febfa943e9646..2a3e02618df79d6ce903bddc594088c414232726 100644 --- a/src/file-viewer/tags/view-audio.marko +++ b/src/file-viewer/tags/view-audio.marko @@ -4,41 +4,38 @@ export interface Input { } - { - const parent = file.getParent(); - if (parent && !onlyAudio) { - const siblings = parent.getPublicChildren(); - - // show lyrics only if - // - this media file is the only audio file - // - there is lyrics.txt in the same directory - const audioFiles = siblings.filter( - (f) => - f.kind === MediaFileKind.file && - extensionToViewer[path.extname(f.basename)] === AudioView, - ); - if ( - audioFiles.length === 1 && - siblings.find((f) => f.basename === "lyrics.txt") - ) { - return siblings.find((f) => f.basename === "lyrics.txt")!; - } - } - - return null; -}> +// { +// const parent = file.getParent(); +// if (parent && !onlyAudio) { +// const siblings = parent.getPublicChildren(); +// +// // show lyrics only if +// // - this media file is the only audio file +// // - there is lyrics.txt in the same directory +// const audioFiles = siblings.filter( +// (f) => f.kind === MediaFileKind.file && f.path.endsWith(".mp3"), +// ); +// if (audioFiles.length === 1) { +// return siblings.find((f) => f.basename === "lyrics.txt") ?? null; +// } +// } +// +// return null; +//}> -
-

- lyrics -

- -
+// +//
+//

+// lyrics +//

+// +//
+// import * as path from "node:path"; import { MediaFile, MediaFileKind } from "#src/file-viewer/models/MediaFile.ts"; diff --git a/src/file-viewer/tags/view-download.marko b/src/file-viewer/tags/view-download.marko index de2faf896b4336611584588864e4fd1c86b977b2..e1979cd44de5143a9529b266053019653090481a 100644 --- a/src/file-viewer/tags/view-download.marko +++ b/src/file-viewer/tags/view-download.marko @@ -53,7 +53,7 @@ export interface Input {

Instead, you may download it: - {file.basename} + ${file.basename} .

diff --git a/src/tags/photo-grid.css b/src/tags/photo-grid.css index accfcfdcb3cd9deb03a35326c191f5fa9238479d..41c0385742e56a52cbe0e59e2776422b538e2d6d 100644 --- a/src/tags/photo-grid.css +++ b/src/tags/photo-grid.css @@ -23,7 +23,7 @@ photo-grid-item { } } photo-grid + blockquote { - margin: 0 -4px; + margin: 0 -4px 1rem -4px; border: none; background-color: var(--primary); color: black;