Skip to content

Name XCCDF report rule-details dialogs from their visible heading - #2489

Open
liangzaihuanyv wants to merge 1 commit into
OpenSCAP:mainfrom
liangzaihuanyv:fix/xccdf-rule-dialog-name-2488
Open

liangzaihuanyv wants to merge 1 commit into
OpenSCAP:mainfrom
liangzaihuanyv:fix/xccdf-rule-dialog-name-2488

Conversation

@liangzaihuanyv

Copy link
Copy Markdown

Resolves #2488.

The generated XCCDF HTML report displays a heading when a rule's details are opened, but does not expose it as the accessible name of the dialog. This change assigns the cloned heading a per-dialog ID and references it with aria-labelledby. It keeps the existing rule-ID fallback when no title is available. Focus management, Bootstrap, and assessment behavior are unchanged.

Regenerated the checked-in report resource with the unmodified report-resource generator. With pristine inputs, the same toolchain reproduced the upstream resource byte for byte.

Validation: An independent local rerun used the same synthetic XCCDF fixture and report stylesheets for both versions. The offline Chrome check had 22 failures across 65 assertions for the original report and passed all 65 for the updated report. Coverage includes opening a dialog for a different rule and retaining the existing rule-ID fallback. The OpenSCAP CLI, full test suite, and upstream CI were not run.

Disclosure: AI assistance was used for the patch and local verification.

Associate each rule-details dialog with the heading in its own cloned
panel. Retain the rule ID fallback when the rule has no title, and
regenerate the checked-in report resource from the JavaScript change.

Fixes OpenSCAP#2488
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Rule-details dialogs in the XCCDF HTML report have no accessible name

1 participant