Add image listing and asset management
Show images in asset directories with preview, rename, replacement, and trash recovery. Update local Markdown references when images move and restore original files if related metadata cannot be committed. Refresh image previews after replacement and compare actual contents when deduplicating subsequent uploads.
This commit is contained in:
1 parent
8b54ccba18
commit
d253536009
25 files changed
+801
-103
No files matched your search
@@ -146,9 +146,7 @@ func (v *Vault) importLinks(ctx context.Context, note string, content []byte, to
|
||||
if !info.Mode().IsRegular() {
|
||||
continue
|
||||
}
|
||||
switch strings.ToLower(path.Ext(rel)) {
|
||||
case ".png", ".jpg", ".jpeg", ".gif", ".webp", ".svg", ".avif", ".apng", ".bmp", ".ico", ".tif", ".tiff":
|
||||
default:
|
||||
if !IsImage(rel) {
|
||||
continue
|
||||
}
|
||||
replacement, found := replacements[rel]
|
||||
|
||||
Reference in new issue
Block a user