Skip to content

Commit

Permalink
Merge pull request #3737 from 10up/chore/copy-changes
Browse files Browse the repository at this point in the history
Copy changes
  • Loading branch information
felipeelia committed Oct 30, 2023
2 parents e3b6a2d + 45dd714 commit b9f5640
Show file tree
Hide file tree
Showing 18 changed files with 39 additions and 26 deletions.
20 changes: 16 additions & 4 deletions assets/js/features/index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
* WordPress dependencies.
*/
import { createRoot, render, WPElement } from '@wordpress/element';
import { createInterpolateElement, createRoot, render, WPElement } from '@wordpress/element';
import { __ } from '@wordpress/i18n';

/**
Expand Down Expand Up @@ -42,9 +42,21 @@ const App = () => (
syncUrl={syncUrl}
>
<p>
{__(
'Features explanation. Bacon ipsum dolor amet turkey cow turducken, tri-tip bresaola landjaeger biltong kevin short ribs alcatra shoulder frankfurter. Buffalo boudin meatloaf sausage cow prosciutto.',
'elasticpress',
{createInterpolateElement(
__(
'ElasticPress Features add functionality to enhance search and queries on your site. You may choose to activate some or all of these Features depending on your needs. You can learn more about each Feature <a>here</a>.',
'elasticpress',
),
{
a: (
// eslint-disable-next-line jsx-a11y/anchor-has-content, jsx-a11y/control-has-associated-label
<a
target="_blank"
href="https://elasticpress.zendesk.com/hc/en-us/articles/16671825423501-Features"
rel="noreferrer"
/>
),
},
)}
</p>
<Features />
Expand Down
2 changes: 1 addition & 1 deletion assets/js/sync-ui/components/offset.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export default () => {
<TextControl
className="ep-sync-advanced-control"
disabled={isSyncing}
help={__('Skip this many objects when syncing.', 'elasticpress')}
help={__('Specify the number of objects to skip during syncing.', 'elasticpress')}
label={__('Skip objects', 'elasticpress')}
onChange={(offset) => setArgs({ ...args, offset })}
type="number"
Expand Down
2 changes: 1 addition & 1 deletion assets/js/sync-ui/components/put-mapping.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export default () => {
{args.put_mapping ? (
<Notice isDismissible={false} status="warning">
{__(
'May result in small changes in website search behaviour while sync is completed.',
'Search results could be out of date or returned in different order while the sync completes.',
'elasticpress',
)}
</Notice>
Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/Autosuggest/Autosuggest.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function __construct() {

$this->short_title = esc_html__( 'Autosuggest', 'elasticpress' );

$this->summary = __( '<p>Suggest relevant content as text is entered into the search field.</p><p>Input fields of type "search" or with the CSS class "search-field" or "ep-autosuggest" will be enhanced with autosuggest functionality. As text is entered into the search field, suggested content will appear below it, based on top search results for the text. Suggestions link directly to the content.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'Input fields of type "search" or with the CSS class "search-field" or "ep-autosuggest" will be enhanced with autosuggest functionality. As text is entered into the search field, suggested content will appear below it, based on top search results for the text. Suggestions link directly to the content.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#autosuggest', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/Comments/Comments.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function __construct() {

$this->title = esc_html__( 'Comments', 'elasticpress' );

$this->summary = __( '<p>Improve comment search relevancy and query performance.</p><p>This feature will empower your website to overcome traditional WordPress comment search and query limitations that can present themselves at scale.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'This feature will empower your website to overcome traditional WordPress comment search and query limitations that can present themselves at scale. This feature is only needed if you are using <code>WP_Comment_Query</code> directly.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#comments', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/DidYouMean/DidYouMean.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function __construct() {

$this->title = esc_html__( 'Did You Mean', 'elasticpress' );

$this->summary = __( '<p>Recommend alternative search terms for misspelled queries or terms with no results.</p><p>"Did You Mean" search feature provides alternative suggestions for misspelled or ambiguous search queries, enhancing search accuracy and user experience. To display suggestions in your theme, please follow <a href="https://elasticpress.zendesk.com/hc/en-us/articles/16673223107085-Did-You-Mean">this tutorial</a>.</p>', 'elasticpress' );
$this->summary = '<p>' . __( '"Did You Mean" search feature provides alternative suggestions for misspelled or ambiguous search queries, enhancing search accuracy and user experience. To display suggestions in your theme, please follow <a href="https://elasticpress.zendesk.com/hc/en-us/articles/16673223107085-Did-You-Mean">this tutorial</a>.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/16673223107085-Did-You-Mean', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/Documents/Documents.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public function __construct() {

$this->title = esc_html__( 'Documents', 'elasticpress' );

$this->summary = __( '<p>Indexes text inside of popular file types, and adds those files types to search results.</p><p>Website search results will include popular document file types, using file names as well as their content. Supported file types include: ppt, pptx, doc, docx, xls, xlsx, pdf.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'Website search results will include popular document file types, using file names as well as their content. Supported file types include: ppt, pptx, doc, docx, xls, xlsx, pdf.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#documents', 'elasticpress' );

Expand Down
10 changes: 4 additions & 6 deletions includes/classes/Feature/Facets/Facets.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,21 +40,19 @@ public function __construct() {

$this->title = esc_html__( 'Filters', 'elasticpress' );

$this->summary = sprintf(
/* translators: %s: Long feature summary. */
__( '<p>Add controls to your website to filter content by one or more taxonomies.</p><p>%s</p>', 'elasticpress' ),
$this->summary = '<p>' .
wp_is_block_theme()
? sprintf(
/* translators: Site Editor URL */
__( 'Adds <a href="%s">filter blocks</a> that administrators can add to the website’s templates and template parts, so that visitors can filter applicable content and search results by one or more taxonomy terms.', 'elasticpress' ),
__( 'Adds <a href="%s">filter blocks</a> that administrators can add to the website’s templates and template parts, so that visitors can filter applicable content and search results by one or more taxonomy terms, metafields, and date ranges.', 'elasticpress' ),
esc_url( admin_url( 'site-editor.php' ) )
)
: sprintf(
/* translators: Widgets Edit Screen URL */
__( 'Adds <a href="%s">filter widgets</a> that administrators can add to the website’s sidebars (widgetized areas), so that visitors can filter applicable content and search results by one or more taxonomy terms.', 'elasticpress' ),
__( 'Adds <a href="%s">filter widgets</a> that administrators can add to the website’s sidebars (widgetized areas), so that visitors can filter applicable content and search results by one or more taxonomy terms, metafields, and date ranges.', 'elasticpress' ),
esc_url( admin_url( 'widgets.php' ) )
)
);
. '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#facets', 'elasticpress' );

Expand Down
3 changes: 2 additions & 1 deletion includes/classes/Feature/InstantResults/InstantResults.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,8 @@ public function __construct() {

$this->short_title = esc_html__( 'Instant Results', 'elasticpress' );

$this->summary = __( '<p>Search forms display results instantly after submission. A modal opens that populates results by querying ElasticPress directly.</p><p>WordPress search forms will display results instantly. When the search query is submitted, a modal will open that populates results by querying ElasticPress directly, bypassing WordPress. As the user refines their search, results are refreshed.</p><p>Requires an <a href="https://www.elasticpress.io/" target="_blank">ElasticPress.io plan</a> or a custom proxy to function.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'WordPress search forms will display results instantly. When the search query is submitted, a modal will open that populates results by querying ElasticPress directly, bypassing WordPress. As the user refines their search, results are refreshed.', 'elasticpress' ) . '</p>' .
'<p>' . __( 'Requires an <a href="https://www.elasticpress.io/" target="_blank">ElasticPress.io plan</a> or a custom proxy to function.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#instant-results', 'elasticpress' );

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ public function __construct() {

$this->title = esc_html__( 'Protected Content', 'elasticpress' );

$this->summary = __( '<p>Optionally index all of your content, including private and unpublished content, to speed up searches and queries in places like the administrative dashboard.</p><p>Securely indexes unpublished content—including private, draft, and scheduled posts —improving load times in places like the administrative dashboard where WordPress needs to include protected content in a query.</p><p><em>We recommend using a secured Elasticsearch setup, such as ElasticPress.io, to prevent potential exposure of content not intended for the public.</em></p>', 'elasticpress' );
$this->summary = '<p>' . __( 'Syncs unpublished content — including private, draft, and scheduled posts — improving load times in places like the administrative dashboard where WordPress needs to include protected content in a query.', 'elasticpress' ) . '</p>' .
'<p><em>' . __( 'We recommend using a secured Elasticsearch setup, such as ElasticPress.io, to prevent potential exposure of content not intended for the public.', 'elasticpress' ) . '</em></p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#protected-content', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/RelatedPosts/RelatedPosts.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function __construct() {

$this->title = esc_html__( 'Related Posts', 'elasticpress' );

$this->summary = __( '<p>ElasticPress understands data in real time, so it can instantly deliver engaging and precise related content with no impact on site performance.</p><p>Output related content using our Widget or directly in your theme using our <a href="https://elasticpress.zendesk.com/hc/en-us/articles/16671825423501-Features#related-posts">API functions.</a></p>', 'elasticpress' );
$this->summary = '<p>' . __( 'Instantly deliver engaging and precise related content with no impact on site performance. Output related content using our block or directly in your theme using our <a href="https://elasticpress.zendesk.com/hc/en-us/articles/16671825423501-Features#related-posts">API functions</a>.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#related-posts', 'elasticpress' );

Expand Down
3 changes: 2 additions & 1 deletion includes/classes/Feature/Search/Search.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ public function __construct() {

$this->title = esc_html__( 'Post Search', 'elasticpress' );

$this->summary = __( '<p>Instantly find the content you’re looking for. The first time.</p><p>Overcome higher-end performance and functional limits posed by the traditional WordPress structured (SQL) database to deliver superior keyword search, instantly. ElasticPress indexes custom fields, tags, and other metadata to improve search results. Fuzzy matching accounts for misspellings and verb tenses.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'Instantly find the content you’re looking for. The first time.', 'elasticpress' ) . '</p>' .
'<p>' . __( 'Overcome higher-end performance and functional limits posed by the traditional WordPress structured (SQL) database to deliver superior keyword search, instantly. ElasticPress indexes custom fields, tags, and other metadata to improve search results. Fuzzy matching accounts for misspellings and verb tenses.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#post-search', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/SearchOrdering/SearchOrdering.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public function __construct() {

$this->title = esc_html__( 'Custom Search Results', 'elasticpress' );

$this->summary = __( '<p>Insert specific posts into search results for specific search queries.</p><p>Selected posts will be inserted into search results in the specified position.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'Selected posts will be inserted into search results in the specified position.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#custom-search-results', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/Terms/Terms.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function __construct() {

$this->title = esc_html__( 'Terms', 'elasticpress' );

$this->summary = __( '<p>Improve WP_Term_Query relevancy and query performance. This feature is only needed if you are using WP_Term_Query directly.</p><p>This feature will empower your website to overcome traditional WordPress term search and query limitations that can present themselves at scale.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'This feature will empower your website to overcome traditional WordPress term search and query limitations that can present themselves at scale. This feature is only needed if you are using <code>WP_Term_Query</code> directly.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#terms', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion includes/classes/Feature/WooCommerce/WooCommerce.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function __construct() {

$this->title = esc_html__( 'WooCommerce', 'elasticpress' );

$this->summary = __( '<p>With ElasticPress, filtering WooCommerce product results is fast and easy. Your customers can find and buy exactly what they’re looking for, even if you have a large or complex product catalog.</p><p>Most caching and performance tools can’t keep up with the nearly infinite ways your visitors might filter or navigate your products. No matter how many products, filters, or customers you have, ElasticPress will keep your online store performing quickly. If used in combination with the Protected Content feature, ElasticPress will also accelerate order searches and back end product management.</p>', 'elasticpress' );
$this->summary = '<p>' . __( 'Most caching and performance tools can’t keep up with the nearly infinite ways your visitors might filter or navigate your products. No matter how many products, filters, or customers you have, ElasticPress will keep your online store performing quickly. If used in combination with the Protected Content feature, ElasticPress will also accelerate order searches and back end product management.', 'elasticpress' ) . '</p>';

$this->docs_url = __( 'https://elasticpress.zendesk.com/hc/en-us/articles/360050447492-Configuring-ElasticPress-via-the-Plugin-Dashboard#woocommerce', 'elasticpress' );

Expand Down
2 changes: 1 addition & 1 deletion tests/php/features/TestAutosuggest.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public function testBoxSummary() {
$this->get_feature()->output_feature_box_summary();
$output = ob_get_clean();

$this->assertStringContainsString( 'Suggest relevant content as text is entered into the search field', $output );
$this->assertStringContainsString( 'As text is entered into the search field, suggested content will appear below it', $output );
}

/**
Expand Down
2 changes: 1 addition & 1 deletion tests/php/features/TestComments.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public function testBoxSummary() {
$this->get_feature()->output_feature_box_summary();
$output = ob_get_clean();

$this->assertStringContainsString( 'Improve comment search relevancy and query performance.', $output );
$this->assertStringContainsString( 'This feature is only needed if you are using <code>WP_Comment_Query</code> directly.', $output );
}

/**
Expand Down
2 changes: 1 addition & 1 deletion tests/php/features/TestSearchOrdering.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public function testOutputFeatureBoxSummary() {
$this->get_feature()->output_feature_box_summary();
$output = ob_get_clean();

$this->assertStringContainsString( 'Insert specific posts into search results for specific search queries.', $output );
$this->assertStringContainsString( 'Selected posts will be inserted into search results in the specified position.', $output );
}

/**
Expand Down

0 comments on commit b9f5640

Please sign in to comment.