-
-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Translation pt br #1238
Translation pt br #1238
Changes from 4 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,6 +8,7 @@ import ClockTime from '../../viewers/common/clock-time/ClockTime'; | |
import RunningTime from '../../viewers/common/running-time/RunningTime'; | ||
|
||
import styles from './StatusBar.module.scss'; | ||
import { useTranslation } from '../../../../../client/src/translation/TranslationProvider'; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Consider simplifying the import path for useTranslation The current import path Consider simplifying this import path. You might be able to use a shorter path or set up path aliases in your project configuration to make imports more manageable. For example: import { useTranslation } from '@/translation/TranslationProvider'; This assumes you've set up path aliases in your TypeScript or webpack configuration. |
||
|
||
interface StatusBarTimersProps { | ||
projectTitle: string; | ||
|
@@ -25,6 +26,8 @@ export default function StatusBarTimers(props: StatusBarTimersProps) { | |
const timer = useTimer(); | ||
const { clock } = useClock(); | ||
|
||
const { getLocalizedString } = useTranslation(); | ||
|
||
const getTimeStart = (): MaybeNumber => { | ||
if (firstStart === undefined) { | ||
return null; | ||
|
@@ -61,25 +64,25 @@ export default function StatusBarTimers(props: StatusBarTimersProps) { | |
<div className={styles.timers}> | ||
{PlaybackIconComponent} | ||
<div className={styles.timeNow}> | ||
<span className={styles.label}>Time now</span> | ||
<span className={styles.label}>{getLocalizedString('common.time_now')}</span> | ||
<ClockTime className={styles.timer} value={clock} /> | ||
</div> | ||
<div className={styles.elapsedTime}> | ||
<span className={styles.label}>Elapsed time</span> | ||
<span className={styles.label}>{getLocalizedString('common.elapsed_time')}</span> | ||
<RunningTime className={styles.timer} value={timer.elapsed} /> | ||
</div> | ||
<div className={styles.runningTime}> | ||
<span className={styles.label}>Running timer</span> | ||
<span className={styles.label}>{getLocalizedString('countdown.running')}</span> | ||
<RunningTime className={styles.timer} value={timer.current} /> | ||
</div> | ||
|
||
<span className={styles.title}>{projectTitle}</span> | ||
<div className={styles.startTime}> | ||
<span className={styles.label}>Scheduled start</span> | ||
<span className={styles.label}>{getLocalizedString('common.scheduled_start')}</span> | ||
<ClockTime className={styles.timer} value={getTimeStart()} /> | ||
</div> | ||
<div className={styles.endTime}> | ||
<span className={styles.label}>Scheduled end</span> | ||
<span className={styles.label}>{getLocalizedString('common.scheduled_end')}</span> | ||
<ClockTime className={styles.timer} value={getTimeEnd()} /> | ||
</div> | ||
</div> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import { TranslationObject } from './en'; | ||
|
||
export const langPtbr: TranslationObject = { | ||
'common.expected_finish': 'TÉRMINO ESPERADO', | ||
'common.minutes': 'min', | ||
'common.now': 'AGORA', | ||
'common.next': 'PRÓXIMO', | ||
'common.public_message': 'MENSAGEM PÚBLICA', | ||
'common.scheduled_start': 'INÍCIO PLANEJADO', | ||
'common.scheduled_end': 'ENCERRAMENTO PLANEJADO', | ||
'common.projected_start': 'INÍCIO PREVISTO', | ||
'common.projected_end': 'ENCERRAMENTO PREVISTO', | ||
'common.stage_timer': 'TEMPO DO APRESENTADOR', | ||
'common.started_at': 'INICIADO ÀS', | ||
'common.time_now': 'HORA ATUAL', | ||
'common.elapsed_time': 'TEMPO CORRIDO', | ||
'countdown.ended': 'EVENTO ENCERRADO ÀS', | ||
'countdown.running': 'TEMPO RESTANTE', | ||
'countdown.select_event': 'SELECIONE UM EVENTO PARA ACOMPANHAR', | ||
'countdown.to_start': 'Tempo para Iniciar', | ||
'countdown.waiting': 'Aguardando o Início do Evento', | ||
'countdown.overtime': 'em tempo extra', | ||
'timeline.live': 'AGORA', | ||
'timeline.done': 'Concluído', | ||
'timeline.due': 'Pendente', | ||
'timeline.followedby': 'Seguido por', | ||
}; |
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -13,6 +13,7 @@ export const langPt: TranslationObject = { | |||||
'common.stage_timer': 'Temporizador do presentador', | ||||||
'common.started_at': 'Iniciado em', | ||||||
'common.time_now': 'Hora atual', | ||||||
'common.elapsed_time': 'Elapsed Time', | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Translation for 'common.elapsed_time' is in English, not Portuguese The newly added translation for 'common.elapsed_time' is currently in English ('Elapsed Time') instead of Portuguese. This doesn't align with the purpose of this file, which is to provide Portuguese translations. Please update the translation to Portuguese. A suggested translation could be: - 'common.elapsed_time': 'Elapsed Time',
+ 'common.elapsed_time': 'Tempo decorrido', Make sure to verify this translation with a native Portuguese speaker or a professional translator to ensure accuracy. 📝 Committable suggestion
Suggested change
|
||||||
'countdown.ended': 'Evento encerrado às', | ||||||
'countdown.running': 'Evento em andamento', | ||||||
'countdown.select_event': 'Selecione um evento para acompanhar', | ||||||
|
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -13,6 +13,7 @@ export const langSv: TranslationObject = { | |||||
'common.stage_timer': 'Timer för scenen', | ||||||
'common.started_at': 'Började vid', | ||||||
'common.time_now': 'Klockan nu', | ||||||
'common.elapsed_time': 'Elapsed Time', | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Incorrect translation: 'common.elapsed_time' is not in Swedish The newly added translation for 'common.elapsed_time' is in English instead of Swedish. This is inconsistent with the rest of the file, which contains Swedish translations. Please replace the English text with the correct Swedish translation. The Swedish phrase for "Elapsed Time" is "Förfluten tid". Here's the corrected line: - 'common.elapsed_time': 'Elapsed Time',
+ 'common.elapsed_time': 'Förfluten tid', 📝 Committable suggestion
Suggested change
|
||||||
'countdown.ended': 'Evenemanget avslutades vid', | ||||||
'countdown.running': 'Evenemang pågår', | ||||||
'countdown.select_event': 'Välj ett evenemang att följa', | ||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codebase verification
Issue Detected: 'ptbr' Language Code Not Fully Integrated
The
ptbr
language code is added to the language selection dropdown but is not registered in the application's language configuration or localization files. This may prevent the application from properly handling Brazilian Portuguese language settings.'ptbr'
in the language configuration files.'ptbr'
to support Brazilian Portuguese translations.🔗 Analysis chain
LGTM! The changes align with the PR objectives.
The addition of the "Português Brasil" option and the indentation fix for the "Polish" option improve the language selection capabilities and code consistency. These changes successfully implement the PR's goal of adding Brazilian Portuguese language support.
To ensure consistency with the application's language handling system, please verify that the 'ptbr' language code is correctly recognized and implemented throughout the application. Run the following script to check for its usage:
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 930
Script:
Length of output: 441