Universal DataProvider for CRUD, Grid and ComboBox

I tried to implement a very basic custom data provider with following signature:

public class CustomDataProvider<E extends AbstractEntity, R extends AbstractRepository<E>>
        extends AbstractBackEndDataProvider<E, String>
        implements ConfigurableFilterDataProvider<E, String, CrudFilter {

When using it in an crud component vaadin seems to swap the String with the CrudFilter. Is there a way I can prevent this behavior?

Here is a snippet of the vaadin flow repository:
https://github.com/vaadin/flow/blob/1aa7dc14498cb2358d9ee95558a014845e8f07a2/flow-data/src/main/java/com/vaadin/flow/data/provider/DataProviderWrapper.java#L38

public abstract class DataProviderWrapper<T, F, M>
        implements DataProvider<T, F> {

    protected DataProvider<T, M> dataProvider;

Looks like the data provider wrapper swaps the filter. I wanted to handle the String and CrudFilter in my repository.