=== WPSnippets AI ===
Contributors: wpsnippetsai, lazycodelab, wipeoutmedia, adictonat0r
Tags: code, snippets, ai, custom-code, hooks
Requires at least: 5.0
Tested up to: 6.8
Requires PHP: 7.4
Stable tag: 1.4.0
License: GPLv3
License URI: https://www.gnu.org/licenses/gpl-3.0.html

A modern lightweight plugin that makes it easier, smarter, and faster to add code to WordPress with a clean UI & built-in AI assistance.

== Description ==

WP Snippets AI revolutionizes WordPress development by combining powerful code snippet management with cutting-edge AI assistance. Whether you're a beginner or a seasoned dev, WP Snippets AI streamlines your workflow.

### Key Features

**AI-Powered Code Generation**
* Generate PHP, JavaScript, CSS, and HTML code using advanced AI models
* Support for OpenAI GPT, Anthropic Claude, and xAI Grok
* Context-aware code generation with iterative refinement
* Natural language to code conversion

**Smart Snippet Management**
* Intuitive code editor with syntax highlighting
* Organize snippets by categories and tags
* Advanced placement system with 20+ hook locations
* Conditional logic and priority management
* Revision history and rollback capabilities

**Iterative Code Refinement**
* Revolutionary multi-turn AI conversation system
* Refine code through natural language instructions
* Visual history timeline of all modifications
* Smart button adaptation based on context
* Start over option for fresh beginnings

**Professional Development Tools**
* Minification for production-ready code
* Code beautification and formatting
* Error detection and validation
* WordPress data integration
* Export/import functionality

**Freemium Business Model**
* Free core functionality
* Premium features unlocked with license
* Automatic updates for licensed users

### Perfect For

* **Developers**: Speed up development with AI assistance
* **Agencies**: Deliver projects faster with professional tools
* **Freelancers**: Stand out with cutting-edge development workflow
* **Content Creators**: Create code tutorials and educational content
* **WordPress Enthusiasts**: Learn development through AI guidance

### Security & Performance

* No external API calls without user consent
* Secure license validation system
* Optimized performance with minimal footprint
* GDPR compliant with privacy-first approach
* Regular security audits and updates

== Installation ==

### Automatic Installation (Recommended)

1. Log in to your WordPress admin dashboard
2. Navigate to **Plugins > Add New**
3. Search for "WPSnippets AI"
4. Click **Install Now** and then **Activate**

### Manual Installation

1. Download the plugin ZIP file from [wpsnippets.ai](https://wpsnippets.ai)
2. Log in to your WordPress admin dashboard
3. Navigate to **Plugins > Add New > Upload Plugin**
4. Upload the ZIP file and click **Install Now**
5. Click **Activate Plugin**

### Initial Setup

1. After activation, visit **WP Snippets AI** in your admin menu
2. Complete the onboarding wizard
3. Configure your AI provider settings (OpenAI, Anthropic, or Grok)
4. Start creating your first AI-powered code snippet!

== Frequently Asked Questions ==

= Is WP Snippets AI free? =

Yes! WP Snippets AI is free to download and use. The core functionality including basic snippet management, code editor, and placement system work without any payment. Premium features like unlimited AI generations, advanced hooks, and automatic updates are unlocked with a license.

= What AI providers are supported? =

WP Snippets AI supports three major AI providers:
* **OpenAI**: GPT-4, GPT-3.5 Turbo
* **Anthropic**: Claude 3.5 Sonnet, Claude 3 Opus, Claude 3 Haiku, Claude 3.5 Sonnet
* **xAI**: Grok-4, Grok-4-Fast, Grok-3, Grok-3-Mini

= How does the iterative code generation work? =

Iterative code generation allows you to refine your code through natural conversation with AI. Start with a basic request, then add features, fix bugs, or improve performance through follow-up instructions. The AI remembers your code and previous changes, building upon each iteration.

= Can I use this on multiple websites? =

Yes, with a valid license you can use WP Snippets AI on multiple websites. Each license is tied to your account and can be activated on multiple domains based on your plan.

= Is my code secure? =

Absolutely. WP Snippets AI follows privacy-first principles:
* Code is processed securely and never stored permanently
* No external API calls without explicit user permission
* All AI communications are encrypted
* License validation is secure and GDPR compliant

= What WordPress versions are supported? =

WP Snippets AI requires WordPress 5.0 or higher and PHP 7.4 or higher. It's tested up to WordPress 6.7 and follows WordPress coding standards.

= Can I export/import my snippets? =

Yes! Premium users can export their snippets as JSON files and import them to other websites. This makes it easy to migrate your code library or share snippets with team members.

= How do I get support? =

Free support is available through our [contact form](https://wpsnippets.ai/contact). Licensed users get priority support and access to premium documentation.

= Can I modify the plugin code? =

The plugin code is licensed under GPLv3, which allows you to modify it for personal use. However, we recommend keeping the original code intact for optimal performance and to receive updates.

= What if I need more AI generations? =

Free users get a limited number of AI generations per month. Licensed users get unlimited generations based on their plan. You can upgrade your license anytime from the license settings page.

== Screenshots ==

1. **Dashboard Overview** – Clean, intuitive interface for managing all your snippets
2. **AI Code Generation** – Generate code using natural language with multiple AI providers
3. **Iterative Refinement** – Refine code through multi-turn conversations with AI
4. **Advanced Editor** – Professional code editor with syntax highlighting and error detection
5. **Placement System** – Flexible hook system with 20+ placement options
6. **Settings & License** – Easy configuration of AI providers and license management

== Changelog ==

= 1.4.0 =
* **Added**: Deep Elementor integration with custom widgets
* **Added**: Snippet Selector Widget for displaying single snippets in Elementor
* **Added**: Snippet List Widget for displaying multiple snippets with grid/list layouts
* **Added**: Five new Elementor-specific assignment locations (header, footer, single, archive, location)
* **Added**: Automatic snippet injection on Elementor-built pages
* **Added**: Full Elementor styling controls (backgrounds, padding, borders, shadows)
* **Added**: Responsive design controls for all widgets
* **Added**: Custom "WP Snippets AI" category in Elementor widget panel
* **Enhanced**: LocationVerifier service with Elementor location support
* **Enhanced**: Service provider architecture for page builder integrations
* **Performance**: Conditional loading with zero overhead on non-Elementor pages
* **Compatibility**: Works with Elementor Free and Pro (3.0+)

= 1.3.0 =
* **Added**: Comprehensive plugin update service for automatic updates
* **Added**: Enhanced configuration constants for WordPress integration
* **Added**: Plugin update checker for seamless version management
* **Enhanced**: Code injection service with improved error handling
* **Enhanced**: Service provider architecture for better dependency injection
* **Fixed**: Removed deprecated ConnectionManager class
* **Fixed**: Version consistency across all plugin files

= 1.2.0 =
* **Changed**: Refactored text domain from 'wpsai' to 'wpsnippets-ai' (98 files updated)
* **Added**: Complete internationalization framework for translations
* **Added**: Language directory structure for .po/.mo files
* **Security**: Enhanced output escaping for WordPress.org compliance
* **Security**: Improved input sanitization across all forms and endpoints
* **Fixed**: WordPress Plugin Checker security and compatibility issues
* **Fixed**: Inconsistent text domains across codebase
* **Compatibility**: Full translation-ready and RTL-ready support
* **Compliance**: Passed all WordPress Plugin Checker requirements

= 1.1.0 =
* **Added**: Revolutionary Iterative Code Generation – multi-turn AI refinement
* **Added**: Context-aware AI conversations with history tracking
* **Added**: Smart button adaptation based on editor state
* **Added**: Visual history timeline for code modifications
* **Added**: Grok AI integration (xAI) with full provider support
* **Added**: Claude Sonnet 3.5 support for enhanced performance
* **Added**: Code preview before modifications
* **Added**: "Start Over" functionality for fresh iterations
* **Enhanced**: AI store with Redux state management for history
* **Enhanced**: Code generation form with contextual UI
* **Enhanced**: TypeScript compilation and build optimization
* **Fixed**: UI responsiveness and accessibility improvements
* **Security**: Enhanced input validation and privacy protection

= 1.0.0 =
* Initial release
* Core snippet management system
* OpenAI and Anthropic AI integration
* Code editor with syntax highlighting
* Snippet assignments and placements
* License management system
* WordPress data integration
* Onboarding flow
* Settings management
* Trial system

== Upgrade Notice ==

= 1.4.0 =
Massive update with comprehensive Elementor integration! Add code snippets visually using custom Elementor widgets with full styling controls. Automatically compatible with existing snippets.

= 1.3.0 =
Important update with automatic plugin updates service. Ensures you always have the latest features and security fixes.

= 1.2.0 =
Critical security and localization update. Text domain refactored for WordPress.org compliance. All users should update immediately.

= 1.1.0 =
Major update with iterative AI code generation! This revolutionary feature allows multi-turn conversations with AI for code refinement. All existing functionality remains backward compatible.

= 1.0.0 =
Initial stable release. No upgrade needed if coming from beta versions.

== Other Notes ==

### System Requirements

* **WordPress**: 5.0 or higher
* **PHP**: 7.4 or higher
* **MySQL**: 5.6 or higher
* **Memory**: 128MB minimum (256MB recommended)

### Privacy Policy

WP Snippets AI respects your privacy:
* No code is stored on our servers
* AI processing happens securely with your chosen provider
* License validation is encrypted and secure
