Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor Twig Compiler Pass #154

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dTatham
Copy link

@dTatham dTatham commented Dec 2, 2017

Hi!
I've added some basic support for SF4 and refactored the Twig template compiler pass to allow for a configuration parameter rather than automatically picking a template (needed it to squish the country widget into an input-group)

Still open:

  • updated doc
  • didn't look at the PHP templating stuff as I'm not familiar with it

This is my first PR, so if there's anything missing please let me know :)

@piotrantosik
Copy link

SF4 compatibility exist and waiting for merge in #153

@dTatham
Copy link
Author

dTatham commented Dec 4, 2017

Okay, I’ll wait for the merge and rebase if necessary

@robhogan
Copy link
Member

@dTatham At least some of this has been covered by other PRs - could you rebase so we can check whatever's left? Thanks.

Switched to relying on configuration to pick the template

Signed-off-by: Daniel Zauner <daniel@zauner.email>
@dTatham
Copy link
Author

dTatham commented Jan 12, 2018

Alrighty, here's what's left after the rebase:

  • Switched to relying on configuration to pick the template (as prelude to turning it into a SF4 recipe).
  • Introduces a new parameter misd_phone_number.template which makes it easier to modify the Twig form theme.
  • Extended the if/else sequence by bootstrap 4 template
  • I kept the if/else sequence which ensures the template is dropped in right behind the form theme to keep the PR as minimally invasive as possible; however - with the growing number of form themes, should this be dropped in favor of simply dropping in the phone number theme last?

I'm not sure if DependencyInjection/Compiler/FormPhpTemplateCompilerPass.php needs an update as well as I'm not familiar with Symfony PHP theming.

@dTatham dTatham changed the title Feature/sf4 bump Refactor Twig Compiler Pass Jan 12, 2018
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.

None yet

3 participants