mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
fix: use WebP as magick preset preloader cache format to keep image transparency (#4065)
This commit is contained in:
parent
6144d2748e
commit
0daa5df644
2 changed files with 5 additions and 2 deletions
|
|
@ -32,7 +32,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/):
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|
||||||
- Keep package hashes indifferent to line endings when `ya pkg` pulls packages
|
- Keep package hashes indifferent to line endings when `ya pkg` pulls packages ([#4064])
|
||||||
|
- Use WebP as `magick` preset preloader cache format to keep image transparency ([#4065])
|
||||||
|
|
||||||
### Improved
|
### Improved
|
||||||
|
|
||||||
|
|
@ -1750,3 +1751,5 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/):
|
||||||
[#4022]: https://github.com/sxyazi/yazi/pull/4022
|
[#4022]: https://github.com/sxyazi/yazi/pull/4022
|
||||||
[#4031]: https://github.com/sxyazi/yazi/pull/4031
|
[#4031]: https://github.com/sxyazi/yazi/pull/4031
|
||||||
[#4040]: https://github.com/sxyazi/yazi/pull/4040
|
[#4040]: https://github.com/sxyazi/yazi/pull/4040
|
||||||
|
[#4064]: https://github.com/sxyazi/yazi/pull/4064
|
||||||
|
[#4065]: https://github.com/sxyazi/yazi/pull/4065
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,7 @@ function M:preload(job)
|
||||||
cmd:arg { "-background", job.args.bg, "-alpha", "remove" }
|
cmd:arg { "-background", job.args.bg, "-alpha", "remove" }
|
||||||
end
|
end
|
||||||
|
|
||||||
local status, err = cmd:arg(string.format("JPG:%s", cache)):status()
|
local status, err = cmd:arg(string.format("WEBP:%s", cache)):status()
|
||||||
if not status then
|
if not status then
|
||||||
return true, Err("Failed to start `magick`, error: %s", err)
|
return true, Err("Failed to start `magick`, error: %s", err)
|
||||||
elseif not status.success then
|
elseif not status.success then
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue