Skip to content

fix: applying formatting to header/footer#2904

Merged
harbournick merged 2 commits intomainfrom
artem/SD-2618-v5
Apr 22, 2026
Merged

fix: applying formatting to header/footer#2904
harbournick merged 2 commits intomainfrom
artem/SD-2618-v5

Conversation

@artem-harbour
Copy link
Copy Markdown
Contributor

@artem-harbour artem-harbour commented Apr 22, 2026

Linear: SD-2618

Fixes inconsistent toolbar formatting in header/footer by removing stale selection restoration and avoiding deferred mark execution in H/F.

What changed

  • Skip restoreSelection() for header/footer toolbar interactions.
  • Execute mark-toggle commands immediately in header/footer (no pendingMarkCommands queue).
  • Simplify mark command selection resolution to use live transaction selection (tr.selection) via a centralized helper.
  • Clean up command call sites/signatures accordingly.
  • Add regression tests for:
    • no restoreSelection call in header/footer toolbar flow,
    • immediate (non-queued) mark-toggle execution in header/footer.

Result

  • bold/italic/underline/color/highlight now apply immediately in centered header/footer text.
  • fontFamily/fontSize now apply immediately without requiring an extra selection change.
  • Body behavior remains unchanged.

@linear
Copy link
Copy Markdown

linear Bot commented Apr 22, 2026

@codecov-commenter
Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@artem-harbour artem-harbour self-assigned this Apr 22, 2026
@artem-harbour artem-harbour marked this pull request as ready for review April 22, 2026 16:51
Copy link
Copy Markdown
Collaborator

@harbournick harbournick left a comment

Choose a reason for hiding this comment

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

LGTM

@harbournick harbournick merged commit 75c8f51 into main Apr 22, 2026
16 checks passed
@harbournick harbournick deleted the artem/SD-2618-v5 branch April 22, 2026 20:07
@superdoc-bot
Copy link
Copy Markdown
Contributor

superdoc-bot Bot commented Apr 22, 2026

🎉 This PR is included in @superdoc-dev/react v1.2.0-next.41

The release is available on GitHub release

@superdoc-bot
Copy link
Copy Markdown
Contributor

superdoc-bot Bot commented Apr 22, 2026

🎉 This PR is included in vscode-ext v2.3.0-next.43

@superdoc-bot
Copy link
Copy Markdown
Contributor

superdoc-bot Bot commented Apr 22, 2026

🎉 This PR is included in template-builder v1.6.0-next.6

The release is available on GitHub release

@superdoc-bot
Copy link
Copy Markdown
Contributor

superdoc-bot Bot commented Apr 22, 2026

🎉 This PR is included in esign v2.3.0-next.43

The release is available on GitHub release

@superdoc-bot
Copy link
Copy Markdown
Contributor

superdoc-bot Bot commented Apr 22, 2026

🎉 This PR is included in superdoc v1.28.0-next.6

The release is available on GitHub release

@superdoc-bot
Copy link
Copy Markdown
Contributor

superdoc-bot Bot commented Apr 22, 2026

🎉 This PR is included in superdoc-cli v0.8.0-next.6

The release is available on GitHub release

@superdoc-bot
Copy link
Copy Markdown
Contributor

superdoc-bot Bot commented Apr 22, 2026

🎉 This PR is included in superdoc-sdk v1.6.0-next.42

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants