optimize badge thumbnail image