feat: WordPress plugin versioning + heatmap fix + dynamic latest download

- Add VERSION file (1.5.4) for tracking WP plugin version
- Update plugin headers to 1.5.4 (cannaiq-menus.php, crawlsy-menus.php)
- Add dynamic /downloads/cannaiq-menus-latest.zip route that auto-redirects
  to highest version (no manual symlinks needed)
- Update frontend download links to use -latest.zip
- Fix StateHeatmap.tsx to parse API values as numbers (fixes string concat bug)
- Document versioning rules in CLAUDE.md

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Kelly
2025-12-09 09:32:26 -07:00
parent e2166bc25f
commit 37dfea25e1
9 changed files with 77 additions and 9 deletions

1
wordpress-plugin/VERSION Normal file
View File

@@ -0,0 +1 @@
1.5.4

View File

@@ -36,9 +36,16 @@ zip -r "${OUTPUT_DIR}/${OUTPUT_FILE}" . \
-x "assets/css/crawlsy-menus.css" \
-x "assets/js/crawlsy-menus.js"
# Create/update the "latest" symlink
cd "${OUTPUT_DIR}"
rm -f cannaiq-menus-latest.zip
ln -s "${OUTPUT_FILE}" cannaiq-menus-latest.zip
echo ""
echo "Build complete!"
echo " File: ${OUTPUT_DIR}/${OUTPUT_FILE}"
echo " Size: $(ls -lh "${OUTPUT_DIR}/${OUTPUT_FILE}" | awk '{print $5}')"
echo ""
echo "Download URL: https://cannaiq.co/downloads/cannaiq-menus-${VERSION}.zip"
echo "Download URLs:"
echo " Versioned: https://cannaiq.co/downloads/cannaiq-menus-${VERSION}.zip"
echo " Latest: https://cannaiq.co/downloads/cannaiq-menus-latest.zip"

View File

@@ -3,7 +3,7 @@
* Plugin Name: CannaIQ Menus
* Plugin URI: https://cannaiq.co
* Description: Display cannabis product menus from CannaIQ with Elementor integration. Real-time menu data updated daily.
* Version: 1.5.3
* Version: 1.5.4
* Author: CannaIQ
* Author URI: https://cannaiq.co
* License: GPL v2 or later
@@ -15,7 +15,7 @@ if (!defined('ABSPATH')) {
exit; // Exit if accessed directly
}
define('CANNAIQ_MENUS_VERSION', '1.5.3');
define('CANNAIQ_MENUS_VERSION', '1.5.4');
define('CANNAIQ_MENUS_API_URL', 'https://cannaiq.co/api/v1');
define('CANNAIQ_MENUS_PLUGIN_DIR', plugin_dir_path(__FILE__));
define('CANNAIQ_MENUS_PLUGIN_URL', plugin_dir_url(__FILE__));

View File

@@ -3,7 +3,7 @@
* Plugin Name: Crawlsy Menus
* Plugin URI: https://creationshop.io
* Description: Display cannabis product menus from Crawlsy with Elementor integration
* Version: 1.5.2
* Version: 1.5.4
* Author: Creationshop
* Author URI: https://creationshop.io
* License: GPL v2 or later
@@ -15,7 +15,7 @@ if (!defined('ABSPATH')) {
exit; // Exit if accessed directly
}
define('CRAWLSY_MENUS_VERSION', '1.5.2');
define('CRAWLSY_MENUS_VERSION', '1.5.4');
define('CRAWLSY_MENUS_API_URL', 'https://cannaiq.co/api/v1');
define('CRAWLSY_MENUS_PLUGIN_DIR', plugin_dir_path(__FILE__));
define('CRAWLSY_MENUS_PLUGIN_URL', plugin_dir_url(__FILE__));