Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
handleChange( event ) {
const locale = event.target.value;
const currentLanguage = this.getCurrentLanguage();
const nextLanguage = find( config( 'languages' ), { langSlug: locale } );
if ( currentLanguage.isRtl !== nextLanguage.isRtl ) {
// RTL and LTR languages use a different build, so we need to
// reload the page if the language direction changes
window.location.href = getPath( 'home', {}, { locale } );
} else {
this.props.switchLocale( locale );
this.props.hideSelect();
}
}
redirectToSearch( query, numberOfResultsToDisplay ) {
if ( query !== ownProps.location.query.q || config( 'initial_number_of_search_results' ) === numberOfResultsToDisplay ) {
// reset the result count when the query changes and hide it from the url if it is the default
numberOfResultsToDisplay = undefined;
}
dispatch( push( {
pathname: getPath( 'search' ),
query: { q: query, r: numberOfResultsToDisplay }
} ) );
}
} )
<p>
{ i18n.translate( 'You may be asked to approve these changes for each domain separately. ' +
"We'll email you with instructions." ) }
</p>
}
<p>
{ i18n.translate(
'By clicking "Update contact information", you agree to the ' +
'{{draLink}}Domain Registration Agreement{{/draLink}} and confirm that if you are transferring ownership of the domain, ' +
'the new owner has agreed in writing to be bound by the same agreement. {{faqLink}}What does this mean?{{/faqLink}}',
{
components: {
draLink: <a rel="noopener noreferrer" href="https://wordpress.com/automattic-domain-name-registration-agreement/">,
faqLink: </a><a rel="noopener noreferrer" href="{">
}
}
) }
</a></p><a rel="noopener noreferrer" href="{">
);
}
</a>
selectDomain( domainProduct, isUserLoggedIn ) {
dispatch( selectDomain( domainProduct ) );
if ( isUserLoggedIn ) {
dispatch( push( getPath( 'contactInformation' ) ) );
} else {
dispatch( push( getPath( 'signupUser' ) ) );
}
}
} ),
redirectToSearch( query ) {
dispatch( push( {
pathname: getPath( 'search' ),
query: { q: query }
} ) );
},
<button disabled="{">
{ i18n.translate( 'Contact domain assistant', {
comment: 'The domain assistant is our customer support team'
} ) }
</button>
<div>
</div>
);
}
}
}
} ) }<p></p>
<div id="sawbuck">
<h3>{ i18n.translate( 'What is wordpress.sawbuck.com?' ) }</h3>
<p>{ i18n.translate( 'The domain sawbuck.com is used internally by get.blog. When registering a new domain, you may receive an email to verify your contact information. It is sent from help@wordpress.sawbuck.com, and contains a link to validate.sawbuck.com. This is a legitimate get.blog email, and the link is safe to click.' ) }</p>
</div>
<div id="connect-domain">
<h3>{ i18n.translate( 'How do I connect my domain to my site?' ) }</h3>
<p>{ i18n.translate( 'Go to {{link}}My Domains{{/link}} to see all your domains and set them up. If your domain is already connected, you may have to reset it to the default settings before you can start the set up again.', {
components: {
link:
}
} ) }</p>
</div>
<div id="nameservers">
<h3>{ i18n.translate( 'How do I set custom name servers?' ) }</h3>
<p>{ i18n.translate( 'To choose custom servers for your domain, start setting it up from {{link}}My Domains{{/link}}, and then choose “Configure manually” on the next screen. If your domain is already connected, you may have to reset it to the default settings before you can start the set up again.', {
components: {
link:
}
} ) }</p>
</div>
<div id="transfer">
<h3>{ i18n.translate( 'Can I transfer my domain?' ) }</h3></div>
<h3>{ i18n.translate( 'Want a different blogging platform?' ) }</h3>
<p>
{ i18n.translate( 'We\'ll be adding more options for automatic set up soon. In the meantime, our Domain Assistants can help you {{link}}find the best place to start your new blog{{/link}}.', {
components: { link: }
} ) }
</p>
<div>
</div>
);
}
}
'and require total control over all features.' ), 2 )
}
<p></p>
<button disabled="{">
{ i18n.translate( 'Next' ) }
</button>
<div>
</div>
);
}
}
{ ...removeInvalidInputProps( message ) }
/>
<button disabled="{">
{ i18n.translate( 'Contact our domain assistant' ) }
</button>
<div>
{ i18n.translate( 'Back' ) }
</div>
);
}
}