پرش به محتویات

"Filter: bricks/conditions/groups"

گروه های شرایط موجود در رابط شرایط عنصر را فیلتر می‌کند. این به شما امکان می‌دهد دسته بندی های جدیدی را برای شرایط سفارشی خود اضافه کنید.

پارامترها

  • $groups (array): Array of condition groups. Each group has a name and label.

نمونه استفاده

add_filter( 'bricks/conditions/groups', function( $groups ) {
    // Add a custom condition group
    $groups[] = [
        'name'  => 'my_custom_group',
        'label' => esc_html__( 'My Custom Group', 'my-plugin' ),
    ];

    return $groups;
} );