Library compatibility issue with UNO R4 Wifi

Hi everyone,
I've just received an Arduino UNO R4 wifi and I'm trying to upgrade an old project, which consists of a day-night simulator using dimmable LED lamps. I work using lamps in AC.
To manage the lamps I use the official library given by the dimmer's manufacturer link here.
This lib should support both esp32 and avr archs but it gives me a compiling error for r4 wifi saying that the board is not compatible.
Has anyone any idea on what to do? Is it only a macro problem which is not recognized by the lib (which would actually be easy to solve) or have I to rewrite the whole lib (in this case, have you any suggestion on how to rewrite it)?

Uno R4 is not AVR or esp32

I found something about that but the processor is named esp32 so I was not sure...
at this point I suppose to have to rewrite the whole library.
Have you any suggestion/documentation or similar?

I'm not even able to find the macro which defines the R4 Wifi board (e.g. for the R3 was ARDUINO_ARCH_AVR).

What makes you say that ?
The ESP32 is used to provide WiFi but you are uploading to the Renasas processor

See https://docs.arduino.cc/hardware/uno-r4-wifi/

the library will not work with Uno R4

Oh sorry, on the cardboard box both chips are reported in a single block so i assumed it was only one.
image