Crop
#
Advanced configurationPiio crop functionality allows you to crop your images individually and it is used by setting the data-piio-crop
attribute.
The data-piio-crop
attribute has two mandatory values: width
and height
of the crop.
In case you need to change the x-axis
and y-axis
from where crop the image, the attribute accepts two additional values. The first one represents x-axis
and the second one represents y-axis
.
Values: width
, height
, [x-axis
,y-axis
]
By default is going to crop from the center of the original image.
If width, height, x or y are set to numbers between 0.1 and 1 they are going to be treated as percentages otherwise they are going to be treated as px units.
Example: Basic usage setting width and height
Example: Setting x-axis and y-axis addiotionaly