Skip to content
Snippets Groups Projects
Commit c8b068b2 authored by chrisgarrity's avatar chrisgarrity Committed by GitHub
Browse files

updating string ids to follow convention (#700)

Changed existing string ids to use the convention `<repo>.<component>.<identifier>`
parent 0c5810ee
No related branches found
No related tags found
No related merge requests found
...@@ -43,7 +43,7 @@ const fs = require('fs'); ...@@ -43,7 +43,7 @@ const fs = require('fs');
const path = require('path'); const path = require('path');
const mkdirp = require('mkdirp'); const mkdirp = require('mkdirp');
const locales = ['en', 'es', 'fr']; const locales = ['en', 'es', 'de', 'ar', 'he'];
const LANG_DIR = './translations/'; const LANG_DIR = './translations/';
const MSGS_DIR = './locale/'; const MSGS_DIR = './locale/';
......
...@@ -26,7 +26,7 @@ const addExtensionMessage = ( ...@@ -26,7 +26,7 @@ const addExtensionMessage = (
<FormattedMessage <FormattedMessage
defaultMessage="Extensions" defaultMessage="Extensions"
description="Button to add an extension in the target pane" description="Button to add an extension in the target pane"
id="targetPane.addExtension" id="gui.gui.addExtension"
/> />
); );
......
...@@ -30,72 +30,72 @@ const BufferedInput = BufferedInputHOC(Input); ...@@ -30,72 +30,72 @@ const BufferedInput = BufferedInputHOC(Input);
const messages = defineMessages({ const messages = defineMessages({
sound: { sound: {
id: 'soundEditor.sound', id: 'gui.soundEditor.sound',
description: 'Lable for the name of the sound', description: 'Label for the name of the sound',
defaultMessage: 'Sound' defaultMessage: 'Sound'
}, },
play: { play: {
id: 'soundEditor.play', id: 'gui.soundEditor.play',
description: 'Title of the button to start playing the sound', description: 'Title of the button to start playing the sound',
defaultMessage: 'Play' defaultMessage: 'Play'
}, },
stop: { stop: {
id: 'soundEditor.stop', id: 'gui.soundEditor.stop',
description: 'Title of the button to stop the sound', description: 'Title of the button to stop the sound',
defaultMessage: 'Stop' defaultMessage: 'Stop'
}, },
trim: { trim: {
id: 'soundEditor.trim', id: 'gui.soundEditor.trim',
description: 'Title of the button to start trimminging the sound', description: 'Title of the button to start trimminging the sound',
defaultMessage: 'Trim' defaultMessage: 'Trim'
}, },
save: { save: {
id: 'soundEditor.save', id: 'gui.soundEditor.save',
description: 'Title of the button to save trimmed sound', description: 'Title of the button to save trimmed sound',
defaultMessage: 'Save' defaultMessage: 'Save'
}, },
undo: { undo: {
id: 'soundEditor.undo', id: 'gui.soundEditor.undo',
description: 'Title of the button to undo', description: 'Title of the button to undo',
defaultMessage: 'Undo' defaultMessage: 'Undo'
}, },
redo: { redo: {
id: 'soundEditor.redo', id: 'gui.soundEditor.redo',
description: 'Title of the button to redo', description: 'Title of the button to redo',
defaultMessage: 'Redo' defaultMessage: 'Redo'
}, },
faster: { faster: {
id: 'soundEditor.faster', id: 'gui.soundEditor.faster',
description: 'Title of the button to apply the faster effect', description: 'Title of the button to apply the faster effect',
defaultMessage: 'Faster' defaultMessage: 'Faster'
}, },
slower: { slower: {
id: 'soundEditor.slower', id: 'gui.soundEditor.slower',
description: 'Title of the button to apply the slower effect', description: 'Title of the button to apply the slower effect',
defaultMessage: 'Slower' defaultMessage: 'Slower'
}, },
echo: { echo: {
id: 'soundEditor.echo', id: 'gui.soundEditor.echo',
description: 'Title of the button to apply the echo effect', description: 'Title of the button to apply the echo effect',
defaultMessage: 'Echo' defaultMessage: 'Echo'
}, },
robot: { robot: {
id: 'soundEditor.robot', id: 'gui.soundEditor.robot',
description: 'Title of the button to apply the robot effect', description: 'Title of the button to apply the robot effect',
defaultMessage: 'Robot' defaultMessage: 'Robot'
}, },
louder: { louder: {
id: 'soundEditor.louder', id: 'gui.soundEditor.louder',
description: 'Title of the button to apply the louder effect', description: 'Title of the button to apply the louder effect',
defaultMessage: 'Louder' defaultMessage: 'Louder'
}, },
softer: { softer: {
id: 'soundEditor.softer', id: 'gui.soundEditor.softer',
description: 'Title of the button to apply thr.softer effect', description: 'Title of the button to apply thr.softer effect',
defaultMessage: 'Softer' defaultMessage: 'Softer'
}, },
reverse: { reverse: {
id: 'soundEditor.reverse', id: 'gui.soundEditor.reverse',
description: 'Title of the button to apply the reverse effect', description: 'Title of the button to apply the reverse effect',
defaultMessage: 'Reverse' defaultMessage: 'Reverse'
} }
......
...@@ -43,7 +43,7 @@ const SpriteSelectorItem = props => ( ...@@ -43,7 +43,7 @@ const SpriteSelectorItem = props => (
<FormattedMessage <FormattedMessage
defaultMessage="delete" defaultMessage="delete"
description="Menu item to delete in the right click menu" description="Menu item to delete in the right click menu"
id="contextMenu.delete" id="gui.spriteSelectorItem.contextMenuDelete"
/> />
</MenuItem> </MenuItem>
</ContextMenu> </ContextMenu>
......
...@@ -14,7 +14,7 @@ const addSpriteMessage = ( ...@@ -14,7 +14,7 @@ const addSpriteMessage = (
<FormattedMessage <FormattedMessage
defaultMessage="Add Sprite" defaultMessage="Add Sprite"
description="Button to add a sprite in the target pane" description="Button to add a sprite in the target pane"
id="targetPane.addSprite" id="gui.spriteSelector.addSprite"
/> />
); );
......
...@@ -13,7 +13,7 @@ const addBackdropMessage = ( ...@@ -13,7 +13,7 @@ const addBackdropMessage = (
<FormattedMessage <FormattedMessage
defaultMessage="Add Backdrop" defaultMessage="Add Backdrop"
description="Button to add a backdrop in the target pane" description="Button to add a backdrop in the target pane"
id="targetPane.addBackdrop" id="gui.stageSelector.targetPaneAddBackdrop"
/> />
); );
...@@ -49,7 +49,7 @@ const StageSelector = props => { ...@@ -49,7 +49,7 @@ const StageSelector = props => {
<FormattedMessage <FormattedMessage
defaultMessage="Backdrops" defaultMessage="Backdrops"
description="Label for the backdrops in the stage selector" description="Label for the backdrops in the stage selector"
id="stageSelector.backdrops" id="gui.stageSelector.backdrops"
/> />
</div> </div>
<div className={styles.count}>{backdropCount}</div> <div className={styles.count}>{backdropCount}</div>
......
...@@ -15,7 +15,7 @@ const TurboMode = () => ( ...@@ -15,7 +15,7 @@ const TurboMode = () => (
<FormattedMessage <FormattedMessage
defaultMessage="Turbo Mode" defaultMessage="Turbo Mode"
description="Label indicating turbo mode is active" description="Label indicating turbo mode is active"
id="controls.turboMode" id="gui.turboMode.active"
/> />
</div> </div>
</div> </div>
......
...@@ -65,14 +65,14 @@ class CostumeTab extends React.Component { ...@@ -65,14 +65,14 @@ class CostumeTab extends React.Component {
<FormattedMessage <FormattedMessage
defaultMessage="Add Backdrop" defaultMessage="Add Backdrop"
description="Button to add a backdrop in the editor tab" description="Button to add a backdrop in the editor tab"
id="action.addBackdrop" id="gui.costumeTab.addBackdrop"
/> />
); );
const addCostumeMsg = ( const addCostumeMsg = (
<FormattedMessage <FormattedMessage
defaultMessage="Add Costume" defaultMessage="Add Costume"
description="Button to add a costume in the editor tab" description="Button to add a costume in the editor tab"
id="action.addCostume" id="gui.costumeTab.addCostume"
/> />
); );
......
...@@ -76,14 +76,14 @@ class SoundTab extends React.Component { ...@@ -76,14 +76,14 @@ class SoundTab extends React.Component {
<FormattedMessage <FormattedMessage
defaultMessage="Record Sound" defaultMessage="Record Sound"
description="Button to record a sound in the editor tab" description="Button to record a sound in the editor tab"
id="action.recordSound" id="gui.soundTab.recordSound"
/> />
); );
const addSoundMsg = ( const addSoundMsg = (
<FormattedMessage <FormattedMessage
defaultMessage="Add Sound" defaultMessage="Add Sound"
description="Button to add a sound in the editor tab" description="Button to add a sound in the editor tab"
id="action.addSound" id="gui.soundTab.addSound"
/> />
); );
......
import localeDataEn from 'react-intl/locale-data/en'; import localeDataEn from 'react-intl/locale-data/en';
import localeDataEs from 'react-intl/locale-data/es'; import localeDataEs from 'react-intl/locale-data/es';
import localeDataFr from 'react-intl/locale-data/fr'; import localeDataAr from 'react-intl/locale-data/ar';
import localeDataDe from 'react-intl/locale-data/de';
import localeDataHe from 'react-intl/locale-data/he';
import messages from '../locale/messages.json'; // eslint-disable-line import/no-unresolved import messages from '../locale/messages.json'; // eslint-disable-line import/no-unresolved
...@@ -15,9 +17,19 @@ export default { ...@@ -15,9 +17,19 @@ export default {
localeData: localeDataEs, localeData: localeDataEs,
messages: messages.es messages: messages.es
}, },
fr: { ar: {
name: 'Français', name: 'العربية',
localeData: localeDataFr, localeData: localeDataAr,
messages: messages.fr messages: messages.ar
},
de: {
name: 'Deutsch',
localeData: localeDataDe,
messages: messages.de
},
he: {
name: 'עִבְרִית',
localeData: localeDataHe,
messages: messages.he
} }
}; };
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment