How to use the i18n-calypso.localize function in i18n-calypso

To help you get started, we’ve selected a few i18n-calypso examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Automattic / wp-calypso / client / my-sites / domains / domain-management / domain-connect / domain-connect-authorize-records.jsx View on Github external
"To set up this service, we're going to make some changes to the " +
								'the DNS records for your domain.'
						) }
					
					 
					<a>{ showRecordsLinkText }</a>
				<p></p>
				{ this.renderDnsTemplateRecords() }
				{ this.renderConflictingRecords() }
			
		);
		/* eslint-enable jsx-a11y/anchor-is-valid,jsx-a11y/click-events-have-key-events,jsx-a11y/no-static-element-interactions */
	}
}

export default localize( DomainConnectAuthorizeRecords );
github Automattic / wp-calypso / client / my-sites / checkout / cart / cart-messages.jsx View on Github external
);
		} else if ( ! isEmpty( messages.success ) ) {
			notices.success(
				messages.success.map( ( success, index ) =&gt; (
					<p>{ success.message }</p>
				) )
			);
		}
	}

	render() {
		return null;
	}
}

export default localize( CartMessages );
github Automattic / wp-calypso / client / extensions / woocommerce / app / promotions / fields / date-field.js View on Github external
selectedDay={ selectedDay }
				onSelectDay={ onSelectDay }
				disabledDays={ disabledDays }
			/&gt;
		
	);
};

DateField.propTypes = {
	fieldName: PropTypes.string,
	explanationText: PropTypes.string,
	value: PropTypes.string,
	edit: PropTypes.func,
};

export default localize( withLocalizedMoment( DateField ) );
github Automattic / wp-calypso / client / blocks / product-purchase-features-list / site-activity.jsx View on Github external
<div>
		 }
			title={ translate( 'Activity' ) }
			description={ translate(
				'View a chronological list of all the changes and updates to your site in an organized, readable way.'
			) }
			buttonText={ translate( 'View your site activity' ) }
			href={ `/activity-log/${ siteSlug }` }
		/&gt;
	</div>
);

export default connect( state =&gt; ( {
	siteSlug: getSelectedSiteSlug( state ),
} ) )( localize( SiteActivity ) );
github Automattic / wp-calypso / client / post-editor / editor-notice / index.jsx View on Github external
}

		return {
			siteId,
			site: getSelectedSite( state ),
			type: post.type,
			typeObject: getPostType( state, siteId, post.type ),
			postUrl: post.URL || null,
			postDate: post.date || null,
		};
	},
	{
		setLayoutFocus,
		recordTracksEvent,
	}
)( localize( withLocalizedMoment( EditorNotice ) ) );
github Automattic / wp-calypso / client / post-editor / editor-permalink / index.jsx View on Github external
&gt;
					{ tooltipMessage }
				
			
		);
	}
}

export default connect( state =&gt; {
	const siteId = getSelectedSiteId( state );
	const postId = getEditorPostId( state );

	return {
		slug: getEditedPostSlug( state, siteId, postId ),
	};
} )( localize( EditorPermalink ) );
github Automattic / wp-calypso / client / my-sites / people / followers-list / index.jsx View on Github external
import EmptyContent from 'components/empty-content';
import FollowersStore from 'lib/followers/store';
import EmailFollowersStore from 'lib/email-followers/store';
import accept from 'lib/accept';
import analytics from 'lib/analytics';
import ListEnd from 'components/list-end';
import { preventWidows } from 'lib/formatting';

/**
 * Stylesheet dependencies
 */
import './style.scss';

const maxFollowers = 1000;

const Followers = localize(
	class FollowersComponent extends Component {
		constructor() {
			super();

			this.infiniteList = React.createRef();
		}

		state = {
			bulkEditing: false,
		};

		renderPlaceholders() {
			return ;
		}

		fetchNextPage = () =&gt; {
github Automattic / wp-calypso / client / blocks / comment-detail / comment-detail-reply.jsx View on Github external
className={ buttonClasses }
					disabled={ ! hasCommentText }
					onClick={ this.submitComment }
				&gt;
					{ translate( 'Send' ) }
				
			
		);
	}
}

const mapStateToProps = state =&gt; ( {
	currentUser: getCurrentUser( state )
} );

export default connect( mapStateToProps )( localize( CommentDetailReply ) );
github Automattic / wp-calypso / client / my-sites / checkout / checkout / domain-details-form.jsx View on Github external
<div>
				
				{ this.props.contactDetails ? (
					
				) : (
					
				) }
			</div>
		);
	}
}

export default connect( state =&gt; ( { contactDetails: getContactDetailsCache( state ) } ), {
	recordTracksEvent,
	updateContactDetailsCache,
} )( localize( DomainDetailsFormContainer ) );
github Automattic / wp-calypso / client / my-sites / email / gsuite-add-users / index.jsx View on Github external
export default connect(
	state => {
		const selectedSite = getSelectedSite( state );
		const siteId = get( selectedSite, 'ID', null );
		const domains = getDomainsBySiteId( state, siteId );
		return {
			domains,
			domainsWithForwards: getDomainsWithForwards( state, domains ),
			gsuiteUsers: getGSuiteUsers( state, siteId ),
			isRequestingDomains: isRequestingSiteDomains( state, siteId ),
			selectedSite,
		};
	},
	{ recordTracksEvent: recordTracksEventAction }
)( localize( GSuiteAddUsers ) );