Added crop functionality