=== ShinPix – Image Optimizer & Size Control ===
Contributors: shindev
Tags: image optimization, thumbnails, image sizes, performance, media
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 0.4.3
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Control which thumbnail sizes WordPress generates, cap oversized uploads, and convert images to WebP — built for shared hosting.

== Description ==

Every time you upload an image, WordPress and your theme create several extra copies — often eight to ten files per image. On shared hosting with inode (file count) limits, this fills your quota fast, slows down backups, and wastes disk space.

**ShinPix** gives you back control:

* **Choose which image sizes are generated.** See every size registered by WordPress and your theme, with dimensions, and disable the ones you do not use.
* **See your savings.** ShinPix shows how many files each upload stores now versus the maximum, so you can see the inodes you save at a glance.
* **Safe by default.** ShinPix flags the sizes the WordPress admin and block editor rely on, and warns you before you disable them.
* **Cap oversized uploads.** Automatically scale down huge phone photos (often 4000px+) to a sensible maximum, keeping web quality while cutting file size.
* **Convert to WebP.** Create a lighter WebP copy of every new upload and serve it automatically to browsers that support it — with the original kept as a fallback. ShinPix detects whether your server can produce WebP and disables the feature gracefully if it cannot.
* **Compress on upload.** Set the quality used for the images WordPress generates, so every size is leaner.
* **Optimize your existing library.** Scan what is already in your Media Library and convert it to WebP in the background, batch by batch, with a progress bar you can pause and resume. Optimize or re-optimize a single image right from the Media Library, and retry anything that failed.

ShinPix is built for the real world of budget shared hosting. It is lightweight, adds no front-end overhead, and only changes what happens at upload time.

**Coming soon (and on the roadmap):**

* AVIF conversion (Pro)
* Scheduled, fully automatic background processing (Pro)
* Offload to S3, Cloudflare R2, Wasabi and other object storage to remove image files from your server entirely

ShinPix is part of the **ShinKit** family of WordPress tools.

== Installation ==

1. Upload the `shinpix` folder to `/wp-content/plugins/`, or install the ZIP via Plugins → Add New → Upload Plugin.
2. Activate the plugin.
3. Go to Settings → ShinPix and choose your image sizes.

Changes apply to new uploads. Existing images are not modified.

== Frequently Asked Questions ==

= Does this delete my existing images? =

No. ShinPix never deletes or overwrites an original. New uploads are optimized automatically, and you can optimize images already in your library from the ShinPix settings or the Media Library — the WebP copies are created alongside the originals.

= Will disabling sizes break my theme? =

It can if your theme relies on a specific size. The "thumbnail" size is also used in the WordPress admin. Disable sizes you are confident you do not use, and test your site afterwards.

= What does scaling oversized uploads do? =

WordPress already scales very large uploads (default 2560px). ShinPix lets you set a smaller limit so big photos are stored at a more web-friendly size.

== Changelog ==

= 0.4.3 =
* Add a bundled Vietnamese translation.
* Use the ShinPix logo in the settings header.
* Settings panel now uses the full admin width, with the size input no longer stretching.

= 0.4.1 =
* Escape image URLs rewritten in post content.
* Remove the optional full-page output-buffer rewrite; WebP is served through WordPress's image filters.

= 0.4.0 =
* Scan the existing Media Library and bulk-convert it to WebP with a pausable progress bar.
* Added a ShinPix status column to the Media Library with a per-image optimize / re-optimize button.
* Added an error log with retry and dismiss for images that fail to convert.

= 0.3.0 =
* Detect server image capabilities (GD / Imagick, WebP, AVIF) and degrade gracefully.
* Convert new JPEG and PNG uploads to WebP, keeping the original as a fallback.
* Serve WebP on the frontend to browsers that support it, with an optional content-rewrite mode.
* Add a WebP quality slider and an on-upload compression quality control.
* Redesign the settings screen with the ShinKit admin UI.

= 0.2.0 =
* Added a savings estimate showing how many files each upload stores now versus the maximum.
* Flagged the sizes used by the WordPress admin and block editor, with a warning before disabling them.

= 0.1.0 =
* Initial release.
* Choose which intermediate image sizes WordPress generates on upload.
* Control the oversized-upload scaling threshold.
