# elementor/4.0.0-dev3/modules/interactions/validators/custom-effect-value.php

Elementor Website Builder – more than just a page builder, version 4.0.0-dev3. 36 lines.

- Page: https://pluginprobe.com/plugins/elementor/4.0.0-dev3/code/modules/interactions/validators/custom-effect-value.php
- Raw: https://pluginprobe.com/plugins/elementor/4.0.0-dev3/raw/modules/interactions/validators/custom-effect-value.php
- Modified: 2026-03-25T16:12:18+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/elementor/4.0.0-dev3/code/modules/interactions/validators/custom-effect-value.php#L10-L20`.

```php
<?php

namespace Elementor\Modules\Interactions\Validators;

use Elementor\Modules\AtomicWidgets\Parsers\Props_Parser;
use Elementor\Modules\Interactions\Props\Custom_Effect_Prop_Type;

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

/**
 * TODO: At least a value validator interface to enforce is_valid fxn for consistency
 */
class Custom_Effect_Value {
	public static function is_valid( array $animation_value ): bool {
		$effect_value = $animation_value['effect']['value'] ?? null;

		if ( 'custom' !== $effect_value ) {
			return true;
		}

		if ( ! isset( $animation_value['custom_effect'] ) ) {
			return false;
		}

		$props_parser = Props_Parser::make( [
			'custom_effect' => Custom_Effect_Prop_Type::make(),
		] );

		$result = $props_parser->parse( [ 'custom_effect' => $animation_value['custom_effect'] ] );

		return $result->is_valid();
	}
}

```
