@@ -286,7 +286,6 @@ protected function render_content() {
286
286
* @access public
287
287
*/
288
288
public function repeater_js_template () {
289
- $ l10n = Kirki_l10n::get_strings ();
290
289
?>
291
290
<script type="text/html" class="customize-control-repeater-content">
292
291
<# var field; var index = data.index; #>
@@ -434,22 +433,22 @@ public function repeater_js_template() {
434
433
<# } #>
435
434
</label>
436
435
437
- <figure class="kirki-image-attachment" data-placeholder="<?php esc_attr_e ( $ l10n ['no-image-selected ' ] ); ?> " >
436
+ <figure class="kirki-image-attachment" data-placeholder="{{ window.kirki. l10n['no-image-selected'] }} " >
438
437
<# if ( field.default ) { #>
439
438
<# var defaultImageURL = ( field.default.url ) ? field.default.url : field.default; #>
440
439
<img src="{{{ defaultImageURL }}}">
441
440
<# } else { #>
442
- <?php esc_attr_e ( $ l10n ['no-image-selected ' ] ); ?>
441
+ {{ window.kirki. l10n['no-image-selected'] }}
443
442
<# } #>
444
443
</figure>
445
444
446
445
<div class="actions">
447
- <button type="button" class="button remove-button<# if ( ! field.default ) { #> hidden<# } #>"><?php esc_attr_e ( $ l10n ['remove ' ] ); ?> </button>
448
- <button type="button" class="button upload-button" data-label="<?php esc_attr_e ( $ l10n ['add-image ' ] ); ?> " data-alt-label="<?php esc_attr_e ( $ l10n ['change-image ' ] ); ?> " >
446
+ <button type="button" class="button remove-button<# if ( ! field.default ) { #> hidden<# } #>">{{ window.kirki. l10n['remove'] }} </button>
447
+ <button type="button" class="button upload-button" data-label=" {{ window.kirki. l10n['add-image'] }} " data-alt-label="{{ window.kirki. l10n['change-image'] }} " >
449
448
<# if ( field.default ) { #>
450
- <?php esc_attr_e ( $ l10n ['change-image ' ] ); ?>
449
+ {{ window.kirki. l10n['change-image'] }}
451
450
<# } else { #>
452
- <?php esc_attr_e ( $ l10n ['add-image ' ] ); ?>
451
+ {{ window.kirki. l10n['add-image'] }}
453
452
<# } #>
454
453
</button>
455
454
<# if ( field.default.id ) { #>
@@ -470,22 +469,22 @@ public function repeater_js_template() {
470
469
<# } #>
471
470
</label>
472
471
473
- <figure class="kirki-file-attachment" data-placeholder="<?php esc_attr_e ( $ l10n ['no-file-selected ' ] ); ?> " >
472
+ <figure class="kirki-file-attachment" data-placeholder="{{ window.kirki. l10n['no-file-selected'] }} " >
474
473
<# if ( field.default ) { #>
475
474
<# var defaultFilename = ( field.default.filename ) ? field.default.filename : field.default; #>
476
475
<span class="file"><span class="dashicons dashicons-media-default"></span> {{ defaultFilename }}</span>
477
476
<# } else { #>
478
- <?php esc_attr_e ( $ l10n ['no-file-selected ' ] ); ?>
477
+ {{ window.kirki. l10n['no-file-selected'] }}
479
478
<# } #>
480
479
</figure>
481
480
482
481
<div class="actions">
483
- <button type="button" class="button remove-button<# if ( ! field.default ) { #> hidden<# } #>"><?php esc_attr_e ( $ l10n[ ' remove ' ] ); ?> </button>
484
- <button type="button" class="button upload-button" data-label="<?php esc_attr_e ( $ l10n ['add-file ' ] ); ?> " data-alt-label="<?php esc_attr_e ( $ l10n ['change-file ' ] ); ?> " >
482
+ <button type="button" class="button remove-button<# if ( ! field.default ) { #> hidden<# } #>">{{ window.kirki. l10n. remove }} </button>
483
+ <button type="button" class="button upload-button" data-label="{{ window.kirki. l10n['add-file'] }} " data-alt-label="{{ window.kirki. l10n['change-file'] }} " >
485
484
<# if ( field.default ) { #>
486
- <?php esc_attr_e ( $ l10n ['change-file ' ] ); ?>
485
+ {{ window.kirki. l10n['change-file'] }}
487
486
<# } else { #>
488
- <?php esc_attr_e ( $ l10n ['add-file ' ] ); ?>
487
+ {{ window.kirki. l10n['add-file'] }}
489
488
<# } #>
490
489
</button>
491
490
<# if ( field.default.id ) { #>
@@ -499,7 +498,7 @@ public function repeater_js_template() {
499
498
500
499
</div>
501
500
<# }); #>
502
- <button type="button" class="button-link repeater-row-remove"><?php esc_attr_e ( $ l10n[ ' remove ' ] ); ?> </button>
501
+ <button type="button" class="button-link repeater-row-remove">{{ window.kirki. l10n. remove }} </button>
503
502
</div>
504
503
</li>
505
504
</script>
0 commit comments