Your IP : 216.73.216.94


Current Path : /home/eolienneia/www/templates/yootheme/vendor/yootheme/builder/elements/icon/
Upload File :
Current File : /home/eolienneia/www/templates/yootheme/vendor/yootheme/builder/elements/icon/element.php

<?php

namespace YOOtheme;

return [
    'transforms' => [
        'render' => function ($node) {
            // Don't render element if content fields are empty
            return (bool) $node->props['icon'];
        },
    ],

    'updates' => [
        '2.1.0-beta.0.1' => function ($node) {
            if (!empty($node->props['icon_ratio'])) {
                $node->props['icon_width'] = round(20 * $node->props['icon_ratio']);
                unset($node->props['icon_ratio']);
            }
        },

        '1.20.0-beta.4' => function ($node) {
            if (isset($node->props['maxwidth_align'])) {
                $node->props['block_align'] = $node->props['maxwidth_align'];
                unset($node->props['maxwidth_align']);
            }
        },
    ],
];