Files
trpic/go.mod
Hubert Chen 2b8e238e72 add thumbhash
add thumbhash use `github.com/galdor/go-thumbhash` and `github.com/evanw/thumbhash`

database:
    add `thumbhash` column for `files` table
image:
    add `EncodeThumbHash()` function use `go.n16f.net/thumbhash`
router:
    add `/api/task/files/thumbhash` endpoint to check thumbhask
task:
    add `CheckThumbHash()` function
web/scripts:
    add thumbhash logic for `load_*` scripts
    add `thumbhash.js` from `https://github.com/evanw/thumbhash/blob/main/js/thumbhash.js`, edited
web/styles/gallery:
    add thumbhash transition when thumbnail loaded
    adjust style for wrapped imgs
web/templates:
    add `role="main"` for gallery and artwork id pages
    render thumbhash script for gallery pages
2026-04-21 23:26:29 +08:00

39 lines
1.3 KiB
Modula-2

module trle5.xyz/trpic
go 1.25.3
require (
entgo.io/ent v0.14.5
github.com/cshum/vipsgen v1.3.1
github.com/dustin/go-humanize v1.0.1
github.com/go-chi/chi/v5 v5.2.4
github.com/google/uuid v1.6.0
github.com/mattn/go-sqlite3 v1.14.42
github.com/pquerna/otp v1.5.0
github.com/ryohidaka/go-pixiv v0.30.2
github.com/sony/sonyflake/v2 v2.2.0
go.n16f.net/thumbhash v1.1.0
golang.org/x/image v0.39.0
gopkg.in/yaml.v3 v3.0.1
trle5.xyz/go-sqlite3-fts5 v0.1.1
)
require (
ariga.io/atlas v0.32.1-0.20250325101103-175b25e1c1b9 // indirect
github.com/agext/levenshtein v1.2.3 // indirect
github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect
github.com/bmatcuk/doublestar v1.3.4 // indirect
github.com/boombuler/barcode v1.0.1-0.20190219062509-6c824513bacc // indirect
github.com/go-openapi/inflect v0.19.0 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/go-querystring v1.1.0 // indirect
github.com/hashicorp/hcl/v2 v2.18.1 // indirect
github.com/mitchellh/go-wordwrap v1.0.1 // indirect
github.com/rogpeppe/go-internal v1.14.1 // indirect
github.com/zclconf/go-cty v1.14.4 // indirect
github.com/zclconf/go-cty-yaml v1.1.0 // indirect
golang.org/x/mod v0.34.0 // indirect
golang.org/x/text v0.36.0 // indirect
gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b // indirect
)