Skip to content

Commit 6cd2e74

Browse files
committed
fix: pr review changes
1 parent 9e4ba26 commit 6cd2e74

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

includes/admin/feedzy-rss-feeds-admin.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,7 @@ public function enqueue_styles_admin() {
250250
if ( 'feedzy_imports' === $screen->post_type && 'edit' === $screen->base && feedzy_show_review_notice() ) {
251251
$asset_file = include FEEDZY_ABSPATH . '/js/build/review.asset.php';
252252
wp_enqueue_script( $this->plugin_name . '_review', FEEDZY_ABSURL . 'js/build/review.js', $asset_file['dependencies'], $asset_file['version'], true );
253+
wp_set_script_translations( $this->plugin_name . '_review', 'feedzy-rss-feeds' );
253254
}
254255

255256
wp_enqueue_style( $this->plugin_name . '-settings', FEEDZY_ABSURL . 'css/settings.css', array(), $this->version );

js/Review/index.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ const App = () => {
2424
const [ isOpen, setOpen ] = useState( true );
2525

2626
const closeModal = async () => {
27-
console.log( 'closeModal' );
2827
try {
2928
await apiFetch({
3029
path: '/wp/v2/settings',
@@ -46,21 +45,22 @@ const App = () => {
4645

4746
return (
4847
<Modal
49-
title={ __( 'Congrats, You\'ve Reached an Impressive Milestone! 🎉', 'feedzy-rss-feeds' ) }
48+
title={ __( 'Congrats, You\'ve Reached an Impressive Milestone!', 'feedzy-rss-feeds' ) + ' 🎉' }
5049
size="medium"
5150
shouldCloseOnClickOutside={ false }
5251
onRequestClose={ closeModal }
5352
>
5453
<p
5554
dangerouslySetInnerHTML={{
5655
__html: sprintf(
57-
// translators: %1$s is an opening strong tag, %2$s is a closing strong tag.
56+
// translators: %1$s is an opening strong tag, %2$s is a closing strong tag, %3$s is the number of posts imported.
5857
__(
59-
"You've successfully imported %1$s more than 100 posts %2$s using Feedzy!",
58+
"You've successfully imported %1$s more than %3$s posts %2$s using Feedzy!",
6059
'feedzy-rss-feeds'
6160
),
6261
'<strong>', // %1$s
63-
'</strong>' // %2$s
62+
'</strong>', // %2$s
63+
100 // %3$s
6464
),
6565
}}
6666
/>
@@ -99,6 +99,6 @@ domReady( () => {
9999
const modalContainer = document.createElement( 'div' );
100100
modalContainer.id = 'fz-review-modal';
101101
document.body.appendChild( modalContainer );
102-
const root = createRoot( document.getElementById( 'fz-review-modal' ) );
103-
root.render( <App /> );
102+
const root = createRoot( document.getElementById( 'fz-review-modal' ) );
103+
root.render( <App /> );
104104
});

0 commit comments

Comments
 (0)