As I work on implementing a cropping feature using react-easy-crop, my goal is to store the user's image along with pixel coordinates that dictate their preferred cropping area.
My objective is to utilize the parameters provided by react-easy-crop in order to crop the banner image for display on a user's profile.
The use of react-easy-crop, which relies on react-image-crop, involves the following parameters:
{ width: integer, height: integer, x: integer, y: integer }
Applying CSS style:
I am seeking guidance on how to use this data to render a cropped image using CSS.
(While aware of alternative CSS cropping methods, I specifically aim to utilize the aforementioned data.)
Implementing Javascript approach:
I have made attempts to convert the Image URL into a blob or base64 format for cropping purposes, but encountered CORS errors when dealing with images hosted on Azure blobs. Instead of tackling security concerns, I would prefer a solution that leans towards CSS implementation.