Skip to content

♿️(frontend) use semantic <p> elements in document info card#2379

Open
Ovgodd wants to merge 1 commit into
mainfrom
fix/a11y-2350-info-card-structure
Open

♿️(frontend) use semantic <p> elements in document info card#2379
Ovgodd wants to merge 1 commit into
mainfrom
fix/a11y-2350-info-card-structure

Conversation

@Ovgodd

@Ovgodd Ovgodd commented Jun 2, 2026

Copy link
Copy Markdown
Collaborator

Purpose

Replace <span> with <p> for the user role and last update date in the document information card (DocHeaderInfo).

Proposal

  • Render user role (and visibility) text in a <p> via Text as="p"
  • Render last update / trashbin date text in a <p> via Text as="p"
  • Reset paragraph margins ($margin="0") and align the row layout to preserve the existing visual appearance

@Ovgodd Ovgodd requested a review from AntoLC June 2, 2026 14:55
@Ovgodd Ovgodd self-assigned this Jun 2, 2026
@Ovgodd Ovgodd added bug Something isn't working accessibility triage labels Jun 2, 2026
@Ovgodd Ovgodd moved this from Backlog to In review in LaSuite Docs A11y Jun 2, 2026
@Ovgodd Ovgodd force-pushed the fix/a11y-2350-info-card-structure branch from 96c12f8 to c41895b Compare June 2, 2026 14:56
@coderabbitai

coderabbitai Bot commented Jun 2, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: d6acb170-fb60-4712-b178-c11cfebed5ac

📥 Commits

Reviewing files that changed from the base of the PR and between c41895b and 1490520.

📒 Files selected for processing (2)
  • CHANGELOG.md
  • src/frontend/apps/impress/src/features/docs/doc-header/components/DocHeaderInfo.tsx

Walkthrough

This PR centers the DocHeaderInfo outer Box ($align="center"), changes both Text elements to semantic paragraphs (as="p") with $margin="0", and preserves the first Text's conditional $theme and existing visibility/role separator. It also adds an Unreleased → Changed changelog entry. No public or exported APIs were modified.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Suggested reviewers

  • AntoLC
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main change: using semantic

elements in the document info card component, which directly matches the changeset.

Description check ✅ Passed The description is directly related to the changeset, outlining the purpose and proposal for replacing with

elements in DocHeaderInfo, with specific implementation details.

Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/a11y-2350-info-card-structure

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions

github-actions Bot commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

Size Change: 0 B

Total Size: 4.33 MB

📦 View Changed
Filename Size Change
apps/impress/out/_next/static/ad371385/_buildManifest.js 673 B +673 B (new file) 🆕
apps/impress/out/_next/static/b58adf8f/_buildManifest.js 0 B -673 B (removed) 🏆

compressed-size-action

Wrap role and last-update text in DocHeaderInfo with <p>.
@Ovgodd Ovgodd force-pushed the fix/a11y-2350-info-card-structure branch from c41895b to 1490520 Compare June 3, 2026 07:14

@AntoLC AntoLC left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think it is a correct semantic here, "p" means paragraph, it is means to separate block of text, it is why it has a even a native margin attribute to it. If we want to add "p" it should be more on the "Box" component so.

That said, if we want to be top notch semantic, we should use something more appropriate like dl and its friends.

@Ovgodd

Ovgodd commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator Author

I don't think it is a correct semantic here, "p" means paragraph, it is means to separate block of text, it is why it has a even a native margin attribute to it. If we want to add "p" it should be more on the "Box" component so.

That said, if we want to be top notch semantic, we should use something more appropriate like dl and its friends.

@cyberbaloo what solution do you prefer / is better ?

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

Labels

accessibility bug Something isn't working triage

Projects

Status: In review

Development

Successfully merging this pull request may close these issues.

Document information card: unstructured information in paragraph elements

2 participants