# Changelog

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

## [1.1.0] - 2024-12-17

### Changed - 2024-12-17 (v1.1.0)

- **Plugin Rebranding**: Complete plugin rebranding for WordPress.org compliance
  - Plugin name changed to "One Time Email Access Guard"
  - Plugin slug updated to "one-time-email-access-guard"
  - Text domain changed to "one-time-email-access-guard"
  - Author updated to Marco Gargano
  - Author URI updated to https://www.marcogargano.com
  - All translation files renamed and recompiled
  - Documentation updated (README.md, readme.txt, CHANGELOG.md)
  - Folder and main plugin file renamed

### Added - 2024-12-03 (v1.1.0)

- **CSV Import/Export**: Complete user data management with CSV files in Options page
  - Export all users with full details (name, email, phone, expiry, status)
  - Import users from CSV with automatic creation
  - Warning system for potential duplicates during import
  - Secure file handling with nonce verification
- **Cache Management**: Improved data consistency with WordPress native cache invalidation
- **User Status Display**: Enhanced user list in post edit pages showing both expiry and active status
- **Admin Interface**: Moved CSV functionality to Options page for better organization

## [1.0.0] - 2024-12-03

### Added - 2024-12-03 (v1.0.0)

- **Code Optimization**: Final cleanup and removal of unused elements
- **Documentation**: Comprehensive changelog and technical documentation
- **Admin UX Enhancements**: Button group styling for related actions and outline button styles for confirmations
- **WordPress Compliance**: Final adjustments for Plugin Directory guidelines

### Enhanced - 2024-12-02

- **Bulk Operations**: Mass management tools for user administration with bulk user activation/deactivation and button group interface
- **Expiry System**: Bulk date setting with date/time picker and current date/time defaults
- **UI Improvements**: Two-step confirmation system for all bulk operations
- **Admin Interface**: Enhanced button styling and modern user experience

### Implemented - 2024-12-01

- **User Expiration System**: Individual user expiry dates and times with unlimited access option and automatic expiry validation
- **Status Indicators**: Visual status system (active, expired, unlimited) with icons and responsive table layouts
- **International Phone Support**: Complete country code system with 195+ countries, flag emojis, and separate phone number fields
- **Email Integration**: Professional HTML email templates with site branding, icon integration, and multilingual content

### Developed - 2024-11-30

- **Core OTP System**: Complete email-based OTP authentication system for WordPress pages and posts
- **User Management**: Custom post type for managing OTP users with detailed contact information
- **Admin Interface**: Comprehensive admin panel with overview dashboard, user management, active pages listing, and plugin options
- **Security Features**: Enterprise-level security with nonce verification, transient-based OTP storage, cookie-based access tokens, and password hashing
- **Customization Options**: Extensive styling options with modal overlay controls, background/text color customization, and shadow effects

### Initial - 2024-11-29

- **Plugin Structure**: Basic WordPress plugin architecture with singleton pattern and proper hook integration
- **Page Protection**: Meta box integration for enabling OTP protection on any page or post
- **Frontend Templates**: Custom template system with protected page override, OTP forms, and shortcode support
- **Multilingual Support**: Complete internationalization with Italian (it_IT) translation and proper text domain implementation
- **Basic Functionality**: OTP request, verification, access control system with sortable user columns and bulk selection

### Core Features

- **Core OTP System**: Complete email-based OTP authentication system for WordPress pages and posts
- **User Management**: Custom post type for managing OTP users with detailed contact information
- **Page Protection**: Meta box integration for enabling OTP protection on any page or post
- **Admin Interface**: Comprehensive admin panel with multiple sections:
  - Overview dashboard
  - User management with add/edit capabilities
  - Active pages listing
  - Plugin options and customization
- **Security Features**: Enterprise-level security implementation:
  - Nonce verification for all forms
  - Transient-based OTP storage (15-minute expiry)
  - Cookie-based access tokens
  - Password hashing for OTP codes
  - User permission checks
- **Frontend Templates**: Custom template system:
  - Protected page template override
  - OTP request and verification forms
  - Status notifications and error handling
  - Shortcode support for flexible integration
- **Multilingual Support**: Complete internationalization:
  - Italian (it_IT) translation
  - English (en_US) base language
  - Translation-ready with .pot file
  - Proper text domain implementation

### Advanced Features

- **Bulk Operations**: Mass management tools for user administration:
  - Bulk user activation/deactivation with button group interface
  - Bulk expiry date setting with date/time picker
  - Two-step confirmation system for all bulk operations
- **User Expiration System**: Flexible user access control:
  - Individual user expiry dates and times
  - Unlimited access option
  - Visual status indicators (active, expired, unlimited)
  - Automatic expiry validation
- **International Phone Support**: Complete country code system:
  - 195+ country codes with flag emojis
  - Separate country code and phone number fields
  - Automatic phone number validation
- **Email Integration**: Professional email system:
  - HTML email templates with site branding
  - Site icon integration or fallback design
  - Responsive email layout
  - Multilingual email content
- **Customization Options**: Extensive styling and behavior options:
  - Modal overlay color and opacity controls
  - Modal background and text color customization
  - Shadow effects toggle
  - Required field configuration (first name, last name)
  - Custom blocked content messages
- **Admin UX Enhancements**: Modern admin interface:
  - Sortable user columns
  - Bulk selection with "Select All" functionality
  - Visual status indicators with icons
  - Responsive table layouts
  - Button group styling for related actions
  - Outline button styles for confirmations

### Technical Implementation

- **WordPress Standards**: Full compliance with WordPress coding standards
- **PHP 7.2+ Compatibility**: Modern PHP features with backward compatibility
- **Singleton Pattern**: Efficient plugin architecture
- **Hook System**: Proper WordPress action and filter integration
- **Caching**: Transient caching for protected posts
- **Database Optimization**: Efficient meta queries with proper indexing
- **Security**: PHPCS compliance with security best practices

### Files Structure

```
one-time-email-access-guard/
├── assets/css/otp-access-frontend.css
├── includes/class-otp-access-plugin.php
├── languages/ (5 translation files)
├── templates/single-otp-secure-page.php
├── one-time-email-access-guard.php
├── README.md
├── LICENSE
└── CHANGELOG.md
```

### WordPress Plugin Directory Compliance

- Follows WordPress Plugin Directory guidelines
- Proper plugin headers and metadata
- GPL v2+ licensing
- Security best practices implementation
- No external dependencies
- Clean activation/deactivation hooks
