Skip to content

Commit

Permalink
Add translation to strings
Browse files Browse the repository at this point in the history
  • Loading branch information
dmsnell committed May 4, 2016
1 parent 9ce7a97 commit d5419ce
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
5 changes: 3 additions & 2 deletions client/components/tinymce/plugins/insert-menu/menu-items.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import React from 'react';

import Gridicon from 'components/gridicon';
import SocialLogo from 'components/social-logo';
import i18n from 'lib/mixins/i18n';

const GridiconButton = ( { icon, label } ) => (
<div>
Expand All @@ -21,13 +22,13 @@ export default [
{
name: 'insert_media_item',
icon: 'add-image',
item: <GridiconButton icon="image-multiple" label={ 'Add Media' } />,
item: <GridiconButton icon="image-multiple" label={ i18n.translate( 'Add Media' ) } />,
cmd: 'wpcomAddMedia'
},
{
name: 'insert_contact_form',
icon: 'mention',
item: <GridiconButton icon="mention" label={ 'Add Contact Form' } />,
item: <GridiconButton icon="mention" label={ i18n.translate( 'Add Contact Form' ) } />,
cmd: 'wpcomContactForm'
}
];
3 changes: 2 additions & 1 deletion client/components/tinymce/plugins/insert-menu/plugin.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import tinymce from 'tinymce/tinymce';
import { renderToString } from 'react-dom/server';

import Gridicon from 'components/gridicon';
import i18n from 'lib/mixins/i18n';

import menuItems from './menu-items';

Expand All @@ -20,7 +21,7 @@ const initialize = editor => {

editor.addButton( 'wpcom_insert_menu', {
type: 'splitbutton',
title: 'Insert content',
title: i18n.translate( 'Insert content' ),
classes: 'btn wpcom-insert-menu insert-menu',
cmd: menuItems[0].cmd,
menu: menuItems.map( ( { name } ) => editor.menuItems[ name ] ),
Expand Down

0 comments on commit d5419ce

Please sign in to comment.