diff options
| author | Lester Caine <lester@lsces.co.uk> | 2026-06-04 13:17:17 +0100 |
|---|---|---|
| committer | Lester Caine <lester@lsces.co.uk> | 2026-06-04 13:17:17 +0100 |
| commit | a64b642809ae64d1d6268ffc7c99d59dad57d41e (patch) | |
| tree | 2660e4334c31edf0990a3be83213460bfad1b20f /smartyplugins | |
| parent | 256142a9f228999f42410b24aa2b4e46341a2e71 (diff) | |
| download | themes-a64b642809ae64d1d6268ffc7c99d59dad57d41e.tar.gz themes-a64b642809ae64d1d6268ffc7c99d59dad57d41e.tar.bz2 themes-a64b642809ae64d1d6268ffc7c99d59dad57d41e.zip | |
Switch iconset to SVG-only — drop small/medium/large PNG directories
All iconset icons (ipackage=icons) now served from scalable/ as SVGs.
ipath (/small/, /medium/, /large/) is preserved only for cache key
differentiation and SVG width/height calculation; no PNG directory
lookups are performed.
Four icons remapped to SVG equivalents that exist in tango/scalable/:
dialog-cancel -> process-stop (newsletters: unsubscribed)
emblem-downloads -> network-receive (fisheye: download file)
emblem-shared -> emblem-symbolic-link (boards: moved topic)
mail-mark-important -> emblem-important (messages: flagged)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'smartyplugins')
| -rwxr-xr-x | smartyplugins/function.biticon.php | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/smartyplugins/function.biticon.php b/smartyplugins/function.biticon.php index e219036..adc4edb 100755 --- a/smartyplugins/function.biticon.php +++ b/smartyplugins/function.biticon.php @@ -172,22 +172,13 @@ function smarty_function_biticon( $pParams, $pSmall = false ) { // violators will be poked with soft cushions by the Cardinal himself!!! $icon_style = !empty( $pParams['istyle'] ) ? $pParams['istyle'] : $gBitSystem->getConfig( 'site_icon_style', DEFAULT_ICON_STYLE ); - if( false !== ( $matchFile = biticon_first_match( UTIL_PKG_PATH."iconsets/$icon_style".$pParams['ipath'], $pParams['iname'] ))) { - return biticon_output( $pParams, UTIL_PKG_URL."iconsets/$icon_style".$pParams['ipath'].$matchFile ); - } - - if( $icon_style != DEFAULT_ICON_STYLE && false !== ( $matchFile = biticon_first_match( UTIL_PKG_PATH."iconsets/".DEFAULT_ICON_STYLE.$pParams['ipath'], $pParams['iname'] ))) { - return biticon_output( $pParams, UTIL_PKG_URL."iconsets/".DEFAULT_ICON_STYLE.$pParams['ipath'].$matchFile ); - } - - // SVG fallback: raster not found, try scalable/ directory - $isize = trim( $pParams['ipath'], '/' ); + // Iconsets are SVG-only: serve from scalable/ at ipath-derived dimensions. + // ipath (/small/, /medium/, /large/) is preserved for cache key differentiation. + $pParams['isize'] = trim( $pParams['ipath'], '/' ); if( false !== ( $matchFile = biticon_first_match( UTIL_PKG_PATH."iconsets/$icon_style/scalable/", $pParams['iname'], ['svg'] ))) { - $pParams['isize'] = $isize; return biticon_output( $pParams, UTIL_PKG_URL."iconsets/$icon_style/scalable/".$matchFile ); } if( $icon_style != DEFAULT_ICON_STYLE && false !== ( $matchFile = biticon_first_match( UTIL_PKG_PATH."iconsets/".DEFAULT_ICON_STYLE."/scalable/", $pParams['iname'], ['svg'] ))) { - $pParams['isize'] = $isize; return biticon_output( $pParams, UTIL_PKG_URL."iconsets/".DEFAULT_ICON_STYLE."/scalable/".$matchFile ); } |
