<?php
/**
 * Options Page Builder — universal content tag replacement.
 *
 * Replaces {wp_powersuite_opb:page_slug:field_id} in post content and widget text.
 *
 * @package OptionsPageBuilder
 */

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

add_filter( 'the_content', 'wpps_opb_filter_content_tags', 18 );
add_filter( 'widget_text_content', 'wpps_opb_filter_content_tags', 18 );
add_filter( 'widget_block_content', 'wpps_opb_filter_content_tags', 18 );

function wpps_opb_filter_content_tags( string $content ): string {
	return wpps_opb_replace_content_tags( $content );
}
