Merge pull request 'label переключателя пустых строк через htmlFor (#36, AURORA-1527)' (#37) from feat/36-a11y-switch into test

This commit is contained in:
aep 2026-10-16 18:40:21 +03:00
commit 1237105af2
2 changed files with 12 additions and 5 deletions

View File

@ -47,7 +47,12 @@ export function ChecksPanel({ checks, editable, dirty, onAccept }: Props) {
<Alert type='error' showIcon title={`Нарушения (${checks.failed.length})`} description={failureList(checks.failed)} /> <Alert type='error' showIcon title={`Нарушения (${checks.failed.length})`} description={failureList(checks.failed)} />
)} )}
{checks.soft_failed.length > 0 && ( {checks.soft_failed.length > 0 && (
<Alert type='warning' showIcon title={`Предупреждения проверок (${checks.soft_failed.length})`} description={failureList(checks.soft_failed)} /> <Alert
type='warning'
showIcon
title={`Предупреждения проверок (${checks.soft_failed.length})`}
description={failureList(checks.soft_failed)}
/>
)} )}
{checks.cross_form && ( {checks.cross_form && (
<Alert <Alert

View File

@ -199,10 +199,12 @@ export function StatementReview({ document, onChanged }: { document: DocumentOut
/> />
)} )}
{emptySublines.size > 0 && ( {emptySublines.size > 0 && (
<label style={{ display: 'inline-flex', alignItems: 'center', gap: 8, cursor: 'pointer' }}> <span style={{ display: 'inline-flex', alignItems: 'center', gap: 8 }}>
<Switch size='small' checked={showEmptySublines} onChange={setShowEmptySublines} /> <Switch id='show-empty-sublines' size='small' checked={showEmptySublines} onChange={setShowEmptySublines} />
<span>Показать пустые строки детализации ({emptySublines.size})</span> <label htmlFor='show-empty-sublines' style={{ cursor: 'pointer' }}>
Показать пустые строки детализации ({emptySublines.size})
</label> </label>
</span>
)} )}
<StatementTable <StatementTable
documentType={statement.document.document_type} documentType={statement.document.document_type}