Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 2 additions & 8 deletions app/javascript/packages/step-indicator/step-indicator-step.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import { t } from '@18f/identity-i18n';
export enum StepStatus {
CURRENT,
COMPLETE,
PENDING,
INCOMPLETE,
}

Expand All @@ -20,7 +19,7 @@ export interface StepIndicatorStepProps {
}

function StepIndicatorStep({ title, status }: StepIndicatorStepProps) {
const { CURRENT, COMPLETE, PENDING, INCOMPLETE } = StepStatus;
const { CURRENT, COMPLETE, INCOMPLETE } = StepStatus;

const classes = [
'step-indicator__step',
Expand All @@ -38,19 +37,14 @@ function StepIndicatorStep({ title, status }: StepIndicatorStepProps) {
case INCOMPLETE:
statusText = t('step_indicator.status.not_complete');
break;
case PENDING:
statusText = t('step_indicator.status.pending');
break;
default:
statusText = t('step_indicator.status.current');
}

return (
<li className={classes}>
<span className="step-indicator__step-title">{title}</span>
<span className={status === PENDING ? 'step-indicator__step-subtitle' : 'usa-sr-only'}>
{statusText}
</span>
<span className="usa-sr-only">{statusText}</span>
</li>
);
}
Expand Down
1 change: 0 additions & 1 deletion config/locales/step_indicator/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ en:
complete: Completed
current: Current step
not_complete: Not completed
pending: Pending
1 change: 0 additions & 1 deletion config/locales/step_indicator/es.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ es:
complete: Completo
current: Siguiente paso
not_complete: No se ha completado
pending: Pendiente
1 change: 0 additions & 1 deletion config/locales/step_indicator/fr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ fr:
complete: Terminé
current: Étape en cours
not_complete: Non terminé
pending: En attente