Skip to content

Commit 4dfbdca

Browse files
author
Marco Pereirinha
committed
Update wording so it is clear it is a Cloudinary feature
1 parent 45a5b12 commit 4dfbdca

4 files changed

Lines changed: 32 additions & 11 deletions

File tree

php/media/class-global-transformations.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ public function load_preview( $video = false ) {
319319
*/
320320
public function taxonomy_ordering( $type, $post ) {
321321
if ( $this->has_public_taxonomies( $post ) ) {
322-
add_meta_box( 'cld-taxonomy-order', __( 'Categories/Tags transformations', 'cloudinary' ), array( $this, 'render_ordering_box' ), null, 'side', 'core' );
322+
add_meta_box( 'cld-taxonomy-order', __( 'Cloudinary terms transformations', 'cloudinary' ), array( $this, 'render_ordering_box' ), null, 'side', 'core' );
323323
}
324324
}
325325

@@ -451,7 +451,7 @@ private function init_taxonomy_manager( $post ) {
451451

452452
$out = array();
453453
$out[] = '<div class="cld-tax-order">';
454-
$out[] = '<p style="font-size: 12px; font-style: normal; color: rgb( 117, 117, 117 );">' . esc_html__( 'If you placed custom transformations on categories/tags you may order them below. ', 'cloudinary' ) . '</li>';
454+
$out[] = '<p style="font-size: 12px; font-style: normal; color: rgb( 117, 117, 117 );">' . esc_html__( 'If you placed custom transformations on these terms you may order them below. ', 'cloudinary' ) . '</li>';
455455
$out[] = '<ul class="cld-tax-order-list" id="cld-tax-items">';
456456
$out[] = '<li class="cld-tax-order-list-item no-items">' . esc_html__( 'No terms added', 'cloudinary' ) . '</li>';
457457
if ( ! empty( $terms ) ) {
@@ -464,7 +464,7 @@ private function init_taxonomy_manager( $post ) {
464464
// Get apply Type.
465465
if ( ! empty( $terms ) ) {
466466
$type = get_post_meta( $post->ID, self::META_APPLY_KEY . '_terms', true );
467-
$out[] = '<label class="cld-tax-order-list-type"><input ' . checked( 'overwrite', $type, false ) . ' type="checkbox" value="overwrite" name="cld_apply_type" />' . esc_html__( 'Disable global transformations', 'cloudinary' ) . '</label>';
467+
$out[] = '<label class="cld-tax-order-list-type"><input ' . checked( 'overwrite', $type, false ) . ' type="checkbox" value="overwrite" name="cld_apply_type" />' . esc_html__( 'Disable Cloudinary global transformations', 'cloudinary' ) . '</label>';
468468
}
469469

470470
$out[] = '</div>';

php/templates/taxonomy-term-transformation-fields.php

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,31 @@
55
* @package Cloudinary
66
*/
77

8+
use Cloudinary\Utils;
9+
10+
$taxonomy_slug = Utils::get_sanitized_text( 'taxonomy' );
11+
$tax_object = get_taxonomy( $taxonomy_slug );
12+
13+
// We should be in the context of a term edit screen.
14+
if ( ! $tax_object instanceof WP_Taxonomy ) {
15+
return;
16+
}
17+
18+
$label = $tax_object->labels->singular_name;
819
?>
920
<?php foreach ( $this->taxonomy_fields as $context => $set ) : ?>
1021
<tr>
1122
<td colspan="2">
1223
<h3>
1324
<?php
14-
// translators: variable is context.
15-
echo esc_html( sprintf( __( 'Global %s Transformations', 'cloudinary' ), ucwords( $context ) ) );
25+
echo esc_html(
26+
sprintf(
27+
// translators: The taxonomy label and the context.
28+
__( 'Cloudinary %1$s %2$s Transformations', 'cloudinary' ),
29+
$label,
30+
ucwords( $context )
31+
)
32+
);
1633
?>
1734
</h3>
1835
</td>

ui-definitions/settings-image.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,16 +149,18 @@
149149
array(
150150
'type' => 'text',
151151
'slug' => 'image_freeform',
152-
'title' => __( 'Additional image transformations', 'cloudinary' ),
152+
'title' => __( 'Cloudinary global transformations', 'cloudinary' ),
153153
'default' => '',
154154
'tooltip_text' => sprintf(
155155
// translators: The link to transformation reference.
156156
__(
157-
'A set of additional transformations to apply to all images. Specify your transformations using Cloudinary URL transformation syntax. See %1$sreference%2$s for all available transformations and syntax.',
157+
'A set of additional transformations to apply to all images. Specify your transformations using Cloudinary URL transformation syntax. See %1$sreference%2$s for all available transformations and syntax.%3$s* The Cloudinary global transformations are only applied to assets managed in the Media Library%4$s.',
158158
'cloudinary'
159159
),
160160
'<a href="https://cloudinary.com/documentation/transformation_reference" target="_blank" rel="noopener noreferrer">',
161-
'</a>'
161+
'</a>',
162+
'<br><br><em>',
163+
'</em>'
162164
),
163165
'link' => array(
164166
'text' => __( 'See examples', 'cloudinary' ),

ui-definitions/settings-video.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -235,16 +235,18 @@
235235
array(
236236
'type' => 'text',
237237
'slug' => 'video_freeform',
238-
'title' => __( 'Additional video transformations', 'cloudinary' ),
238+
'title' => __( 'Cloudinary global transformations', 'cloudinary' ),
239239
'default' => '',
240240
'tooltip_text' => sprintf(
241241
// translators: The link to transformation reference.
242242
__(
243-
'A set of additional transformations to apply to all videos. Specify your transformations using Cloudinary URL transformation syntax. See %1$sreference%2$s for all available transformations and syntax.',
243+
'A set of additional transformations to apply to all videos. Specify your transformations using Cloudinary URL transformation syntax. See %1$sreference%2$s for all available transformations and syntax.%3$s* The Cloudinary global transformations are only applied to assets managed in the Media Library%4$s.',
244244
'cloudinary'
245245
),
246246
'<a href="https://cloudinary.com/documentation/transformation_reference" target="_blank" rel="noopener noreferrer">',
247-
'</a>'
247+
'</a>',
248+
'<br><br><em>',
249+
'</em>'
248250
),
249251
'link' => array(
250252
'text' => __( 'See examples', 'cloudinary' ),

0 commit comments

Comments
 (0)