Fix Product Versions meta box not appearing for licensed-variable products (v0.5.14)

- Product Versions meta box now always added to product pages, visibility controlled via CSS/JavaScript
- Added Installer::registerProductTypes() to create product type terms in the product_type taxonomy
- Product type terms are now ensured to exist on woocommerce_init hook for existing installations
- Fixed License Settings tab and Product Versions visibility toggling when changing product types

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-01-27 16:16:32 +01:00
parent d2e3b41a00
commit f9efe698ea
6 changed files with 107 additions and 69 deletions

View File

@@ -51,11 +51,18 @@ code.file-hash {
}
/* License Product Tab - Hidden by default, shown via JS based on product type */
#woocommerce-product-data .show_if_licensed,
#woocommerce-product-data .show_if_licensed-variable {
#woocommerce-product-data ul.wc-tabs li.show_if_licensed,
#woocommerce-product-data ul.wc-tabs li.show_if_licensed-variable {
display: none;
}
/* When shown, restore proper display for tab list items */
#woocommerce-product-data ul.wc-tabs li.show_if_licensed.wclp-active,
#woocommerce-product-data ul.wc-tabs li.show_if_licensed-variable.wclp-active {
display: block;
}
/* Hide elements for non-licensed products */
#woocommerce-product-data .hide_if_licensed {
display: none !important;
}