Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- Update "Content Helper" to "Content Intelligence" on settings page ([#3489](github.com/Parsely/wp-parsely/pull/3489))
- Update "Content Helper" to "Content Intelligence" on settings page ([#3489](https://github.com/Parsely/wp-parsely/pull/3489))

### Fixed

Expand Down
24 changes: 12 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,18 @@ The plugin automatically inserts the Parse.ly metadata and JavaScript in all pub
- Choose whether logged-in users should be tracked.
- Define how to track every Post Type (as Post, Non-Post or no tracking).

#### The Parse.ly Content Helper

The [Content Helper](https://docs.parse.ly/plugin-content-helper/) is a set of content insight tools including:
- The [Parse.ly Dashboard Widget](https://docs.parse.ly/plugin-content-helper/#h-dashboard) - Displays the site's top posts in the WordPress Dashboard.
- The [Parse.ly Stats Column](https://docs.parse.ly/plugin-content-helper/#h-posts) - Displays published post performance for the last 7 days in Post Lists.
- The [Engagement Boost](https://docs.wpvip.com/parse-ly/wp-parsely-features/traffic-boost/) feature - Helps you increase page views and engagement by strategically placing links to key content within high-performing articles on your site.
- The [Parse.ly Editor Sidebar](https://docs.parse.ly/plugin-content-helper/#h-editor) - This sidebar is integrated into the WordPress Editor and offers insights about the content currently being edited such as:
- [Title Suggestions](https://docs.wpvip.com/parse-ly/wp-parsely-features/title-suggestions/) - Generates title suggestions for the post/page currently being edited.
- [Excerpt Suggestions](https://docs.wpvip.com/parse-ly/wp-parsely-features/excerpt-suggestions/) - Generates an excerpt suggestion for the post/page currently being edited.
- [Smart Linking](https://docs.wpvip.com/parse-ly/wp-parsely-features/smart-linking/) - Automatically adds links to the current content that point to the most relevant and top-performing posts.
- [Related Posts](https://docs.parse.ly/plugin-content-helper/#h-related-posts) - Displays a list of the website’s most successful posts, similar to the post/page currently being edited.
- [Performance Stats](https://docs.parse.ly/plugin-content-helper/#h-see-performance-details) - Displays performance metrics about the content currently being edited.
#### Parse.ly Content Intelligence

[Content Intelligence](https://docs.parse.ly/plugin-content-intelligence/) is a set of content insight tools including:
- The [Parse.ly Dashboard Widget](https://docs.parse.ly/plugin-content-intelligence/#h-dashboard) - Displays the site's top posts in the WordPress Dashboard.
- The [Parse.ly Stats Column](https://docs.parse.ly/plugin-content-intelligence/#h-posts) - Displays published post performance for the last 7 days in Post Lists.
- The [Engagement Boost](https://docs.wpvip.com/parse-ly/parsely-features/engagement-boost/) feature - Helps you increase page views and engagement by strategically placing links to key content within high-performing articles on your site.
- The [Parse.ly Editor Sidebar](https://docs.parse.ly/plugin-content-intelligence/#h-editor) - This sidebar is integrated into the WordPress Editor and offers insights about the content currently being edited such as:
- [Title Suggestions](https://docs.wpvip.com/parse-ly/parsely-features/title-suggestions/) - Generates title suggestions for the post/page currently being edited.
- [Excerpt Suggestions](https://docs.wpvip.com/parse-ly/parsely-features/excerpt-suggestions/) - Generates an excerpt suggestion for the post/page currently being edited.
- [Smart Linking](https://docs.wpvip.com/parse-ly/parsely-features/smart-linking/) - Automatically adds links to the current content that point to the most relevant and top-performing posts.
- [Related Posts](https://docs.parse.ly/plugin-content-intelligence/#h-related-posts) - Displays a list of the website’s most successful posts, similar to the post/page currently being edited.
- [Performance Stats](https://docs.parse.ly/plugin-content-intelligence/#h-see-performance-details) - Displays performance metrics about the content currently being edited.

#### The Parse.ly Recommendations Block

Expand Down
2 changes: 1 addition & 1 deletion build/admin-settings.asset.php
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?php return array('dependencies' => array('react', 'wp-api-fetch', 'wp-data', 'wp-escape-html', 'wp-i18n', 'wp-url'), 'version' => '06c370fcce39bc6e0276');
<?php return array('dependencies' => array('react', 'wp-api-fetch', 'wp-data', 'wp-escape-html', 'wp-i18n', 'wp-url'), 'version' => '66f2b3e882defbfd9d95');
2 changes: 1 addition & 1 deletion build/admin-settings.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/TESTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,10 +122,10 @@ Before releasing a new wp-parsely version, we should perform a basic manual smok
- Visit the settings page and click on the tabs
- Update a setting using the settings page
- Try to save an invalid Site ID and API Secret combination
- Try the Content Helper Widget and Sidebar with:
- Try the Content Intelligence Widget and Sidebar with:
- An empty API Secret
- No Site ID
- Check that The Content Helper Post List Stats appears
- Check that The Content Intelligence Post List Stats appears
- Check that "ld+json" and "parsely-cfg" are injected into the front-end

This list is currently a work in progress.
2 changes: 1 addition & 1 deletion src/UI/class-dashboard-page.php
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ public function enqueue_dashboard_page_scripts( ?string $hook_suffix ): void {
}

/**
* Injects Content Helper permissions into the dashboard page.
* Injects Content Intelligence permissions into the dashboard page.
*
* @since 3.19.0
*/
Expand Down
13 changes: 7 additions & 6 deletions src/UI/class-settings-page.php
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,8 @@ final class Settings_Page {
private $managed_options_badge = array();

/**
* The Content Helper features that can be configured in the settings page.
* The Content Intelligence features that can be configured in the settings
* page.
*
* @since 3.16.0
*
Expand Down Expand Up @@ -429,12 +430,12 @@ private function initialize_basic_section(): void {
}

/**
* Registers the Content Helper section and its settings.
* Registers the Content Intelligence section and its settings.
*
* @since 3.16.0
*/
private function initialize_content_helper_section(): void {
$section_key = 'content-helper-section';
$section_key = 'content-intelligence-section';

add_settings_section(
$section_key,
Expand Down Expand Up @@ -936,7 +937,7 @@ public function print_checkbox_tag( $args, $options = null ): void {
}

/**
* Prints a Content Helper AI feature section.
* Prints a Content Intelligence AI feature section.
*
* @since 3.16.0
*
Expand Down Expand Up @@ -1309,7 +1310,7 @@ private function validate_basic_section( $input ): array {
}

/**
* Validates the fields of the Content Helper section.
* Validates the fields of the Content Intelligence section.
*
* @since 3.16.0
*
Expand All @@ -1318,7 +1319,7 @@ private function validate_basic_section( $input ): array {
*/
private function validate_content_helper_section( $input ) {
/**
* Sanitizes the Content Helper data.
* Sanitizes the Content Intelligence data.
*
* @since 3.16.0
*/
Expand Down
7 changes: 4 additions & 3 deletions src/class-parsely.php
Original file line number Diff line number Diff line change
Expand Up @@ -561,13 +561,14 @@ public function get_options() {
$this->set_default_full_metadata_in_non_posts();
}

// Existing plugin installation without Content Helper options.
// Existing plugin installation without Content Intelligence options.
/* @phpstan-ignore isset.offset, booleanAnd.alwaysFalse */
if ( is_array( $options ) && ! isset( $options['content_helper'] ) ) {
$this->set_default_content_helper_settings_values();
}

// Existing plugin installation that's missing a Content Helper feature option.
// Existing plugin installation that's missing a Content Intelligence
// feature option.
/* @phpstan-ignore isset.offset */
if ( is_array( $options ) && isset( $options['content_helper'] ) ) {
/** @var array<string,Parsely_Options_Content_Helper_Feature> $pch_options */
Expand Down Expand Up @@ -685,7 +686,7 @@ public function set_default_full_metadata_in_non_posts(): void {
}

/**
* Sets the default values for Content Helper options.
* Sets the default values for Content Intelligence options.
*
* Gives PCH access to all users having the edit_posts capability, to keep
* consistent behavior with plugin versions prior to 3.16.0.
Expand Down
14 changes: 7 additions & 7 deletions src/class-permissions.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,12 @@ public static function get_user_roles_with_edit_posts_cap(): array {

/**
* Returns whether the current user has the permission to access the
* specified Content Helper feature.
* specified Content Intelligence feature.
*
* @since 3.16.0
*
* @param string $feature_name The feature's name.
* @param Parsely_Options_Content_Helper $pch_options The Content Helper options.
* @param Parsely_Options_Content_Helper $pch_options The Content Intelligence options.
* @param int|false $post_id The post ID, if the check is for a specific post.
* @return bool Whether the current user can access the specified feature.
*/
Expand All @@ -74,8 +74,8 @@ public static function current_user_can_use_pch_feature(
$user_roles = $current_user->roles;

/**
* Filters whether the current user can use the specified Content Helper
* feature.
* Filters whether the current user can use the specified Content
* Intelligence feature.
*
* This filter can be used to override the default permissions check.
*
Expand Down Expand Up @@ -148,8 +148,8 @@ public static function current_user_can_use_pch_feature(
}

/**
* Returns a JSON-encoded string with the Content Helper permissions for the
* current user.
* Returns a JSON-encoded string with the Content Intelligence permissions
* for the current user.
*
* @since 3.16.0
*
Expand Down Expand Up @@ -179,7 +179,7 @@ public static function get_pch_permissions_json( $pch_options ): string {
}

/**
* Builds and returns a permissions settings array for the Content Helper,
* Builds and returns a permissions settings array for Content Intelligence,
* based on the passed values.
*
* @since 3.16.0
Expand Down
12 changes: 6 additions & 6 deletions src/content-helper/common/class-content-helper-feature.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Content Helper: Base class for all Content Helper features
* Content Intelligence: Base class for all Content Intelligence features
*
* @package Parsely
* @since 3.9.0
Expand All @@ -15,7 +15,7 @@
use WP_REST_Request;

/**
* Base class for all Content Helper features.
* Base class for all Content Intelligence features.
*
* @since 3.9.0
*/
Expand All @@ -29,8 +29,8 @@ abstract class Content_Helper_Feature {
protected $parsely;

/**
* Returns the global Content Helper filter name. The global filter controls
* the enabled/disabled state of all Content Helper features.
* Returns the global Content Intelligence filter name. The global filter
* controls the enabled/disabled state of all Content Intelligence features.
*
* @since 3.9.0
*
Expand All @@ -42,7 +42,7 @@ final public static function get_global_filter_name(): string {

/**
* Returns the feature's filter name. The feature filter controls the
* enabled/disabled state of a particular Content Helper feature.
* enabled/disabled state of a particular Content Intelligence feature.
*
* @since 3.9.0
*
Expand Down Expand Up @@ -136,7 +136,7 @@ protected function inject_inline_scripts(
$are_credentials_set = $this->parsely->site_id_is_set() &&
$this->parsely->api_secret_is_set();

// Inject Content Helper permissions.
// Inject Content Intelligence permissions.
$permissions_json = Permissions::get_pch_permissions_json(
$this->parsely->get_options()['content_helper']
);
Expand Down
6 changes: 3 additions & 3 deletions src/content-helper/common/content-helper-error.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ import {

/**
* Enumeration of all the possible errors that might get thrown or processed by
* the Content Helper during error handling. All errors thrown by the Content
* Helper should start with a "ch_" prefix.
* Content Intelligence during error handling. All errors thrown by Content
* Intelligence should start with a "ch_" prefix.
*/
export enum ContentHelperErrorCode {
AccessToFeatureDisabled = 'ch_access_to_feature_disabled',
Expand Down Expand Up @@ -45,7 +45,7 @@ export enum ContentHelperErrorCode {
}

/**
* Extends the standard JS Error class for use with the Content Helper.
* Extends the standard JS Error class for use with Content Intelligence.
*
* @see https://github.com/microsoft/TypeScript/wiki/FAQ#why-doesnt-extending-built-ins-like-error-array-and-map-work
*/
Expand Down
2 changes: 1 addition & 1 deletion src/content-helper/common/css/common.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
@import "../components/loading/style";

/**
* Common styles for the content helper.
* Common styles for Content Intelligence.
*/
.parsely-panel-settings {
width: 100%;
Expand Down
6 changes: 3 additions & 3 deletions src/content-helper/common/utils/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export const DASHBOARD_BASE_URL = 'https://dash.parsely.com';
export const PUBLIC_API_BASE_URL = 'https://api.parsely.com/v2';

/**
* Periods that are available in the Content Helper.
* Periods that are available in Content Intelligence.
*
* @since 3.10.0
* @since 3.11.0 Moved to constants.ts.
Expand All @@ -23,7 +23,7 @@ export enum Period {
}

/**
* Metrics that are available in the Content Helper.
* Metrics that are available in Content Intelligence.
*
* @since 3.10.0
* @since 3.11.0 Moved to constants.ts.
Expand All @@ -34,7 +34,7 @@ export enum Metric {
}

/**
* Post filter types that are available in the Content Helper.
* Post filter types that are available in Content Intelligence.
*
* @since 3.11.0
*/
Expand Down
4 changes: 2 additions & 2 deletions src/content-helper/common/utils/permissions.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/**
* Defines the structure of a Content Helper Permissions object.
* Defines the structure of a Content Intelligence Permissions object.
*
* @since 3.16.0
*/
Expand All @@ -11,7 +11,7 @@ export interface ContentHelperPermissions {
}

/**
* Returns the current user's permissions for the Content Helper.
* Returns the current user's permissions for Content Intelligence.
*
* @since 3.16.0
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ protected function can_enable_feature( bool ...$conditions ): bool {

/**
* Returns the feature's filter name. The feature filter controls the
* enabled/disabled state of a particular Content Helper feature.
* enabled/disabled state of a particular Content Intelligence feature.
*
* Not in use for Editor Sidebar features.
*
Expand Down
4 changes: 2 additions & 2 deletions src/content-helper/editor-sidebar/editor-sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -190,11 +190,11 @@ export const getSettingsFromJson = ( settingsJson: string = '' ): SidebarSetting
};

/**
* Returns the Content Helper Editor Sidebar.
* Returns the Content Intelligence Editor Sidebar.
*
* @since 3.4.0
*
* @return {import('react').JSX.Element} The Content Helper Editor Sidebar.
* @return {import('react').JSX.Element} The Content Intelligence Editor Sidebar.
*/
const ContentHelperEditorSidebar = (): React.JSX.Element => {
const { settings, setSettings } = useSettings<SidebarSettings>();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* Content Helper: Excerpt Suggestions feature class
* Content Intelligence: Excerpt Suggestions feature class
*
* @package Parsely
* @since 3.13.0
Expand All @@ -13,7 +13,7 @@
use Parsely\Content_Helper\Editor_Sidebar\Editor_Sidebar_Feature;

/**
* Content Helper: Excerpt Suggestions feature class
* Content Intelligence: Excerpt Suggestions feature class
*
* @since 3.13.0
* @since 3.17.0 Renamed to Excerpt Suggestions and converted to an Editor Sidebar feature.
Expand Down Expand Up @@ -101,7 +101,7 @@ public function callback_is_feature_enabled(
}

/**
* Inserts Content Helper Excerpt Suggestions inline scripts.
* Inserts Content Intelligence Excerpt Suggestions inline scripts.
*
* @since 3.17.0
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,8 @@ export const RelatedPostsPanel = (): React.JSX.Element => {
const { getEditedPostContent } = select( 'core/editor' ) as GutenbergFunction;
debouncedSetPostContent( getEditedPostContent() );
} else {
// It would be better to mock this in the Content Helper structure
// test.
// It would be better to mock this in the Content Intelligence
// structure test.
debouncedSetPostContent( 'Jest test is running' );
}
}, [ debouncedSetPostContent ] );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ type SidebarPerformanceTabProps = {

/**
* SidebarPerformanceTab component.
* Renders the Performance tab in the Content Helper Sidebar.
* Renders the Performance tab in the Content Intelligence Sidebar.
*
* @since 3.14.0
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ type SidebarToolsTabProps = {

/**
* SidebarToolsTab component.
* Renders the Tools tab in the Content Helper sidebar.
* Renders the Tools tab in the Content Intelligence sidebar.
*
* @since 3.14.0
*
Expand Down
Loading
Loading