=== FreshNews AI Content Hub ===
Contributors: freshnewsai
Tags: embed, content, freshnews, signals
Requires at least: 5.0
Tested up to: 6.4
Stable tag: 1.4.6
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Embed FreshNews.ai content hub directly into your WordPress site using script-based embedding for optimal E-E-A-T SEO value.

== Description ==

FreshNews AI Content Hub plugin allows you to embed your FreshNews.ai content hub directly into your WordPress site using a script-based embed method. This provides optimal E-E-A-T (Experience, Expertise, Authoritativeness, Trust) SEO value because content is rendered directly on your domain, allowing search engines to properly index and attribute it.

== Features ==

* Script-based embedding (not iframe) for optimal SEO
* Easy configuration via WordPress admin settings
* Auto-create WordPress page with shortcode
* Support for multiple widget modes (signals list, insights list, single article)
* Canonical URL handling for E-E-A-T SEO
* Deferred script loading for better performance
* Customizable theme (light/dark/auto)
* Multi-language support
* robots.txt sitemap integration for crawler discovery

== Installation ==

1. Copy the `freshnews-ai-content-hub` folder to your WordPress `wp-content/plugins/` directory
2. Activate the plugin through the 'Plugins' menu in WordPress
3. Go to Settings → FreshNews AI Content Hub to configure the plugin
4. Enter your Signals URL (e.g., https://signals.yourdomain.com)
5. Enter your Embed Script URL (e.g., https://signals.yourdomain.com/embed/insights.js)
6. Optionally enter your Embed CSS URL (e.g., https://signals.yourdomain.com/embed/insights.css)
7. Configure widget settings (mode, kind, limit, etc.)
8. Save settings
9. The plugin will auto-create a page at /signals (or your configured slug) with the [freshnews_content_hub] shortcode

== Usage ==

After configuration, you can use the shortcode `[freshnews_content_hub]` in any post or page.

For backward compatibility, `[freshnews_newsroom]` also works.

You can also override settings per shortcode:
* `[freshnews_content_hub mode="insights-list" kind="insight" limit="10"]`
* `[freshnews_content_hub mode="article" slug="article-slug"]`

== Settings ==

* **Enabled**: Enable/disable the plugin
* **Signals URL**: Your FreshNews.ai CNAME domain (required)
* **Embed Script URL**: URL to the embed script (required)
* **Embed CSS URL**: Optional CSS stylesheet URL
* **Widget Mode**: Display mode (signals-list, insights-list, article)
* **Article Kind**: Filter by kind (daily, insight, how_to, analysis)
* **Article Limit**: Maximum articles to display (1-100)
* **Link Base URL**: Optional base URL for article links
* **Page Slug**: Slug for auto-created page
* **Page Title**: Title for auto-created page
* **Auto-create Page**: Automatically create/update a WordPress page
* **Language**: Language code (e.g., "en")
* **Theme**: Theme preference (light, dark, auto)
* **Canonical Mode**: Canonical link handling
* **Defer Script Loading**: Defer script loading for performance

== Requirements ==

* WordPress 5.0 or higher
* FreshNews.ai account with CNAME custom domain configured
* Access to your FreshNews.ai embed script URL

== Frequently Asked Questions ==

= Do I need a CNAME custom domain? =

Yes, for production use, you must use a CNAME custom domain (e.g., signals.yourdomain.com). The tenant is automatically resolved from the domain.

= Can I use this for testing? =

Yes, you can use the generic domain (news.freshnews.ai) for testing, but you'll need to provide the tenant slug in the widget configuration.

= Does this work with any WordPress theme? =

Yes, the plugin is designed to work with any WordPress theme. The embed widget uses its own CSS that can be customized.

== Changelog ==

= 1.0.0 =
* Initial release (renamed from FreshNews.ai Newsroom)
* Script-based embedding support
* Admin settings page
* Auto-create page functionality
* Canonical URL handling
* Multiple widget modes support
* robots.txt sitemap integration

== ZIP Packaging ==

To create a distributable ZIP file:

1. Navigate to the parent directory containing the `freshnews-ai-content-hub` folder
2. Create a ZIP file of the entire `freshnews-ai-content-hub` folder
3. The ZIP should contain:
   - freshnews-ai-content-hub.php (main plugin file)
   - includes/ directory (with class-freshnews-ai-content-hub.php and admin-settings.php)
   - assets/ directory (with js/embed-loader.js)
   - uninstall.php
   - readme.txt
   - .gitignore (optional, can be excluded from ZIP)

Users can then install the plugin by:
1. Going to WordPress Admin → Plugins → Add New
2. Clicking "Upload Plugin"
3. Selecting the ZIP file
4. Activating the plugin

== Upgrade Notice ==

= 1.0.0 =
Initial release of FreshNews AI Content Hub plugin.
