Skip to content

Commit ab796a6

Browse files
author
Marco Pereirinha
committed
Update wording on term trasnformations
1 parent a77181a commit ab796a6

2 files changed

Lines changed: 20 additions & 2 deletions

File tree

ui-definitions/settings-image.php

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,17 @@
55
* @package Cloudinary
66
*/
77

8+
use Cloudinary\Utils;
89
use function Cloudinary\get_plugin_instance;
910

11+
$transformations_title = __( 'Cloudinary global transformations', 'cloudinary' );
12+
13+
$taxonomy_slug = Utils::get_sanitized_text( 'taxonomy' );
14+
15+
if ( $taxonomy_slug ) {
16+
$transformations_title = __( 'Term transformations', 'cloudinary' );
17+
}
18+
1019
$settings = array(
1120
array(
1221
'type' => 'panel',
@@ -149,7 +158,7 @@
149158
array(
150159
'type' => 'text',
151160
'slug' => 'image_freeform',
152-
'title' => __( 'Cloudinary global transformations', 'cloudinary' ),
161+
'title' => $transformations_title,
153162
'default' => '',
154163
'tooltip_text' => sprintf(
155164
// translators: The link to transformation reference.

ui-definitions/settings-video.php

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,17 @@
55
* @package Cloudinary
66
*/
77

8+
use Cloudinary\Utils;
89
use function Cloudinary\get_plugin_instance;
910

11+
$transformations_title = __( 'Cloudinary global transformations', 'cloudinary' );
12+
13+
$taxonomy_slug = Utils::get_sanitized_text( 'taxonomy' );
14+
15+
if ( $taxonomy_slug ) {
16+
$transformations_title = __( 'Term transformations', 'cloudinary' );
17+
}
18+
1019
$settings = array(
1120
array(
1221
'type' => 'panel',
@@ -235,7 +244,7 @@
235244
array(
236245
'type' => 'text',
237246
'slug' => 'video_freeform',
238-
'title' => __( 'Cloudinary global transformations', 'cloudinary' ),
247+
'title' => $transformations_title,
239248
'default' => '',
240249
'tooltip_text' => sprintf(
241250
// translators: The link to transformation reference.

0 commit comments

Comments
 (0)