Skip to content

Commit 2c8e40b

Browse files
committed
reverted two components to use old strings, not shared
(can do that refactor another time)
1 parent e50c2a6 commit 2c8e40b

File tree

2 files changed

+21
-7
lines changed

2 files changed

+21
-7
lines changed

src/components/custom-procedures/custom-procedures.jsx

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import React from 'react';
33
import Modal from '../../containers/modal.jsx';
44
import Box from '../box/box.jsx';
55
import {defineMessages, injectIntl, intlShape, FormattedMessage} from 'react-intl';
6-
import sharedMessages from '../../lib/shared-messages';
76

87
import booleanInputIcon from './icon--boolean-input.svg';
98
import textInputIcon from './icon--text-input.svg';
@@ -119,13 +118,21 @@ const CustomProcedures = props => (
119118
className={styles.cancelButton}
120119
onClick={props.onCancel}
121120
>
122-
{props.intl.formatMessage(sharedMessages.cancel)}
121+
<FormattedMessage
122+
defaultMessage="Cancel"
123+
description="Label for button to cancel custom procedure edits"
124+
id="gui.customProcedures.cancel"
125+
/>
123126
</button>
124127
<button
125128
className={styles.okButton}
126129
onClick={props.onOk}
127130
>
128-
{props.intl.formatMessage(sharedMessages.ok)}
131+
<FormattedMessage
132+
defaultMessage="OK"
133+
description="Label for button to save new custom procedure"
134+
id="gui.customProcedures.ok"
135+
/>
129136
</button>
130137
</Box>
131138
</Box>

src/components/slider-prompt/slider-prompt.jsx

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
import {defineMessages, intlShape, injectIntl} from 'react-intl';
2-
import sharedMessages from '../../lib/shared-messages';
1+
import {defineMessages, FormattedMessage, intlShape, injectIntl} from 'react-intl';
32
import PropTypes from 'prop-types';
43
import React from 'react';
54

@@ -68,13 +67,21 @@ const SliderPromptComponent = props => (
6867
className={styles.cancelButton}
6968
onClick={props.onCancel}
7069
>
71-
{props.intl.formatMessage(sharedMessages.cancel)}
70+
<FormattedMessage
71+
defaultMessage="Cancel"
72+
description="Button in prompt for cancelling the dialog"
73+
id="gui.sliderPrompt.cancel"
74+
/>
7275
</button>
7376
<button
7477
className={styles.okButton}
7578
onClick={props.onOk}
7679
>
77-
{props.intl.formatMessage(sharedMessages.ok)}
80+
<FormattedMessage
81+
defaultMessage="OK"
82+
description="Button in prompt for confirming the dialog"
83+
id="gui.sliderPrompt.ok"
84+
/>
7885
</button>
7986
</Box>
8087
</Box>

0 commit comments

Comments
 (0)