• Resolved adrienfidanza

    (@adrienfidanza)


    Hello,

    After installing the plugin, I successfully managed to add a custom icon with an embedded animation (.svg). However, it is impossible to control the size of this icon. Indeed, I tried to change the icon size through the “Icon size” field in the “Icon” section, but this only works for the preinstalled icons. Is there a solution to change the custom icon size? (I have already looked at the code of the plugin, but this solution is obviously not ideal). Thank you in advance.

    Regards

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author safelayout

    (@safelayout)

    Hi @adrienfidanza,
    Thanks for reaching out to us!

    Yes, as you said, the icon size only affects the preinstalled icons and the custom icon will be displayed with its original size.
    If you want the image to be displayed in a different size, it is better to modify the image size with an image editor.
    But if you want to do this by changing the source code of the plugin ( we do not recommend! ), you must change the codes at the end of the ”set_icon” function of the “\wp-content\plugins\safelayout-cute-preloader\inc\class-safelayout-preloader-admin.php” file, lines 2421 and 2422 ( version 2.0.90 ).

    $width = ‘100px’; //$options[‘custom_icon_width’];
    $height = ’30px’; //$options[‘custom_icon_height’];

    Important note: after changing the code, you must go back to the plugin settings page and click the “Save Changes” button for the changes to take effect.

    Regards,

    Thread Starter adrienfidanza

    (@adrienfidanza)

    Hello,

    Thank you very much for this quick and detailed answer. The solution you proposed is working great, despite the fact that it is obviously not “ideal”. Maybe a future update could implement this functionality =)

    Regards

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.