File tree Expand file tree Collapse file tree 5 files changed +12
-4
lines changed
Expand file tree Collapse file tree 5 files changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -234,7 +234,7 @@ const App: React.FC = (): React.JSX.Element => {
234234 const tabs : Tabs . TabItem [ ] = [
235235 {
236236 key : projectData . robot . modulePath ,
237- title : 'Robot' ,
237+ title : t ( 'ROBOT' ) ,
238238 type : TabType . ROBOT ,
239239 } ,
240240 ] ;
Original file line number Diff line number Diff line change 3434 "SPANISH" : " Spanish" ,
3535 "HELP" : " Help" ,
3636 "ABOUT" : " About" ,
37+ "BLOCKS" : " Blocks" ,
38+ "CODE" : " Code" ,
39+ "COPY" : " Copy" ,
3740 "BLOCKLY" :{
3841 "OF_TYPE" : " of type" ,
3942 "WITH" : " with" ,
Original file line number Diff line number Diff line change 2929 "SPANISH" : " Español" ,
3030 "HELP" : " Ayuda" ,
3131 "ABOUT" : " Acerca de" ,
32+ "BLOCKS" : " Bloques" ,
33+ "CODE" : " Código" ,
34+ "COPY" : " Copiar" ,
3235 "addTabDialog" : {
3336 "title" : " Agregar Pestaña" ,
3437 "newItemPlaceholder" : " Agregar Módulo" ,
Original file line number Diff line number Diff line change @@ -25,6 +25,7 @@ import { Prism as SyntaxHighlighter } from 'react-syntax-highlighter';
2525import { dracula , oneLight } from 'react-syntax-highlighter/dist/esm/styles/prism' ;
2626
2727import type { MessageInstance } from 'antd/es/message/interface' ;
28+ import { useTranslation } from 'react-i18next' ;
2829
2930/** Function type for setting string values. */
3031type StringFunction = ( input : string ) => void ;
@@ -64,6 +65,7 @@ export default function CodeDisplay(props: CodeDisplayProps): React.JSX.Element
6465 }
6566
6667 const { token } = Antd . theme . useToken ( ) ;
68+ const { t } = useTranslation ( ) ;
6769 const syntaxStyle = syntaxHighligherFromTheme ( props . theme ) ;
6870
6971 /** Handles copying the generated code to clipboard. */
@@ -90,8 +92,8 @@ export default function CodeDisplay(props: CodeDisplayProps): React.JSX.Element
9092 /** Renders the header section with title and copy button. */
9193 const renderHeader = ( ) : React . JSX . Element => (
9294 < Antd . Space >
93- < Antd . Typography . Title level = { 3 } > Code </ Antd . Typography . Title >
94- < Antd . Tooltip title = "Copy" >
95+ < Antd . Typography . Title level = { 3 } > { t ( "CODE" ) } </ Antd . Typography . Title >
96+ < Antd . Tooltip title = { t ( "COPY" ) } >
9597 < Antd . Button
9698 icon = { < CopyIcon /> }
9799 size = "small"
Original file line number Diff line number Diff line change @@ -97,7 +97,7 @@ export default function Header(props: HeaderProps): React.JSX.Element {
9797 fontWeight : TITLE_FONT_WEIGHT ,
9898 } }
9999 >
100- Blocks
100+ { t ( "BLOCKS" ) }
101101 </ Antd . Typography >
102102 < Antd . Typography
103103 style = { {
You can’t perform that action at this time.
0 commit comments