- Require Standard Lib by Xon v1.1.0+
- Force usage of global functions so php can optimize them into special bytecode instead of function calls
- Fix disabling generating png links if svg => png is not configured
- Improve installer to report svg => svg conditions which can block usage
- Use "canonical" URL before XF2.2.3 as "full" doesn't work as expected in all contexts
- Add basic validation that an SVG template should render correctly
- Add an optimization pass for SVG's. Prunes pruning whitespace and nodes/attributes known to be safe to remove. Includes minifying any inline css.
- Support LESS/CSS in SVG's <style> element.
- Add option "Render SVG's as PNG for mobile devices", this supports rewriting calls to getSvgUrl from .svg to .png
- Requires Brower Detection v2.1.0+ add-on
- Requires updating webserver URL rewrite urls to support PNGs
- Caching requires explicitly defining a caching context with the name "sv-svg-img" or "css".
- Supports Imagick or CLI executables as a back-end to render SVGs to PNGs.
Using Imagick is not recommended- Example using resvg, as a CLI-executable back-end;
/usr/local/bin/resvg --quiet {sourceFile} {destFile}
This requires compiling using Rust, or use the pre-compiled linux x86_64 binary here.
Compiling can be done with;Rich (BB code):curl https://sh.rustup.rs -sSf | sh source $HOME/.cargo/env cargo install resvg cp ~/.cargo/bin/resvg /usr/local/bin/resvg chmod +x /usr/local/bin/resvg
- Minor code cleanup, avoid connecting to master redis instance to only connect to a replica instance on rendering cached output