Skip to content

Commit

Permalink
fix: pr review changes
Browse files Browse the repository at this point in the history
  • Loading branch information
HardeepAsrani committed Dec 19, 2024
1 parent 8e4a776 commit 3035ca0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions includes/admin/feedzy-rss-feeds-admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,7 @@ public function enqueue_styles_admin() {
if ( 'feedzy_imports' === $screen->post_type && 'edit' === $screen->base && feedzy_show_review_notice() ) {
$asset_file = include FEEDZY_ABSPATH . '/js/build/review.asset.php';
wp_enqueue_script( $this->plugin_name . '_review', FEEDZY_ABSURL . 'js/build/review.js', $asset_file['dependencies'], $asset_file['version'], true );
wp_set_script_translations( $this->plugin_name . '_review', 'feedzy-rss-feeds' );
}

wp_enqueue_style( $this->plugin_name . '-settings', FEEDZY_ABSURL . 'css/settings.css', array(), $this->version );
Expand Down
14 changes: 7 additions & 7 deletions js/Review/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ const App = () => {
const [ isOpen, setOpen ] = useState( true );

const closeModal = async () => {
console.log( 'closeModal' );
try {
await apiFetch({
path: '/wp/v2/settings',
Expand All @@ -46,21 +45,22 @@ const App = () => {

return (
<Modal
title={ __( 'Congrats, You\'ve Reached an Impressive Milestone! 🎉', 'feedzy-rss-feeds' ) }
title={ __( 'Congrats, You\'ve Reached an Impressive Milestone!', 'feedzy-rss-feeds' ) + ' 🎉' }
size="medium"
shouldCloseOnClickOutside={ false }
onRequestClose={ closeModal }
>
<p
dangerouslySetInnerHTML={{
__html: sprintf(
// translators: %1$s is an opening strong tag, %2$s is a closing strong tag.
// translators: %1$s is an opening strong tag, %2$s is a closing strong tag, %3$s is the number of posts imported.
__(
"You've successfully imported %1$s more than 100 posts %2$s using Feedzy!",
"You've successfully imported %1$s more than %3$s posts %2$s using Feedzy!",
'feedzy-rss-feeds'
),
'<strong>', // %1$s
'</strong>' // %2$s
'</strong>', // %2$s
100 // %3$s
),
}}
/>
Expand Down Expand Up @@ -99,6 +99,6 @@ domReady( () => {
const modalContainer = document.createElement( 'div' );
modalContainer.id = 'fz-review-modal';
document.body.appendChild( modalContainer );
const root = createRoot( document.getElementById( 'fz-review-modal' ) );
root.render( <App /> );
const root = createRoot( document.getElementById( 'fz-review-modal' ) );
root.render( <App /> );
});

0 comments on commit 3035ca0

Please sign in to comment.