=== Sale Timer for WooCommerce - Saletix ===
Contributors: maha25, themewant
Tags: woocommerce, sale timer, countdown timer, sale countdown, urgency
Requires at least: 5.8
Tested up to: 6.9
Requires PHP: 7.4
Stable tag: 1.0.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Boost WooCommerce sales with a sale-end timer — text notice, live countdown, or urgency progress bar near the Add to Cart button.

== Description ==

**Sale Timer for WooCommerce – Saletix** automatically displays a sale-end notice on WooCommerce single product pages whenever a sale end date is set. Choose from three display styles and position it exactly where you want — directly above or below the Add to Cart button — to create urgency and increase conversions.

> No coding required. Works out of the box with any WooCommerce theme.

=== Three Display Styles ===

**Text Notice**
A clean, simple message — "🔥 Sale ends in 3 days" — styled to match your store.

**Live Countdown Timer**
A ticking days / hours / mins / secs countdown that updates every second. Creates strong urgency without slowing down your page (vanilla JS, no dependencies).

**Urgency Progress Bar**
A visual bar showing how much of the sale period is left. Automatically shifts colour from amber → orange → red as the deadline approaches, giving shoppers an instant sense of scarcity.

=== Key Features ===

* **3 display styles** — Text, Countdown, Progress Bar
* **Flexible position** — Above or below the Add to Cart button
* **Custom colours** — Set background, text, and accent colour to match your brand
* **Fully automatic** — Reads WooCommerce sale end date, no extra data entry
* **Auto-hides** — Disappears the moment the sale ends
* **Lightweight** — Minimal CSS, tiny optional JS file, zero external dependencies
* **Theme-independent** — Uses standard WooCommerce hooks
* **Translation ready** — Fully localised with `.pot` file included

=== Settings ===

Find all settings under **WooCommerce → Settings → Products → Sale Timer**.

* Display Style (Text / Countdown / Progress Bar)
* Position (Above / Below Add to Cart)
* Background Colour
* Text Colour
* Accent Colour (progress bar fill and countdown box background)

A direct **Settings** link appears on the Plugins page for quick access.

=== Requirements ===

* WordPress 5.8 or higher
* WooCommerce 5.0 or higher
* PHP 7.4 or higher

== Installation ==

**From the WordPress Plugin Directory:**

1. Go to **Plugins → Add New** in your WordPress dashboard
2. Search for **Saletix Sale Timer for WooCommerce**
3. Click **Install Now**, then **Activate**

**Manual installation:**

1. Download the plugin zip file
2. Go to **Plugins → Add New → Upload Plugin**
3. Upload the zip and click **Install Now**, then **Activate**

**After activation:**

1. Go to any WooCommerce product and set a **Sale Price** with a **Sale End Date**
2. Visit the product page — the sale notice appears automatically
3. Customise style, position, and colours under **WooCommerce → Settings → Products → Sale Timer**

== Frequently Asked Questions ==

= Does this work without a sale end date? =
No. Saletix only displays a notice when a WooCommerce sale end date is scheduled on the product. If no end date is set, nothing is shown.

= Which display style should I use? =
The **Countdown** style creates the strongest urgency and typically drives the highest conversion lift. The **Progress Bar** is great for visually communicating scarcity. Use **Text** for a subtle, minimal look.

= Where on the page does the notice appear? =
By default it appears just above the Add to Cart button. You can switch it to below the Add to Cart button in the plugin settings. Both positions use dedicated WooCommerce hooks so placement is precise across all themes.

= Does it slow down my site? =
No. The plugin loads a small CSS file on product pages only. The countdown JS file is loaded only when the Countdown style is selected. There are no external scripts or requests.

= Does it work with variable products? =
Yes. Saletix works with all WooCommerce product types (simple, variable, grouped) as long as a sale end date is configured.

= Does it work with my theme? =
Yes. Saletix uses the standard `woocommerce_before_add_to_cart_form` and `woocommerce_after_add_to_cart_form` hooks which are part of WooCommerce core and supported by all properly built WooCommerce themes.

= Can I translate the plugin? =
Yes. Saletix is fully translation-ready. A `.pot` file is included in the `/languages/` folder. You can use Loco Translate or any compatible tool to add your language.

= Is there a Pro version? =
A Pro version with extended features is planned. Stay tuned on the ThemeWant website.

== Screenshots ==

1. Text style — clean sale-end message above the Add to Cart button
2. Countdown style — live ticking timer with days, hours, minutes, seconds
3. Progress Bar style — urgency bar that changes colour as the deadline approaches
4. Settings panel — WooCommerce → Settings → Products → Sale Timer

== Privacy Policy ==

Sale Timer for WooCommerce – Saletix uses [Appsero](https://appsero.com) SDK to collect some telemetry data upon user's confirmation. This helps us to troubleshoot problems faster & make product improvements.

Appsero SDK **does not gather any data by default.** The SDK only starts gathering basic telemetry data **when a user allows it via the admin notice**. We collect the data to ensure a great user experience for all our users.

Integrating Appsero SDK **DOES NOT IMMEDIATELY** start gathering data, **without confirmation from users in any case.**

Learn more about how [Appsero collects and uses this data](https://appsero.com/privacy-policy/).

== Changelog ==

= 1.0.4 =
* Added: Appsero SDK integration for opt-in telemetry and improved support

= 1.0.2 =
* Added: Three display styles — Text, Countdown, Progress Bar
* Added: Position setting — Above or Below Add to Cart button
* Added: Colour settings — Background, Text, and Accent colours
* Added: Live JavaScript countdown timer (vanilla JS, no dependencies)
* Added: Urgency progress bar with automatic colour shifting (amber → orange → red)
* Added: Direct Settings link on the Plugins page
* Changed: Position now uses dedicated WooCommerce cart form hooks for reliable placement across all themes
* Improved: Countdown JS only loaded when Countdown style is active

= 1.0.1 =
* Minor styling improvements

= 1.0.0 =
* Initial release

== Upgrade Notice ==

= 1.1.0 =
New display styles, colour controls, and position settings added. No breaking changes — existing installs continue working with the default Text style.
