# Changelog

All notable changes to ZenBlocks will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.1.0] - 2026-02-23

### Added

- PRO feature dual-layer frontend protection (PHP filter + CSS separation)
- PHP filter enhancement: strip PRO-only HTML elements, CSS classes, and CSS variables
- PRO animation CSS delivered exclusively via zenblocks-pro plugin
- License check requires both active license and zenblocks-pro plugin enabled

### Security

- PRO features no longer bypassable via custom CSS when license is inactive
- Animation CSS files not loaded on frontend without active PRO license

## [1.0.1] - 2026-02-22

### Added

- Hover state indicator icon in toolbar
- Layer z-index settings for button elements
- Band border panel with responsive controls
- Block inserter preview (example) and search keywords
- Auto-open preset tab on new block insertion
- Auto-set YouTube thumbnail as poster image when video URL is set
- Autoplay notice for embed videos in editor
- Dutch (nl_NL) locale support
- Translation JSON auto-merge build script (`scripts/merge-translation-json.js`)

### Changed

- Media selector buttons changed to icon-only UI for compact layout
- Video URL apply/cancel buttons changed to icon buttons
- Design preset UI improvements and file reorganization
- Preset card UI and PRO badge presentation unified
- Image/video picker UI updated with aspect ratio metadata
- Video source workflows refined for thumbnail, band, and background
- Thumbnail and band responsive toggles split by panel
- Free version now includes text modules and copy/text additional settings
- Translation JSON files consolidated from ~2000 to 30 files (10 locales × 3 build hashes)

### Fixed

- Preset switching incorrectly detecting PRO badge
- Hover preview icon state for animated button icons
- Background image default change not syncing hover URL
- Micro copy / Sub copy margin-left/right not working
- Band pattern hover PC color/size CSS missing
- Thumbnail/band border responsive toggle affecting other settings
- Editor deprecation warnings
- Plugin Check compliance (function naming, file operations, distignore)
- Video poster not clearing when switching to non-YouTube videos
- Double poster display in editor layers
- Broken image icon for embed videos without thumbnails
- Translation JSON not loading for shared components in editor
- `load_plugin_textdomain` not registered

### Removed

- All `console.log` / `console.warn` debug statements from source files
- Unused `deprecated.js` (pre-release cleanup)

## [1.0.0] - 2026-02-07

Initial release of ZenBlocks.

### Added

- **Button Basic block** with advanced styling capabilities
  - Gradient backgrounds, shadows, hover effects, icons
  - Micro copy / Sub copy text elements
  - Micro text / Sub text elements
  - Icon frame with border and animation
  - Thumbnail image settings
  - Band (decorative strip) settings
  - Background image with preset selector (25+ images)
  - Background patterns (dots, lines, grid, circles, triangles)
  - Background color overlay with cross-fade hover transition
  - Text animation (character-by-character effects)
  - Button / Frame / Icon animations
  - Design presets (pattern selector with reset)
- **Responsive design system**
  - 4 breakpoints: PC / MD (Medium) / TB (Tablet) / SP (Smartphone)
  - Customizable breakpoint values via Settings > ZenBlocks
  - Per-device display/hide settings
  - Responsive preview in editor with iframe resize
  - CSS variable-based responsive styling
- **Per-page CSS generation** for optimal frontend performance
  - Automatic CSS file generation on post save
  - CSS cache management with manual clear option
  - Auto-clear on plugin update
- **Pro feature system**
  - Free/Pro feature gating with `ProFeatureOverlay` component
  - Lemon Squeezy integration for license management and payments
  - Feature definitions with `feature-definitions.js` and `feature-gate.jsx`
- **Internationalization (i18n)**
  - Full English source with `__()` / `_e()` wrappers
  - Japanese (ja) translation - complete
  - French (fr_FR), Spanish (es_ES), Portuguese (pt_BR), Italian (it_IT), Korean (ko_KR), Indonesian (id_ID), Traditional Chinese (zh_TW)
- **Editor UX**
  - Toolbar shortcuts with dropdown menus
  - Hover tab with live hover preview
  - Sync buttons for hover state synchronization
  - Custom color palette with theme/custom/gradient support
  - Sticky panel headers
  - Size presets (S/M/L) in toolbar
- **Admin settings page** (Settings > ZenBlocks)
  - License status display
  - CSS cache management
  - Breakpoint configuration via REST API
- **Security**
  - Nonce verification on all AJAX/REST endpoints
  - `current_user_can()` permission checks
  - Input sanitization (`sanitize_text_field`, `absint`, `esc_url`)
  - Output escaping (`esc_html`, `esc_attr`, `esc_url`, `esc_js`)
  - WordPress Plugin Check compliant
