Skip to content

Add read-only summaries for Symfony Forms - #1

Merged
alkinbg merged 6 commits into
mainfrom
feature/form-summary
Oct 14, 2026
Merged

alkinbg merged 6 commits into
mainfrom
feature/form-summary

Conversation

@alkinbg

@alkinbg alkinbg commented Oct 14, 2026

Copy link
Copy Markdown
Owner

Summary

Introduce FormSummaryBundle: reuse an existing Symfony FormView to display a read-only summary without maintaining a second field definition.

  • Add form_summary(), form_summary_row() and form_summary_value() Twig functions using Symfony's native form-theme mechanism.
  • Reuse field labels, selected choice labels, translation settings and transformed view values, including nested forms and collections.
  • Support field exclusion with summary: false, custom textual values with summary_value, and configurable empty placeholders. Preserve zero and false values.
  • Exclude password, hidden, file, repeated and button fields, including CSRF tokens and descendants of excluded fields. Escape output and reject automatic serialization of arbitrary objects.
  • Keep summaries repeatable without marking form fields as rendered.
  • Include English and Bulgarian boolean translations, installation and customization documentation, and an MIT license.

Verification

Verified CI run for commit 80e8c0560ad5b1b15636c0d90da3801688706419 passed all five jobs:

PHP Symfony
8.2 6.4
8.3 7.4
8.4 8.0
8.4 8.1
8.5 8.1

Each job runs Composer validation, PHPUnit, PHPStan level 8 and PHP syntax checks. The suite contains 53 tests and 121 assertions, including a real Symfony kernel integration test with CSRF enabled.

Scope

This initial implementation only renders form views. It does not persist data, authorize access, validate submissions, introduce a workflow engine, or publish a release. The README includes development-branch installation instructions; no Packagist release or Flex recipe is assumed.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 80e8c0560a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@alkinbg
alkinbg force-pushed the feature/form-summary branch from ffda40a to 80e8c05 Compare October 14, 2026 08:06
@alkinbg
alkinbg marked this pull request as draft October 14, 2026 08:19
Repository owner deleted a comment from chatgpt-codex-connector Bot Oct 14, 2026
Repository owner deleted a comment from chatgpt-codex-connector Bot Oct 14, 2026
@alkinbg
alkinbg merged commit 80e8c05 into main Oct 14, 2026
20 checks passed
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.

1 participant