( function( $ ) {
    "use strict";
    var pxl_circilar_text_handler = function( $scope ) {
        let elements = $scope.find('.pxl-circular-text .pxl-item--text');
        if(!elements.length) return;

        elements.each(function() {
            const radius = $(this).attr('data-radius')
            let circleType = new CircleType(this)
            circleType.radius(radius)
            .forceHeight(true) 
            .forceWidth(true)   
        });
    };
    
    $( window ).on( 'elementor/frontend/init', function() {
        elementorFrontend.hooks.addAction( 'frontend/element_ready/pxl_circular_text.default', function( $scope ) {
            pxl_circilar_text_handler($scope);
        });
    } );
} )( jQuery );