joomla / joomla-framework

[READ-ONLY] This repo is no longer in active development. Please see https://github.com/joomla-framework for the individual Framework packages.
http://framework.joomla.org
GNU General Public License v2.0
189 stars 140 forks source link

Port API packages from CMS #297

Closed mbabker closed 9 years ago

mbabker commented 10 years ago

There are some API wrappers written over the last couple of years that were contributed to the Platform and CMS (all now reside in the CMS) that aren't present here. Where able, we should reach out to those contributors to see if they're willing to port those packages into the Framework. If they're unable, this could be a good project for someone who is interested in becoming more familiar with namespacing code that previously wasn't.

eddieajau commented 10 years ago

None of those seem particularly well represented on Packagist so it would be good for us to pick them up. Something to would be is there a support package for API where we can suck out the common code.

piotr-cz commented 10 years ago

The JForm package has got some new - cool functionality: GSOC Project 'Improve Form Fields'.

eddieajau commented 10 years ago

I think we should have a "meeting" about what to do with the Form package. I think we need a good plan about how to build it better.

mbabker commented 10 years ago

Agreed. As it stands today, it's really a relic of CMS style development. There's certainly use for a Form package in our Framework, but not in the current shape it's in.

piotr-cz commented 10 years ago

I really like the Form package, but not having an easy option to override Fields HTML output drives me crazy.

abemedia commented 10 years ago

I'd be happy to bring the Form package up to scratch as I already have made various amendments on my local version. Should I include all the new fields introduced in https://github.com/joomla/joomla-cms/pull/1842? I however prefer the XML attribute for the placeholder to be called placeholder rather than hint.

piotr-cz commented 10 years ago

@abeMedia There was a discussion about refactoring the Form package: https://github.com/joomla/joomla-framework/issues/303

Personally I like how Symfony2 is using special attributes because you may stick anything inside:

public function buildForm(FormBuilderInterface $builder, array $options)
{
    $builder->add('field', 'type', array(
        'label' => 'fieldLabel',
        'required' => true,
        'attr' => array(
           'placeholder' => 'Field placeholder'
        )
    ));
}

BTW new home for Form is here: https://github.com/joomla-framework/form and I think that and the Framework User group are propitiate places for discussion.

abemedia commented 10 years ago

@piotr-cz Thanks for the pointers. Have posted in the group.

abemedia commented 10 years ago

And yes I definitely like that with the attributes! I was just thinking about how best to go about data-attributes but that approach is perfect.

spignataro commented 10 years ago

This looks to have been not made it in the Joomla! 3.3 package - yet advertised it is. Is there a reason why?

bweston92 commented 10 years ago

@piotr-cz and the fact you can't change the form control (i.e jform) after the form instance in created, that drives me crazy.