- photos: generates a downscaled JPEG thumbnail per image, because serving a folder of 12-megapixel originals to a grid is unusable on a TV box. Uses CatmullRom scaling via golang.org/x/image; decodes jpeg/png/gif/webp. - an undecodable format returns no thumbnail rather than an error, so the grid falls back to a placeholder. - images already smaller than the 512px ceiling are passed through untouched. - library items endpoint now returns library_id, which the viewer needs to find its siblings for navigation. - web: PhotoViewer with keyboard and button navigation within the library. Verified: 900x1200 PNG thumbnailed to a 512-long-edge JPEG and served; unit tests assert exact dimensions, aspect preservation, and that non-images produce no thumbnail without erroring.
21 lines
585 B
Modula-2
21 lines
585 B
Modula-2
module github.com/mithral/vellum
|
|
|
|
go 1.26.8
|
|
|
|
require (
|
|
golang.org/x/crypto v0.58.0
|
|
golang.org/x/image v0.47.0
|
|
modernc.org/sqlite v1.60.1
|
|
)
|
|
|
|
require (
|
|
github.com/dustin/go-humanize v1.0.1 // indirect
|
|
github.com/google/uuid v1.6.0 // indirect
|
|
github.com/mattn/go-isatty v0.0.24 // indirect
|
|
github.com/ncruces/go-strftime v1.0.0 // indirect
|
|
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect
|
|
golang.org/x/sys v0.49.0 // indirect
|
|
modernc.org/libc v1.77.1 // indirect
|
|
modernc.org/mathutil v1.7.1 // indirect
|
|
modernc.org/memory v1.12.1 // indirect
|
|
)
|