-
Notifications
You must be signed in to change notification settings - Fork 1k
add optional "filter" type to image resize function #2623
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: next
Are you sure you want to change the base?
Conversation
I'm not sure if I have incorrectly configured something, but it seems that running |
|
* feat: port zola release build to gh actions & support linux arm64 Signed-off-by: Henrik Gerdes <[email protected]> * fix: add buildx support for multi-arch docker images Signed-off-by: Henrik Gerdes <[email protected]> * fix: pin gh release action to sha & allow pre-releases Signed-off-by: Henrik Gerdes <[email protected]> * fix: use env in gh action for linux arm build Signed-off-by: Henrik Gerdes <[email protected]> * chore: switch to dtolnay/rust-toolchain action for rust setup Signed-off-by: Henrik Gerdes <[email protected]> * fix: windows archive step Signed-off-by: Henrik Gerdes <[email protected]> --------- Signed-off-by: Henrik Gerdes <[email protected]>
"catmullrom" => FilterType::CatmullRom, | ||
"gaussian" => FilterType::Gaussian, | ||
_ => return Err(anyhow!("Invalid filter type: {}", filter)), | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we convert directly to the filter type from the image crate and skip our own?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I went with a custom type because FilterType from the image crate is not Hash
, so it breaks downstream functionality when the processed image paths are generated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've just made a PR to impl it, let's see if it works
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think it's released in the most recent version
Signed-off-by: xixishidibei <[email protected]>
Having a crate depend on files outside of its directory breaks building Zola as a dependency using Nix
* Add pagination info to get_section * Add documentation for pagination information * Stick to section properties `paginated` attributes removed
…nt (getzola#2688) This adds semantic meaning to the footnotes organization and improves accessibility by aiding disabled users who rely on assistive devices such as screen readers which utilize semantic tags such as the footer element in order to navigate properly. The hr element is semantically defined as representing a paragraph-level thematic break. Now that the footnotes are descendants of the footer element, the hr element originally preceding the footnotes list is no longer necessary (footnotes are no longer paragraph-level content) and thus replaced. However, the footer element is given the class "footnotes" to allow for styling, so the following CSS could be used to provide a stylistically equivalent visible border separating the footnotes from the content if so desired: .footnotes { border-top: 2px groove gray; } Test snapshots are also updated to reflect the new footer elements.
* Add external links class option to Markdown configuration * Validate external links class * Rename external link test snapshots
…n-minify-html * feat: do not minify js when minify html * test: update tests
…zola#2745) * Add optional arg to serve for extra paths to watch for changes * Address feedback
@aaron404 are you interested in updating that PR? |
* Add path annotation for codeblock * Doc * Rename path to name
@Keats I think I have missed something. You mentioned you made a PR to impl it (I assume impl |
It's image-rs/image@02a4928 |
It looks like we also need FilterType to impl |
Hmm.. |
Looks like both PRs have been merged? |
IMPORTANT: Please do not create a Pull Request adding a new feature without discussing it first.
The place to discuss new features is the forum: https://zola.discourse.group/
If you want to add a new feature, please open a thread there first in the feature requests section.
Sanity check:
Code changes
(Delete or ignore this section for documentation changes)
next
branch?If the change is a new feature or adding to/changing an existing one:
filter
parameter to theresize_image
function. It defaults tolanczos3
which is what was previously hardcoded. I had to add a mirror of theFilter
type from theimage
crate to implHash
for it. I'm not sure if there's a cleaner way to do this.