From 0dd4408b230baeee57b7a6d52648ca7396745789 Mon Sep 17 00:00:00 2001 From: magdev Date: Wed, 31 Dec 2025 22:12:43 +0100 Subject: [PATCH] Bump version to 1.1.8 for release MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Version 1.1.8 includes critical UI bug fixes: - Admin rendering bug (tab visibility) - Frontend product selector not appearing - Price formatting localization Updated CHANGELOG.md with comprehensive v1.1.8 release notes. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 --- CHANGELOG.md | 36 ++++++++++++++++++++++++++++++++++++ wc-composable-product.php | 4 ++-- 2 files changed, 38 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 900dfa9..fa36e12 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,42 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.1.8] - 2025-12-31 + +### Fixed + +- **CRITICAL**: Admin rendering bug where both General and Composable Options tabs showed simultaneously on initial page load +- **CRITICAL**: Frontend product selector not appearing on product pages - WooCommerce's default add-to-cart button now hidden for composable products +- **CRITICAL**: Price formatting not localized - prices now display with proper currency symbols, decimal separators, and thousand separators for all locales + +### Added + +- `wc_price()` Twig function for proper price formatting in templates +- `formatPrice()` JavaScript method with full WooCommerce locale support +- Price format localization data passed to frontend JavaScript (decimal/thousand separators, currency position, number of decimals) +- `hide_default_add_to_cart()` method to prevent WooCommerce's default purchase UI for composable products + +### Changed + +- Enhanced CSS specificity with `!important` flags for proper tab visibility control +- Template now uses `{{ fixed_price_html|raw }}` instead of raw currency concatenation +- Product selector passes pre-formatted price HTML from `wc_price()` function +- Frontend JavaScript updates prices dynamically using WooCommerce format settings + +### Technical + +- Modified files: assets/css/admin.css (+24 lines), includes/Cart_Handler.php (+14 lines), includes/Plugin.php (+7 lines), includes/Product_Selector.php (+2 lines), templates/product-selector.twig, assets/js/frontend.js (+28 lines) +- All PHP files pass syntax validation +- Supports Swiss format (CHF 50.-), European format (50,00 €), US format ($50.00), and all other WooCommerce locales +- Thousand separator support: comma (1,000), dot (1.000), apostrophe (1'000), space (1 000) + +### Notes + +- This release fixes all three critical UI bugs reported in CLAUDE.md +- Admin tabs now display correctly on initial page load without JavaScript flicker +- Frontend product selector is now the only purchase interface (no WooCommerce default button) +- All prices maintain proper locale formatting during dynamic updates + ## [1.1.7] - 2025-12-31 ### Added diff --git a/wc-composable-product.php b/wc-composable-product.php index 6201090..1953d82 100644 --- a/wc-composable-product.php +++ b/wc-composable-product.php @@ -3,7 +3,7 @@ * Plugin Name: WooCommerce Composable Products * Plugin URI: https://github.com/magdev/wc-composable-product * Description: Create composable products where customers select a limited number of items from a configurable set - * Version: 1.1.7 + * Version: 1.1.8 * Author: Marco Graetsch * Author URI: https://example.com * License: GPL v3 or later @@ -19,7 +19,7 @@ defined('ABSPATH') || exit; // Define plugin constants -define('WC_COMPOSABLE_PRODUCT_VERSION', '1.1.7'); +define('WC_COMPOSABLE_PRODUCT_VERSION', '1.1.8'); define('WC_COMPOSABLE_PRODUCT_FILE', __FILE__); define('WC_COMPOSABLE_PRODUCT_PATH', plugin_dir_path(__FILE__)); define('WC_COMPOSABLE_PRODUCT_URL', plugin_dir_url(__FILE__));